Kiibohd Controller
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.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /* Copyright (C) 2014-2016 by Jacob Alexander
  2. *
  3. * This file is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 3 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This file is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this file. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #pragma once
  17. // ----- Includes -----
  18. // Project Includes
  19. #include <matrix_setup.h>
  20. // ----- Matrix Definition -----
  21. // CapTest
  22. // (TODO)
  23. //
  24. // Strobe
  25. // PTB0..3,16,17
  26. // PTC4,5
  27. // PTD0
  28. //
  29. // Sense
  30. // PTD1..7
  31. // -- Strobes --
  32. // Format
  33. // gpio( <port letter>, <port #> )
  34. // Freescale ARM MK20's support GPIO PTA, PTB, PTC, PTD and PTE 0..31
  35. // Not all chips have access to all of these pins (most don't have 160 pins :P)
  36. //
  37. GPIO_Pin Matrix_strobe[] = { gpio(B,0), gpio(B,1), gpio(B,2), gpio(B,3), gpio(B,16), gpio(B,17), gpio(C,4), gpio(C,5), gpio(D,0) };
  38. // -- Sense --
  39. // Format
  40. // sense( <port letter>, <port #>, <adc #>, <adc channel #> )
  41. // Freescale ARM MK20's support 32 ADC channels
  42. // However, not every channel is useful for reading from an input pin.
  43. //
  44. // NOTE: Be careful that you are not using a strobe and a sense at the same time!
  45. //
  46. ADC_Pin Matrix_sense[] = { sense(B,4,0,5) };
  47. // TODO
  48. // Misc pins required for control