I'm working with a rev sensor(color sensor-see in description). I know it's hexa adress, but i can't figure out the register hex for reading red,blue,green color. They do not provide a datasheet. I tried to do a "for in for", as from 0 --->0x99 to write and read registers but nothing.
After some research, i've found this LINK :http://www.mouser.com/ds/2/588/TMD3782_Datasheet_EN_v2-475385.pdf, where it seems to be a sensor almost like this.
When i try to use that register hex(i tried almost all of them) it does nothing but shows an integer continously.
Does that mean you don't even have a type string or the like from your sensor? What does "almost like this" mean? Does it just look similar? Does it claim to be compatible?
They do not provide a datasheet.
Then don't buy it. You'll never find out where the registers are and what their function is.
And this is the way i tried to cover register hex
Don't post code excerpts, always post complete code! And use code tags!!!
Your code won't work. Wire.read() never returns anything other than -1 if not preceded by a successful call to Wire.requestFrom().
The OP hinted that he bought the device at REV robotics. Google produced this page and sure enough, the lazy idiots do not provide a data sheet.
REV robotics does, however, provide this totally convincing user review:
THIS THING CHANGED MY LIFE!!! NOW I CAN SEE ALL COLORS, JUST WITH THIS SENSOR!! IT IS AWESOME. I THINK I AM IN LOVE WITH THIS PRODUCT.
COLOR SENSOR LOVER on Oct 12th 2017