masaakiNakamura

IchigoJam_Train/pwmCompensation

Sep 12th, 2020
1,709
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. list 1,30000
  2.  
  3. 10 @ARUN:'Train
  4. 100 GOSUB @GETK: OUT 6
  5. 200 ?"Push BTN"
  6. 210 IF !BTN() THEN CONT
  7. 220 IF BTN() THEN CONT
  8. 230 WAIT 60
  9. 300 PWM 2,2000-K: WAIT 600
  10. 310 PWM 2,2000
  11. 320 GOTO 10
  12. 20000 @GETK
  13. 20010 K=ANA(2):WAIT2
  14. 20011 K=K+ANA(2):WAIT2
  15. 20012 K=K+ANA(2):WAIT2
  16. 20013 K=K+ANA(2):WAIT2
  17. 20014 K=K+ANA(2):WAIT2
  18. 20015 K=K+ANA(2):WAIT2
  19. 20016 K=K+ANA(2):WAIT2
  20. 20017 K=K+ANA(2):WAIT2
  21. 20018 K=K+ANA(2):WAIT2
  22. 20019 K=K+ANA(2)
  23. 20020 K=K/10
  24. 20050 K=495*64/K*31
  25.  
  26. 20060 IF K > 2000 THEN K = 2000: ?" Low Battery"
  27. 20090 RETURN
  28.  
  29.  
  30.  
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×