dimhoff / si4010prog

Programmer/Debugger for Silicon Laboratories SI4010 MCU
Other
21 stars 5 forks source link

Help with FX2 #2

Closed markusdd closed 12 months ago

markusdd commented 12 months ago

Hi,

I have an FX2 mini board here and I can get the tool to connect after building the driver, but I am lost as to how to connect it physically. The README uses pin designators I do not have. I have PA0-x PB0-x PD0x, some CTL pins, an SDA and SCL etc.

I tried using the oscilloscope but cannot find anything.

This is my board Lcsoft-miniboard-front

(I have pulled J1 so it comes upo as the generic Cypress EZ-USB that the driver expects)

When I use it I always get back 0x00 for both Device and Revision ID from s4010prog identify

dimhoff commented 12 months ago

Hi,

First of all did you black list the usbtest module? If you run lsmod and see the usbtest module you need to unload it and blacklist it

echo 'blacklist usbtest' | sudo tee /etc/modprobe.d/si4010prog.conf

I used the pin names of the SI4010 chip. But the pin naming on the board is quit logical: PA1 == IOA.1; PA2 == IOA.2. Here is how I connected a RFM60S module:

20231119_140830

Finally you should load the c2_fx2 firmware into the FX2 device. This can be done using cycfx2prog:

sudo cycfx2prog prg:c2prog.ihx run

Now when you run si4010prog identify:

$ sudo ./si4010prog identify
Device ID: 0x24; Revision ID: 0x02
markusdd commented 12 months ago

Thanks for your quick response!

usbtest is not present on the Fedora I am using, I checked for that following your README

I guess the issue I am having is that I missed that I need to load the fx2 firmware by myself, I thought this gets pushed as a driver once the device is being enumerated by si4010prog, so that will be my problem.

I will try this and get back to you shortly, thanks so much for the help!

markusdd commented 12 months ago

ok next question right away: how do I generate this firmware ihx file?

I ran your normal cmake build and si4010prog is running fine, but I do not find this firmware.

markusdd commented 12 months ago

ok, I just figured out the driver is built using it's own makefile, and newer distributions package sdcc differently and the generic executable is now called sdcc-sdcc, so I needed to hack the makefile.

I now have ID reading working. And flashing as well!

Thanks so much for this amazing little toolkit, in case you need a Tesla Chargedoor opener hit me up ;)

F_TuQ3jXMAAewnr F_TuRL6W0AAlqjk

dimhoff commented 12 months ago

Good to hear it works:)