Libraries to support working with GMLAN - General Motors CAN BUS network in most of their vehicles between 2007-present day. Please note this is a work in progress and not guaranteed to be correct, use at your own risk! Read commit logs / subscribe to see what has been added, it's a work in progress after all ;)

Files at this revision

API Documentation at this revision

Comitter:
foxdie
Date:
Mon Apr 08 11:31:12 2013 +0000
Parent:
8:bc97fa5d306e
Commit message:
Fixed bug where transmission of multi-frame messages wasn't recognising flow control to continue resulting in code waiting around doing nada

Changed in this revision

GMLAN.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r bc97fa5d306e -r 4af02032daeb GMLAN.cpp
--- a/GMLAN.cpp	Mon Apr 08 10:29:31 2013 +0000
+++ b/GMLAN.cpp	Mon Apr 08 11:31:12 2013 +0000
@@ -148,7 +148,9 @@
     return buffer.generate();
 }
 void GMLAN_11Bit_Request::processFrame(CANMessage msg) {
-    if (((msg.id & 0xFF) == (id & 0xFF)) && (request_state == GMLAN_STATE_AWAITING_REPLY)) {
+    if (((msg.id & 0xFF) == (id & 0xFF)) && 
+        ((request_state == GMLAN_STATE_AWAITING_REPLY) || (request_state == GMLAN_STATE_AWAITING_FC))
+    ) {
         // Only handle requests we've instigated
         char datatochars [8];
         memcpy(datatochars, msg.data, 8);