libsbp  v2.4.7
flash.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015-2018 Swift Navigation Inc.
3  * Contact: Swift Navigation <dev@swiftnav.com>
4  *
5  * This source is subject to the license found in the file 'LICENSE' which must
6  * be be distributed together with this source. All other rights reserved.
7  *
8  * THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
9  * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
10  * WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
11  */
12 
13 /*****************************************************************************
14  * Automatically generated from yaml/swiftnav/sbp/flash.yaml
15  * with generate.py. Please do not hand edit!
16  *****************************************************************************/
17 
27 #ifndef LIBSBP_FLASH_MESSAGES_H
28 #define LIBSBP_FLASH_MESSAGES_H
29 
30 #include "common.h"
31 
32 SBP_PACK_START
33 
34 
44 #define SBP_MSG_FLASH_PROGRAM 0x00E6
45 typedef struct SBP_ATTR_PACKED {
47  u8 addr_start[3];
51  u8 data[0];
53 
54 
62 #define SBP_MSG_FLASH_DONE 0x00E0
63 typedef struct SBP_ATTR_PACKED {
66 
67 
78 #define SBP_MSG_FLASH_READ_REQ 0x00E7
79 typedef struct SBP_ATTR_PACKED {
81  u8 addr_start[3];
86 
87 
98 #define SBP_MSG_FLASH_READ_RESP 0x00E1
99 typedef struct SBP_ATTR_PACKED {
101  u8 addr_start[3];
106 
107 
116 #define SBP_MSG_FLASH_ERASE 0x00E2
117 typedef struct SBP_ATTR_PACKED {
123 
124 
130 #define SBP_MSG_STM_FLASH_LOCK_SECTOR 0x00E3
131 typedef struct SBP_ATTR_PACKED {
134 
135 
141 #define SBP_MSG_STM_FLASH_UNLOCK_SECTOR 0x00E4
142 typedef struct SBP_ATTR_PACKED {
145 
146 
155 #define SBP_MSG_STM_UNIQUE_ID_REQ 0x00E8
156 
157 
166 #define SBP_MSG_STM_UNIQUE_ID_RESP 0x00E5
167 typedef struct SBP_ATTR_PACKED {
168  u8 stm_id[12];
170 
171 
177 #define SBP_MSG_M25_FLASH_WRITE_STATUS 0x00F3
178 typedef struct SBP_ATTR_PACKED {
179  u8 status[1];
181 
182 
185 SBP_PACK_END
186 
187 #endif /* LIBSBP_FLASH_MESSAGES_H */
u8 response
Response flags.
Definition: flash.h:64
u8 target
Target flags.
Definition: flash.h:46
u32 sector_num
Flash sector number to erase (0-11 for the STM, 0-15 for the M25)
Definition: flash.h:119
uint8_t u8
Unsigned 8-bit integer.
Definition: common.h:40
u8 target
Target flags.
Definition: flash.h:118
u8 addr_len
Length of set of addresses to program, counting up from starting address [bytes]. ...
Definition: flash.h:48
u32 sector
Flash sector number to unlock.
Definition: flash.h:143
u8 target
Target flags.
Definition: flash.h:100
u8 target
Target flags.
Definition: flash.h:80
uint32_t u32
Unsigned 32-bit integer.
Definition: common.h:44
u8 addr_len
Length of set of addresses to read, counting up from starting address [bytes].
Definition: flash.h:102
u32 sector
Flash sector number to lock.
Definition: flash.h:132
u8 addr_len
Length of set of addresses to read, counting up from starting address [bytes].
Definition: flash.h:82