Merge pull request #10733 from pan-/fix-nrf52-memory-pools

Fix nrf52 memory pools
pull/10769/head
Martin Kojtal 2019-06-04 21:01:15 +01:00 committed by GitHub
commit fbc489e6a5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 19 additions and 19 deletions

View File

@ -24,12 +24,12 @@
},
"max-l2cap-channels": {
"help": "Maximum number of connection oriented channels",
"value": 8,
"value": 1,
"macro_name": "L2C_COC_CHAN_MAX"
},
"max-l2cap-clients": {
"help": "Maximum number of connection oriented channel registered clients",
"value": 4,
"value": 1,
"macro_name": "L2C_COC_REG_MAX"
},
"max-att-writes": {
@ -53,7 +53,7 @@
},
"rx-acl-buffer-size": {
"help": "Size of the buffer holding the reassembled complete ACL packet. This will limit the effective ATT_MTU (to its value minus 4 bytes for the header). The size of the buffer must be small enough to be allocated from the existing cordio pool. If this value is increased you may need to adjust the memory pool.",
"value": 100
"value": 70
},
"max-prepared-writes": {
"help": "Number of queued prepare writes supported by server.",

View File

@ -3,11 +3,11 @@
"config": {
"max-advertising-sets": {
"help": "Maximum number of advertising sets.",
"value": 4
"value": 3
},
"max-advertising-reports": {
"help": "Maximum number of pending legacy or extended advertising reports.",
"value": 8
"value": 4
},
"default-extended-advertising-fragmentation-size": {
"help": "Default extended advertising data fragmentation size.",
@ -23,15 +23,15 @@
},
"rx-buffers": {
"help": "Default number of receive buffers.",
"value": 8
"value": 4
},
"phy-coded-support": {
"help": "Coded PHY supported.",
"value": 0
},
"extended-advertising-size": {
"help": "Maximum extended advertising data (and scan data response) size",
"value": 128
"help": "Maximum extended advertising data (and scan data response) size, Minimum value is 251",
"value": 251
},
"max-acl-size": {
"help": "Maximum ACL buffer size",
@ -39,7 +39,7 @@
},
"tx-buffers": {
"help": "Default number of send buffers",
"value": 8
"value": 4
},
"handle-vendor-specific-hci-commands": {
"help": "Handle VS HCI commands. Valid values are 0 (ignore) and 1 (handle).",

View File

@ -7,15 +7,15 @@
},
"extended-advertising-size": {
"help": "Maximum extended advertising data (and scan data response) size",
"value": 1650
"value": 512
},
"max-acl-size": {
"help": "Maximum ACL buffer size",
"value": 512
"value": 256
},
"tx-buffers": {
"help": "Default number of send buffers",
"value": 16
"value": 4
},
"cryptocell310-acceleration": {
"help": "Should the link layer use the Crypto Cell 310 to offload encryption.",

View File

@ -67,11 +67,11 @@ using namespace ble::vendor::cordio;
#define MBED_CONF_CORDIO_LL_TX_BUFFERS MBED_CONF_CORDIO_LL_NRF52840_TX_BUFFERS
#define MBED_CONF_CORDIO_LL_PHY_CODED_SUPPORT MBED_CONF_CORDIO_LL_NRF52840_PHY_CODED_SUPPORT
#define CORDIO_LL_MEMORY_FOOTPRINT 41906UL
#define CORDIO_LL_MEMORY_FOOTPRINT 15400UL
#else
#define CORDIO_LL_MEMORY_FOOTPRINT 12768UL
#define CORDIO_LL_MEMORY_FOOTPRINT 12500UL
#endif
@ -235,9 +235,9 @@ ble::vendor::cordio::buf_pool_desc_t NRFCordioHCIDriver::get_buffer_pool_descrip
{
static union {
#if defined(NRF52840_XXAA)
uint8_t buffer[ 17304 ];
uint8_t buffer[ 4900 ];
#else
uint8_t buffer[ 8920 ];
uint8_t buffer[ 4900 ];
#endif
uint64_t align;
};
@ -246,8 +246,7 @@ ble::vendor::cordio::buf_pool_desc_t NRFCordioHCIDriver::get_buffer_pool_descrip
{ 32, 16 + 4 },
{ 64, 8 },
{ 128, 4 + MBED_CONF_CORDIO_LL_MAX_ADVERTISING_REPORTS },
{ aclBufSize, MBED_CONF_CORDIO_LL_TX_BUFFERS + MBED_CONF_CORDIO_LL_RX_BUFFERS },
{ 272, 1 }
{ aclBufSize, MBED_CONF_CORDIO_LL_TX_BUFFERS + MBED_CONF_CORDIO_LL_RX_BUFFERS }
};
return buf_pool_desc_t(buffer, pool_desc);

View File

@ -14,6 +14,7 @@
"INIT_PERIPHERAL",
"INIT_ENCRYPTED",
"LHCI_ENABLE_VS=0",
"BB_CLK_RATE_HZ=1000000"
"BB_CLK_RATE_HZ=1000000",
"LL_MAX_PER_SCAN=3"
]
}