Skip to content

Commit

Permalink
[examples] Deduplicate USB examples
Browse files Browse the repository at this point in the history
  • Loading branch information
salkinium committed Jan 6, 2024
1 parent 124c414 commit ca06286
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 291 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,11 @@ jobs:
- name: Examples SAMD Devices
if: always()
run: |
(cd examples && ../tools/scripts/examples_compile.py feather_m4 samd samd21_xplained_pro)
(cd examples && ../tools/scripts/examples_compile.py feather_m4 samd)
- name: Examples SAMG Devices
if: always()
run: |
(cd examples && ../tools/scripts/examples_compile.py samg55_xplained_pro)
- name: Examples SAME5x Devices
if: always()
run: |
(cd examples && ../tools/scripts/examples_compile.py same54_xplained_pro)
- name: Examples SAME70 Devices
if: always()
run: |
Expand Down
51 changes: 0 additions & 51 deletions examples/feather_m4/usbserial/main.cpp

This file was deleted.

12 changes: 0 additions & 12 deletions examples/feather_m4/usbserial/project.xml

This file was deleted.

6 changes: 6 additions & 0 deletions examples/generic/usb/project.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,16 @@
<!-- <extends>modm:disco-f746ng</extends> -->
<!-- <extends>modm:disco-l476vg</extends> -->
<!-- <extends>modm:feather-m0</extends> -->
<!-- <extends>modm:feather-m4</extends> -->
<!-- <extends>modm:nucleo-f429zi</extends> -->
<!-- <extends>modm:nucleo-h723zg</extends> -->
<!-- <extends>modm:nucleo-h743zi</extends> -->
<!-- <extends>modm:rp-pico</extends> -->
<!-- <extends>modm:samd21-mini</extends> -->
<!-- <extends>modm:samd21-xplained-pro</extends> -->
<!-- <extends>modm:same54-xplained-pro</extends> -->
<!-- <extends>modm:samg55-xplained-pro</extends> -->
<!-- <extends>modm:nucleo-f446ze</extends> -->
<options>
<option name="modm:build:build.path">../../../build/generic/usb</option>
<option name="modm:build:openocd.cfg">openocd.cfg</option>
Expand All @@ -34,6 +39,7 @@
<module>modm:io</module>
</modules>
<collectors>
<!-- Optional for modm:disco-f746ng -->
<!-- <collect name="modm:build:cppdefines">CFG_TUSB_DEBUG=3</collect> -->
</collectors>
</library>
56 changes: 0 additions & 56 deletions examples/nucleo_f446ze/usbserial/main.cpp

This file was deleted.

13 changes: 0 additions & 13 deletions examples/nucleo_f446ze/usbserial/project.xml

This file was deleted.

44 changes: 0 additions & 44 deletions examples/samd21_xplained_pro/usbserial/main.cpp

This file was deleted.

12 changes: 0 additions & 12 deletions examples/samd21_xplained_pro/usbserial/project.xml

This file was deleted.

44 changes: 0 additions & 44 deletions examples/same54_xplained_pro/usbserial/main.cpp

This file was deleted.

12 changes: 0 additions & 12 deletions examples/same54_xplained_pro/usbserial/project.xml

This file was deleted.

29 changes: 0 additions & 29 deletions examples/samg55_xplained_pro/usbserial/main.cpp

This file was deleted.

13 changes: 0 additions & 13 deletions examples/samg55_xplained_pro/usbserial/project.xml

This file was deleted.

6 changes: 6 additions & 0 deletions src/modm/board/samg55_xplained_pro/board.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,12 @@ initialize()
inline void
initializeUsbFs()
{
// Pull DP low briefly on reset to make sure USB host disconnects/reconnects
MATRIX->CCFG_SYSIO |= (CCFG_SYSIO_SYSIO11 | CCFG_SYSIO_SYSIO10);
GpioA22::setOutput(false);
modm::delay_ms(5);
GpioA22::setInput();

SystemClock::enableUsb();
Usb::initialize<Board::SystemClock>();
}
Expand Down

0 comments on commit ca06286

Please sign in to comment.