Reply
Posts: 4
Registered: ‎07-28-2015
Accepted Solution

Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

I'm trying to add the OTA client cluster to my app on an EM357 connected to an EM35x Dev Board Rev C.  I installed the app-bootloader-spi-at45db021d.s37 bootloader along with the app, but on startup the app crashes somewhere in emberAfPluginEepromRead().  I can't single-step deep enough to find where it crashes, but there's eventually a watchdog timeout.

 

Am I using the correct bootloader (as listed in AN728) for this dev board with a Winbond W25Q80BCSNIG chip?

 

I have the jumpers J34 to J37 set to SC2.  The only jumper changes made from default board settings were to disconnect SC1 from the DEI port and connect it to the USB connection.

 

Here's the stack dump from when it comes back:

Reset info: 0x05 (WDG)
Extended Reset info: 0x0502 (LWM)
Handler mode using main stack (200010E0 to 20001A48), SP = 20001868
520 bytes used (22%) in main stack (out of 2408 bytes total)
No interrupts active
Reset cause: Watchdog caught with enhanced info
Instruction address: 08000890
R0 = 456D6953, R1 = 61642045, R2 = 203A6174, R3 = 20323833
R4 = 64726F77, R5 = 666F2073, R6 = 35303120, R7 = 530011D1
R8 = 35200A0D, R9 = 30303235, R10 = 39353332, R11 = 72646430
R12 = 20383034, R13(LR) = FF0A3732, MSP = 20001868, PSP = 00011004
PC = 08000890, xPSR = 01000000, MSP used = 00000208, PSP used = 00000000
CSTACK bottom = 200010E0, ICSR = 00000802, SHCSR = 00070000, INT_ACTIVE = 00000000
CFSR = 00000000, HFSR = 00000000, DFSR = 00000000, MMAR/BFAR = E000ED34
AFSR = 00000000, Ret0 = 0801F7AB, Ret1 = 0801F835, Ret2 = 0801F86D
Ret3 = 0801F91F, Ret4 = 0801EFEB, Ret5 = 08007EA5, Dat0 = 00000000
Dat1 = 00000000

 

Next steps?  Am I missing something in the setup?

 

-Tom

Posts: 183
Registered: ‎03-31-2014

Re: Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

Hello Tom,

 

Looks like your jumpers are set correctly. For the bootloader you shoud be using app-bootloader-spiflash.s37 found in /tool/bootloader-em357/app-bootloader-spiflash/

 

Cheers,

Konrad

Posts: 4
Registered: ‎07-28-2015

Re: Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

Hmmm.  Not much better.  Fails an assert from ota-storage-eeprom-read-modify-write.c:

 

 

void emAfOtaStorageEepromInit(void)
{
  // Older drivers do not have an EEPROM info structure that we can reference
  // so we must just assume they are okay.  
  if (emberAfPluginEepromInfo() != NULL) {
    // OTA code must match the capabilities of the part.  This code
    // assumes that a page erase prior to writing data is NOT required.
    assert((emberAfPluginEepromInfo()->capabilitiesMask
            & EEPROM_CAPABILITIES_PAGE_ERASE_REQD)
           == 0);
  }
}
[ASSERT:ota-storage-eeprom-read-modify-write.c:100]
Reset info: 0x07 (CRS)
Extended Reset info: 0x0701 (AST)
Handler mode using main stack (200010E0 to 20001A48), SP = 20001960
480 bytes used (20%) in main stack (out of 2408 bytes total)
No interrupts active
Reset cause: Assert ota-storage-eeprom-read-modify-write.c:100
R0 = 30300A0D, R1 = 30303330, R2 = 20303333, R3 = 20323833
R4 = 64726F77, R5 = 666F2073, R6 = 35303120, R7 = 3A0011D1
R8 = 2D61746F, R9 = 726F7473, R10 = 2D656761, R11 = 72706565
R12 = 722D6D6F, R13(LR) = 2D646165, MSP = 69646F6D, PSP = 00011004
PC = 080048E0, xPSR = 61000000, MSP used = 000001E0, PSP used = 00000000
CSTACK bottom = 200010E0, ICSR = 00000806, SHCSR = 00070008, INT_ACTIVE = 00000000
CFSR = 00010000, HFSR = 00000000, DFSR = 00000000, MMAR/BFAR = E000ED34
AFSR = 00000000, Ret0 = 0801F81D, Ret1 = 0801EEF9, Ret2 = 08008575
Ret3 = 08008587, Ret4 = 08015BC3, Ret5 = 08019415, Dat0 = 0801F778
Dat1 = 00000064
Posts: 183
Registered: ‎03-31-2014

Re: Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

Hello Tom,

 

Do you have "EEPROM Device Read-modify-write Support" enabled in AppBuilder in the OTA Simple Storage EEPROM Driver Plugin? The winbond part does not have this feature.

 

Cheers,

Konrad

Posts: 4
Registered: ‎07-28-2015

Re: Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

That finally did it.  Between changing the bootloader and turning off read-modify-write support I'm now booting without crashing.

 

Thanks!

Highlighted
Posts: 6
Registered: ‎09-23-2016

Re: Problems accessing serial flash with EM357 on EM35x Dev Board Rev C

Hello,

 

I am working on EM3588 chip (ZigBee). I would like to change the reset time of the watchdog timer. I used the appbuilder to configure the project. Where could I modify it? Could anyone please help me?

 

Thank you in advance!

Best Regards,

 

Aniketh