mcci-catena / Catena-Arduino-Platform

Arduino platform library for MCCI Catena IoT Systems
MIT License
12 stars 11 forks source link

Support commands that don't complete instantly #161

Closed terrillmoore closed 5 years ago

terrillmoore commented 5 years ago

The command parser currently works well, but it doesn't support commands that do things like "read Modbus registers" -- this is an asynchronous operation that completes "later".

High-level summary:

Note that a command might pThis->completeCommand() before it returns kPending. (This is useful when handling completion routines that might call back during the downcall if there's an immediate failure -- they can just call completeCommand no matter when the callback occurs.)