summaryrefslogtreecommitdiffstats
path: root/example_avr_double/doubleproto.proto
diff options
context:
space:
mode:
authorPetteri Aimonen <jpa@git.mail.kapsi.fi>2013-01-29 22:10:37 +0200
committerPetteri Aimonen <jpa@git.mail.kapsi.fi>2013-01-29 22:10:37 +0200
commite4b55179d1f53c42916f5e62fb83789973bf4b01 (patch)
tree4505321c4c14bdca6362b1e1bb1054c3588a4543 /example_avr_double/doubleproto.proto
parent2392d255749715ad337d3f5e23d3de7f2065e3dd (diff)
Add an example of handling doubles on AVR platform.
Diffstat (limited to 'example_avr_double/doubleproto.proto')
-rw-r--r--example_avr_double/doubleproto.proto13
1 files changed, 13 insertions, 0 deletions
diff --git a/example_avr_double/doubleproto.proto b/example_avr_double/doubleproto.proto
new file mode 100644
index 00000000..d8b7f2db
--- /dev/null
+++ b/example_avr_double/doubleproto.proto
@@ -0,0 +1,13 @@
+// A message containing doubles, as used by other applications.
+message DoubleMessage {
+ required double field1 = 1;
+ required double field2 = 2;
+}
+
+// A message containing doubles, but redefined using uint64_t.
+// For use in AVR code.
+message AVRDoubleMessage {
+ required fixed64 field1 = 1;
+ required fixed64 field2 = 2;
+}
+