I’m having trouble getting settings to “stick” when setting them from the serial interface. I’ve tried --set-owner, --set wifi_ssid, and --set wifi_password all with no luck on the serial interface, although setting the owner name works OK on the Android interface. I recently re-flashed firmware-tbeam-1.2.30.80e4bc6.bin in order to try to get the web UI up and running. Before that, I was able to use --set wifi_ssid and --set wifi_password, and it worked OK.
Here’s a transcript of my session with --debug enabled:
jdstroy@laptop:~/ttgo$ sudo meshtastic --port /dev/ttyS3 --debug --set wifi_ssid 'exampe_ssid' --set wifi_password 'example_password' --set wifi_ap_mode false --info
DEBUG:root:Not logging serial output
DEBUG:root:Connecting to /dev/ttyS3
DEBUG:root:Sending: want_config_id: 1452937022
DEBUG:root:Received myinfo: my_node_num: 84682428 has_gps: true num_bands: 13 firmware_version: "1.2.30.80e4bc6" reboot_count: 54 message_timeout_msec: 300000 min_app_version: 20200 max_channels: 8
DEBUG:root:Received nodeinfo: {'num': 84682428, 'user': {'id': '!050c26bc', 'longName': 'Yell', 'shortName': 'Yll', 'macaddr': 'PGEFDCa8', 'hwModel': 'TBEAM'}, 'position': {'latitudeI': 302317541, 'longitudeI': -978873096, 'altitude': 306, 'time': 1621878012, 'latitude': 30.2317541, 'longitude': -97.8873096}, 'lastHeard': 1621878012}
DEBUG:root:Config complete ID 1452937022
DEBUG:root:Serializing protobuf as data: get_radio_request: true
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: " \001" want_response: true } id: 604535689 hop_limit: 3 want_ack: true }
DEBUG:root:Received radio config, now fetching channels...
DEBUG:root:Requesting channel 0
DEBUG:root:Serializing protobuf as data: get_channel_request: 1
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: "0\001" want_response: true } id: 604535690 hop_limit: 3 want_ack: true }
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b'*\x18\n\x16\x08\n\x10\xe8\x020\x84\x07P\xff\x93\xeb\xdc\x03x\x01\x80\x02\x01\x90\x02\n', 'requestId': 604535689, 'admin': {'getRadioResponse': {'preferences': {'positionBroadcastSecs': 10, 'sendOwnerInterval': 360, 'phoneTimeoutSecs': 900, 'lsSecs': 999999999, 'region': 'US', 'locationShare': 'LocEnabled', 'gpsUpdateInterval': 10}}, 'raw': get_radio_response { preferences { position_broadcast_secs: 10 send_owner_interval: 360 phone_timeout_secs: 900 ls_secs: 999999999 region: US location_share: LocEnabled gps_update_interval: 10 } } }}, 'id': 1720763711, 'rxTime': 1621878012, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: "*\030\n\026\010\n\020\350\0020\204\007P\377\223\353\334\003x\001\200\002\001\220\002\n" request_id: 604535689 } id: 1720763711 rx_time: 1621878012 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
DEBUG:root:Received channel settings { modem_config: Bw125Cr48Sf4096 psk: "\001" } role: PRIMARY
DEBUG:root:Requesting channel 1
DEBUG:root:Serializing protobuf as data: get_channel_request: 2
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: "0\002" want_response: true } id: 604535691 hop_limit: 3 want_ack: true }
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b':\t\x12\x05\x18\x03"\x01\x01\x18\x01', 'requestId': 604535690, 'admin': {'getChannelResponse': {'settings': {'modemConfig': 'Bw125Cr48Sf4096', 'psk': 'AQ=='}, 'role': 'PRIMARY'}, 'raw': get_channel_response { settings { modem_config: Bw125Cr48Sf4096 psk: "\001" } role: PRIMARY } }}, 'id': 1720763712, 'rxTime': 1621878012, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: ":\t\022\005\030\003\"\001\001\030\001" request_id: 604535690 } id: 1720763712 rx_time: 1621878012 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
DEBUG:root:Received channel index: 1 settings { }
DEBUG:root:Finished downloading channels
Connected to radio
DEBUG:root:Sending heartbeat, interval 450.0
DEBUG:root:Serializing protobuf as data: time: 1621878011
DEBUG:root:Sending: packet { to: 4294967295 decoded { portnum: POSITION_APP payload: "M\373\344\253`" } id: 604535692 hop_limit: 3 }
Set wifi_ssid to exampe_ssid
DEBUG:root:Sending:
Set wifi_password to example_password
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b':\x04\x08\x01\x12\x00', 'requestId': 604535691, 'admin': {'getChannelResponse': {'index': 1, 'settings': {}}, 'raw': get_channel_response { index: 1 settings { } } }}, 'id': 1720763713, 'rxTime': 1621878012, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: ":\004\010\001\022\000" request_id: 604535691 } id: 1720763713 rx_time: 1621878012 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
Set wifi_ap_mode to false
Writing modified preferences to device
DEBUG:root:Serializing protobuf as data: set_radio { preferences { position_broadcast_secs: 10 send_owner_interval: 360 phone_timeout_secs: 900 ls_secs: 999999999 wifi_ssid: "exampe_ssid" wifi_password: "example_password" region: US location_share: LocEnabled gps_update_interval: 10 } }
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: "\n7\n5\010\n\020\350\0020\204\007P\377\223\353\334\003b\013exampe_ssidj\020example_passwordx\001\200\002\001\220\002\n" } id: 604535693 hop_limit: 3 want_ack: true }
DEBUG:root:Wrote config
Owner: Yell (Yll)
My info: { "myNodeNum": 84682428, "hasGps": true, "numBands": 13, "firmwareVersion": "1.2.30.80e4bc6", "rebootCount": 54, "messageTimeoutMsec": 300000, "minAppVersion": 20200, "maxChannels": 8 }
Nodes in mesh:
{'num': 84682428, 'user': {'id': '!050c26bc', 'longName': 'Yell', 'shortName': 'Yll', 'macaddr': 'PGEFDCa8', 'hwModel': 'TBEAM'}, 'position': {'latitudeI': 302317541, 'longitudeI': -978873096, 'altitude': 306, 'time': 1621878012, 'latitude': 30.2317541, 'longitude': -97.8873096}, 'lastHeard': 1621878012}
Preferences: { "positionBroadcastSecs": 10, "sendOwnerInterval": 360, "phoneTimeoutSecs": 900, "lsSecs": 999999999, "wifiSsid": "exampe_ssid", "wifiPassword": "example_password", "region": "US", "locationShare": "LocEnabled", "gpsUpdateInterval": 10 }
Channels:
PRIMARY psk=default { "modemConfig": "Bw125Cr48Sf4096", "psk": "AQ==" }
Primary channel URL: https://www.meshtastic.org/d/#CgUYAyIBAQ
DEBUG:root:Closing stream
DEBUG:root:Sending: disconnect: true
DEBUG:root:reader is exiting
DEBUG:root:Closing our port
jdstroy@laptop:~/ttgo$ sudo meshtastic --port /dev/ttyS3 --debug --info
DEBUG:root:Not logging serial output
DEBUG:root:Connecting to /dev/ttyS3
DEBUG:root:Sending: want_config_id: 3266087387
DEBUG:root:Received myinfo: my_node_num: 84682428 has_gps: true num_bands: 13 firmware_version: "1.2.30.80e4bc6" reboot_count: 55 message_timeout_msec: 300000 min_app_version: 20200 max_channels: 8
DEBUG:root:Received nodeinfo: {'num': 84682428, 'user': {'id': '!050c26bc', 'longName': 'Yell', 'shortName': 'Yll', 'macaddr': 'PGEFDCa8', 'hwModel': 'TBEAM'}, 'position': {'latitudeI': 302320799, 'longitudeI': -978871813, 'altitude': 306, 'time': 1621878026, 'latitude': 30.2320799, 'longitude': -97.8871813}, 'lastHeard': 1621878026}
DEBUG:root:Config complete ID 3266087387
DEBUG:root:Serializing protobuf as data: get_radio_request: true
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: " \001" want_response: true } id: 1634340353 hop_limit: 3 want_ack: true }
DEBUG:root:Received radio config, now fetching channels...
DEBUG:root:Requesting channel 0
DEBUG:root:Serializing protobuf as data: get_channel_request: 1
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: "0\001" want_response: true } id: 1634340354 hop_limit: 3 want_ack: true }
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b'*\x18\n\x16\x08\n\x10\xe8\x020\x84\x07P\xff\x93\xeb\xdc\x03x\x01\x80\x02\x01\x90\x02\n', 'requestId': 1634340353, 'admin': {'getRadioResponse': {'preferences': {'positionBroadcastSecs': 10, 'sendOwnerInterval': 360, 'phoneTimeoutSecs': 900, 'lsSecs': 999999999, 'region': 'US', 'locationShare': 'LocEnabled', 'gpsUpdateInterval': 10}}, 'raw': get_radio_response { preferences { position_broadcast_secs: 10 send_owner_interval: 360 phone_timeout_secs: 900 ls_secs: 999999999 region: US location_share: LocEnabled gps_update_interval: 10 } } }}, 'id': 1060614845, 'rxTime': 1621878026, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: "*\030\n\026\010\n\020\350\0020\204\007P\377\223\353\334\003x\001\200\002\001\220\002\n" request_id: 1634340353 } id: 1060614845 rx_time: 1621878026 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
DEBUG:root:Received channel settings { modem_config: Bw125Cr48Sf4096 psk: "\001" } role: PRIMARY
DEBUG:root:Requesting channel 1
DEBUG:root:Serializing protobuf as data: get_channel_request: 2
DEBUG:root:Sending: packet { to: 84682428 decoded { portnum: ADMIN_APP payload: "0\002" want_response: true } id: 1634340355 hop_limit: 3 want_ack: true }
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b':\t\x12\x05\x18\x03"\x01\x01\x18\x01', 'requestId': 1634340354, 'admin': {'getChannelResponse': {'settings': {'modemConfig': 'Bw125Cr48Sf4096', 'psk': 'AQ=='}, 'role': 'PRIMARY'}, 'raw': get_channel_response { settings { modem_config: Bw125Cr48Sf4096 psk: "\001" } role: PRIMARY } }}, 'id': 1060614846, 'rxTime': 1621878026, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: ":\t\022\005\030\003\"\001\001\030\001" request_id: 1634340354 } id: 1060614846 rx_time: 1621878026 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
DEBUG:root:Received channel index: 1 settings { }
DEBUG:root:Finished downloading channels
Connected to radio
DEBUG:root:Sending heartbeat, interval 450.0
DEBUG:root:Serializing protobuf as data: time: 1621878026
DEBUG:root:Sending: packet { to: 4294967295 decoded { portnum: POSITION_APP payload: "M\n\345\253`" } id: 1634340356 hop_limit: 3 }
DEBUG:root:Sending:
Owner: Yell (Yll)
DEBUG:root:Publishing meshtastic.receive.admin: packet={'from': 84682428, 'to': 84682428, 'decoded': {'portnum': 'ADMIN_APP', 'payload': b':\x04\x08\x01\x12\x00', 'requestId': 1634340355, 'admin': {'getChannelResponse': {'index': 1, 'settings': {}}, 'raw': get_channel_response { index: 1 settings { } } }}, 'id': 1060614847, 'rxTime': 1621878026, 'hopLimit': 3, 'priority': 'RELIABLE', 'raw': from: 84682428 to: 84682428 decoded { portnum: ADMIN_APP payload: ":\004\010\001\022\000" request_id: 1634340355 } id: 1060614847 rx_time: 1621878026 hop_limit: 3 priority: RELIABLE , 'fromId': '!050c26bc', 'toId': '!050c26bc'}
My info: { "myNodeNum": 84682428, "hasGps": true, "numBands": 13, "firmwareVersion": "1.2.30.80e4bc6", "rebootCount": 55, "messageTimeoutMsec": 300000, "minAppVersion": 20200, "maxChannels": 8 }
Nodes in mesh:
{'num': 84682428, 'user': {'id': '!050c26bc', 'longName': 'Yell', 'shortName': 'Yll', 'macaddr': 'PGEFDCa8', 'hwModel': 'TBEAM'}, 'position': {'latitudeI': 302320799, 'longitudeI': -978871813, 'altitude': 306, 'time': 1621878026, 'latitude': 30.2320799, 'longitude': -97.8871813}, 'lastHeard': 1621878026}
Preferences: { "positionBroadcastSecs": 10, "sendOwnerInterval": 360, "phoneTimeoutSecs": 900, "lsSecs": 999999999, "region": "US", "locationShare": "LocEnabled", "gpsUpdateInterval": 10 }
Channels:
PRIMARY psk=default { "modemConfig": "Bw125Cr48Sf4096", "psk": "AQ==" }
Primary channel URL: https://www.meshtastic.org/d/#CgUYAyIBAQ
DEBUG:root:Closing stream
DEBUG:root:Sending: disconnect: true
DEBUG:root:reader is exiting
DEBUG:root:Closing our port
Notice Preferences has non-default values (from the phone), but didn’t retain the wifi settings set in the previous session.
Python client version is 1.2.35. Device firmware version is 1.2.30.80e4bc6 (as shown in output above).
Ideas?