Below are my setups:
- ThingsBoard (Community Edition)
- Self-hosted on DigitalOcean
- Raspberry Pi 4 running the applications below:
- Node-Red collecting data from sensor (DHT22) and publishing it to ThingsBoard using "MQTT Out" node
- ThingsBoard IoT Gateway (TIG) connecting to ThingsBoard using "MQTT Connector"
I'm able to publish all the sensor data from Node-Red to ThingsBoard using MQTT. The problem is that I need to use ThingsBoard "RPC Remote Shell" function. In order to achieve this I've installed TIG on my Raspberry Pi.
Both Node-Red and TIG are using the same "Security Token". When TIG is connected to ThingsBoard it will interrupt Node-Red's connection to ThingsBoard.
For now, as a workaround, I had to create two "Device" within ThingsBoard in order to get two different "Security Token". One token is for Node-Red and another is for TIG. This seems to sort out the problem temporarily but I ended up with two logical "Device" within ThingsBoard for one physical device (Raspberry Pi).
Is there a setting that to allow multiple connection from one "Security Token" on ThingsBoard? Or which part of ThingsBoard's codes do I need to edit in order to allow it? Or perhaps there's a way to enable "RPC Remote Shell" including other RPC capabilities using Node-Red instead of TIG? I have to use Node-Red as this is the easiest method to gather data instead of TIG. Let me know if you have a creative solution for this problem.
Appreciate your help. Thanks in advance.