mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
fix for set_custom_var
This commit is contained in:
parent
fb5fcae614
commit
a39c000f5d
3 changed files with 5 additions and 4 deletions
|
|
@ -1499,6 +1499,7 @@ public:
|
||||||
}
|
}
|
||||||
_serial->writeFrame(out_frame, dp - (char *)out_frame);
|
_serial->writeFrame(out_frame, dp - (char *)out_frame);
|
||||||
} else if (cmd_frame[0] == CMD_SET_CUSTOM_VAR && len >= 4) {
|
} else if (cmd_frame[0] == CMD_SET_CUSTOM_VAR && len >= 4) {
|
||||||
|
cmd_frame[len] = 0;
|
||||||
char* sp = (char *) &cmd_frame[1];
|
char* sp = (char *) &cmd_frame[1];
|
||||||
char* np = strchr(sp, ':'); // look for separator char
|
char* np = strchr(sp, ':'); // look for separator char
|
||||||
if (np) {
|
if (np) {
|
||||||
|
|
|
||||||
|
|
@ -40,9 +40,9 @@ build_flags = ${t1000-e.build_flags}
|
||||||
-D MAX_CONTACTS=100
|
-D MAX_CONTACTS=100
|
||||||
-D MAX_GROUP_CHANNELS=8
|
-D MAX_GROUP_CHANNELS=8
|
||||||
-D BLE_PIN_CODE=123456
|
-D BLE_PIN_CODE=123456
|
||||||
-D BLE_DEBUG_LOGGING=1
|
; -D BLE_DEBUG_LOGGING=1
|
||||||
-D MESH_PACKET_LOGGING=1
|
; -D MESH_PACKET_LOGGING=1
|
||||||
-D MESH_DEBUG=1
|
; -D MESH_DEBUG=1
|
||||||
-D RX_BOOSTED_GAIN=true
|
-D RX_BOOSTED_GAIN=true
|
||||||
-D RF_SWITCH_TABLE
|
-D RF_SWITCH_TABLE
|
||||||
-D HAS_UI
|
-D HAS_UI
|
||||||
|
|
|
||||||
|
|
@ -187,7 +187,7 @@ const char* T1000SensorManager::getSettingValue(int i) const {
|
||||||
bool T1000SensorManager::setSettingValue(const char* name, const char* value) {
|
bool T1000SensorManager::setSettingValue(const char* name, const char* value) {
|
||||||
if (strcmp(name, "gps") == 0) {
|
if (strcmp(name, "gps") == 0) {
|
||||||
if (strcmp(value, "0") == 0) {
|
if (strcmp(value, "0") == 0) {
|
||||||
stop_gps(); // or should this be sleep_gps() ??
|
sleep_gps(); // sleep for faster fix !
|
||||||
} else {
|
} else {
|
||||||
start_gps();
|
start_gps();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue