Simple Mbed Cloud client application for NuMaker-PFM-M487 and NuMaker-PFM-NUC472 over Ethernet.
This application contains the example codes to:
1) Connect PFM-M487/PFM-NUC472 boards to Pelion
2) Enable Firmware update
For storage, PFM-M487/PFM-NUC472 support both SPI interface SD and built-in SD bus SD.
For connectivity, PFM-M487/PFM-NUC472 support Ethernet (on-board) by default.
This example supports Ethernet and built-in SD by default.
mbed_app.json@7:6aee86899520, 2018-10-08 (annotated)
- Committer:
- ccli8
- Date:
- Mon Oct 08 16:42:08 2018 +0800
- Revision:
- 7:6aee86899520
- Parent:
- 3:9e8abf07add2
- Child:
- 8:ed66653e5a22
Update to simple-mbed-cloud-client 1.4.1
1. Update to mbed-os 5.10
2. Remove sd-driver.lib, which is integrated into mbed-os.
3. Remove tools\ originally for packing bootloader and application. It is replaced with
managed bootloader mechanism.
4. Support default block device, which is enabled since mbed-os 5.10.
(1) Support Nuvoton SD card in SD bus mode as default
(2) Support SD card in SPI mode
5. Support default network interface, which is enabled sicne mbed-os 5.10.
(1) Support Ethernet as default
(2) Support WiFi ESP8266
6. Support OTA
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
ccli8 |
7:6aee86899520 | 1 | { |
ccli8 |
7:6aee86899520 | 2 | "macros": [ |
ccli8 |
7:6aee86899520 | 3 | "MBEDTLS_USER_CONFIG_FILE=\"mbedTLSConfig_mbedOS.h\"", |
ccli8 |
7:6aee86899520 | 4 | "PAL_USER_DEFINED_CONFIGURATION=\"sotp_fs_config_MbedOS.h\"", |
ccli8 |
7:6aee86899520 | 5 | "MBED_CLIENT_USER_CONFIG_FILE=\"mbed_cloud_client_user_config.h\"", |
ccli8 |
7:6aee86899520 | 6 | "MBED_CLOUD_CLIENT_USER_CONFIG_FILE=\"mbed_cloud_client_user_config.h\"", |
ccli8 |
7:6aee86899520 | 7 | "PAL_DTLS_PEER_MIN_TIMEOUT=5000", |
ccli8 |
7:6aee86899520 | 8 | "MBED_CONF_APP_MAIN_STACK_SIZE=6000", |
ccli8 |
7:6aee86899520 | 9 | "ARM_UC_USE_PAL_BLOCKDEVICE=1", |
ccli8 |
7:6aee86899520 | 10 | "MBED_CLOUD_CLIENT_UPDATE_STORAGE=ARM_UCP_FLASHIAP_BLOCKDEVICE" |
ccli8 |
7:6aee86899520 | 11 | ], |
ccli8 |
7:6aee86899520 | 12 | "target_overrides": { |
ccli8 |
7:6aee86899520 | 13 | "*": { |
ccli8 |
7:6aee86899520 | 14 | "platform.stdio-baud-rate": 115200, |
ccli8 |
7:6aee86899520 | 15 | "platform.stdio-convert-newlines": true, |
ccli8 |
7:6aee86899520 | 16 | "update-client.storage-address" : "(1024*1024*64)", |
ccli8 |
7:6aee86899520 | 17 | "update-client.storage-size" : "(1024*1024*2)", |
ccli8 |
7:6aee86899520 | 18 | "update-client.storage-locations": "1", |
ccli8 |
7:6aee86899520 | 19 | "mbed-trace.enable": null, |
ccli8 |
7:6aee86899520 | 20 | "nsapi.default-wifi-security" : "WPA_WPA2", |
ccli8 |
7:6aee86899520 | 21 | "nsapi.default-wifi-ssid" : "\"SSID\"", |
ccli8 |
7:6aee86899520 | 22 | "nsapi.default-wifi-password" : "\"Password\"" |
ccli8 |
7:6aee86899520 | 23 | }, |
ccli8 |
7:6aee86899520 | 24 | "K64F": { |
ccli8 |
7:6aee86899520 | 25 | "target.features_add" : ["BOOTLOADER"], |
ccli8 |
7:6aee86899520 | 26 | "sotp-section-1-address" : "(32*1024)", |
ccli8 |
7:6aee86899520 | 27 | "sotp-section-1-size" : "(4*1024)", |
ccli8 |
7:6aee86899520 | 28 | "sotp-section-2-address" : "(36*1024)", |
ccli8 |
7:6aee86899520 | 29 | "sotp-section-2-size" : "(4*1024)", |
ccli8 |
7:6aee86899520 | 30 | "sotp-num-sections" : 2, |
ccli8 |
7:6aee86899520 | 31 | "update-client.application-details": "(40*1024)" |
ccli8 |
7:6aee86899520 | 32 | }, |
ccli8 |
7:6aee86899520 | 33 | "K66F": { |
ccli8 |
7:6aee86899520 | 34 | "target.features_add" : ["BOOTLOADER"], |
ccli8 |
7:6aee86899520 | 35 | "sotp-section-1-address" : "(32*1024)", |
ccli8 |
7:6aee86899520 | 36 | "sotp-section-1-size" : "(4*1024)", |
ccli8 |
7:6aee86899520 | 37 | "sotp-section-2-address" : "(36*1024)", |
ccli8 |
7:6aee86899520 | 38 | "sotp-section-2-size" : "(4*1024)", |
ccli8 |
7:6aee86899520 | 39 | "sotp-num-sections" : 2, |
ccli8 |
7:6aee86899520 | 40 | "update-client.application-details": "(40*1024)" |
ccli8 |
7:6aee86899520 | 41 | }, |
ccli8 |
7:6aee86899520 | 42 | "NUCLEO_F429ZI": { |
ccli8 |
7:6aee86899520 | 43 | "target.features_add" : ["STORAGE", "BOOTLOADER"], |
ccli8 |
7:6aee86899520 | 44 | "target.app_offset": "0x10400", |
ccli8 |
7:6aee86899520 | 45 | "target.header_offset": "0x10000", |
ccli8 |
7:6aee86899520 | 46 | "target.bootloader_img": "bootloader/mbed-bootloader-F429ZI.bin", |
ccli8 |
7:6aee86899520 | 47 | "target.components_add": ["SD"], |
ccli8 |
7:6aee86899520 | 48 | "sd.SPI_MOSI" : "PE_6", |
ccli8 |
7:6aee86899520 | 49 | "sd.SPI_MISO" : "PE_5", |
ccli8 |
7:6aee86899520 | 50 | "sd.SPI_CLK" : "PE_2", |
ccli8 |
7:6aee86899520 | 51 | "sd.SPI_CS" : "PE_4", |
ccli8 |
7:6aee86899520 | 52 | "update-client.application-details" : "(0x08000000+64*1024)", |
ccli8 |
7:6aee86899520 | 53 | "app.sotp-section-1-address": "(0x081C0000)", |
ccli8 |
7:6aee86899520 | 54 | "app.sotp-section-1-size" : "(128*1024)", |
ccli8 |
7:6aee86899520 | 55 | "app.sotp-section-2-address": "(0x081E0000)", |
ccli8 |
7:6aee86899520 | 56 | "app.sotp-section-2-size" : "(128*1024)" |
ccli8 |
7:6aee86899520 | 57 | }, |
ccli8 |
7:6aee86899520 | 58 | "NUMAKER_PFM_NUC472": { |
ccli8 |
7:6aee86899520 | 59 | "target.features_add" : ["BOOTLOADER"], |
ccli8 |
7:6aee86899520 | 60 | "target.components_add" : ["NUSD"], |
ccli8 |
7:6aee86899520 | 61 | "target.network-default-interface-type" : "ETHERNET", |
ccli8 |
7:6aee86899520 | 62 | "update-client.bootloader-details" : "0x0", |
ccli8 |
7:6aee86899520 | 63 | "update-client.application-details" : "0x13000", |
ccli8 |
7:6aee86899520 | 64 | |
ccli8 |
7:6aee86899520 | 65 | "drivers.uart-serial-rxbuf-size" : 1024, |
ccli8 |
7:6aee86899520 | 66 | "drivers.uart-serial-txbuf-size" : 1024, |
ccli8 |
7:6aee86899520 | 67 | |
ccli8 |
7:6aee86899520 | 68 | "sotp-section-1-address" : "0x11000", |
ccli8 |
7:6aee86899520 | 69 | "sotp-section-1-size" : "0x1000", |
ccli8 |
7:6aee86899520 | 70 | "sotp-section-2-address" : "0x12000", |
ccli8 |
7:6aee86899520 | 71 | "sotp-section-2-size" : "0x1000", |
ccli8 |
7:6aee86899520 | 72 | "sotp-num-sections" : 2, |
ccli8 |
7:6aee86899520 | 73 | |
ccli8 |
7:6aee86899520 | 74 | "update-client.storage-address" : "(1024*1024*480)", |
ccli8 |
7:6aee86899520 | 75 | "update-client.storage-size" : "(1024*1024*2)", |
ccli8 |
7:6aee86899520 | 76 | |
ccli8 |
7:6aee86899520 | 77 | "target.macros_add": [ |
ccli8 |
7:6aee86899520 | 78 | "ESP8266_AT_SEL=ESP8266_AT_EXTERN" |
ccli8 |
7:6aee86899520 | 79 | ] |
ccli8 |
7:6aee86899520 | 80 | }, |
ccli8 |
7:6aee86899520 | 81 | "NUMAKER_PFM_M487": { |
ccli8 |
7:6aee86899520 | 82 | "target.features_add" : ["BOOTLOADER"], |
ccli8 |
7:6aee86899520 | 83 | "target.components_add" : ["NUSD"], |
ccli8 |
7:6aee86899520 | 84 | "target.network-default-interface-type" : "ETHERNET", |
ccli8 |
7:6aee86899520 | 85 | "update-client.bootloader-details" : "0x0", |
ccli8 |
7:6aee86899520 | 86 | "update-client.application-details" : "0x13000", |
ccli8 |
7:6aee86899520 | 87 | |
ccli8 |
7:6aee86899520 | 88 | "drivers.uart-serial-rxbuf-size" : 1024, |
ccli8 |
7:6aee86899520 | 89 | "drivers.uart-serial-txbuf-size" : 1024, |
ccli8 |
7:6aee86899520 | 90 | |
ccli8 |
7:6aee86899520 | 91 | "sotp-section-1-address" : "0x11000", |
ccli8 |
7:6aee86899520 | 92 | "sotp-section-1-size" : "0x1000", |
ccli8 |
7:6aee86899520 | 93 | "sotp-section-2-address" : "0x12000", |
ccli8 |
7:6aee86899520 | 94 | "sotp-section-2-size" : "0x1000", |
ccli8 |
7:6aee86899520 | 95 | "sotp-num-sections" : 2, |
ccli8 |
7:6aee86899520 | 96 | |
ccli8 |
7:6aee86899520 | 97 | "update-client.storage-address" : "(1024*1024*480)", |
ccli8 |
7:6aee86899520 | 98 | "update-client.storage-size" : "(1024*1024*2)", |
ccli8 |
7:6aee86899520 | 99 | |
ccli8 |
7:6aee86899520 | 100 | "target.macros_add": [ |
ccli8 |
7:6aee86899520 | 101 | "ESP8266_AT_SEL=ESP8266_AT_EXTERN" |
ccli8 |
7:6aee86899520 | 102 | ] |
ccli8 |
7:6aee86899520 | 103 | } |
ccli8 |
7:6aee86899520 | 104 | }, |
ccli8 |
7:6aee86899520 | 105 | "config": { |
ccli8 |
7:6aee86899520 | 106 | "format-storage-layer-on-error": { |
ccli8 |
7:6aee86899520 | 107 | "help": "Whether to format the storage layer when it cannot be read - always disable for production devices!", |
ccli8 |
7:6aee86899520 | 108 | "value": 1 |
ccli8 |
7:6aee86899520 | 109 | }, |
ccli8 |
7:6aee86899520 | 110 | "developer-mode": { |
ccli8 |
7:6aee86899520 | 111 | "help": "Enable Developer mode to skip Factory enrollment", |
ccli8 |
7:6aee86899520 | 112 | "value": 1 |
ccli8 |
7:6aee86899520 | 113 | }, |
ccli8 |
7:6aee86899520 | 114 | "sotp-section-1-address": { |
ccli8 |
7:6aee86899520 | 115 | "help": "Flash sector address for SOTP sector 1", |
ccli8 |
7:6aee86899520 | 116 | "macro_name": "PAL_INTERNAL_FLASH_SECTION_1_ADDRESS", |
ccli8 |
7:6aee86899520 | 117 | "value": null |
ccli8 |
7:6aee86899520 | 118 | }, |
ccli8 |
7:6aee86899520 | 119 | "sotp-section-1-size": { |
ccli8 |
7:6aee86899520 | 120 | "help": "Flash sector size for SOTP sector 1", |
ccli8 |
7:6aee86899520 | 121 | "macro_name": "PAL_INTERNAL_FLASH_SECTION_1_SIZE", |
ccli8 |
7:6aee86899520 | 122 | "value": null |
ccli8 |
7:6aee86899520 | 123 | }, |
ccli8 |
7:6aee86899520 | 124 | "sotp-section-2-address": { |
ccli8 |
7:6aee86899520 | 125 | "help": "Flash sector address for SOTP sector 2", |
ccli8 |
7:6aee86899520 | 126 | "macro_name": "PAL_INTERNAL_FLASH_SECTION_2_ADDRESS", |
ccli8 |
7:6aee86899520 | 127 | "value": null |
ccli8 |
7:6aee86899520 | 128 | }, |
ccli8 |
7:6aee86899520 | 129 | "sotp-section-2-size": { |
ccli8 |
7:6aee86899520 | 130 | "help": "Flash sector size for SOTP sector 2", |
ccli8 |
7:6aee86899520 | 131 | "macro_name": "PAL_INTERNAL_FLASH_SECTION_2_SIZE", |
ccli8 |
7:6aee86899520 | 132 | "value": null |
ccli8 |
7:6aee86899520 | 133 | }, |
ccli8 |
7:6aee86899520 | 134 | "sotp-num-sections": { |
ccli8 |
7:6aee86899520 | 135 | "help": "Number of SOTP sections", |
ccli8 |
7:6aee86899520 | 136 | "macro_name": "PAL_INT_FLASH_NUM_SECTIONS", |
ccli8 |
7:6aee86899520 | 137 | "value": null |
ccli8 |
7:6aee86899520 | 138 | } |
ccli8 |
7:6aee86899520 | 139 | } |
ccli8 |
7:6aee86899520 | 140 | } |