Download data/examples/01basics/readav2.bas from introvoyz041/tinybasic: direct link, hf CLI and curl.
- Browser
- Download file 300 Bytes
-
https://huggingface.co/datasets/introvoyz041/tinybasic/resolve/main/data/examples/01basics/readav2.bas
- Command line
-
hf download hf://datasets/introvoyz041/tinybasic/data/examples/01basics/readav2.bas
-
curl -L -o readav2.bas https://huggingface.co/datasets/introvoyz041/tinybasic/resolve/main/data/examples/01basics/readav2.bas
300 Bytes
| 10 REM "ReadAnalogVoltage from Arduino examples - integer version" | |
| 100 REM "setup() put your setup code here, to run once:" | |
| 200 REM "loop() put your main code here, to run repeatedly:" | |
| 210 FOR I | |
| 220 S=AREAD(AZERO) | |
| 230 V=S*5/1023 | |
| 240 PRINT V;"."; | |
| 250 S=S-V*1023/5 | |
| 260 V=S*50/1023 | |
| 270 PRINT V | |
| 280 NEXT | |