This library controls the WNC. There is a derived class for usage from the K64F board.
Fork of WncControllerLibrary by
Diff: WncController.cpp
- Revision:
- 17:59b1e9341188
- Parent:
- 16:f748245382ac
- Child:
- 18:ca2899c353c2
--- a/WncController.cpp Sat Sep 10 02:47:24 2016 +0000
+++ b/WncController.cpp Sat Sep 10 02:55:56 2016 +0000
@@ -674,7 +674,7 @@
size_t len = 0;
startTimerB();
- while ((len < (MAX_LEN_WNC_CMD_RESPONSE - 1)) && (getTimerTicksB_mS() < timeout_ms)) {
+ while ((len <= MAX_LEN_WNC_CMD_RESPONSE) && (getTimerTicksB_mS() < timeout_ms)) {
if (charReady()) {
chin_last = chin;
chin = getc();
@@ -690,7 +690,7 @@
}
stopTimerB();
- if (len >= (MAX_LEN_WNC_CMD_RESPONSE - 1))
+ if (len > MAX_LEN_WNC_CMD_RESPONSE)
dbgPuts("Max cmd length reply exceeded!");
return (len);
