Skip to content

Commit

Permalink
Merge pull request #5 from sblakemore/motolab-1wire
Browse files Browse the repository at this point in the history
Add 1wire support to MOTOLAB target on UART1
  • Loading branch information
borisbstyle committed Sep 14, 2015
2 parents b8c5a2c + 2a9aba7 commit c1afeaf
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/main/io/serial_1wire.c
Expand Up @@ -62,6 +62,15 @@ const escHardware_t escHardware[ESC_COUNT] = {
{ GPIOB, 9 },
{ GPIOA, 2 },
{ GPIOA, 3 }
#elif MOTOLAB
{ GPIOA, 4 },
{ GPIOA, 6 },
{ GPIOB, 0 },
{ GPIOB, 1 },
{ GPIOA, 1 },
{ GPIOA, 2 },
{ GPIOA, 3 },
{ GPIOA, 8 }
#endif
};

Expand Down
7 changes: 7 additions & 0 deletions src/main/target/MOTOLAB/target.h
Expand Up @@ -176,3 +176,10 @@
#define BIND_PORT GPIOB
#define BIND_PIN Pin_4

#define USE_SERIAL_1WIRE
#define ESC_COUNT 8
#define S1W_TX_GPIO GPIOB
#define S1W_TX_PIN GPIO_Pin_6
#define S1W_RX_GPIO GPIOB
#define S1W_RX_PIN GPIO_Pin_7

0 comments on commit c1afeaf

Please sign in to comment.