aboutsummaryrefslogtreecommitdiffstats
path: root/src/isotp/receive.c
diff options
context:
space:
mode:
authorChristopher Peplin <chris.peplin@rhubarbtech.com>2014-01-05 15:43:26 -0500
committerChristopher Peplin <chris.peplin@rhubarbtech.com>2014-01-05 15:43:43 -0500
commitef06cb3a05d45df7a04cf91ab5c0b233fdf2bd48 (patch)
tree795869c8418953b7ef522cf13a53277032c683cb /src/isotp/receive.c
parent8922abb7ff8c30e1fa5af078284eb6aebf0052e5 (diff)
Move a few things about to make compiling with other projects possible.
Diffstat (limited to 'src/isotp/receive.c')
-rw-r--r--src/isotp/receive.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/isotp/receive.c b/src/isotp/receive.c
index bfbf16fd..65390648 100644
--- a/src/isotp/receive.c
+++ b/src/isotp/receive.c
@@ -1,16 +1,18 @@
#include <isotp/receive.h>
+#include <bitfield/bitfield.h>
+#include <string.h>
-bool isotp_handle_single_frame(IsoTpReceiveHandle* handle, IsoTpMessage* message) {
- isotp_complete_receive(handle, message);
- return true;
-}
-
-void isotp_complete_receive(IsoTpReceiveHandle* handle, IsoTpMessage* message) {
+static void isotp_complete_receive(IsoTpReceiveHandle* handle, IsoTpMessage* message) {
if(handle->message_received_callback != NULL) {
handle->message_received_callback(message);
}
}
+bool isotp_handle_single_frame(IsoTpReceiveHandle* handle, IsoTpMessage* message) {
+ isotp_complete_receive(handle, message);
+ return true;
+}
+
IsoTpReceiveHandle isotp_receive(IsoTpShims* shims,
const uint16_t arbitration_id, IsoTpMessageReceivedHandler callback) {
IsoTpReceiveHandle handle = {