summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2016-01-29 20:45:10 +0100
committerDaniel Friesel <derf@finalrewind.org>2016-01-29 20:45:10 +0100
commit2812a77fe2b46997616ccd793b030befd5413729 (patch)
tree5517b23dfed2f88c7487adb15be19b93133d9fb4 /src
parent8b1bad7e3e8d9311cb881e4df2101203f5a1eb9e (diff)
re-add transmission demo code
Diffstat (limited to 'src')
-rw-r--r--src/main.cc5
-rw-r--r--src/system.cc6
2 files changed, 8 insertions, 3 deletions
diff --git a/src/main.cc b/src/main.cc
index 91ff92a..765f1d9 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -10,11 +10,12 @@
#include "modem.h"
#include "system.h"
+animation_t ohai;
+
int main (void)
{
- animation_t ohai;
ohai.mode = AnimationType::TEXT;
- ohai.speed = (4 << 4) + 15;
+ ohai.speed = (2 << 4) + 15;
ohai.data = (uint8_t *)"\001 Ohai ";
ohai.length = 8;
diff --git a/src/system.cc b/src/system.cc
index fa039ce..774127d 100644
--- a/src/system.cc
+++ b/src/system.cc
@@ -12,6 +12,8 @@
System rocket;
+extern animation_t ohai;
+
uint8_t disp_buf[128];
void System::loop()
@@ -76,8 +78,10 @@ void System::loop()
if (i == 127) {
i = 0;
} else if (modem_byte == 0) {
+ ohai.data = disp_buf;
+ ohai.length = i-1;
+ display.show(&ohai);
i = 0;
- //display.show(disp_buf);
}
}
}