这里写模块介绍介绍,做到读完这段,就能对模块有初步了解,让客户懂的用这个模块能干什么
这里需要显示拍照图片,可以一张图片,可以多张图片(不要用SVG图)
SKU:产品名称
这里填写当前Arduino软件库完成了哪些功能
To use this library, first download the library file, paste it into the \Arduino\libraries directory, then open the examples folder and run the demo in the folder.
typedef struct {
uint8_t b: 5;
uint8_t g: 6;
uint8_t r: 5;
} __attribute__ ((packed)) sColor_t;
typedef struct {
uint8_t light: 4;
uint8_t sound: 4;
} __attribute__ ((packed)) sCombinedData_t;
typedef struct {
uint8_t lowpower: 1;
uint8_t highspeed: 1;
uint8_t reserved: 7;
} __attribute__ ((packed)) sMode_t;
typedef enum{
eNormalPower = 0,
eLowPower = 1,
}eLowPowerMode_t;
typedef enum{
eNormalSpeed = 0<<1,
eHighSpeed = 1<<1,
}eHighSpeedMode_t;
/**
* @brief 初始化函数
* @return 返回0表示初始化成功,返回其他值表示初始化失败
*/
int begin(void);
/**
* @brief 获取声音强度值
* @return 返回声音强度,单位是DB
*/
uint16_t getSoundStrength(void);
/**
* @brief 获取光线强度值
* @return 返回光线强度,单位是流明
*/
uint16_t getLightStrength(void);
/**
* @brief 切换模式
* @return 返回0操作成功, 返回其他值操作失败
*/
uint8_t switchMode(uint8_t mode);
/**
* @brief 设置LED灯的颜色
@note 设置颜色后,0.2秒后生效
* @param r 红色通道颜色值,范围0-255
* @param g 绿色通道颜色值,范围0-255
* @param b 蓝色通道颜色值,范围0-255
*/
void setLED(uint8_t r, uint8_t g, uint8_t b);
/**
* @brief 设置LED灯的颜色
@note 设置颜色后,0.2秒后生效
* @param color rgb565格式的颜色值
*/
void setLED(uint16_t color);
MCU | Work Well | Work Wrong | Untested | Remarks |
---|---|---|---|---|
Arduino uno | √ | |||
Mega2560 | √ | |||
Leonardo | √ | |||
ESP32 | √ |
- data 2019-6-25
- version V0.1
Written by([email protected]), 2019. (Welcome to our website)