separate PCA9685 driver into a shared directory
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
#ifndef PCA_9685_H_
|
||||
#define PCA_9685_H_
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
/* PCA9685 I2C address */
|
||||
/* 0x40 is the 7-bit address. HAL requires it shifted left by 1 (0x80) */
|
||||
#define PCA9685_ADDR_1 (0x41 << 1)
|
||||
#define PCA9685_ADDR_2 (0x42 << 1)
|
||||
|
||||
bool PCA9685_Init(uint8_t dev_addr);
|
||||
void PCA9685_SetPWM(uint8_t dev_addr, uint8_t channel, uint16_t on, uint16_t off);
|
||||
void PCA9685_SetPin(uint8_t dev_addr, uint8_t channel, uint8_t val);
|
||||
|
||||
#endif /* PCA_9685_H_ */
|
||||
Reference in New Issue
Block a user