The Spark Core landed!

First impression

This is the box it came in, not just a plain normal boring cardboard box, but one with text and graphics on all sides.

2014-02-01 14.57.17 (Large)

Inside we find the Spark Core itself, and a nice visible link telling where to start.

2014-02-01 14.57.55 (Large)

Seems to have everything needed to get going… The Spark Core, a breadboard, USB cable, and a sticker!

2014-02-01 14.58.48 (Large)

The first impression was fine and I looked like they were serious about what they were doing, but as soon as I wanted to get the Spark Core online, the problems started.

Getting it online

To get it connected to the network, all you do is to power it up, open the app on your phone and put the wifi info in, and it then sends it to the core.

However, when I powered mine up it went into the breathing state, and after a long wait (over a minute) the app said it found no core. Repeating the process a few times gave the same result, which is strange, because the breathing should indicate it was online.

Maybe the app just didn’t find it, but it was online? To check I went to the site and it said I had no cores, but if the mobile app failed, I could do it by USB.

So I decided to do it by USB, the guide linked the driver for the core, and said the core had to be in “listening mode”. After some searching around on the site I gave up on finding how to put it into listening mode, and instead tried google to find it. According to the result I got there, I had to hold the mode button down for about 3 seconds, until the led starts to blink blue.

This didn’t seem to do the trick either, my computer did not notice anything new connected, maybe it does not like Windows 8.1? I don’t know, can’t find it on their site.

After messing around with the USB way to do it, I gave up on that too and started to look at what else to do. To do another attempt with the mobile app I cleared the memory on the Spark Core, and it went into the blue flashing state, which means it is waiting for WiFi credentials. After opening the mobile app and putting the needed information in, it found the Spark Core and asked for a name for it, and after this it also showed up on their website.

First examples

The first thing I uploaded to my Spark Core was a classic, just a simple blink.

This just turns D0 HIGH and LOW with a 1000ms delay, and it was an absolute success!

Blinking a led gets boring pretty fast though, and this device is more meant to do things online, so lets try that.

Again I decided to use an example from their site and just did a copy/paste. The code uploaded fine, and I started working on a little PHP snipped to send the device id, access token, and the command.

After a few tries the returned errors was gone, and I seemed like I had a working function to send commands to the Spark Core, but it did not do what I expected it would do, actually it did nothing at all.

Having used a unmodified example from the site, I expected my function to be wrong, but the return from the Spark API seemed like there was nothing wrong.

Turns out, the example is wrong, the comments said

l1,HIGH or l1,LOW
l2,HIGH or l2,LOW

but what actually works is

l0,HIGH or l0,LOW
l1,HIGH or l1,LOW

Now what?

The next I am planning on doing is to make the Spark Core a part of my home automation system. The first thing I need to do is to rewrite a sketch from when I used Arduino’s and RF modules, then modify my PHP based system that is handling all the commands for the different devices I got.

4 comments

Leave a Reply