Make Electronics

(nextflipdebug2) #1

Experiment 35: Checking the Real World


308 Chapter 5


This table shows measurements made with PICAXE 08M controller.

Resistance (in ohms)
between the ADC
pin and the negative
supply

Equivalent digital
value

2000 255
1900 243
1800 230
1700 218
1600 205
1500 192
1400 179
1300 166
1200 154
1100 141
1000 128
900 115
800 102
700 90
600 77
500 64
400 51
300 38
200 26
100 13
0 0

Now we can modify the program to make it do something with the informa-
tion that it’s taking in:
main:
readadc 2,b0
let w1 = 5 * b0
high 1
pause w1
low 1
pause w1
goto main
Free download pdf