fiatlux/firmware/bus.h
jedi 1cd16f0aad
Some checks failed
continuous-integration/drone/push Build is failing
stash
2023-02-19 13:40:59 +01:00

32 lines
514 B
C

#ifndef FIATLUX_BUS_H
#define FIATLUX_BUS_H
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
uint32_t spi_transfer_32_duplex(uint8_t bus, uint32_t val);
uint16_t spi_transfer_16_duplex(uint8_t bus, uint32_t val);
uint32_t bus_transfer_msg(uint8_t addr, uint16_t dat);
bool bus_transfer_msg_arr(uint8_t addr, uint16_t dat[], uint8_t len);
uint16_t bus_get_version();
bool bus_ping();
void reset_bus();
bool bus_init();
bool bus_init_next();
#ifdef __cplusplus
}
#endif
#endif //FIATLUX_BUS_H