How to design an On-board Programming Interface with PC through a USB connector

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

 Hello everyone,

   

We've implemented our real-time application using CY8CKIT-050 PSoC®5 Development Kit. Now we are trying to design our own board. An on-board programming interface with pc through a usb connector is required to write program to the PSoC5 chip. But we don't know how to design this part. 

   

Up to now, I found two ways to make it possible. One is FX2LP programmer circuitry from Kit-050.  Another one is MiniProg3 which is kind of expensive for us. We are wondering if there are other methods to implement an On-board Programming Interface. Thank you so much !

   

Best Regards,

0 Likes
5 Replies
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

Some possibilities / examples -

   

 

   

    

   

          

   

http://www.cypress.com/?app=forum&id=2233&rID=71536

   

 

   

http://www.cypress.com/?app=forum&id=2232&rID=56007

   

 

   

http://www.cypress.com/?rID=44530

   

 

   

And of course bootloaders –

   

 

   

http://www.cypress.com/?rID=50230     AN68272 UART BL     PSOC 3, 4, 5LP

   

http://www.cypress.com/?rID=41002     AN60317 I2C BL         PSOC 3, 5LP

   

http://www.cypress.com/?rID=57561     AN73503 USB HID BL with GUI Host     PSOC 3, 5LP

   

http://www.cypress.com/?rID=56014     PSoC® 3, PSoC 4, and PSoC 5LP Introduction To Bootloaders

   

http://www.cypress.com/?rID=83293     AN86526 - PSoC® 4 I2C Bootloader

   

 

   

Regards, Dana.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

A PSoC5 allows for a USBUART Bootloader. This would require an initial programming at your factory (Using a MiniProg 3) and at the customer's site a PC and a (free) Cypress Program will be used. The advantage is that no additional hardware except the USB-plug and a cable will be required.

   

 

   

Bob

0 Likes
Anonymous
Not applicable

 Thank you! The EZ-USB-FX1 based PSOC 3/5 programmer is what I'm looking for. 

0 Likes
Anonymous
Not applicable

 Copying from my post to reddit's /r/PSoC (which is stuck in the spam filter):

   

I recently purchased a number of the PSoC5LP SchmartBoards[1] . They are designed to work with a bootloader for programming, but I wanted to be able to program the chip directly.

   

The CY7C68013A (FX2LP) chip works as a programmer for the PSoC5LP, and there are boards[2] on eBay for cheap that use that chip.

   

The LCSoft board is intended to run as a knock-off Saleae Logic. Modern versions of the software break many of these clones, but it's easy enough to convert them. The EEPROM holds the device IDs and can optionally store the firmware we want - in this case, the FX2 programming firmware.

   

The first step is to remove the jumper and boot it. Install and fire up CyConsole[3] , and use hex2bix to convert the firmware to an IIC file for programming. In the Suite USB directory, there is a utility at Firmware\bin\hex2bix.exe. Run it as so:

   
    

hex2bix -M 0x8000 -i "[path to fx2lp_fw.hex in PSoC programmer Service directory]" -F 0xC2 -O "[output file].iic".

   
   

This creates an iic version of the firmware which can be programmed to the EEPROM. Replace the jumper, and in CyConsole, go to Options, EZ-USB. Here you will find the "Lg EEPROM" option (because these boards have a larger EEPROM), and can select the iic file created earlier. Reset the board, and it's now a programmer.

   

The next step is to program the SchmartBoard itself. If you don't have a programming header handy, an alternative is to use USB to program the device in SWDIO mode (as described in KBA82881[4] ). If you cut open a USB cable, you will generally have green as D+ and White as D-. This corresponds to SWDIO and SWDCK, respectively. Solder some headers on to the four wires, and you have almost everything you need to program.

   

Although there is a pin labeled XRES on the SchmartBoard, it's for the EEPROM (not the PSoC). To get access, pin 10 on the JTAG header needs to be accessed. I used a probe I had lying around. This connects to PB2 on the board (Reset).

   

Next, the green wire (SWDIO) is connected to PD0, and the white wire (yellow in my picture) is connected to PD1. Red and Black are connected to +3.3 and ground (yes, this means that USB is 3.3v instead of 5). Connect the USB header, acquire, and program.

   

What it looks like: http://imgur.com/a/JIxwi[5]

0 Likes
Anonymous
Not applicable

The previous post I made is about programming through the USB connector specifically, rather than just programming through a USB programmer.  It still requires access to the reset pin, but it can likely be made to use power cycling instead, if there is an interest in that.

0 Likes