AnsweredAssumed Answered

BF527-ezKit SPI flash and touch screen driver, using both at the same time

Question asked by tcmichals on Feb 1, 2010
Latest reply on Feb 1, 2010 by vapier

There are two good examples using SPI (Max1233Example)  and BF527EzFlashDriver_M25P16.


I'm confused that the FlashDriver for the SPI is accessing the SPI directly and not using adi_device_access layer to the SPI driver, is there a reason?


Where the question is, lets say, I wanted to use the SPI flash and the touch screen at the same time.  It seems to me that the Flash driver does not use the adi_device_access APIs to access SPI, so would this cause an issue?  Since all of the thread locking is done is the adi_device_access API?


The reason for asking, I have a need to access multple devices using SPI; flash and LCD.  Just want to make sure I understand the issues of mixing the types of accesses to the SPI.  Or I'm just not understing it?


For example, in adi_m25p16.c WriteFlash... accesses the SPI directly, if I don't add some high level mutex it could be possible to access the SPI from two different threads ie LCD update and write flash..


Just confused...