Skip to content
Snippets Groups Projects
Commit ef45b851 authored by schneider's avatar schneider
Browse files

fix(bsec): More accurate statements about stack usage

parent 5ddc1877
No related branches found
No related tags found
No related merge requests found
...@@ -130,7 +130,7 @@ int main(void) ...@@ -130,7 +130,7 @@ int main(void)
if (xTaskCreate( if (xTaskCreate(
vBSECTask, vBSECTask,
(const char *)"BSEC", (const char *)"BSEC",
configMINIMAL_STACK_SIZE * 3, /* 768 bytes. Mainly for state saving... */ configMINIMAL_STACK_SIZE * 3,
NULL, NULL,
tskIDLE_PRIORITY + 1, tskIDLE_PRIORITY + 1,
NULL) != pdPASS) { NULL) != pdPASS) {
......
...@@ -203,6 +203,7 @@ void state_save(const uint8_t *state_buffer, uint32_t length) ...@@ -203,6 +203,7 @@ void state_save(const uint8_t *state_buffer, uint32_t length)
goto done; goto done;
} }
printf("stack high: %lu\n", uxTaskGetStackHighWaterMark(NULL));
printf("Success\n"); printf("Success\n");
done: done:
epic_file_close(fd); epic_file_close(fd);
...@@ -311,7 +312,7 @@ int bsec_read_bme680(struct bme680_sensor_data *data) ...@@ -311,7 +312,7 @@ int bsec_read_bme680(struct bme680_sensor_data *data)
* Checks config and activates the BSEC libary if requested. * Checks config and activates the BSEC libary if requested.
* *
* Initializes the BSEC library before starting the task to * Initializes the BSEC library before starting the task to
* reduce the stack size needed for the task by at least 512 bytes * reduce the stack size needed for the task by at least 250 bytes
*/ */
int bsec_activate(void) int bsec_activate(void)
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment