05-12-2018 03:14 AM
Hi guy, I am actually having a hard time to find a good example to set up my color sensor for my robot by using myrio 1900/ I2C, is it possible to give me a good explanation how to use use read and write from myrio I2C , especially what does slavery address and byte count , byte reads mean/ corresponding to the attached color sensor datasheet , I am using 45-2018 model . thank you so much!
05-12-2018 02:46 PM - last edited on 05-14-2018 09:39 AM by Kristi_Martinez
hey, This might sound stupid, my school wants us to build a robot that would be able to implement the color sensor( datasheet is also attached ), As I pull off the myrio I2C bracket to the block diagram, I am having trouble to identify those input/ output parameters to what's given in the datasheet, like slavery address, byte count, byte read , bytes to write, and I can hardly find any example of this online, more specifically, how should those values given in the datasheet 0x67, 0x34, 0x56 be used in the labview coding? Thanks
color sensor datasheet
http://modernroboticsinc.com/Content/Images/uploaded/Sensors/Sensor%20Documentation.pdf
05-12-2018 02:56 PM - last edited on 05-14-2018 09:39 AM by Kristi_Martinez
This might sound stupid, my school wants us to build a robot that would be able to implement the color sensor( datasheet is also attached ), As I pull off the myrio I2C bracket to the block diagram, I am having trouble to identify those input/ output parameters to what's given in the datasheet, like slavery address, byte count, byte read , bytes to wrtie, and I can hardly find any example of this online, more specifically, how should those values given in the datasheet 0x67, 0x34, 0x56 be used in the labview coding? Thanks
color sensor model (45-2018)
Color sensor datasheet [45-2018]
05-13-2018 07:51 PM
No need to create 3 messages with the same question.
They've been merged into a single thread.
05-14-2018 11:39 AM
Hey Junn,
You might get some insight from the I2C examples (Help >> Find Examples >> Search 'i2c'). The 'Generic I2C' Read and Write examples would be a good starting point. I'm not sure if these are the same for myRIO toolkit examples, but it's worth checking.
You might also have some luck with the I2C Express VI. This page also explains what the different parameters are (i.e. byte count, bytes to read, etc.). The slave address, per that page, will have to be specified in 7 bits. So use something like a hex -> binary converter to determine what your address values should be.
Bdog
05-14-2018 12:39 PM
ohh, Thank you so much for the tip on example finding ( I didn't know there is a example finder,, it seems to be a great way to start off =D)!!