Update ThingSet library (new NVM handling)
This commit is contained in:
@@ -1187,6 +1187,8 @@ void data_objects_init()
|
||||
else {
|
||||
battery_conf_overwrite(&bat_conf, &bat_conf_user);
|
||||
}
|
||||
|
||||
ts.set_update_callback(SUBSET_NVM, data_objects_update_conf);
|
||||
}
|
||||
|
||||
void thingset_auth()
|
||||
|
||||
@@ -117,10 +117,6 @@ void can_isotp_thread()
|
||||
LOG_INF("Got %d bytes via ISO-TP. Processing ThingSet message.", req_len);
|
||||
resp_len = ts.process(rx_buffer, req_len, tx_buffer, sizeof(tx_buffer));
|
||||
LOG_DBG("TX buf: %x %x %x %x", tx_buffer[0], tx_buffer[1], tx_buffer[2], tx_buffer[3]);
|
||||
|
||||
if (ts.check_updated(SUBSET_NVM, true)) {
|
||||
data_objects_update_conf();
|
||||
}
|
||||
}
|
||||
else {
|
||||
tx_buffer[0] = TS_STATUS_INTERNAL_SERVER_ERR;
|
||||
|
||||
@@ -65,11 +65,6 @@ void serial_process_command()
|
||||
uart_poll_out(uart_dev, tx_buf[i]);
|
||||
}
|
||||
uart_poll_out(uart_dev, '\n');
|
||||
|
||||
if (ts.check_updated(SUBSET_NVM, true)) {
|
||||
// ToDo: This could take a few milliseconds, better offload from ISR context
|
||||
data_objects_update_conf();
|
||||
}
|
||||
}
|
||||
|
||||
// release buffer and start waiting for new commands
|
||||
|
||||
Reference in New Issue
Block a user