.

https://www.mediafire.com/file/sjhxgn70gxshilg/protocol_spi_pwm.png/file

Revision:
109:4ee7ffc8f175
Child:
110:a6d1d3525014
diff -r 2fd41d299a8c -r 4ee7ffc8f175 protocol.h
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/protocol.h	Tue Apr 05 13:34:51 2022 +0000
@@ -0,0 +1,16 @@
+#ifndef PROTOCOL_H
+#define PROTOCOL_H
+
+#include <stdint.h>
+
+#define STATE_START_OF_FRAME 0
+#define STATE_PROPULSION 1
+#define STATE_DIRECTION 2
+#define STATE_CHECKSUM 3
+
+char calculateChecksum(uint32_t propulsion, uint32_t direction);
+void decodeMessage(char c);
+void getVerifiedPWMValues(uint32_t *pwms);
+char isDataAvailable();
+
+#endif
\ No newline at end of file