Tinkerforge Node-RED nodes

For a recent project I’ve been working on a collection of different Node-RED nodes. Part of this set is a group of nodes to interact with Tinkerforge Bricks and Bricklets.

Tinkerforge is a platform of stackable devices and sensors/actuators that can be connected to via USB or can be attached directly to the network via Ethernet or Wifi.

Tinkerforge Stack

Collections of sensors/actuators, known as bricklets, are grouped together round a Master Brick. Each Master Brick can host up to 4 sensors/actuators but multiple Master Brick’s can be stacked to add more capacity. The Master Brick also has a Micro USB socket which can be used to connect to a host machine running a deamon called brickd. The host runs a daemon that handles discovering the attached devices and exposes access to them via an API. There are also Ethernet (with and without PoE) and WiFi bricks which allow you to link the stack directly to the network.

As well as the Master Brick there is a RED Brick which contains a ARM Cortex A8 processor, SD card, USB socket and micro HDMI adapter. This runs a small Linux distribution (based on Debian) and hosts a copy of brickd.

There are bindings for the API in a number of languages including:

  • C/C++
  • C#
  • Delphi
  • Java
  • Javascript
  • PHP
  • Perl
  • Python
  • Ruby

For the Node-RED nodes I took the Javascript bindings and wrapped them as Node-RED nodes. So far the following bricklets are supported:

Adding others shouldn’t be hard, but these were the ones I had access to in order to test.

All the nodes share a config node which is configured to point to the instance of the brickd the sensors are linked and it then provides a filtered list of available bricklets for each node.

Node-RED - Google Chrome_004

The code for the nodes can be found here and is available on npmjs.org here

6 thoughts on “Tinkerforge Node-RED nodes”

  1. Hi

    I have brickd running on a Pi with a Master Brick and Analogue Out v2 connect on port D connected by USB. I am trying to control from Node Red and have installed node-red-contrib-tinkerforge. Brickviewer on the Pi can detect the master and analogue bricklet and can adjust the output correctly, so brickd seems to be working. Node red Analogue out node detects the Analogue node id correctly but does not change the output. The config is localhost:4223 which is the same as Brickviewer on the Pi. Any suggestions would be appreciated

    1. Not off the top of my head. My test environment is all in the office so I can’t have a proper look until next week, but I’ll try and remember to give it a go on Monday.

    2. Actually just a quick thought, double check that the value you sending to the node is a number and not a string. If you wire in a debug node it should tell you what the type is at the top of the debug entry.

      1. Yes, definitely a number, I have checked with a debug node. The only difference that I can see from your setup is that you are possibly using brickd on a remote host and connecting to the master brick using ethernet. Thanks for the response

        1. Open an issue on Github so we can track this. If you can include your flow that will make things easier to track down.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>