Items used in this project
The CY8CKIT-049 is a 4$ prototyping kit with PSoC chip from Cypress Semiconductor based on ARM M0 MCU. It has following features :CY8CKIT-049
The first part of the kit is an USB-UART module which serves as a programmer. The Second part has CY8C4248AXI-083 PSoC chip (ARM M0 MCU), which comes with UART Bootloader allowing it to be programmed over UART protocol.
The problems I faces while programming this kit in some of my old projects are :
- Dodgy connection on USB Port during programming
- Limited power for External Circuits
- Heavy project hardware hanging from PC USB
- Plug and unplug again and again to reprogram
I was annoyed and stopped using these kits for a while.
The Solution is very simple:
- Add a reset button for power cycle before bootlodable programming
- Replace the USB-UART module with HC-05 Bluetooth Module
Snap the kit and solder necessary male/female pin header -Snapped, header soldered and Reset Button added
Solder the reset buttonPush switch between Reset and Gnd pin
- Connect the HC-05 to USB-UART module of the kit according to following diagram:-
- Connect to PC with a UART module in AT command mode while holdiing the 'key' button on HC-05 module
- A new port should appear as follows
Open Arduino IDE >> tools >> Port and select the new USB serial port. Next Open serial monitor and select 38400 ( which is AT command mode baud )
Now apply following AT commands in the Arduino serial monitor one line at a time and press send
AT AT+UART = 115200,0,0 AT+RESET
This will change the baud rate of HC-05 to 115200, which is required for programming the main part of the PSoC kit .
Go to Windows Bluetooth option and pair HC-05, new virtual com port will be installed after successful pairing.Adding HC-05 to Windows PC We will use the green one
Now connect the HC-05 to the main part of the CY8CKIT-049 which has the mcu. See Schematic below for details.Connection between PSoC4 and HC-05
- Open "PSoC Creator (4.2)" and compile the example "Bootloadable Blink LED" program.
- Press & hold the Bootloadable button, press the reset button, release both button to enter programming mode.
- Then go to Tools >> Bootloadable Host >> Select the Bluetooth Serial Port with Baud 115200.
- Next click the upload to program wirelessly.