ChirpStack Node-RED nodes

bruh i still dont understand how you manage to install the non-blue shirpstack nodes.im using the npm installer to only get errors

Can you post errors you’re getting?

I can tell you that I first had to get a newer Node.js (which required a newer version of Windows; newest Node.js didn’t support Windows 7) and then I installed most recent nodeRED and everything else was pretty smooth after that, except for what I said about chirpstack vs ChirpStack.

Hello,
I’ve installed new updated chirpstack node-red nodes https://github.com/brocaar/node-red-contrib-chirpstack but can’t make it running?! I did it some time ago, prior update , fallowing the instructions and it was running properly. Now I get enqueue error as shown on the figure.

How can I troubleshoot this error?

Is there any missing instruction for this new updated nodes?
I wander why is changed DevEUI to DevEui?!

best regards,
Nenad

This was version issue! I was using newly published V4.0.0 chirpstack up/downlink nodes with prev version of chirpstack network and app servers.
When installed @chirpstack/node-red-contrib-chirpstack@3.0.1 both, up and downlink messages work smoothly as before.
Anyhow I’m still curious to know how to troubleshoot enqueue error (and other type of errors) when happens.

1 Like

can you send the contrib v3 installation tutorial?

There’s no any special tutorial, you should fallow https://github.com/brocaar/node-red-contrib-chirpstack, just force installation of 3.0.1 version with
npm install @chirpstack/node-red-contrib-chirpstack@3.0.1

1 Like

and be sure that you properly deleted previously installed version.
Check it with npm list -g if you install it as global
If you still see old version in palette manager do restart Node-red. I use pm2 for that. br

Hi @nensak ,
what version of node.js and node-red are you using? I already forced the installation with npm install @chirpstack/node-red-contrib-chirpstack@3.0.1 , restarted node-red, and I still do not see any of the ChirpStack nodes available. When I search on the “Manage Palette” section, I only see the nodes available from @smartparks but nothing from @chirpstack.
Thank you!


1 Like

I have solved it after many restarts of node-red.

  1. cd ~/.node-red
  2. ls
  3. cd node_modules
  4. git clone https://github.com/brocaar/node-red-contrib-chirpstack.git
  5. npm i node-red-contrib-chirpstack
  6. node-red restart
  7. Close web session
  8. Reopen. They should appear after restarting node-red.

Make sure you have Node-Red version 3.0.1 and stable version of node.js, which is v16.16.0 as of now.

1 Like

the ‘echo function’ examples above and throughout the documentation make sense as the foundation for a class A device but I’m looking to initiate downlinks on an ad-hoc basis for a (timing insensitive) Class C device which necessitates constructing the downlink message without the aid of an inbound message. I’ve had this working previously but am now screwing it up somehow, as the downlink node reports an error “devEui is undefined”.

I’m constructing the input in a function node in the form:

msg.payload = {
devEui: “a840535318187fa”,
confirmed: false,
fPort: 4,
data: ‘08ff’,
}

return msg;

Can anyone point to an example function node that does work?
using ChirpStack 4.01

So I’ve upgraded to 4.0.2 and downlinks are now working with no change to the function node code.

But i still get [different] unexpected output from the downlink node:

msg : undefined
undefined

Should this not be returning the downlink ID? I can see that in other respects the downlink is definitely working.

I wander if anyone managed to make downlink working in node-red-contrib-chirpstack@4.0.0?!
I did it with version @3.0.1 and with chiprstack V3 but now I can’t repeat it again.
On @4.0.0 I could not make it at all, as I suppose that @4.0.0 must be used with chirpstack V4, and can’t run with V3?
I saw that porzim posted an issue on github and have got an attention of brocar, so I hope this will be solved soon.
I just want to stress that I keep this as very important element of entire chirpstack infrastructure. When looking on TTN there are many resources related to using Node Red in many scenarios. We are lacking any progress in this topic. SSome real example would be of great help if anyone can help?

Correct, the major versions must match. Thus for ChirpStack v4, you must use the v4 version of the package.

You will also find documentation here:
https://www.chirpstack.io/docs/guides/node-red-integration.html

I saw that porzim posted an issue on github and have got an attention of brocar, so I hope this will be solved soon.

Yes, that is on my list to look into this. I’m not sure if there is an issue, but if there is, I’ll fix it or update the documentation.

Thank you brocaar! Meantime I’ve got the downlink message running on V4 versions! Here are the screens of uplink and downlink messages, using your example flow.

It seams ok, but I wander where are fPort and payload in the event data?

The debug message after the device downlink shows the queue ID that was generated after the enqueue. If you want to see the requested downlink, then you could enable the debug node after the function node, which will then print the payload that goes to the device downlink node.

Thanks, I knew this, but was not clear with question, obviously.
I expected to find payload and fPort in LoraWANframe and event details in downlink message of ChirpStack applications, but with no success?! When looking to screens I sent, the first shows uplink message in both, ChirpStack and Node red, and there all data sent up from node/applications could be found in Node red, fCnt, fPort and data, but when looking in downlink message, there’s no any of them, although they have been created created by example function and shown in debug node, connected to the function.
It means that the downlink node works (as it returns the msgID), but can’t transfer desired data, ie payload, or I don’t know where to look and how to use them?!

This appears to be broken…
Followed theese steps

  1. cd ~/.node-red
  2. ls
  3. cd node_modules
  4. git clone https://github.com/brocaar/node-red-contrib-chirpstack.git
  5. npm i node-red-contrib-chirpstack
  6. node-red restart
  7. Close web session
  8. Reopen. They should appear after restarting node-red.

and got

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/node-red-contrib-chirpstack - Not found
npm ERR! 404
npm ERR! 404 ‘node-red-contrib-chirpstack@*’ is not in this registry.
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

on step 5

I think it should be @chirpstack/node-red-contrib-chirpstack:

Hello… Brocaar. I have success for get data from node rfm95 arduino to chirpstack- nodered (node → chirpstack-nodered). is it possible to reverse ? (chirpstack-nodered → node). I need send message to node from nodered-chripstack

Please see Node-RED integration - ChirpStack open-source LoRaWAN® Network Server documentation, it includes a node for scheduling downlinks.