VLCB SDK
An opinionated SDK for VLCB protocol
Loading...
Searching...
No Matches
inc/vlcb/module/param.h
Go to the documentation of this file.
1#pragma once
2
3#include <stdint.h>
4
7
8#define VLCB_MODULE_PARAMS_MIN_LEN 20
9
10#define VLCB_MODULE_PARAMS(name, len) \
11 uint8_t name##_data[sizeof(VlcbModuleParams) + sizeof(uint8_t) * len]; \
12 VlcbModuleParams *const name = (VlcbModuleParams *const)name##_data;
13
14#define VLCB_MODULE_PARAMS_STD(name) \
15 VLCB_MODULE_PARAMS(name, VLCB_MODULE_PARAMS_MIN_LEN)
16
17typedef struct {
18 uint8_t len;
19 uint8_t buf[];
21
23 VlcbModuleParams *const params, const VlcbModuleVersion version,
24 const VlcbManufacturer moduleManu, const VlcbBusType busType,
25 const uint8_t moduleType, const uint8_t cpuId,
26 const VlcbProcessorManufacturer cpuManu,
27 const VlcbModuleParamCpuManuId cpuManuId,
28 const VlcbModuleParamLoadAddr loadAddr, const VlcbModuleFlags moduleFlags,
29 const uint8_t nodeVariableCount, const uint8_t eventCount,
30 const uint8_t eventVariableCount);
uint32_t VlcbModuleParamLoadAddr
char VlcbModuleParamCpuManuId[4]
void vlcb_module_params_Init(VlcbModuleParams *const params, const VlcbModuleVersion version, const VlcbManufacturer moduleManu, const VlcbBusType busType, const uint8_t moduleType, const uint8_t cpuId, const VlcbProcessorManufacturer cpuManu, const VlcbModuleParamCpuManuId cpuManuId, const VlcbModuleParamLoadAddr loadAddr, const VlcbModuleFlags moduleFlags, const uint8_t nodeVariableCount, const uint8_t eventCount, const uint8_t eventVariableCount)
Definition param.c:18
VlcbManufacturer
VlcbProcessorManufacturer
Definition processor.h:9