WB32F10x Standard Peripherals Firmware Library

drv_iic_soft.h
1 #ifndef __DRV_IIC_SOFT_H__
2 #define __DRV_IIC_SOFT_H__
3
4 /* includes. */
5 #include "wb32f10x.h"
6
7
8
9 void IIC_Init(void);
10 void IIC_Start(void);
11 void IIC_Stop(void);
12 void IIC_Ack(void);
13 void IIC_NAck(void);
14 uint8_t IIC_WaitAck(void);
15 void IIC_SendByte(uint8_t data);
16 uint8_t IIC_ReadByte(void);
17 uint8_t IIC_CheckDevice(uint8_t address);
18
19 #define IIC_WR 0 /* 写控制bit */
20 #define IIC_RD 1 /* 读控制bit */
21
22
23 #endif /* __DRV_IIC_SOFT_H__ */