示例#1
0
void mRGB_Init()
{
	// Init the I2C
	I2C_begin();	
		
	mRGB_cmd[ADDR0] = OLIMEX;				// I2C Slave Address (aka ADDR0)	
	mRGB_cmd[ADDR1] = MODRGB;				// I2C Register		 (aka ADDR1)
	mRGB_cmd[ADDR2] = ADDRESS;				// I2C Register		 (aka ADDR2)
}	
示例#2
0
文件: I2CBus.cpp 项目: ADTL/ARMWork
void I2CBus::begin(uint32_t clkHz)
{
	status = I2C_init(i2cx, I2CMASTER);
	status = I2C_begin(i2cx);
}