Page 1 of 1

Maybe Issues with SPI update?

Posted: Tue Jul 23, 2019 2:23 pm
by Lord Grezington
Hello Everyone

I did a program a while back in FC6, I then did an update to the program where I needed to add Modbus Slave back in November last year. Back then it seemed to work fine, but now I am having issues... And its defenitly based on FC8 and its updates...

So, I have attacehd the FC6 Program that works fine once it get compiled from FC6. When I open from FC8.2 I need to set the RS232 component to no RX pin in order for it to compile (the RS232 is obsolete now anyway). Then when I test it on hardware the SPI does not work anymore as well as the output on A4. When I do a little blinker program (on A4) I can find out that it will work when I put the blinker before the SPI initialise, and will not work after it.

*EDIT* one more thing. I have changed the Auto CS for hte SPI on/off, this does nothing. Also when I use the correct pin for hte CS / SS it still does not work.

Hope this all makes sence, let me know if you need more information

Thanks

Re: Maybe Issues with SPI update?

Posted: Wed Jul 24, 2019 1:20 pm
by Benj
Hello,

I've looked at the SPI Initialise CAL code and there are no blocking functions there which could potentially cause a lockup.

Can you add a flasher to flash say twice before you do the initialise to see if the initialise is causing the MCU to reset?

You could also maybe try SPI channel 2 which has the remappable pins and see if this is any better.

Re: Maybe Issues with SPI update?

Posted: Wed Jul 24, 2019 1:40 pm
by Lord Grezington
Hi Ben

Thanks for the reply

I will try using channel 2 and remap the pins.

I dont think the SPI component starts the reset, I think it just prevents some of the other features working (like the flash on the pin)

Thanks

Re: Maybe Issues with SPI update?

Posted: Wed Jul 24, 2019 3:30 pm
by Lord Grezington
Hi Ben

Switching to Channel 2 and re-mapping the pins seems to have worked. Not sure why channel 1 is not working.

Thanks for your help