Anyone have The Things Network (MQTT) working with Ignition?

I have a number of temperature & relative humidity nodes sending data in over MQTT to The Things Network. Thus far, I have been subscribing to these data via NodeRED on a local virtual server.

I am now looking on how to best connect this to our ignition gateway. I have tried installing cirrus engine but am not getting anywhere getting module to connect to TTN - it always get “connect with retry failed due to Unable to connect to server” with zero more information in log.

I know my ‘username’ and ‘password’ are good as I have been using these in NodeRED for 12+ months. I’m specifying ‘third party’ for server type. I have tried every variation of URL (tcp://bridge.us.thethings.network:1883, tcp://west-us.thethings.network:1883, etc) to no avail.

If anyone has this working, please let me know what URL should be.

I already use KepwareEx for our AutomationDirect PLC and I see they support MQTT too. I also get a feeling that these forums are biased towards Cirrus (strategic partner and all). Does anyone have KepwareEx working with TTN and was it easy to set up?

Thank you.

Not sure what is TTN (I guess it’s some MQTT related stuff) but www.pubnub.com allows you to connect remote devices and computers including ignition server over internet easily with latency of max 500 ms across the globe. Don’t know if it’s an answer in right direction.

I wrote a tutorial on using NCD sensors with the Cirrus Link modules using MQTT. It may not be what you are looking for, but it may have something that could help you. check it out here if you’d like.

Thanks for the link to the MQTT tutorial - half of it is helpful. The Things Network (TTN) is the cloud broker counterpart to Cirrus Link’s Distributor module. I didn’t know about custom namespace for JSON payload - not sure what TTN gateway does.

Using Quick Start Guide, I logged in to my TTN Console account and figured out that my region broker’s address is: us-west.thethings.network:1883 (one less mystery).

Alas, still no luck.

Well at least I wasn’t totally unhelpful. You should be able to get in touch with Cirrus Link support via email. I contacted them and got some good information quickly from them even without purchasing any of their software, I only had the demo.

Thanks to everyone. I did open ticket with CirrusLink, they responded same day requesting TRACE logs of their client module, and I sent them everything.

I used a simple & free windows app called MQTTBox (http://workswithweb.com/mqttbox.html; it also works fine under Windows 7) to confirm that my credentials were valid, and demonstrate that connecting to my broker & subscribing to namespace yielded real-time data. Good app to show proof that broker is not the problem :slight_smile:

HI @filipg, did you manage to connect to the TTN?

For connecting to The Things Network (TTN), you’ll need to use a Custom Namespace configuration in MQTT Engine version 4.0.10 or higher (this is important for the String Conversions feature). You should be able to configure the server settings per the TTN guidance here.

For the Custom Namespace, go to the String Conversions tab (new with MQTT Engine 4.0.10) and set it up like below:

This substitutes the @ sign from the topic definitions so that the hierarchy can be properly represented as Ignition tags (which don’t allow certain characters). This is what I use to pull in LoRaWAN sensor data here at the house that my LoRaWAN gateway is publishing up to TTN.

3 Likes

There is a new help document here for TTN: Do I need to do anything special to connect to my TTN (www.thethingsnetwork.org) broker - MQTT Modules for Ignition 8.x - Confluence

1 Like