diff options
Diffstat (limited to 'src/isotp/receive.c')
-rw-r--r-- | src/isotp/receive.c | 14 |
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 = { |