diff options
author | bwisn <56162793+bwisn@users.noreply.github.com> | 2021-10-18 07:17:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-18 16:17:29 +1100 |
commit | 7e3ff206b8600265ea086040b397f1a600c4a7f3 (patch) | |
tree | 0af0d0f17c01eeae7b2d30eb7a82904928def9a2 /tmk_core | |
parent | 1a63b24548cf0891621e54772320a5fec04186cb (diff) | |
download | qmk_firmware-7e3ff206b8600265ea086040b397f1a600c4a7f3.tar.gz qmk_firmware-7e3ff206b8600265ea086040b397f1a600c4a7f3.zip |
Add HT32 support to core (#14388)
* tmk_core: temporary fix to allow HT32 based keyboards to work without patched ChibiOS-contrib (AnnePro2)
* HT32: add spi support
Add persistent led support with eeprom (#9)
* adding HT32 support to chibios SPI master driver
update spi driver, fix bad merging with master
* HT32: fix formatting
HT32: Fix formatting: tmk_core/protocol/chibios/usb_main.c
Co-authored-by: Drashna Jaelre <drashna@live.com>
* HT32: Apply suggestions from fauxpark's code review
Co-authored-by: Ryan <fauxpark@gmail.com>
* HT32: update spi driver
* ht32: apply code review suggestions, remove old workaround
Co-authored-by: tech2077 <tech2077@gmail.com>
Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'tmk_core')
-rw-r--r-- | tmk_core/common/chibios/chibios_config.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/tmk_core/common/chibios/chibios_config.h b/tmk_core/common/chibios/chibios_config.h index c35f589557..f065948028 100644 --- a/tmk_core/common/chibios/chibios_config.h +++ b/tmk_core/common/chibios/chibios_config.h @@ -48,4 +48,12 @@ # define USE_I2CV1_CONTRIB // for some reason a bunch of ChibiOS-Contrib boards only have clock_speed # define USE_GPIOV1 # endif -#endif
\ No newline at end of file +#endif + +#if defined(HT32) +# define CPU_CLOCK HT32_CK_SYS_FREQUENCY +# define PAL_MODE_ALTERNATE PAL_HT32_MODE_AF +# define PAL_OUTPUT_TYPE_OPENDRAIN (PAL_HT32_MODE_OD | PAL_HT32_MODE_DIR) +# define PAL_OUTPUT_TYPE_PUSHPULL PAL_HT32_MODE_DIR +# define PAL_OUTPUT_SPEED_HIGHEST 0 +#endif |