UART communication with modem

Home Forums MultiConnect OCG UART communication with modem

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #6649
    James Womack
    Participant

    I am able to establish a terminal connection with the cellular modem (H5), issue AT commands and obtain a PDP context where I can ping an IP address. I’m using minicom to do this. Is there some way to accomplish this without using minicom (i.e. entering a terminal console and exiting when I’m done)?

    I would like to be able to run a program (Python script preferably) where I initialize the IP link (through AT commands) and then send to the modem packets to be forwarded over the air. I would like to have a serial communications link where I send an AT command and receive the response before sending the next AT command. How might I do this?

    #6652
    James Womack
    Participant

    After a search I found that the serial.Serial module in Python can be used to read from and write to the cellular modem. I am able to connect and set up a PDP context. Next is to read GPIO, ADC and I2C from the OSG (and breakout) while in Python and report the results to an MQTT broker. I see where I can use the os module and use the os.system method to work with IO. If there is a more elegant way of doing this, please let me know.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.