PER Firmware
Loading...
Searching...
No Matches
sd_card.h
Go to the documentation of this file.
1
8
#ifndef SD_CARD_H
9
#define SD_CARD_H
10
11
#include <stdint.h>
12
#include "
common/rtos/rtos.h
"
13
14
typedef
enum
{
15
SD_STATE_DISABLED
= 0,
16
SD_STATE_INSERT_CARD
= 1,
17
SD_STATE_MOUNTING
= 2,
18
SD_STATE_OPENING_FILE
= 3,
19
SD_STATE_READY2LOG
= 4,
20
SD_STATE_CLOSING_FILE
= 5,
21
SD_STATE_UNMOUNTING
= 6,
22
SD_STATE_RECOVERING
= 7,
23
SD_STATE_FATAL
= 8
24
}
sd_state_t
;
25
26
static
constexpr
uint32_t
SD_FSM_PERIOD_MS
= 50;
27
void
sd_card_periodic
(
void
);
28
void
sd_power_loss_callback
(
void
);
29
30
#endif
// SD_CARD_H
rtos.h
Wrapper macros for FreeRTOS constructs (tasks, queues, semaphores) to simplify static memory allocati...
sd_card_periodic
void sd_card_periodic(void)
Definition
sd_card.c:72
SD_FSM_PERIOD_MS
static constexpr uint32_t SD_FSM_PERIOD_MS
Definition
sd_card.h:26
sd_power_loss_callback
void sd_power_loss_callback(void)
Definition
sd_card.c:67
sd_state_t
sd_state_t
Definition
sd_card.h:14
SD_STATE_RECOVERING
@ SD_STATE_RECOVERING
Definition
sd_card.h:22
SD_STATE_UNMOUNTING
@ SD_STATE_UNMOUNTING
Definition
sd_card.h:21
SD_STATE_DISABLED
@ SD_STATE_DISABLED
Definition
sd_card.h:15
SD_STATE_CLOSING_FILE
@ SD_STATE_CLOSING_FILE
Definition
sd_card.h:20
SD_STATE_READY2LOG
@ SD_STATE_READY2LOG
Definition
sd_card.h:19
SD_STATE_INSERT_CARD
@ SD_STATE_INSERT_CARD
Definition
sd_card.h:16
SD_STATE_OPENING_FILE
@ SD_STATE_OPENING_FILE
Definition
sd_card.h:18
SD_STATE_FATAL
@ SD_STATE_FATAL
Definition
sd_card.h:23
SD_STATE_MOUNTING
@ SD_STATE_MOUNTING
Definition
sd_card.h:17
firmware
source
daq
sd_card
sd_card.h
Generated by
1.12.0