Hi Guys,
I really had some hard days trying to figure out, why this damn external SPI-Flash didn't answer, although I had no problems with it in former times.
It's hard to belive, but there were quite different SPI signals on my logic analyzer compiling the same SPI 'read' procedure with FC5 and with FC6 on the ATMega 328 !!
The SIN (MOSI on the ATMega) produces with FC6 a quite strange signal, especially on the 'read' command.
With FC5 everything is fine.
Please have a look on the attached pictures and please provide a quick fix or help me to find a workaround, because I need to finish my project urgently.
Btw, this symptoms occur on many SPI devices (I tried different EE /Flash -chips), but strangely enough there are also devices like RTC-chips that have no problems with the incorrect signals on FC6 and give the right answer....
Hope you could help!
Many thanks!!
Niro
!! SPI-protocol compiling ERROR with FC 6
Moderator: Benj
-
- Posts: 77
- Joined: Mon Jan 03, 2011 8:58 pm
- Has thanked: 29 times
- Been thanked: 10 times
- Contact:
!! SPI-protocol compiling ERROR with FC 6
- Attachments
-
- FC6_SPI_read_ERROR.jpg (83.49 KiB) Viewed 6400 times
-
- FC5_SPI_read_OK.jpg (87 KiB) Viewed 6400 times
- LeighM
- Matrix Staff
- Posts: 2178
- Joined: Tue Jan 17, 2012 10:07 am
- Has thanked: 481 times
- Been thanked: 699 times
- Contact:
Re: !! SPI-protocol compiling ERROR with FC 6
Looks like you might need to check the SPI mode and clock phase, they are different between your V5 and V6 images,
-
- Posts: 77
- Joined: Mon Jan 03, 2011 8:58 pm
- Has thanked: 29 times
- Been thanked: 10 times
- Contact:
Re: !! SPI-protocol compiling ERROR with FC 6
Yes, that is right, but I found no option to change this in FC.
But what is more, what the SIN (MOSI) signal produces on the 'read' command seems to be wrong anyway, no matter which mode or the phase you choose.
If I'm wrong, please correct me.
Best regards,
Niro
But what is more, what the SIN (MOSI) signal produces on the 'read' command seems to be wrong anyway, no matter which mode or the phase you choose.
If I'm wrong, please correct me.
Best regards,
Niro
- LeighM
- Matrix Staff
- Posts: 2178
- Joined: Tue Jan 17, 2012 10:07 am
- Has thanked: 481 times
- Been thanked: 699 times
- Contact:
Re: !! SPI-protocol compiling ERROR with FC 6
Hi
The SPI component has properties here ...
When the component does a read it sends a dummy 0x55 on MOSI, it would be unusual for this to cause a problem.
Please try a change of the clock phase property and see if you then get a read.
The SPI component has properties here ...
When the component does a read it sends a dummy 0x55 on MOSI, it would be unusual for this to cause a problem.
Please try a change of the clock phase property and see if you then get a read.
-
- Posts: 77
- Joined: Mon Jan 03, 2011 8:58 pm
- Has thanked: 29 times
- Been thanked: 10 times
- Contact:
Re: !! SPI-protocol compiling ERROR with FC 6
Hi,
this properties window of the SPI component I already know and I have exactly the same configuration here.
And it is also the same configuration as in FC5, which works quite nice.
Any ideas?
Many thanks
Niro
this properties window of the SPI component I already know and I have exactly the same configuration here.
And it is also the same configuration as in FC5, which works quite nice.
Any ideas?
Many thanks
Niro
-
- Posts: 77
- Joined: Mon Jan 03, 2011 8:58 pm
- Has thanked: 29 times
- Been thanked: 10 times
- Contact:
Re: !! SPI-protocol compiling ERROR with FC 6
Hi,
yes, I tried, but it didn't work...
I then wrote the SPI initialization with standard c-code, as advised in the datasheet and did not use SPI macro from flowcode.
Now it works all fine.
Niro
yes, I tried, but it didn't work...
I then wrote the SPI initialization with standard c-code, as advised in the datasheet and did not use SPI macro from flowcode.
Now it works all fine.
Niro