Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gas sensor firmware update #733

Open
wants to merge 23 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 20 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions kitsune/commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -1298,6 +1298,14 @@ void sample_sensor_data(periodic_data* data,NetStats_t * keyword_net_stats)
data->tvoc = tvoc;
data->has_co2 = true;
data->co2 = eco2;

data->has_tvoc_ver = true;
data->tvoc_ver.has_tvoc_app_fw_version = true;
data->tvoc_ver.tvoc_app_fw_version = tvoc_get_fw_app_version();
data->tvoc_ver.has_tvoc_boot_fw_version = true;
data->tvoc_ver.tvoc_boot_fw_version = tvoc_get_fw_boot_version();
data->tvoc_ver.has_tvoc_hw_version = true;
data->tvoc_ver.tvoc_hw_version = tvoc_get_hw_version();
}
}
}
Expand Down Expand Up @@ -2057,6 +2065,10 @@ tCmdLineEntry g_sCmdTable[] = {
{ "thp", Cmd_read_temp_hum_press, "" },
{ "tv", Cmd_meas_TVOC, "" },
{"tvenv", Cmd_set_tvenv, ""},
{"tvfw",cmd_tvoc_fw_update, ""},
{"tvver",cmd_tvoc_get_ver, ""},
{"tvgets",cmd_tvoc_status, ""},
{"tverr",cmd_tvoc_errid, ""},

{ "uv", Cmd_read_uv, "" },
{ "light", Cmd_readlight, "" },
Expand Down
2 changes: 2 additions & 0 deletions kitsune/fatfs_cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -999,6 +999,8 @@ xQueueHandle download_queue = 0;

hlo_stream_t * hlo_http_get_opt(hlo_stream_t * sock, const char * host, const char * endpoint);

int tvoc_fw_update(const char* path, const char* filename);

void file_download_task( void * params ) {
SyncResponse_FileDownload download_info;
unsigned char top_sha_cache[SHA1_SIZE];
Expand Down
Loading