@mohit @mdma @peekay123
I am having an issue with the flashee library freezing the E0 module when a read or write is issued. Would it be possible for one of you to test to see if the flashee library works with the external flash MX25L4006EM1I-12G (512Kb) or MX25L8006EM1I-12G (1Mb) chips?
I am trying to do final testing for our new product but this is the only piece preventing any further development.
I tried it but it appears to be freezing the E0 and then it just goes into an endless reset loop once it tries to read or write to the chip. I also tried looking into the code itself but I’m not familiar with the code structure.
It does not appear that the flashee library will work with the E0 as it was designed to work with P1’s external flash memory. On the E0 module, the FLASH chip is connected to a different SPI channel of the microcontroller. You’ll have to make changes in the code accordingly.
@mdma do you know if the library can be modified easily?
@mohit thanks for looking into this. Do you know off hand what channel its running on?
@wesner0019 Going by the pin definition in platform_config.h, the external FLASH on P1 is connected to SPI2 channel of the STM32 micro.
@mdma do you think the flashee library can be updated to work with spinach channel 2? I see from the code that it references a particle spi_flash.h library. I’m guessing that this works with channel 1 but not channel 2.
@wesner0019, have you considered using SPIFFS?
@peekay123, we’ve looked into it but our current deployed 500 products are already using the Flashee and we wanted to make it as compatible as possible between the Eseries and the P1.
@mdma @peekay123 do you think the spi_flash.h needs to be copied and then modified to some think like spi2_flash.h to get the Flashee Library working? Then this could be called to for the flash to work on the eseries boards.
It looks the spi_flash point to the hw_config files starting at line 682 @ https://github.com/particle-iot/firmware/blob/ad64959eac6e3e3e68c1e17ef817e5bbbf1dca29/platform/MCU/STM32F2xx/SPARK_Firmware_Driver/src/hw_config.c
Then the pins are configured within this file: https://github.com/particle-iot/firmware/blob/273b422659536b492e163f236b4c9dcb94a044da/platform/MCU/STM32F2xx/SPARK_Firmware_Driver/inc/platform_config.h
After looking into this it doesnt look like the Flashee Library can be easily updated to work with the eseries, since it eventually point to particle supplied configuration files. These would need to be updated by particle to avoid local compiling
Or the flashee library needs to include its own reduced hardware configuration files which would likely take up precious memory.
Thoughts? We are stuck on a response for this for our hardware development.