DIY fertilizer mixer and plant watering machine https://www.xythobuz.de/giessomat.html
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.

config_pins.h 1.8KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. #ifndef _CONFIG_PINS_H_
  2. #define _CONFIG_PINS_H_
  3. // ----------------------------------------------------------------------------
  4. // ----------------------------------------------------------------------------
  5. #ifdef PLATFORM_AVR
  6. #define BUILTIN_LED_PIN 13
  7. // ----------------------------------------------------------------------------
  8. #ifdef FUNCTION_UI
  9. #define SERIAL_LCD_TX_PIN 10
  10. #define KEYMATRIX_ROWS 4
  11. #define KEYMATRIX_COLS 3
  12. #define KEYMATRIX_ROW_PINS 5, 6, 7, 8
  13. #define KEYMATRIX_COL_PINS 2, 3, 4
  14. #endif // FUNCTION_UI
  15. // ----------------------------------------------------------------------------
  16. #ifdef FUNCTION_CONTROL
  17. #define VALVE_COUNT 5
  18. #define VALVE_PINS 10, 11, 12, 14, 15
  19. #define PUMP_COUNT 3
  20. #define PUMP_PINS 16, 17, 18
  21. #define SWITCH_COUNT 2
  22. #define SWITCH_PINS 19, 20
  23. #endif // FUNCTION_CONTROL
  24. #endif // PLATFORM_AVR
  25. // ----------------------------------------------------------------------------
  26. // ----------------------------------------------------------------------------
  27. #ifdef PLATFORM_ESP
  28. #define BUILTIN_LED_PIN 1
  29. // ----------------------------------------------------------------------------
  30. #ifdef FUNCTION_UI
  31. #error configuration not supported
  32. #endif // FUNCTION_UI
  33. // ----------------------------------------------------------------------------
  34. #ifdef FUNCTION_CONTROL
  35. // R1 R2 R3 R4 R5 R6 R7 R8
  36. // 4 0 2 15 18 5 17 16
  37. #define VALVE_COUNT 5
  38. #define VALVE_PINS 4, 0, 2, 15, 18
  39. #define PUMP_COUNT 3
  40. #define PUMP_PINS 5, 17, 16
  41. #define SWITCH_COUNT 2
  42. #define SWITCH_PINS 22, 23
  43. #define I2C_SDA_PIN 21
  44. #define I2C_SCL_PIN 22
  45. #endif // FUNCTION_CONTROL
  46. #endif // PLATFORM_ESP
  47. // ----------------------------------------------------------------------------
  48. // ----------------------------------------------------------------------------
  49. #endif // _CONFIG_PINS_H_