Stream data from node-red to c program?

@Colin I tried this, but still I get the error

error

[{"id":"88d894d0.d2b9e8","type":"inject","z":"2998129e.ad50de","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"-v -a3 -c1 -f434 -m100","payloadType":"str","x":180,"y":320,"wires":[["454465f3.2b008c"]]}]

@Colin, This my intended command : sudo ./RX_Demo -v -a3 -c1 -f434 -m100

@sridhar2rok: I just entered the absolute path to my C program in the Command field, e.g.:

C:/Users/JDoe/SomeFolder/CompiledCProgram.exe

But getting the program to execute was only a fraction of the challenge for me. Most of my time was spent figuring out how to get the input data in just the right format for the program. That took a bit of experimenting and a lot of staring at debugger node outputs :smiley:

Note that I said you have to use the full path to the command, not ./command.
Also if you need to use sudo then you will have to tell the system that the node-red user does not need to enter a password to run that command with sudo. Better is to make sure that the node-red user has access to whatever the command needs to access, so you don't need to use sudo.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.