Skip to content

Commit 9363ccc

Browse files
authored
Merge pull request #73 from dmadison/t4
Teensy 4 Boards Support
2 parents 63c8d07 + 0183676 commit 9363ccc

File tree

3 files changed

+18
-13
lines changed

3 files changed

+18
-13
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,20 @@ jobs:
1313

1414
strategy:
1515
matrix:
16-
board: ['Arduino Leonardo (Serial)', 'Arduino Leonardo (XInput)', 'Teensy LC']
16+
board: ['Arduino Leonardo (Serial)', 'Arduino Leonardo (XInput)', 'Teensy 3.2', 'Teensy 4.0']
1717
include:
1818
- board: 'Arduino Leonardo (Serial)'
1919
fqbn: arduino:avr:leonardo
2020
- board: 'Arduino Leonardo (XInput)'
2121
fqbn: xinput:avr:leonardo
22-
- board: 'Teensy LC'
23-
fqbn: teensy:avr:teensyLC:usb=xinput,speed=48,opt=osstd,keys=en-us
22+
- board: 'Teensy 3.2'
23+
fqbn: teensy:avr:teensy31:usb=xinput,speed=72,opt=o2std,keys=en-us
24+
- board: 'Teensy 4.0'
25+
fqbn: teensy:avr:teensy40:usb=xinput,speed=600,opt=o2std,keys=en-us
2426

2527
steps:
2628
- name: Checkout
27-
uses: actions/checkout@v2
29+
uses: actions/checkout@v3
2830

2931
- name: Install Arduino IDE
3032
run: |

extras/SupportedBoards.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,12 @@ Here is a complete list of all of the currently supported boards. Each header li
2626
* [Qduino Mini](https://www.sparkfun.com/products/13614)
2727
* [LilyPad USB Plus](https://www.sparkfun.com/products/14346)
2828

29-
## [Teensy 3 Boards](https://github.com/dmadison/ArduinoXInput_Teensy/)
29+
## [Teensy Boards](https://github.com/dmadison/ArduinoXInput_Teensy/)
3030

3131
* [Teensy 3.6](https://www.pjrc.com/store/teensy36.html)
3232
* [Teensy 3.5](https://www.pjrc.com/store/teensy35.html)
3333
* [Teensy 3.1](https://www.pjrc.com/store/teensy31.html) / [3.2](https://www.pjrc.com/store/teensy32.html)
34-
* [Teensy LC](https://www.pjrc.com/teensy/teensyLC.html)
34+
* [Teensy LC](https://www.pjrc.com/store/teensylc.html)
35+
* [Teensy 4.0](https://www.pjrc.com/store/teensy40.html)
36+
* [Teensy 4.1](https://www.pjrc.com/store/teensy41.html)
37+
* [Teensy MicroMod](https://www.sparkfun.com/products/16402)

src/XInput.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,17 @@
3232
#warning "Non-XInput version selected in boards menu! Using debug print - board will not behave as an XInput device"
3333
#endif
3434

35-
// Teensy 3 Boards
35+
// Teensy Boards
3636
#elif defined(TEENSYDUINO)
37-
// Teensy 3.1-3.2: __MK20DX256__
38-
// Teensy LC: __MKL26Z64__
39-
// Teensy 3.5: __MK64FX512__
40-
// Teensy 3.6: __MK66FX1M0__
41-
// Teensy 4.0-4.1 __IMXRT1062__
37+
// Teensy 3.1-3.2: __MK20DX256__
38+
// Teensy LC: __MKL26Z64__
39+
// Teensy 3.5: __MK64FX512__
40+
// Teensy 3.6: __MK66FX1M0__
41+
// Teensy 4.0, 4.1, MicroMod __IMXRT1062__
4242
#if !defined(__MK20DX256__) && !defined(__MKL26Z64__) && \
4343
!defined(__MK64FX512__) && !defined(__MK66FX1M0__) && \
4444
!defined(__IMXRT1062__)
45-
#warning "Not a supported board! Must use Teensy 3.1/3.2, LC, 3.5, 3.6, or 4.0/4.1"
45+
#warning "Not a supported board! Must use Teensy 3.1/3.2, LC, 3.5, 3.6, 4.0, 4.1, or MicroMod"
4646
#elif !defined(USB_XINPUT)
4747
#warning "USB type is not set to XInput in boards menu! Using debug print - board will not behave as an XInput device"
4848
#endif /* if supported Teensy board */

0 commit comments

Comments
 (0)