Firmware v0.2.0 released, with many fixes

Hello all,

Today we pushed a new version of the Spark Core firmware. We’re (finally) starting to number our versions, so we’re calling this Spark firmware v0.2.0. Here are the releases for the three firmware libraries:

The choice of v0.2.0 was deliberate; we believe that this firmware is a significant step forward from where we started (let’s call that v0.1.0), but it is still in rapid development. We are continuing to make dramatic changes and improvements, and we expect to do so for quite some time. These changes will occasionally be breaking, and we will not increment to v1.0 until we feel like the pace is slowing and breaking changes become extremely infrequent. This is in line with semantic versioning and many software packages that we know and love and use everyday like Node.js.

From now on, firmware applications built with the web IDE will be built with Spark firmware v0.2.0, which is shown in the ‘Settings’ panel of the IDE:

Now that we are properly versioning our firmware releases, we will also be publishing changelogs. However since we have been doing a poor job of keeping track until now, we will instead give you this:

Just kidding. Here is a list of some of the great changes that have been implemented in the firmware in the recent past:

  • Spark.publish() rocked our worlds (and our servers)
  • Rate limiting for publishing events was put in place, because void loop() { Spark.publish("DEATH TO THE CLOUD");}
  • Network.RSSI() returns the signal strength
  • Firmware is ready for Time to be set by Cloud (still needs work on the Cloud side)
  • Sampling timing was adjusted to fix analog sensor issues
  • “Blue Flash of Death” was resolved
  • Improvements to OTA firmware update
  • Shrink the binary size (now ~70KB instead of ~90KB)
  • Process messages to/from cloud during long delay()

Many thanks to the contributors of these improvements, including @zachary, @satishgn, @david_s5, and @timb.

Finally, we are now also tracking “Known issues” in our documentation:

The only known issue at present is CFOD (Cyan Flash of Death), and a major improvement is coming soon! Thanks to the guys at TI for prioritizing the issue.

Enjoy the new firmware, and good luck with your projects and products!


This topic is now pinned. It will appear at the top of its category until it is either unpinned by a moderator, or the Clear Pin button is pressed.


i think Spark.connect(), Spark,disconnect(), WiFi.on(), deserves some credits and official documentation? :wink:

GREAT JOB :spark: team and all the contributors :smiley: :thumbsup:


@kennethlimcp Yes absolutely, except we are going to be making some changes to the syntax of these requests, and we won’t be officially announcing/documenting these features until we have made those changes. It’ll be officially part of our next push!

Thanks! Will there be a colour to differentiate Spark.disconnect() or there’s already one that i’m not aware off? :smiley:

I tried to test those new features with firmware V0.2.0 and realized i can’t reach the core. Spark.disconnect() worked and my Spark.connect() didn’t run (somewhere coded wrongly).

Visually i couldn’t tell until i used Spark-cli to check the status :smiley:

more great work from team spark! excellent news.

@zach does this include the interim TI firmware provided for CFOD ?, or is the “major improvement is coming soon!”

I’ll write up the new spec a bit later, but there will be three potential states of the Core running, each with different lights:

Breathing white: Your code is running, but the Wi-Fi module is off

Breathing green: Your code is running and the Wi-Fi module is on, but you’re not connected to the Cloud

Breathing cyan: Your code is running and you’re connected to the Cloud


This doesn’t include the TI firmware fix; that’s the improvement coming soon! We need to first figure out a good way to package up the patch programmer in an over-the-air firmware update without risking bricking the Core; it’ll be a tricky maneuver.

I got like magenta issues right now during OTA download.

There’s some weird magenta sequence during OTA and sometimes:

  • doesn’t boot at all (no light nothing)
  • blinking magenta on power up
  • flashing yellow

Hi @kennethlimcp - can you give a bit more detail on what you’re seeing on the LED and what the Core is doing at that time?

@zach the previous post has 1 vine video (the clearer one got corrupted :X)

So during OTA:

  • Long solid magenta (~1-2s) then continues to blink
  • Weird blinking like blink…pause…blink…blink (missed videoing this!)

Towards the end, the blinking magenta appears normal as though the core managed to recover somehow.

But at the end of OTA when the core is supposed to restart, i get stuff like:

  • doesn’t boot at all (no light nothing)
  • rapidly blinking magenta on power up
  • flashing yellow

I’m trying to get a sample TCPclient code running and the OTA killed the core. So i flashed the core-firmware.bin using DFU. Reflashed over OTA and sometimes ending up in the situation

Thanks @kennethlimcp, I’ll raise this as an issue on Github, hopefully we can get it resolved soon.

I’ll try to get a good video when it happens again!

Thanks! Also, when you flash locally, are you using the Spark Firmware v0.2.0 release?

Not that. I used the release V02 of factory-reset firmware.

@zach you are in luck today!

Uploading the videos now…

Some facts:

  1. I’m running some TCPclient code and maybe some bad coding screwed up the sockets
  2. The core recovery seems to kick in but not 100%

To debug, please switch to Spark Firmware v0.2.0 (tagged in each repository as spark_3); we have put fixes in place for OTA and don’t want to be debugging issues that have already been fixed :smile:


I changed my factory firmware to spark_3 and tested again.

My core went to blinking red --> restart --> not sure if recovery mechanism kicked in --> OTA flash --> solid magenta and hanged

I can only say that if the recovery mechanism is in the compile-server2 to stop user code from running if there’s some weird error, it’s not working somehow. I have my core repeatedly blinking red --> restart – runs code again --> blinking red

Is your own application code in there as well? If you run it with the default Tinker firmware, do you have the same issues?

I believe that recovery mechanism was removed (because it was confusing); if your application code has a hard fault, the Core will now reset and run your code again, causing your device to keep rebooting until you factory reset. Sounds like you’ve got a hard fault to fix :wink:


It is also worth mentioning the awexome power of disabling the CLOUD and/or WLAN from the moment the Core powers up with one or both of these include statements:

#include "spark_disable_wlan.h"
#include "spark_disable_cloud.h"

You can always enable them at runtime in your code via:

WiFi.on(); // turns on WLAN
Spark.connect(); // Connects to CLOUD

This may or may not change, but it works currently.