Update version of isotp-c library.
authorChristopher Peplin <chris.peplin@rhubarbtech.com>
Fri, 3 Jan 2014 19:40:46 +0000 (14:40 -0500)
committerChristopher Peplin <chris.peplin@rhubarbtech.com>
Fri, 3 Jan 2014 19:40:46 +0000 (14:40 -0500)
deps/isotp-c
src/obd2/obd2.c
src/obd2/obd2.h

index 3b25a04..101d36e 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 3b25a0491ce9ef9b55c903c6c7f0929bc2910d1a
+Subproject commit 101d36e65bc7cb2b1fc8e4dbae4eacf749c98b00
index 1dcb827..d3c0fb9 100644 (file)
@@ -139,10 +139,10 @@ DiagnosticResponse diagnostic_receive_can_frame(DiagnosticShims* shims,
     if(!handle->isotp_send_handle.completed) {
         // TODO when completing a send, this returns...a Message? we have to
         // check when the isotp_send_handle is completed, and if it is, start
-        isotp_receive_can_frame(&handle->isotp_shims,
+        isotp_continue_send(&handle->isotp_shims,
                 &handle->isotp_send_handle, arbitration_id, data, size);
     } else if(!handle->isotp_receive_handle.completed) {
-        IsoTpMessage message = isotp_receive_can_frame(&handle->isotp_shims,
+        IsoTpMessage message = isotp_continue_receive(&handle->isotp_shims,
                 &handle->isotp_receive_handle, arbitration_id, data, size);
 
         if(message.completed) {
index 2bb6c77..a2ea033 100644 (file)
@@ -31,10 +31,6 @@ typedef struct {
     uint8_t payload_length;
 } DiagnosticRequest;
 
-// TODO I don't like this, it's hard coding isotp library stuff here
-typedef bool (*SendIsoTpMessageShim)(IsoTpHandle* handle,
-        const uint8_t* payload, uint16_t payload_size);
-
 // Thanks to
 // http://www.canbushack.com/blog/index.php?title=scanning-for-diagnostic-data&more=1&c=1&tb=1&pb=1
 // for the list of NRCs
@@ -120,8 +116,8 @@ typedef struct {
     bool completed;
 
     IsoTpShims isotp_shims;
-    IsoTpHandle isotp_send_handle;
-    IsoTpHandle isotp_receive_handle;
+    IsoTpSendHandle isotp_send_handle;
+    IsoTpReceiveHandle isotp_receive_handle;
     DiagnosticResponseReceived callback;
     DiagnosticMilStatusReceived mil_status_callback;
     DiagnosticVinReceived vin_callback;