Small typo fix

Signed-off-by: krzychb

Merges https://github.com/espressif/esp-idf/pull/1331
This commit is contained in:
Adrián Paníček 2017-11-29 09:26:44 +01:00 committed by krzychb
parent 866b84b9f8
commit 0f2d417a74

View file

@ -41,7 +41,7 @@ void app_main()
// Read // Read
printf("Reading restart counter from NVS ... "); printf("Reading restart counter from NVS ... ");
int32_t restart_counter = 0; // value will default to 0, if not set yet in NVS int32_t restart_counter = 0; // value will default to 0, if not set yet in NVS
err = nvs_get_i32(my_handle, "restart_conter", &restart_counter); err = nvs_get_i32(my_handle, "restart_counter", &restart_counter);
switch (err) { switch (err) {
case ESP_OK: case ESP_OK:
printf("Done\n"); printf("Done\n");
@ -57,7 +57,7 @@ void app_main()
// Write // Write
printf("Updating restart counter in NVS ... "); printf("Updating restart counter in NVS ... ");
restart_counter++; restart_counter++;
err = nvs_set_i32(my_handle, "restart_conter", restart_counter); err = nvs_set_i32(my_handle, "restart_counter", restart_counter);
printf((err != ESP_OK) ? "Failed!\n" : "Done\n"); printf((err != ESP_OK) ? "Failed!\n" : "Done\n");
// Commit written value. // Commit written value.