My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

WProgram.h 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #ifndef WProgram_h
  2. #define WProgram_h
  3. #include <stdlib.h>
  4. #include <string.h>
  5. #include <math.h>
  6. #include <avr/interrupt.h>
  7. #include "wiring.h"
  8. #ifdef __cplusplus
  9. #include "WCharacter.h"
  10. #include "WString.h"
  11. #include "HardwareSerial.h"
  12. uint16_t makeWord(uint16_t w);
  13. uint16_t makeWord(byte h, byte l);
  14. #define word(...) makeWord(__VA_ARGS__)
  15. unsigned long pulseIn(uint8_t pin, uint8_t state, unsigned long timeout = 1000000L);
  16. void tone(uint8_t _pin, unsigned int frequency, unsigned long duration = 0);
  17. void noTone(uint8_t _pin);
  18. // WMath prototypes
  19. long random(long);
  20. long random(long, long);
  21. void randomSeed(unsigned int);
  22. long map(long, long, long, long, long);
  23. #if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
  24. const static uint8_t A0 = 54;
  25. const static uint8_t A1 = 55;
  26. const static uint8_t A2 = 56;
  27. const static uint8_t A3 = 57;
  28. const static uint8_t A4 = 58;
  29. const static uint8_t A5 = 59;
  30. const static uint8_t A6 = 60;
  31. const static uint8_t A7 = 61;
  32. const static uint8_t A8 = 62;
  33. const static uint8_t A9 = 63;
  34. const static uint8_t A10 = 64;
  35. const static uint8_t A11 = 65;
  36. const static uint8_t A12 = 66;
  37. const static uint8_t A13 = 67;
  38. const static uint8_t A14 = 68;
  39. const static uint8_t A15 = 69;
  40. #else
  41. const static uint8_t A0 = 14;
  42. const static uint8_t A1 = 15;
  43. const static uint8_t A2 = 16;
  44. const static uint8_t A3 = 17;
  45. const static uint8_t A4 = 18;
  46. const static uint8_t A5 = 19;
  47. const static uint8_t A6 = 20;
  48. const static uint8_t A7 = 21;
  49. #endif
  50. #endif
  51. #endif