Skip to content

Commit 0d714a4

Browse files
committed
storage: minor fixes
minor fixes Signed-off-by: Simen S. Røstad <simen.rostad@nordicsemi.no>
1 parent 62f5294 commit 0d714a4

5 files changed

Lines changed: 9 additions & 6 deletions

File tree

app/overlay-memfault.conf

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ CONFIG_MEMFAULT_COREDUMP_COLLECT_BSS_REGIONS=y
1919
CONFIG_MEMFAULT_COREDUMP_FULL_THREAD_STACKS=y
2020
## Disable metric to remove error due to missing File System mount point
2121
CONFIG_MEMFAULT_FS_BYTES_FREE_METRIC=n
22+
## Disable location metrics due to not being properly implemented for external handling of location
23+
## requests when using the location library.
24+
CONFIG_MEMFAULT_NCS_LOCATION_METRICS=n
2225

2326
# Certificate management
2427
CONFIG_MEMFAULT_ROOT_CERT_STORAGE_NRF9160_MODEM=y
@@ -27,7 +30,6 @@ CONFIG_MODEM_KEY_MGMT=y
2730
# Memfault NCS integration
2831
CONFIG_MEMFAULT_NCS_DEVICE_ID_IMEI=y
2932
CONFIG_MEMFAULT_NCS_PROJECT_KEY=""
30-
CONFIG_MEMFAULT_NCS_LOCATION_METRICS=y
3133
CONFIG_MEMFAULT_NCS_LTE_METRICS=y
3234
CONFIG_MEMFAULT_NCS_STACK_METRICS=y
3335
CONFIG_MEMFAULT_NCS_INTERNAL_FLASH_BACKED_COREDUMP=y

app/src/main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,8 @@ static void sampling_begin_common(struct main_state *state_object)
440440
uint32_t time_elapsed = current_time - state_object->sample_start_time;
441441

442442
if ((state_object->sample_start_time > 0) &&
443-
(time_elapsed < state_object->sample_interval_sec)) {
443+
(time_elapsed < state_object->sample_interval_sec) &&
444+
(state_object->chan != &BUTTON_CHAN)) {
444445
LOG_DBG("Too soon to start sampling, time_elapsed: %d, interval: %d",
445446
time_elapsed, state_object->sample_interval_sec);
446447

app/src/modules/storage/Kconfig.storage

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ config APP_STORAGE_MAX_RECORDS_PER_TYPE
4141

4242
config APP_STORAGE_BATCH_BUFFER_SIZE
4343
int "Storage batch buffer size in bytes"
44-
default 256
44+
default 1024
4545
help
4646
Size of the internal buffer for batch data access.
4747
This buffer is used to transfer data from the storage backend
@@ -95,6 +95,7 @@ config APP_STORAGE_SHELL
9595

9696
config APP_STORAGE_SHELL_STATS
9797
bool "Enable storage shell stats commands"
98+
default y if APP_STORAGE_SHELL
9899
help
99100
Enable shell commands for displaying statistics about the storage module.
100101
This includes information about stored records, types, and memory usage.

app/src/modules/storage/storage.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -938,8 +938,7 @@ static void state_buffer_pipe_active_run(void *o)
938938
break;
939939

940940
default:
941-
LOG_DBG("Ignoring message type: %d", msg->type);
942-
941+
/* Don't care */
943942
break;
944943
}
945944
}

app/src/modules/storage/storage_shell.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,4 +165,4 @@ SHELL_STATIC_SUBCMD_SET_CREATE(storage_sub_cmds,
165165
SHELL_SUBCMD_SET_END
166166
);
167167

168-
SHELL_CMD_REGISTER(storage, &storage_sub_cmds, "Storage module commands", NULL);
168+
SHELL_CMD_REGISTER(att_storage, &storage_sub_cmds, "Storage module commands", NULL);

0 commit comments

Comments
 (0)