logo

qmk_firmware

custom branch of QMK firmware git clone https://anongit.hacktivis.me/git/qmk_firmware.git

config.h (3266B)


  1. /*
  2. Copyright 2012 Jun Wako <wakojun@gmail.com>
  3. Copyright 2015 Jack Humbert
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation, either version 2 of the License, or
  7. (at your option) any later version.
  8. This program 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. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. */
  15. #pragma once
  16. // #define USB_VBUS_PIN B10
  17. // WS2812 RGB LED strip input and number of LEDs
  18. #define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
  19. #define WS2812_PWM_CHANNEL 1 // default: 2
  20. #define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
  21. //#define WS2812_PWM_COMPLEMENTARY_OUTPUT // Define for a complementary timer output (TIMx_CHyN); omit for a normal timer output (TIMx_CHy).
  22. // #define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
  23. #define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
  24. #define DEBUG_LED_PIN C13
  25. /* Audio config */
  26. #define AUDIO_PIN A5
  27. #define AUDIO_PIN_ALT A4
  28. #define AUDIO_PIN_ALT_AS_NEGATIVE
  29. /* serial.c configuration for split keyboard */
  30. #define SERIAL_USART_FULL_DUPLEX // Enable full duplex operation mode.
  31. #define SERIAL_USART_TX_PIN A9
  32. #define SERIAL_USART_RX_PIN A10
  33. #define SERIAL_USART_DRIVER SD1
  34. #define SERIAL_USART_TX_PAL_MODE 7 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 7
  35. #define SERIAL_USART_RX_PAL_MODE 7 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 7
  36. #define SERIAL_USART_TIMEOUT 100 // USART driver timeout. default 100
  37. /* i2c config for oleds */
  38. #define I2C_DRIVER I2CD1
  39. #define I2C1_SCL_PIN B6
  40. #define I2C1_SDA_PIN B7
  41. #define I2C1_SCL_PAL_MODE 4
  42. #define I2C1_SDA_PAL_MODE 4
  43. #define I2C1_CLOCK_SPEED 400000
  44. /* spi config for eeprom and pmw3360 sensor */
  45. #define SPI_DRIVER SPID2
  46. #define SPI_SCK_PIN B13
  47. #define SPI_SCK_PAL_MODE 5
  48. #define SPI_MOSI_PIN B15
  49. #define SPI_MOSI_PAL_MODE 5
  50. #define SPI_MISO_PIN B14
  51. #define SPI_MISO_PAL_MODE 5
  52. /* eeprom config */
  53. #define EXTERNAL_EEPROM_SPI_SLAVE_SELECT_PIN B8
  54. #define EXTERNAL_EEPROM_SPI_CLOCK_DIVISOR 8
  55. // #define EXTERNAL_EEPROM_BYTE_COUNT 8196
  56. // #define EXTERNAL_EEPROM_PAGE_SIZE 32
  57. // #define EXTERNAL_EEPROM_ADDRESS_SIZE 2
  58. // #define DEBUG_EEPROM_OUTPUT
  59. /* pmw3360 config */
  60. #define PMW33XX_CS_PIN B9
  61. #define PMW33XX_SPI_DIVISOR 8