Files
templates/c/gas-logger/ports/pm35/gas_logger_pm35.h

17 lines
632 B
C

#ifndef GAS_LOGGER_PM35_H
#define GAS_LOGGER_PM35_H
#include "gas_logger.h"
/* Project adapter: pm35_modbus uses the firmware's zero-based modbus[128].
* pm67_voltage[2] is the latest CAN cache, updated under the same IRQ lock.
* No direct CAN requests are performed while capturing. */
typedef struct {
volatile uint16_t *modbus;
volatile uint16_t *pm67_voltage;
uint32_t (*enter)(void *);
void (*leave)(void *,uint32_t);
void *irq_user;
} gl_pm35_context;
gl_result gl_pm35_init(gas_logger *log, gl_pm35_context *context,
uint16_t *bank0, uint16_t *bank1, uint32_t bank_words);
#endif