var arr = new Uint16Array(100);
for (var i=0;i<arr.length;i++) arr[i]=analogRead(INPUT_PIN)*65536;
result = arr[arr.length/2]/65536;
© Espruino, powered by microcosm.
Report a problem