Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Artery AT32F435/7 DFU and VCP support #3259

Merged
merged 4 commits into from Jan 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions src/js/port_handler.js
Expand Up @@ -11,6 +11,7 @@ const TIMEOUT_CHECK = 500 ; // With 250 it seems that it produces a memory leak
export const usbDevices = { filters: [
{'vendorId': 1155, 'productId': 57105}, // STM Device in DFU Mode || Digital Radio in USB mode
{'vendorId': 10473, 'productId': 393}, // GD32 DFU Bootloader
{'vendorId': 0x2E3C, 'productId': 0xDF11}, // AT32F435 DFU Bootloader
] };

const PortHandler = new function () {
Expand Down
10 changes: 9 additions & 1 deletion src/js/protocols/stm32usbdfu.js
Expand Up @@ -346,10 +346,18 @@ STM32DFU_protocol.prototype.getChipInfo = function (_interface, callback) {
// H750 SPRacing H7 EXST: "@External Flash /0x90000000/1001*128Kg,3*128Kg,20*128Ka" - Early BL firmware with incorrect string, treat as above.

// H750 Partitions: Flash, Config, Firmware, 1x BB Management block + x BB Replacement blocks)
// AT32 F437 "@Internal Flash /0x08000000/08*04Ka,1000*04Kg"
if (str === "@External Flash /0x90000000/1001*128Kg,3*128Kg,20*128Ka") {
str = "@External Flash /0x90000000/998*128Kg,1*128Kg,4*128Kg,21*128Ka";
}

//AT32F43xxM
if (str === "@Option byte /0x1FFFC000/01*4096 g"){
str = "@Option bytes /0x1FFFC000/01*4096 g";
}
//AT32F43xxG
if (str === "@Option byte /0x1FFFC000/01*512 g"){
str = "@Option bytes /0x1FFFC000/01*512 g";
}
// split main into [location, start_addr, sectors]

var tmp0 = str.replace(/[^\x20-\x7E]+/g, "");
Expand Down
1 change: 1 addition & 0 deletions src/js/serial.js
Expand Up @@ -28,6 +28,7 @@ const serial = {
{'vendorId': 4292, 'productId': 60000}, // CP210x
{'vendorId': 4292, 'productId': 60001}, // CP210x
{'vendorId': 4292, 'productId': 60002}, // CP210x
{'vendorId': 0x2e3c, 'productId': 0x5740}, // AT32 VCP
],

connect: function (path, options, callback) {
Expand Down