summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/app/sysinfo/Makefile.inc1
-rw-r--r--src/app/sysinfo/main.cc33
2 files changed, 34 insertions, 0 deletions
diff --git a/src/app/sysinfo/Makefile.inc b/src/app/sysinfo/Makefile.inc
new file mode 100644
index 0000000..4cc2151
--- /dev/null
+++ b/src/app/sysinfo/Makefile.inc
@@ -0,0 +1 @@
+loop = 1
diff --git a/src/app/sysinfo/main.cc b/src/app/sysinfo/main.cc
new file mode 100644
index 0000000..a2e2660
--- /dev/null
+++ b/src/app/sysinfo/main.cc
@@ -0,0 +1,33 @@
+#include "arch.h"
+#include "driver/gpio.h"
+#include "driver/stdout.h"
+#include "driver/uptime.h"
+
+void loop(void)
+{
+ static unsigned char done = 0;
+
+ if (!done) {
+ kout << "sizeof(char) = " << sizeof(char) << endl;
+ kout << "sizeof(short) = " << sizeof(short) << endl;
+ kout << "sizeof(int) = " << sizeof(int) << endl;
+ kout << "sizeof(long int) = " << sizeof(long int) << endl;
+ kout << "sizeof(long long) = " << sizeof(long long) << endl;
+ kout << "sizeof(float) = " << sizeof(float) << endl;
+ kout << "sizeof(double) = " << sizeof(double) << endl;
+ done = 1;
+ }
+}
+
+int main(void)
+{
+ arch.setup();
+ gpio.setup();
+ kout.setup();
+
+ kout << "Hello, World!" << endl;
+
+ arch.idle_loop();
+
+ return 0;
+}