Analogvalue A0 inverted tfrom 12 to 8bit. 8bit controlled by com-port. 8bits to IIC-IC PCF8574a with 8leds lowaktiv. You see there a 8bit digital counter depending aof the analogvalue.
Homepage
My boards Nucleo F103RB and two IIC Systems:
Neumaier Feb 2018