how to configure a I2C in MCB1700 with LPC1758?
I have a MCB1700 board with LPC1758, I am trying to use the I2C on it as a master to run a ultrasonic sensor srf08.
How should I configure the I2C setting on the LPC1758?
Hello ,
I have used the I2C driver that comes with the NXP MCB1700 bundle and so I might be able to help you out.
I just took a quick look at the srf08 datasheet and so as to not make any assumptions, I just want to ask a few questions.
Is the hardware setup already done?
Pull up resistors?
does the microcontroller you are using have a 5V I2C interface?
The srf08 is an I2C slave device and your microcontroller will be the master as albanrampon suggested.
As far as the software is concerned, to do the simplest test to ensure the sensor is connected and the software is proper, read location 0 of the srf08. As mentioned in the datasheet, it should return to you the software revision of the srf08.