Update LoRa Network Server config from console

Home Forums Conduit: AEP Model Update LoRa Network Server config from console

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #12005
    kiran
    Participant

    I have a Conduit AEP model and would like to make configuration changes from the console. Is it possible to modify LoRa Network Server configuration by modifying “lora-network-server.conf” file?

    I tried modifying the “Network EUI and Key” in the conf file but that change did not get reflected on the WebGUI (for verification). If additional steps are needed, can you please provide the necessary commands.

    Thanks,
    Kiran

    #12025
    Jeff Hatch
    Keymaster

    Kiran,

    The information that you want to modify is in the API configuration file in /var/config/db.json. However, if you modify this file outside of making API requests it is possible that you will see your settings get reverted back by the API. The most effective way to modify these settings outside of the Web UI is to make curl requests to the API. To do this you can use a command like:

    curl -s -m 5 -X PUT -H “Content-Type: json/application” -d ‘{ “network” : { “eui”:”UUIDabcdefg”, “key”:”SOME_VALUE” }}’ 127.0.0.1/api/loraNetwork

    And then save this change:

    curl -i -X POST -H ‘Content-Type: application/json’ -d ‘{}’ http://127.0.0.1/api/command/save

    Hope that helps,

    Jeff Hatch

    #12045
    kiran
    Participant

    Jeff,

    Thank you. That worked.

    Currently, I’m using a Windows machine to access the Serial console. Does the Gateway console work with a Linux machine? If so, can you please guide me through the steps involved. My test requirements would need to access this device from Linux host (Ubuntu 14.04).

    Thanks,
    Kiran

    #12047
    Jeff Hatch
    Keymaster

    Kiran,

    You’re in luck, I am currently running Ubuntu 14.04 as my workstation. You should be able to just connect your Conduit’s debug console to a USB port on the Ubuntu machine, and the tty should get instantiated in /dev as a /dev/ttyACM*. I use minicom to connect to the debug console tty from a terminal. The terminal program I use is called Terminator.

    The minicom program has a man page and a lot of different questions pertaining to its use are on the Internet. To connect with minicom you might have to ‘sudo’ in order to connect to the tty.

    Jeff

    #12048
    Mike Fiore
    Blocked

    I believe if you add yourself to the “dialout” group, you won’t have to use sudo when starting minicom.

    Cheers,

    Mike

    #12049
    kiran
    Participant

    Jeff and Mike,

    Thank you for the quick response. I can now access the console at /dev/ttyACM0. Assumed it would get instantiated as /dev/ttyUSB*. I use minicom for Serial communication too and have always used ‘sudo’. Will try the “dialout’ group option.

    Thanks,
    Kiran

    • This reply was modified 8 years, 1 month ago by kiran.
    • This reply was modified 8 years, 1 month ago by kiran.
    • This reply was modified 8 years, 1 month ago by kiran.
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.