HandleTestCommand turns all the typed-in/serial commands into function calls sent via a eventqueue to the driver shim/wrapper class. More...
#include <NFCCommands.h>
Static Public Member Functions | |
static int | cmd_get_last_nfc_error (int argc, char *argv[]) |
return and clear the last result code. More... | |
static int | cmd_set_last_nfc_error (int argc, char *argv[]) |
internal function to test getlastnfcerror More... | |
static int | cmd_get_conf_nfceeprom (int argc, char *argv[]) |
returns compile time flag if NFC EEPROM was compiled More... | |
static int | cmd_get_max_ndef (int argc, char *argv[]) |
For EEPROM, returns the driver max_ndef value, else returns the app config MBED_CONF_APP_TEST_NDEF_MSG_MAX. More... | |
static int | cmd_init_nfc (int argc, char *argv[]) |
Init must be called before invoking any other calls, obtains a driver reference and initializes driver. More... | |
static int | cmd_set_smartposter (int argc, char *argv[]) |
write a smartposter url, 'Sp' NDEF to the target More... | |
static int | cmd_erase (int argc, char *argv[]) |
erases the EEPROM if present More... | |
static int | cmd_get_supported_rf_protocols (int argc, char *argv[]) |
Returns a CSV list of protocols supported. More... | |
static int | cmd_configure_rf_protocols (int argc, char *argv[]) |
Sets the protocols supported (unimplemented) More... | |
static int | cmd_start_discovery (int argc, char *argv[]) |
starts the NFC discovery loop if controller, has no effect on EEPROM More... | |
static int | cmd_stop_discovery (int argc, char *argv[]) |
stops the NFC discovery loop if controller More... | |
static int | cmd_read_message (int argc, char *argv[]) |
read raw EEPROM contents, reads a buffer if a controller is used More... | |
static int | cmd_write_long_ndef_message (int argc, char *argv[]) |
write a text 'T' NDEF message to the target More... | |
HandleTestCommand turns all the typed-in/serial commands into function calls sent via a eventqueue to the driver shim/wrapper class.
Methods with cmd_ prefix map to the serial commands, and are building blocks for test cases and scenarios. The first function a test must call is typically the initnfc command. Commands report back a test verdict, and a NFC status code. The test verdict is always success unless the command is not allowed. Tests much check the NFC error code for NFC_OK or zero; this pattern allows us to write negative tests which expect a specific NFC error.
Handlers are statics because the test framework is not supporting C++
Definition at line 57 of file NFCCommands.h.
|
static |
Sets the protocols supported (unimplemented)
|
static |
erases the EEPROM if present
|
static |
returns compile time flag if NFC EEPROM was compiled
|
static |
return and clear the last result code.
Type "help getlastnfcerror" for a list of error codes
|
static |
For EEPROM, returns the driver max_ndef value, else returns the app config MBED_CONF_APP_TEST_NDEF_MSG_MAX.
|
static |
Returns a CSV list of protocols supported.
|
static |
Init must be called before invoking any other calls, obtains a driver reference and initializes driver.
|
static |
read raw EEPROM contents, reads a buffer if a controller is used
|
static |
internal function to test getlastnfcerror
|
static |
write a smartposter url, 'Sp' NDEF to the target
|
static |
starts the NFC discovery loop if controller, has no effect on EEPROM
|
static |
stops the NFC discovery loop if controller
|
static |
write a text 'T' NDEF message to the target