I’m using a raspberry pi 3 with Raspbian and Java 8 and need some help : I can’t find how to receive data from ADS1015’s pin.
I’m using NetBeans 8 with Java and I have Pi4J installed ( cf http://pi4j.com/ ).
My ADS1015 is detected by my Raspberry at 0x48 address (which is the one I had selected).
I tried something like :
But it doesn’t work and returns 133 all the time and I don’t understand why.
Code: Select all
I2CBus i2cbus = I2CFactory.getInstance(I2CBus.BUS_1); I2CDevice device1 = i2cbus.getDevice(0x48); System.out.println(device1.read());
I need to read data from ADS1015’s pin (A0, A1, A2 or A3) and I can’t find the specific command to proceed.
Please, help me !
Thanks in advance