IsCommValid()
Purpose
Know if a remote controller connected to the CrcDuino via a CrcConnect module.
When to use
Whenever you need to check if the communication with the remote controller is up.
Where to use
In the void loop()
part of your .ino
file. The connection is not established when the void setup()
part of your .ino
file is executed.
Click here to learn more on the CrcConnect system, that allows to control a CrcDuino using popular off-the-shelf remote controllers.
This function requires the use of the following CrcLib functions at some point of your .ino
file in order to work properly:
Returns
This function returns the status of the communication with a remote controller as a bool
type.
LOW
, if the connection is not establishedHIGH
, if the connection is established
Main prototype and parameters
static bool CrcLib::isCommValid();
The following parameters must be passed to the function for it to work properly:
No parameters needed.
Overloads
This function does not have any overloads. It can only be used as described by the main prototype.
Examples
More on this function
A “physical” way to tell if the communication is established between the CrcDuino and the CrcConnect is to check if the board mounted “X2” LED is lit on the CrcDuino, or if the “COM” LED on the CrcConnect module is lit.