Custom pcb with onboard kitprog psoc -how to ?

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

cross mob
EyLa_1625036
Level 3
Level 3
10 likes given 10 sign-ins 25 replies posted

Hello all , 

I want to design a custom pcb with PSOC5LP on it , but I want to eliminate 

The need for an external miniprog3 programmer to program that PSOC5LP (I want to program it through USB connector ) , 

I don't want the 10pin header on my board , 

I have looked how they did that in the evaluation board's (psoc5 059 , psoc4 pioneer kit ) , 

I can see they have another PSOC device that they are calling (kitprog) that is connected to usb data lines , 

And this kitprog PSOC is connected to a target PSOC device with the SWD lines (see attached block diagram ),

I have a couple of questions regarding that :

1.can Any psoc device be used as an KITPROG device ?(I want a small as possible psoc package , psoc5lp only ? )

2.How do you program that initial KITPROG device ? (if I don't have the 10pin header and the miniprog3 )

3.Where is the firmware for this KITPROG device ? ( I can't find anything on this subject, but I guess you must have some kind of firmware in that KITPROG psoc device ) 

Can you share your experience with implementing a kitprog device in your boards ? 

any other lines that you must connect between KITPROG device and TARGET device except SWD lines ? (like reset ? ) 

kitprog_block_diagram.png

Thanks 

Eyal Lampel

 

 

 

 

 

0 Likes
1 Solution
Len_CONSULTRON
Level 9
Level 9
Beta tester 500 solutions authored 1000 replies posted

Eyal Lampel,


I can see they have another PSOC device that they are calling (kitprog) that is connected to usb data lines


This is true.  This is a Cypress/Infineon boot-loadable USB interface that implements the 5-pin SWD programming/debugging interface to the target PSoC5.


2.How do you program that initial KITPROG device ? (if I don't have the 10pin header and the miniprog3 )


In order to eliminate the 5-pin SWD or 10-pin JTAG programming/debugging header, you would need to preprogram a PSoC5 with the firmware you intend to use BEFORE soldering it to the PCB.


3.Where is the firmware for this KITPROG device ? ( I can't find anything on this subject, but I guess you must have some kind of firmware in that KITPROG psoc device ) 

 

 You will have to contact Infineon if they are willing to release this KitProg code to you.


1.can Any psoc device be used as an KITPROG device ?(I want a small as possible psoc package , psoc5lp only ? )

 

 The KitProg code is designed to be loaded into specific PSoC5LPs.


any other lines that you must connect between KITPROG device and TARGET device except SWD lines ? (like reset ? ) 

 

 On the KitProg board to target board interface there are 4 more wires that are routed that are NOT a part of the 5-pin SWD interface.  These extra wires support the I2C and UART communication between the two boards.

Len_CONSULTRON_0-1675549088311.png

Len
"Engineering is an Art. The Art of Compromise."

View solution in original post

10 Replies
Len_CONSULTRON
Level 9
Level 9
Beta tester 500 solutions authored 1000 replies posted

Eyal Lampel,


I can see they have another PSOC device that they are calling (kitprog) that is connected to usb data lines


This is true.  This is a Cypress/Infineon boot-loadable USB interface that implements the 5-pin SWD programming/debugging interface to the target PSoC5.


2.How do you program that initial KITPROG device ? (if I don't have the 10pin header and the miniprog3 )


In order to eliminate the 5-pin SWD or 10-pin JTAG programming/debugging header, you would need to preprogram a PSoC5 with the firmware you intend to use BEFORE soldering it to the PCB.


3.Where is the firmware for this KITPROG device ? ( I can't find anything on this subject, but I guess you must have some kind of firmware in that KITPROG psoc device ) 

 

 You will have to contact Infineon if they are willing to release this KitProg code to you.


1.can Any psoc device be used as an KITPROG device ?(I want a small as possible psoc package , psoc5lp only ? )

 

 The KitProg code is designed to be loaded into specific PSoC5LPs.


any other lines that you must connect between KITPROG device and TARGET device except SWD lines ? (like reset ? ) 

 

 On the KitProg board to target board interface there are 4 more wires that are routed that are NOT a part of the 5-pin SWD interface.  These extra wires support the I2C and UART communication between the two boards.

Len_CONSULTRON_0-1675549088311.png

Len
"Engineering is an Art. The Art of Compromise."

@Len_CONSULTRON Thank you for the detailed response ! 

The fact that you have to pre-program the kitprog device and 

The fact that   KitProg code is not releasable pretty much make 

It not worth it for me ( i will just connect the 10 pin header ) 

Thanks again  

0 Likes
Len_CONSULTRON
Level 9
Level 9
Beta tester 500 solutions authored 1000 replies posted

Hi,

What is your ultimate goal? 

Placing 5 inline pads for a SWD interface to the target PSoC5 doesn't take much room on a PCB.  There are ways to make it very compact.

Having the 5-pin SWD interface has advantages of allowing the PSoC5 to be soldered to the PCB first then programmed.   Additionally, during development, the SWD can be used to debug your project to eliminate issue before they get to production.

Len
"Engineering is an Art. The Art of Compromise."

@Len_CONSULTRON 

I was facing a problem that the 10pin header FTSH-105-01-L-DV-K-P-TR height is too much for

my system , so i was searching for a way to eliminate that header .

0 Likes

There are so called POGO pin connector, which are used to program microcontrollers on the PCBs. Google it on the internet. Basically, you leave 5 pads on the PCB and stick a POGO plug only for programming. It takes no space and has no cost. 

As a cheap alternative, you can put 5 thru holes in W pattern shifted by 100um so that standard C-grid connector can be plugged with some tension

@odissey1 wow Thank you ! 

I didnt know about the POGO pin connector ...

I can even use that on my other designs .

Yea that solve the height  issue ...

Do you have p.n for a specific pogo  pin pogo connector (and his mating cable )

with some stock in mouser or digykey ?? 

Thanks!

 

0 Likes

There is well known manufacturer for POGO pin JTAG connectors, which has a variety of configurations. I would use a simple 5-pin, soldering it directly to the KitProg with short <2" cable (not sure about power lines, please consult someone). Or use a PSoC programmer stick, which  can be configured where the power comes from.

https://www.tag-connect.com/

TC2050-IDC JTAG connector - DigiKey  

@odissey1 Thanks !

Your replay was really helpful.

best regards

0 Likes
BiBi_1928986
Level 7
Level 7
First comment on blog 500 replies posted 250 replies posted

Hello.

If you want the functionality of Kitprog on your custom pcb, then maybe you implement Kitprog.  This lets you use Creator Debug and Program, as well as PsoC Programmer.  If you ever need to re-program Kitprog, you only need 5 copper test points (for Kitprog 5LP SWD) that you can access with 'pogo pins', otherwise known as a 'bed-of-nails'.  You can use another Kitprog or Miniprog to re-program the pcb Kitprog.  Actually, you'll need it anyways because this is how you'd get the code into the pcb Kitprog in the first place.

To answer your questions:
1) Yes, any PSoC with USB could be programmed to function as Kitprog, but you have to write the code.  For example, PSoC 4200L has a USB port.  Most 5LP PSoC have USB (a few don't, check datasheet).

You could also use an FTDI bridge chip (USB to UART, SPI, I2C) and put a Bootloader in target 5LP on pcb.  Not necesssary to integrate a Kitprog.  You'd still need to pre-program 5LP on pcb with Kitprog or Miniprog.

2) If using 5LP as Kitprog (or any PSoC as Kitprog function), it needs to be pre-programmed before being soldered to pcb, or, you need to provide access to this 5LP SWD signals using a connector or "pogo pins".  You can use a real  Kitprog to program the 5LP or, use the Kitprog residing on a Pioneer board (just add some jumpers and remove 2 resistors).

3) Kitprog firmware source code is Cypress proprietary and not released.  A hex image is available to program Kitprog in one of the Creator installed folders (I think it's in the PSoC Programmer folders which gets installed as part of Creator).  A Kitprog can be restored with this image by using another Kitprog as the programmer, or with Miniprog via the SWD signals.  BTW, this image can only be programmed into the 5LP device code of a real Kitprog.

If you do want to invent another Kitprog, there are plenty of articles to read on Cypress website, as well as articles on Bootloaders.
CY8C58LP, CY8C56LP, CY8C54LP, CY8C52LP PSoC® 5LP Device Programming Specifications (infineon.com)
PSoC™ Creator - Introduction to bootloaders (infineon.com)

Don't under estimate the effort to design a Kitprog programmer.  That's only one half the equation.  You then need to consider the PC software (or Mac, or Linux) that will drive the programmer.  If you want to use existing tools, then you'll need a real Kitprog.  Otherwise, lots of coding.  There are more Cypress articles on how to do this as well.  See this recent discussion:
Re: Does anybody have Source Code for a C# Project... - Infineon Developer Community

So, stuff is out there for you to use.  Lots of things to consider.
Good luck with your project.

edit: Len types faster than me.  Sorry for some repetition in my response.

@BiBi_1928986 

Thank you for the detailed response ! 

The fact that you have to pre-program the kitprog device and 

The fact that   KitProg code is not releasable pretty much make 

It not worth it for me ( i will just connect the 10 pin header ) 

Thanks again  

0 Likes