summaryrefslogtreecommitdiff
path: root/controller/fw/src/protocol.c
diff options
context:
space:
mode:
authorjaseg <git-bigdata-wsl-arch@jaseg.de>2020-03-16 19:19:34 +0100
committerjaseg <git-bigdata-wsl-arch@jaseg.de>2020-03-16 19:19:34 +0100
commita1dc923315514ed6f23da5f2c0950830975299f8 (patch)
tree9954004d0517c73b57a2021213a91975b7779931 /controller/fw/src/protocol.c
parentfed186a49fc8f27a8a31fd40f8c8b26d32a4b932 (diff)
downloadmaster-thesis-a1dc923315514ed6f23da5f2c0950830975299f8.tar.gz
master-thesis-a1dc923315514ed6f23da5f2c0950830975299f8.tar.bz2
master-thesis-a1dc923315514ed6f23da5f2c0950830975299f8.zip
Fix serial
Diffstat (limited to 'controller/fw/src/protocol.c')
-rw-r--r--controller/fw/src/protocol.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/controller/fw/src/protocol.c b/controller/fw/src/protocol.c
index 17020bd..bbee5ef 100644
--- a/controller/fw/src/protocol.c
+++ b/controller/fw/src/protocol.c
@@ -1,7 +1,13 @@
#include "sr_global.h"
#include "dsss_demod.h"
+#include "con_usart.h"
-void handle_dsss_received(uint8_t unused_a data[static TRANSMISSION_SYMBOLS]) {
- asm volatile ("bkpt");
+void handle_dsss_received(uint8_t data[static TRANSMISSION_SYMBOLS]) {
+ con_printf("DSSS data received: ");
+ for (int i=0; i<TRANSMISSION_SYMBOLS; i++) {
+ int x = (data[i]>>1) * (data[i]&1 ? 1 : -1);
+ con_printf("%3d ", x);
+ }
+ con_printf("\r\n");
}