feat(gas-logger): добавь непрерывный логгер и JSON-карту
This commit is contained in:
8
c/gas-logger/ports/stm32/gas_logger_stm32.c
Normal file
8
c/gas-logger/ports/stm32/gas_logger_stm32.c
Normal file
@@ -0,0 +1,8 @@
|
||||
#include "gas_logger_stm32.h"
|
||||
#ifndef GL_STM32_DEVICE_HEADER
|
||||
#define GL_STM32_DEVICE_HEADER "stm32f4xx.h"
|
||||
#endif
|
||||
#include GL_STM32_DEVICE_HEADER
|
||||
uint32_t gl_stm32_enter(void *user)
|
||||
{ uint32_t saved; (void)user; saved=__get_PRIMASK(); __disable_irq(); return saved; }
|
||||
void gl_stm32_leave(void *user,uint32_t state) { (void)user; __set_PRIMASK(state); }
|
||||
8
c/gas-logger/ports/stm32/gas_logger_stm32.h
Normal file
8
c/gas-logger/ports/stm32/gas_logger_stm32.h
Normal file
@@ -0,0 +1,8 @@
|
||||
#ifndef GAS_LOGGER_STM32_H
|
||||
#define GAS_LOGGER_STM32_H
|
||||
#include <stdint.h>
|
||||
/* Define GL_STM32_DEVICE_HEADER to the project's CMSIS device header.
|
||||
* F1/F4/G4 use the same PRIMASK contract. No HAL/interrupt handler ownership. */
|
||||
uint32_t gl_stm32_enter(void *user);
|
||||
void gl_stm32_leave(void *user,uint32_t state);
|
||||
#endif
|
||||
Reference in New Issue
Block a user