I have a waveshare GSM/GPRS/GNSS hat
I can send and receive AT commands in node red but i also need internet connectivity from the hat.
The problem seems to be that these are two conflicting process on the same port.
So im hoping i can disable one process at a time. I can stop/start the GPRS by using "sudo pon rnet" and "sudo poff rnet" in the exec node but i don't know how to suspend or kill the serial node for the alternate process. Any ideas?
You can't do both at once on a single serial port device. Once you start the PPP session that will totally take over the serial port and there will be no way to do anything else.
The Node-RED serial nodes expect exclusive access to the serial port, there is no way to disconnect it to allow the PPP session to take control.
USB GSM/3G/LTE devices usually present multiple serial devices, to get round these types of problems. One is specifically for running the PPP session and the other is for handling sending AT commands for sending SMS, changing settings and if a GPS device is available querying this.
I'm using the USB port because I need the GPIO for other devices but are the USBs and UART pins separate ports? Could I use GPIO 14 and 15 for AT and the micro USB for PPP?
If we can't use interrupts would it be possible to use multithreading for concurrent processes?
Looking at the spec, it looks like the device only has one UART and a jumpers to link the gpio or usb connector to that, so you won't be able to use both at once.
You are already getting to run multiple processes accessing the port at the same time, PPP and Node-RED.
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.