Posted

My protoyping board for SparkCore that Ive been working on is now available on Tindie

Available on Tindie now

Comes with female headers so you can easily attach and remove you core from the protoboard.

  • Each SparkCore pin is connected to the hole on either side, so you have one spot for each pin inside the prototyping area and one on the outside of the core for connecting to external components.
  • There are additional connected pins for GND, VIN & 3V3
  • Clear labelling on both sides
  • Mounting holes

SparkCore in photos not included for illustrative purposes only

Author

Posted

I’ve posted a project up to hackaday.io and submitted it to the hack a day prize competition. Its something I’ve been working for a while (fairly slowly) its title for the purposes of the hack a day competition is “Wireless Smarthome Buttons” but that name is less than ideal and I really need a better one. Anyway ..

It’s a wireless 2x2 button pad backlit by RGB LED’s, it can be used for controlling any other connected device or project. However my intended usage is controlling smart home devices.

Firmware on the device is pretty simple it uses the MQTT protocol and publishes the press of the buttons to MQTT topics and subscribes to other topics that tells it what colour the LED’s should be. This way the the press of the buttons is disconnected from the illumination of the LED’s. This separation takes its inspiration from the Monome project. The most obvious use case here is the LED’s can be used for notifications as well as indicating button presses or device states.

In the current version the backend is run by some Python code on a Raspberry Pi. I’m currently controlling Lifx lamps using the magicmonkey NoteJS MQTT bridge but I’m thinking of writing my own Lifx MQTT bridge in Ruby.

I’ll be publishing more details and code in the coming weeks to my project on hackaday projects. Check it out.

Author

Posted

I’ve been pushing forward one of my projects recently. I’ve been using the SparkCore allot since receiving my Kickstarer rewards in December last year. I’ve been wanting a prototyping board for the SparkCore and as there wasn’t one available so I designed one. I decided that producing a Spark protobaord would be a nice little project to do and allow me to sort out my logistics and e-commerse ahead of some of my other boards and projects being ready.

After a successful prototype I’ve ordered a bunch of boards and should have them available for sale in the next couple of weeks.

Author

Posted

So try this, go and restart your local MQTT broker. I'll wait

So how did that go?

If you like me based your MQTT clients code on the example code then you probably have some hung clients than need resetting.

So the Arduino/C examples has this code..

void loop()
{
    client.loop();
}

And the python examples have this..

while 1:
    client.loop()

Both simple to understand for starting out but if anything happens to you broker or there is a network problem etc your client is borked.

It fairly easy to fix though, we just don't assume we have a connection when we call client.loop and if we don't have a connection then lets connect.

Arduino/C

  if (client.connected ()){
     client.loop();
  }
  else {
    Serial.println("MQTT Broker Connection Down");
    if (client.connect("Shed_Temp","shed/will",0,0,"Shed Temp Fail")) {
       client.publish("Status","ShedTemp ReStart");
       Serial.println("MQTT Broker Connection Restated");
    }
    else {
      // Don't flood the broker with connections and it's already down so we don't need to worry about a delay disconnecting the client
      delay(15*1000);
      Serial.println("MQTT Connection Delay");
    }
  }

Python

def connectToBroker():
    client.will_set('jarvis/will/local', payload="Jarvis Local Fail", qos=0)
    try:
        if not client.connect("127.0.0.1"):
            client.subscribe("temperature/#", 0)
    except socket.error, (value,message):
        print "Could not open socket: " + message
        time.sleep(5)

while 1:
    try:
        if client.loop():
            print("Broker Connection Error")
            connectToBroker()
    except socket.error, (value,message):
        print "Could not open socket: " + message

While updating my clients code I've also taken the opportunity to setup last will and testament so i get a MQTT message when the clients disconnect. I intend to hook this up to MQTT Warn so I get notifications when MQTT clients disconnect unexpectedly.

Author
Categories ,

Posted

I had a huge day yesterday at Sydney's fist Mini Maker Fair.

I had a stall showing off some of my previous work as well as demonstrating a couple of products I have in development. There was lots of interest in my "Networked Buttons for Sparkcore" product that still needs a name as well as Wink the Smatphone control for professional video cameras.

There isn't a lot of information on these projects on the website, more information will be posted in the coming days. If you keen to hear about progress on the projects please sign up to the mailing list.

Fill out my online form.

Author

← Older Newer →