Solid magenta after a few minutes of flashing magenta?

What I was trying to show was not about the code compiling or working… just that every time it will cause the solid magenta light during the update. Must be something in the compiled code that doesn’t transfer nicely for whatever reason.

I’m not sure how it’s transfered and stored in part of the flash ready for the reboot but it doesn’t seem to get there

Are there any checksums or something that would stop the compiled code transferring at some point?

@Hootie81,

I’m fully aware of your problem and the problem seems to be `EDB`` somehow.

It doesn’t make sense for that behavior to be happening since the code runs great without any panic SOS code.

We need to dig into the EDB code and see what is the one causing the behavior!

Looks like the OTA was successful, but the checking failed which explains why it got stuck at Solid Magenta.

If the code downloaded was ok, it should pass the check and start blinking magenta and eventually get copied to the internal flash and become your new firmware :smiley:

Let me ping @satishgn and he might be able to pinpoint the problem since your 1st code is not too complicated.

I’m really interested to catch this :smiley: :rabbit:

If it helps I had the same problem with my doorbell code once… but changing a few lines fixed it so I moved on and forgot about it… it was very simple at the time and just had 2 tcp connections and checked a digital pin. Shame I didn’t save the code at the point that made it not work, I thought it was some bad code. . Like it normally is for me

If you mentioned TCP, i would say that maybe the sockets was all used up or something similar.

Let us see how we can resolve this with the help of :spark: HQ.

Thanks for your patience! :smiley:

Ok, I understand now. On OTA, I get blinking purple for several seconds then solid purple for a several more seconds then cyan, blinking cyan the breathing cyan. No red. However, the code that runs is the old code not the new code I attempted to OTA.

@peekay123, if you comment out the 2 lines i mentioned, OTA should work perfect.

That’s the result i got after doing some tests. You might want to try replicating that!

@Hootie81,

I did a live troubleshooting with @peekay123 for around 10-15 minutes and we found the issue.

Calling EDB twice would create a .bin while does not allow OTA to function properly when you flash the exact same .bin file. Flashing other firmware like tinker works though!


@satishgn @Dave , need your help on this one.

The code is here: https://dl.dropboxusercontent.com/u/36134145/db.zip

All you need to do is to flash this firmware once, try an OTA with the exact same .bin and it fails.

If you comment out Line 106 or 116, it works fine!

Thanks to @peekay123 for doing the tests with me before his bedtime :stuck_out_tongue:

1 Like

thanks for testing it out @kennethlimcp and @peekay123 hope it helps make this even easier to use. So far its been really great playing with the Spark and everyone on the forums are super helpful.

Im slowly getting back into the programming mentality, its been many many years since i did it at school!

2 Likes

@Hootie81,

the short solution right now as suggested by @peekay123 is to flash another code before flashing your updated code if you face the same “solid magenta” issue.

You can’t imagine how we remotely debugged this sh*t :smiley:

The code has changed completely since then and the issue has gone away for now… it was just a work in progress when i noticed the bug and shared it to try and help

Ive got a DHT22 measuring temp and humidity and logging onto a SD card in a database file with an ID number and time/date, its working great. The plan is to try and make the database searchable… it is already kind-of… but im in the process of making a menu on the serial port to make it easier. all so when i get my RFID reader i have a way to store and search tags and display a welcome message… or a go away message whatever the case may be!

That is now 404 on github. If you have the failing source still, can you stick somewhere accessible please?

YES SIR!

https://dl.dropboxusercontent.com/u/36134145/db.zip

1 Like

@Hootie81, what a strange bug!! Even stranger that it went away when you augmented your code.

You project sounds way cool and I hope you share it with us when your done. Let us know if we can help in the meantime :smile:

1 Like

Heya @kennethlimcp,

Thanks for the ping! I think @zachary would be able to contribute more to the firmware side of the discussion. The most notorious issue I’ve seen is that code that uses spark.publish seems to interfere with OTA updates.

It sounds like you guys are getting into more complex runtime issues though with this firmware, and less OTA issues, so I’ll punt to the firmware guys on this. :smile:

Thanks,
David

1 Like

Hi , In my case it seems never to reach solid magenta . I checked my wifi if its connected and seems never got connected . Any idea on that ? I can do dfu firmware update but no success on connection as well as application run.

Can you clarify further what are you attempting to do?

1.) Is your core breathing cyan?

2.) Are you trying to perform OTA flash via the Web IDE?

Well after i update cc3000 firmware over cli , it keeps blinking Magenta . and doing update of core-firmware , just breathing white greenish , i think.

When the CC300 patch is being performed the led will blink magenta. Once it turns to blinking yellow, that indicates patching is completed.

You can then use spark flash --usb tinker to flash the default code into the core and see what happens.

It should be blinking blue after the flashing is completed :wink:

1 Like

How long should take to change from blinking magenta to blinking yellow ? I tried spark flash --usb tinker it starts breathing not so white color . on spark flash --usb cc3000 it starts blinking magenta and never changes to yellow.