Merge branch 'family/ambz2'

This commit is contained in:
Kuba Szczodrzyński
2023-07-13 17:31:52 +02:00
207 changed files with 3559 additions and 2123 deletions

View File

@@ -1,5 +1,8 @@
{
"build": {
"bkcrypt_coeffs": "510fb093a3cbeadc5993a17ec7adeb03"
},
"flash": {
"tuya": "0x1ED000+0x13000"
}
}

View File

@@ -2,14 +2,9 @@
"pcb": {
"templates": [
"esp12s",
"esp12s-shield",
"pcb-black",
"rf-type1"
],
"vars": {
"MASK_PRESET": "mask_black",
"TRACE_COLOR": "#FAFD9D",
"SILK_COLOR": "white"
},
"pinout_hidden": "I2S,TRIG,WAKE,CTS,RTS,SD",
"pinout": {
"1": {

View File

@@ -5,9 +5,8 @@
"flash": {
"ota1": "0x00B000+0x75000",
"ota2": "0x080000+0x75000",
"kvs": "0xF5000+0x6000",
"userdata": "0xFB000+0x104000",
"rdp": "0x1FF000+0x1000"
"kvs": "0x0F5000+0x8000",
"userdata": "0x0FD000+0x102000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -5,9 +5,8 @@
"flash": {
"ota1": "0x00B000+0xC5000",
"ota2": "0x0D0000+0xC5000",
"kvs": "0x195000+0x6000",
"userdata": "0x19B000+0x64000",
"rdp": "0x1FF000+0x1000"
"kvs": "0x195000+0x8000",
"userdata": "0x19D000+0x62000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -6,8 +6,7 @@
"ota1": "0x00B000+0xF5000",
"ota2": "0x100000+0xF5000",
"kvs": "0x1F5000+0x8000",
"userdata": "0x1FD000+0x202000",
"rdp": "0x3FF000+0x1000"
"userdata": "0x1FD000+0x202000"
},
"upload": {
"flash_size": 4194304,

View File

@@ -0,0 +1,5 @@
{
"flash": {
"tuya": "0x1EB000+0x15000"
}
}

View File

@@ -10,7 +10,8 @@
"boot_xip": "0x000000+0x4000",
"boot_ram": "0x004000+0x4000",
"system": "0x009000+0x1000",
"calibration": "0x00A000+0x1000"
"calibration": "0x00A000+0x1000",
"rdp": "0x1FF000+0x1000"
},
"connectivity": [
"wifi"
@@ -47,10 +48,6 @@
"General info": "../../docs/platform/realtek-amb/README.md",
"Flashing guide": "../../docs/platform/realtek-ambz/flashing.md",
"Debugging": "../../docs/platform/realtek-ambz/debugging.md"
},
"extra": [
"RDP is most likely not used in Tuya firmwares, as the System Data partition contains an incorrect offset 0xFF000 for RDP, which is in the middle of OTA2 image.",
"Additionally, Tuya firmware uses an encrypted KV or file storage, which resides at the end of flash memory. This seems to overlap system RDP area."
]
}
}
}

View File

@@ -0,0 +1,12 @@
{
"flash": {
"ota1": "0x010000+0xE0000",
"ota2": "0x0F0000+0xE0000",
"kvs": "0x1D0000+0x8000",
"userdata": "0x1D8000+0x28000"
},
"upload": {
"flash_size": 2097152,
"maximum_size": 917504
}
}

View File

@@ -2,8 +2,7 @@
"flash": {
"ota1": "0x00C000+0xF8000",
"ota2": "0x104000+0xF8000",
"kvs": "0x1FC000+0x2000",
"userdata": "0x1FE000+0x2000"
"kvs": "0x1FC000+0x4000"
},
"upload": {
"flash_size": 2097152,

View File

@@ -0,0 +1,96 @@
{
"image": {
"keys": {
"decryption": "a0d6dae7e062ca94cbb294bf896b9f68cf8438774256ac7403ca4fd9a1c9564f",
"keyblock": {
"part_table": "882aa16c8c44a7760aa8c9ab22e3568c6fa16c2afa4f0cea29a10abcdf60e44f",
"boot": "882aa16c8c44a7760aa8c9ab22e3568c6fa16c2afa4f0cea29a10abcdf60e44f"
},
"hash_keys": {
"part_table": "47e5661335a4c5e0a94d69f3c737d54f2383791332939753ef24279608f6d72b",
"boot": "ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",
"ota1": "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e5f",
"ota2": "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e5f"
},
"user_keys": {
"boot": "aa0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f",
"ota1": "bb0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f",
"ota2": "bb0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f"
},
"xip_sce_key": "a0d6dae7e062ca94cbb294bf896b9f68",
"xip_sce_iv": "94879487948794879487948794879487"
},
"ptable": {
"boot": "BOOT",
"ota1": "FW1",
"ota2": "FW2"
},
"boot": {
"name": "boot.sram",
"type": "SRAM",
"entry": "__ram_start_table_start__",
"elf": [
".ram.func.table",
".data",
".ram.code_text",
".ram.code_rodata"
],
"is_boot": true
},
"fw": [
{
"type": "FWHS_S",
"sections": [
{
"name": "fwhs.sram",
"type": "SRAM",
"entry": "__ram_start_table_start__",
"elf": [
".ram.img.signature",
".ram.func.table",
".data",
".ram.code_text",
".ram.code_rodata"
]
},
{
"name": "fwhs.psram",
"type": "PSRAM",
"entry": "__psram_start__",
"elf": [
".psram.data",
".psram.code_text",
".psram.code_rodata"
]
}
]
},
{
"type": "XIP",
"sections": [
{
"name": "fwhs.xip_c",
"entry": "XIP_RamImgSignature_s",
"type": "XIP",
"elf": [
".xip.code_c"
]
}
]
},
{
"type": "XIP",
"sections": [
{
"name": "fwhs.xip_p",
"entry": "__xip_code_rodata_start__",
"type": "XIP",
"elf": [
".xip.code_p"
]
}
]
}
]
}
}

View File

@@ -0,0 +1,5 @@
{
"flash": {
"tuya": "0x1D5000+0x10000"
}
}

View File

@@ -13,10 +13,20 @@
},
"debug": {
"protocol": "openocd",
"protocols": []
"protocols": [
"openocd"
],
"openocd_config": "amebaz2.cfg",
"gdb_init": [
"mem 0x9b000000 0x9c000000 ro"
]
},
"upload": {
"maximum_ram_size": 262144
"maximum_ram_size": 262144,
"protocol": "uart",
"protocols": [
"uart"
]
},
"doc": {
"params": {

26
boards/bw15.json Normal file
View File

@@ -0,0 +1,26 @@
{
"_base": [
"realtek-ambz2",
"realtek-ambz2-8720",
"realtek-ambz2-image",
"realtek-ambz2-2mb-992k",
"ic/rtl8720cf",
"pcb/bw15"
],
"build": {
"mcu": "rtl8720cf",
"variant": "bw15"
},
"name": "BW15",
"url": "https://docs.ai-thinker.com/_media/rtl8710/docs/bw15_datasheet_en.pdf",
"vendor": "Ai-Thinker Co., Ltd.",
"pcb": {
"symbol": "BW15"
},
"doc": {
"fccid": "2AXVG-BW15",
"links": {
"Vendor datasheet": "https://docs.ai-thinker.com/_media/rtl8710/docs/bw15_datasheet_en.pdf"
}
}
}

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb1s",
"pcb/cb1s-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb2l",
"pcb/cb2l-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb2s",
"pcb/cb2s-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3l"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3s"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cb3se"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cblc5",
"pcb/cblc5-test"

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/cbu",
"pcb/cbu-test"

View File

@@ -3,7 +3,7 @@
"generic",
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32"
],
"build": {

View File

@@ -4,7 +4,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32"
],
"build": {

View File

@@ -0,0 +1,102 @@
{
"_base": [
"generic",
"realtek-ambz2",
"realtek-ambz2-8720",
"realtek-ambz2-image",
"realtek-ambz2-2mb-992k",
"ic/rtl8720cf"
],
"build": {
"mcu": "rtl8720cf",
"variant": "generic-rtl8720cf-2mb-992k"
},
"name": "Generic - RTL8720CF (2M/992k)",
"symbol": "RTL8720CF (2M/992k)",
"url": "https://docs.libretiny.eu/boards/generic-rtl8720cf-2mb-992k/",
"vendor": "Generic",
"pcb": {
"pinout": {
"1": {
"IC": 15,
"ARD": "D0"
},
"2": {
"IC": 16,
"ARD": "D1"
},
"3": {
"IC": 18,
"ARD": "D2"
},
"4": {
"IC": 19,
"ARD": "D3"
},
"5": {
"IC": 20,
"ARD": "D4"
},
"6": {
"IC": 21,
"ARD": "D5"
},
"7": {
"IC": 22,
"ARD": "D6"
},
"8": {
"IC": 23,
"ARD": "D7"
},
"9": {
"IC": 24,
"ARD": "D8"
},
"10": {
"IC": 25,
"ARD": "D9"
},
"11": {
"IC": 26,
"ARD": "D10"
},
"12": {
"IC": 33,
"ARD": "D11"
},
"13": {
"IC": 34,
"ARD": "D12"
},
"14": {
"IC": 36,
"ARD": "D13"
},
"15": {
"IC": 37,
"ARD": "D14"
},
"16": {
"IC": 38,
"ARD": "D15"
},
"17": {
"IC": 39,
"ARD": "D16"
},
"18": {
"IC": 40,
"ARD": "D17"
},
"19": {
"IC": 1,
"ARD": "D18"
},
"20": {
"IC": 3,
"ARD": "D19"
}
}
}
}

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/lsc-lma35"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/lsc-lma35"
],

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb1s"
],

View File

@@ -2,7 +2,7 @@
"_base": [
"beken-72xx",
"beken-7231n",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb2l",
"pcb/wb2l-test",

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb2l",
"pcb/wb2l-test"

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb2s",
"pcb/wb2s-test"

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb3l"
],

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wb3s"
],

View File

@@ -3,7 +3,7 @@
"beken-72xx",
"beken-7231",
"beken-7231t",
"beken-7231-crypt-tuya",
"beken-7231-tuya",
"ic/bk7231-qfn32",
"pcb/wblc5",
"pcb/wblc5-test"

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"ic/rtl8710bn",
"pcb/wr2-base",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"ic/rtl8710bn",
"pcb/wr2-base",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"realtek-ambz-bx",
"ic/rtl8710bn",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"realtek-ambz-bx",
"ic/rtl8710bn",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"ic/rtl8710bn",
"pcb/wr3-base",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"ic/rtl8710bn",
"pcb/wr3-base",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"realtek-ambz-bx",
"ic/rtl8710bn",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"realtek-ambz-bx",
"ic/rtl8710bn",

View File

@@ -1,6 +1,7 @@
{
"_base": [
"realtek-ambz",
"realtek-ambz-tuya",
"realtek-ambz-2mb-788k",
"ic/rtl8710bn",
"pcb/wr3-base",