From 9debe084fca8992efdf0f08bfed343de0987629e Mon Sep 17 00:00:00 2001 From: jaseg Date: Mon, 9 Mar 2020 13:23:35 +0100 Subject: demod wip --- controller/fw/tools/dsss_demod_test.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'controller/fw/tools') diff --git a/controller/fw/tools/dsss_demod_test.c b/controller/fw/tools/dsss_demod_test.c index 4370f80..d76a8bd 100644 --- a/controller/fw/tools/dsss_demod_test.c +++ b/controller/fw/tools/dsss_demod_test.c @@ -12,6 +12,16 @@ #include "dsss_demod.h" +void handle_dsss_received(uint8_t data[TRANSMISSION_SYMBOLS]) { + printf("data sequence received: [ "); + for (size_t i=0; i>1)); + if (i+1 < TRANSMISSION_SYMBOLS) + printf(", "); + } + printf(" ]\n"); +} + void print_usage() { fprintf(stderr, "Usage: dsss_demod_test [test_data.bin] [optional recording channel number]\n"); } @@ -87,7 +97,7 @@ int main(int argc, char **argv) { fprintf(stderr, "Starting simulation.\n"); struct dsss_demod_state demod; - memset(&demod, 0, sizeof(demod)); + dsss_demod_init(&demod); for (size_t i=0; i