ruuvi.drivers.c
${PROJECT_VERSION}
Drivers for external sensors and peripherals on embedded systems.
|
Go to the source code of this file.
Data Structures | |
struct | fds_page_t |
struct | fds_swap_page_t |
struct | fds_op_t |
struct | fds_gc_data_t |
#define CRITICAL_SECTION_ENTER | ( | ) |
Definition at line 319 of file fds_internal_defs.h.
#define CRITICAL_SECTION_EXIT | ( | ) |
Definition at line 320 of file fds_internal_defs.h.
#define FDS_DATA_PAGES (FDS_VIRTUAL_PAGES - 1) |
Definition at line 99 of file fds_internal_defs.h.
#define FDS_ERASED_WORD (0xFFFFFFFF) |
Definition at line 64 of file fds_internal_defs.h.
#define FDS_HEADER_SIZE (3) |
Definition at line 74 of file fds_internal_defs.h.
#define FDS_HEADER_SIZE_IC (1) |
Definition at line 72 of file fds_internal_defs.h.
#define FDS_HEADER_SIZE_ID (1) |
Definition at line 73 of file fds_internal_defs.h.
#define FDS_HEADER_SIZE_TL (1) |
Definition at line 71 of file fds_internal_defs.h.
#define FDS_OFFSET_DATA (3) |
Definition at line 69 of file fds_internal_defs.h.
#define FDS_OFFSET_IC (1) |
Definition at line 67 of file fds_internal_defs.h.
#define FDS_OFFSET_ID (2) |
Definition at line 68 of file fds_internal_defs.h.
#define FDS_OFFSET_TL (0) |
Definition at line 66 of file fds_internal_defs.h.
#define FDS_OP_COMPLETED (0x1D1D) |
Definition at line 77 of file fds_internal_defs.h.
#define FDS_OP_EXECUTING (NRF_SUCCESS) |
Definition at line 76 of file fds_internal_defs.h.
#define FDS_PAGE_SIZE (FDS_VIRTUAL_PAGE_SIZE) |
Definition at line 102 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_DATA (0xF11E01FE) |
Definition at line 62 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_MAGIC (0xDEADC0DE) |
Definition at line 60 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_SIZE (2) |
Copyright (c) 2015 - 2019, Nordic Semiconductor ASA
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY NORDIC SEMICONDUCTOR ASA "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL NORDIC SEMICONDUCTOR ASA OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Definition at line 55 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_SWAP (0xF11E01FF) |
Definition at line 61 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_WORD_0 (0) |
Definition at line 56 of file fds_internal_defs.h.
#define FDS_PAGE_TAG_WORD_1 (1) |
Definition at line 57 of file fds_internal_defs.h.
#define FDS_PHY_PAGE_SIZE (1024) |
Definition at line 86 of file fds_internal_defs.h.
#define FDS_PHY_PAGES ((FDS_VIRTUAL_PAGES * FDS_VIRTUAL_PAGE_SIZE) / FDS_PHY_PAGE_SIZE) |
Definition at line 90 of file fds_internal_defs.h.
#define FDS_PHY_PAGES_IN_VPAGE (FDS_VIRTUAL_PAGE_SIZE / FDS_PHY_PAGE_SIZE) |
Definition at line 96 of file fds_internal_defs.h.
#define FDS_PHY_PAGES_RESERVED ((FDS_VIRTUAL_PAGES_RESERVED * FDS_VIRTUAL_PAGE_SIZE) / FDS_PHY_PAGE_SIZE) |
Definition at line 93 of file fds_internal_defs.h.
#define NRF_FSTORAGE_NVMC 1 |
Definition at line 79 of file fds_internal_defs.h.
#define NRF_FSTORAGE_SD 2 |
Definition at line 80 of file fds_internal_defs.h.
anonymous enum |
Enumerator | |
---|---|
PAGE_ERASED | |
PAGE_DATA | |
PAGE_SWAP_CLEAN | |
PAGE_SWAP_DIRTY |
Definition at line 236 of file fds_internal_defs.h.
enum fds_delete_step_t |
Enumerator | |
---|---|
FDS_OP_DEL_RECORD_FLAG_DIRTY | |
FDS_OP_DEL_FILE_FLAG_DIRTY | |
FDS_OP_DEL_DONE |
Definition at line 183 of file fds_internal_defs.h.
enum fds_gc_state_t |
Enumerator | |
---|---|
GC_BEGIN | |
GC_NEXT_PAGE | |
GC_FIND_NEXT_RECORD | |
GC_COPY_RECORD | |
GC_ERASE_PAGE | |
GC_DISCARD_SWAP | |
GC_PROMOTE_SWAP | |
GC_TAG_NEW_SWAP |
Definition at line 286 of file fds_internal_defs.h.
enum fds_header_status_t |
Enumerator | |
---|---|
FDS_HEADER_VALID | |
FDS_HEADER_DIRTY | |
FDS_HEADER_CORRUPT |
Definition at line 123 of file fds_internal_defs.h.
enum fds_init_opts_t |
Enumerator | |
---|---|
NO_PAGES | |
NO_SWAP | |
FRESH_INSTALL | |
TAG_SWAP | |
TAG_DATA | |
TAG_DATA_INST | |
PROMOTE_SWAP | |
PROMOTE_SWAP_INST | |
DISCARD_SWAP | |
ALREADY_INSTALLED |
Definition at line 245 of file fds_internal_defs.h.
enum fds_init_step_t |
Enumerator | |
---|---|
FDS_OP_INIT_TAG_SWAP | |
FDS_OP_INIT_TAG_DATA | |
FDS_OP_INIT_ERASE_SWAP | |
FDS_OP_INIT_PROMOTE_SWAP |
Definition at line 162 of file fds_internal_defs.h.
enum fds_op_code_t |
Enumerator | |
---|---|
FDS_OP_NONE | |
FDS_OP_INIT | |
FDS_OP_WRITE | |
FDS_OP_UPDATE | |
FDS_OP_DEL_RECORD | |
FDS_OP_DEL_FILE | |
FDS_OP_GC |
Definition at line 150 of file fds_internal_defs.h.
enum fds_page_type_t |
Enumerator | |
---|---|
FDS_PAGE_DATA | |
FDS_PAGE_SWAP | |
FDS_PAGE_ERASED | |
FDS_PAGE_UNDEFINED |
Definition at line 114 of file fds_internal_defs.h.
enum fds_write_step_t |
Enumerator | |
---|---|
FDS_OP_WRITE_HEADER_BEGIN | |
FDS_OP_WRITE_HEADER_FINALIZE | |
FDS_OP_WRITE_RECORD_ID | |
FDS_OP_WRITE_DATA | |
FDS_OP_WRITE_FIND_RECORD | |
FDS_OP_WRITE_FLAG_DIRTY | |
FDS_OP_WRITE_DONE |
Definition at line 171 of file fds_internal_defs.h.