Cloud Flash and Local Flash

Hello @rickkas7

I have the device firmware built on Tracker Edge Firware version 17

I have an External EEPROM used to store the Non-Volatile data from. for this i am using the SPIFlashRK library. I had to change the manufacturer ID for the EEPROM in SPIFlashRK.
inside this class
class SpiFlash : public SpiFlashBase
}

/**
* @brief The expected manufacturerId, used by isValid(). This is overridden by flash-chip-specific subclasses.
*/

||uint8_t manufacturerId = 0x20;|

{

0x20 is the ID of my EEPROM

and when i FLASH locally vis USB i am able to read this ID and do the read write operations and everything works fine.

but when i do the Cloud FLASH from the command pallete of the work bench Flash is scuccess but I am not getting the read ID as 0x20 and it says EEPROM not found in the Log as i have written.

I am not sure, what is wrong, is it possible that when i do Cloud Flash the Cloud is compiling this against original SPiFlash RK library or the one one in my project with my manufacturer ID modified if it is also compiling ?

also is there any other way to Flash only the binary via cloud from command Pallette or the CLI ?

Thanks

It's not clear why this is happening. I'd guess it's probably timing related, but I can't think of why it should matter. Instead of trying the flash once during setup() I'd change it to try a few times during loop or until it succeeds, and see if that makes a difference.

You can OTA flash using the Particle CLI from a terminal window, but that's essentially what the command palette does, so it probably will not make a difference in this case.

This is the Log while doing Cloud Flash , may be you might get some Idea not sure yet

0000134852 [comm.ota] INFO: Received UpdateStart request
0000134852 [comm.ota] INFO: File size: 93398
0000134853 [comm.ota] INFO: Chunk size: 512
0000134854 [comm.ota] INFO: File checksum:
6c2db0b96569a928875eb5aa140b9fc9ce40e13eec38b29b85b05cc77aab6f94
0000134855 [comm.ota] INFO: Starting firmware update
0000135902 [comm.ota] INFO: Start offset: 0
0000135903 [comm.ota] INFO: Chunk count: 183
0000144553 [comm.ota] INFO: Received UpdateFinish request
0000144553 [comm.ota] INFO: Validating firmware update
0000145538 [comm.ota] INFO: Update time: 10686
0000145539 [comm.ota] INFO: Transfer time: 8121
0000145539 [comm.ota] INFO: Processing time: 3411
0000145540 [comm.ota] INFO: Chunks received: 208
0000145541 [comm.ota] INFO: Chunk ACKs sent: 169
0000145542 [comm.ota] INFO: Duplicate chunks: 25
0000145542 [comm.ota] INFO: Out-of-order chunks: 20
0000145543 [comm.ota] INFO: Applying firmware update

Hello @rickkas7

Apparently the Cloud compile is taking the dependencies as precedence and not considering my locally installed library changes, I commented the dependencies and then i do cloud compile and Flash every thing works fine Now. The Device is able to find the EEPROM and do work as expected.

Thanks & Regards
Dilip Kumar

Yes, that is the expected behavior; you need to comment out or remove the dependency to use a locally modified version when cloud compiling.

See Workbench pseudo libraries for more information.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.