diff options
author | tomaszduda23 <[email protected]> | 2022-09-12 11:53:52 +0200 |
---|---|---|
committer | GitHub <[email protected]> | 2022-09-12 12:53:52 +0300 |
commit | 615863a84846a5a26e5505bdd5e0d63d3baee6e0 (patch) | |
tree | 7d3c8e672dd4356d5b6e3c480c77d284e2845ba7 /hid/lib/drivers-stm32/factory.cpp | |
parent | ce43938d2810fb0bf5d9c89116cf5fc2d02ca40c (diff) |
add SW reset (#107)
Diffstat (limited to 'hid/lib/drivers-stm32/factory.cpp')
-rw-r--r-- | hid/lib/drivers-stm32/factory.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/hid/lib/drivers-stm32/factory.cpp b/hid/lib/drivers-stm32/factory.cpp index e41da67d..247f388f 100644 --- a/hid/lib/drivers-stm32/factory.cpp +++ b/hid/lib/drivers-stm32/factory.cpp @@ -26,6 +26,7 @@ #include "usb/mouse-absolute-stm32.h" #include "usb/mouse-relative-stm32.h" #include "backup-register.h" +#include "board-stm32.h" #ifndef __STM32F1__ # error "Only STM32F1 is supported" @@ -72,4 +73,14 @@ namespace DRIVERS { return new Storage(DRIVERS::DUMMY); } } + + Board* Factory::makeBoard(type _type) { + switch (_type) { + case BOARD: + return new BoardStm32(); + default: + return new Board(DRIVERS::DUMMY); + } + } + } |