Merge pull request #367 from mikeller/increase_vcp_dataflash_block_size

Increased dataflash download block size to 4096 for VCP targets.
10.3.x-maintenance
Michael Keller 2017-01-04 11:17:26 +13:00 committed by GitHub
commit 1d9c22495b
1 changed files with 7 additions and 2 deletions

View File

@ -8,7 +8,8 @@ TABS.onboard_logging = {
blockSize: 128, blockSize: 128,
BLOCK_SIZE: 4096, BLOCK_SIZE: 4096,
VCP_BLOCK_SIZE: 512 VCP_BLOCK_SIZE_3_0: 512,
VCP_BLOCK_SIZE: 4096
}; };
TABS.onboard_logging.initialize = function (callback) { TABS.onboard_logging.initialize = function (callback) {
var var
@ -339,7 +340,11 @@ TABS.onboard_logging.initialize = function (callback) {
function flash_save_begin() { function flash_save_begin() {
if (GUI.connected_to) { if (GUI.connected_to) {
if (BOARD.find_board_definition(CONFIG.boardIdentifier).vcp) { if (BOARD.find_board_definition(CONFIG.boardIdentifier).vcp) {
if (semver.gte(CONFIG.flightControllerVersion, "3.1.0")) {
self.blockSize = self.VCP_BLOCK_SIZE; self.blockSize = self.VCP_BLOCK_SIZE;
} else {
self.blockSize = self.VCP_BLOCK_SIZE_3_0;
}
} else { } else {
self.blockSize = self.BLOCK_SIZE; self.blockSize = self.BLOCK_SIZE;
} }