Advertisement
Guest User

Untitled

a guest
Jun 24th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. #include <os.h>
  2. #include <common.h>
  3. #include "graphics.h"
  4. #include "utils.h"
  5. #include "main.h"
  6.  
  7. int main(void) {
  8. enableLink();
  9. clearScreen();
  10. int number = 0;
  11. while (!isKeyPressed(KEY_NSPIRE_ESC) && !isKeyPressed(KEY_84_CLEAR))
  12. {
  13. if (number < 2000)
  14. {
  15. KEYPAD_84_IO = 3;
  16. }
  17. else
  18. {
  19. KEYPAD_84_IO = 0;
  20. }
  21. number++;
  22. if (number == 4000)
  23. number = 0;
  24. }
  25. disableLink();
  26. return 0;
  27. }
  28.  
  29. void enableLink()
  30. {
  31. MISC_PORTS |= 0x20;
  32. }
  33.  
  34. void disableLink()
  35. {
  36. MISC_PORTS &= 0x20;
  37. }
  38.  
  39. void InterruptHandler()
  40. {
  41.  
  42. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement