
This is a simple mbed client example demonstrating, registration of a device with mbed Device Connector and reading and writing values as well as deregistering on different Network Interfaces including Ethernet, WiFi, 6LoWPAN ND and Thread respectively.
Fork of mbed-os-example-client by
Revision 10:4a3aaf2e130a, committed 2016-08-03
- Comitter:
- mbed_official
- Date:
- Wed Aug 03 13:00:25 2016 +0100
- Parent:
- 9:dcc4b552c03a
- Child:
- 11:b6a2d72c0312
- Commit message:
- Merge pull request #68 from ARMmbed/multiple-board-support
Adding error flag for warning users about missing mbedTLS feature
Commit copied from https://github.com/ARMmbed/mbed-os-example-client
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed Aug 03 12:00:18 2016 +0100 +++ b/main.cpp Wed Aug 03 13:00:25 2016 +0100 @@ -255,6 +255,20 @@ // Entry point to the program int main() { + +#ifndef MBEDTLS_ENTROPY_HARDWARE_ALT + +#ifdef MBEDTLS_TEST_NULL_ENTROPY +#warning "mbedTLS security feature is disabled. Connection will not be secure !! Implement proper hardware entropy for your selected hardware." + +#else + +#error "This hardware does not have entropy, endpoint will not register to Connector.\ +You need to enable NULL ENTROPY for your application, but if this configuration change is made then no security is offered by mbed TLS.\ +Add MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES and MBEDTLS_TEST_NULL_ENTROPY in mbed_app.json macros to register your endpoint." +#endif + +#endif status_ticker.attach_us(blinky, 250000); // Keep track of the main thread