1 of 1 people found this helpful
Cool. Is there a Linux version of the CLI? Don't really want to use Windows/DOS.
PSoC Programmer is Windows only AFAIK.
There's also the option of using the COM interface:
and building the functionality into a custom .NET application.
There's an open source .NET implementation for linux called mono that would maybe run the application, but drivers for the miniprog3 and whatnot would probably be a problem. Looks like their solution for MacOS/Linux is a VM.
I have just started to try using openocd to program a PSOC 5LP. There is apparently PSOC 4 support in openocd already, I can't say as I have not tried using it; but, PSOC 5 is only in the development branch. That said, the code appears to have been in development for the last two years and so it appears to be fairly mature for development code. To get the code, I did the following:
git clone http://openocd.zylin.com/openocd zylin-openocd
git fetch http://openocd.zylin.com/openocd refs/changes/32/3432/26
git cherry-pick FETCH_HEAD
./configure --enable-sysfsgpio --enable-bcm2835gpio --enable-vslink --enable-luminary-icdi --enable-kitprog
sudo make install
I am using a kitprog adapter snapped off a CY8CKIT-059, but also want to be able to use a couple other interfaces just in case, you may want to adjust the "./configure" line to suit your needs. Good luck finding the enable options if you want changes though - openocd documentation sucks.
One note, the install does not copy udev rules to the proper location, you need to run
sudo cp /usr/local/share/openocd/contrib/60-openocd.rules /etc/udev/rules.d
or something very similar, not 100% sure I did not capture that step in my notes. If you do not copy the udev rules normal users cannot run openocd and actually access hardware.
From there I've successfully started openocd, found the right dongle and located a target with:
openocd -f interface/kitprog.cfg -c kitprog_init_acquire_psoc -f target/psoc5lp.cfg -c "telnet_port 4444"
I have not yet been able to usefully program a FLASH image, and when I have tried it has run very slowly. I can't say if actually writing FLASH is faster than my failed attempts but the failures take quite a while to come back.
If you are interested in investigating further, I'd suggest looking at the examples section of Cypress PSoC · azonenberg/openfpga Wiki · GitHub . At least the build information is outdated and did not work for me, I had to adapt. I will start looking at his programming / erasing stuff in more depth shortly but you may want something sooner than I get around to it. If you try to move ahead yourself and make any headway please post an update. I hate having to use Windows just to use a PSOC.