Hallo,

wenn ich bei einem 10k Poti den Schleifer an Port 40 , und die beiden Enden an 32 und 31 schalte, druckt folgender Coder nur 1023.



KAnn mir jemand Hilfestellung geben?

Code:
$regfile = "m16def.dat"
$baud = 9600
$crystal = 16000000



Config Adc = Single , Prescaler = Auto
'Now give power to the chip
Start Adc

'With STOP ADC, you can remove the power from the chip
'Stop Adc

Dim W As Word , Channel As Byte

Channel = 0
'now read A/D value from channel 0
Do
  W = Getadc(channel)
  Print "Channel " ; Channel ; " value " ; W
  Incr Channel
  If Channel > 7 Then Channel = 0
Loop
End