pcf8574ap (I2C)-read potentiometer-

i would read my ptententiometre value with pcf8574ap and print it in monitore?
this is my programme:

#include "Wire.h"
#define pcf8574_adresse B00111000

int i=0;

int val;



void setup() {
 Serial.begin(9600);
 Wire.begin();
}

void loop() {
 Wire.beginTransmission(pcf8574_adresse);
 Wire.write(0x00);
 Wire.endTransmission();
 Wire.requestFrom(pcf8574_adresse,7);
i=Wire.read();
val=((i/16*10)+(i%16));
Serial.println(val);
}

what I need to do to display the value of 0 to1024?
thnks evrybody. :slight_smile: