add some code

This commit is contained in:
2025-09-05 13:25:11 +08:00
parent 9ff0a99e7a
commit 3cf1229a85
8911 changed files with 2535396 additions and 0 deletions

8
partitions/v1/16m.csv Normal file
View File

@@ -0,0 +1,8 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 6M,
ota_1, app, ota_1, 0x700000, 6M,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 6M,
8 ota_1, app, ota_1, 0x700000, 6M,

View File

@@ -0,0 +1,8 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0x3f0000,
ota_0, app, ota_0, 0x400000, 6M,
ota_1, app, ota_1, 0xa00000, 6M,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0x3f0000,
7 ota_0, app, ota_0, 0x400000, 6M,
8 ota_1, app, ota_1, 0xa00000, 6M,

View File

@@ -0,0 +1,9 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 5M,
ota_1, app, ota_1, 0x700000, 5M,
assets_A, data, spiffs, , 4000K,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 5M,
8 ota_1, app, ota_1, 0x700000, 5M,
9 assets_A, data, spiffs, , 4000K,

10
partitions/v1/32m.csv Normal file
View File

@@ -0,0 +1,10 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvsfactory, data, nvs, , 200K,
nvs, data, nvs, , 840K,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
model, data, spiffs, , 0xF0000,
# According to scripts/versions.py, app partition must be aligned to 1MB
ota_0, app, ota_0, 0x200000, 12M,
ota_1, app, ota_1, , 12M,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvsfactory, data, nvs, , 200K,
4 nvs, data, nvs, , 840K,
5 otadata, data, ota, , 0x2000,
6 phy_init, data, phy, , 0x1000,
7 model, data, spiffs, , 0xF0000,
8 # According to scripts/versions.py, app partition must be aligned to 1MB
9 ota_0, app, ota_0, 0x200000, 12M,
10 ota_1, app, ota_1, , 12M,

7
partitions/v1/4m.csv Normal file
View File

@@ -0,0 +1,7 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
factory, app, factory, 0x100000, 3M,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 factory, app, factory, 0x100000, 3M,

View File

@@ -0,0 +1,8 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xD0000,
factory, app, factory, 0xe0000, 2200K,
assets_A, data, spiffs, , 700K,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xD0000,
7 factory, app, factory, 0xe0000, 2200K,
8 assets_A, data, spiffs, , 700K,

8
partitions/v1/8m.csv Normal file
View File

@@ -0,0 +1,8 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 0x380000,
ota_1, app, ota_1, 0x480000, 0x380000,
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 0x380000,
8 ota_1, app, ota_1, 0x480000, 0x380000,

9
partitions/v2/16m.csv Normal file
View File

@@ -0,0 +1,9 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 4M,
ota_1, app, ota_1, 0x500000, 4M,
assets, data, spiffs, 0x900000, 7M
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 4M,
8 ota_1, app, ota_1, 0x500000, 4M,
9 assets, data, spiffs, 0x900000, 7M

9
partitions/v2/16m_c3.csv Normal file
View File

@@ -0,0 +1,9 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 4M,
ota_1, app, ota_1, 0x500000, 4M,
assets, data, spiffs, 0x900000, 4000K
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 4M,
8 ota_1, app, ota_1, 0x500000, 4M,
9 assets, data, spiffs, 0x900000, 4000K

10
partitions/v2/32m.csv Normal file
View File

@@ -0,0 +1,10 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvsfactory, data, nvs, , 200K,
nvs, data, nvs, , 840K,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
model, data, spiffs, , 0xF0000,
ota_0, app, ota_0, 0x200000, 4M,
ota_1, app, ota_1, 0x600000, 4M,
assets, data, spiffs, 0xA00000, 16M
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvsfactory, data, nvs, , 200K,
4 nvs, data, nvs, , 840K,
5 otadata, data, ota, , 0x2000,
6 phy_init, data, phy, , 0x1000,
7 model, data, spiffs, , 0xF0000,
8 ota_0, app, ota_0, 0x200000, 4M,
9 ota_1, app, ota_1, 0x600000, 4M,
10 assets, data, spiffs, 0xA00000, 16M

9
partitions/v2/8m.csv Normal file
View File

@@ -0,0 +1,9 @@
# ESP-IDF Partition Table
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x4000,
otadata, data, ota, 0xd000, 0x2000,
phy_init, data, phy, 0xf000, 0x1000,
model, data, spiffs, 0x10000, 0xF0000,
ota_0, app, ota_0, 0x100000, 3M,
ota_1, app, ota_1, 0x400000, 3M,
assets, data, spiffs, 0x700000, 1M
1 # ESP-IDF Partition Table
2 # Name, Type, SubType, Offset, Size, Flags
3 nvs, data, nvs, 0x9000, 0x4000,
4 otadata, data, ota, 0xd000, 0x2000,
5 phy_init, data, phy, 0xf000, 0x1000,
6 model, data, spiffs, 0x10000, 0xF0000,
7 ota_0, app, ota_0, 0x100000, 3M,
8 ota_1, app, ota_1, 0x400000, 3M,
9 assets, data, spiffs, 0x700000, 1M

46
partitions/v2/README.md Normal file
View File

@@ -0,0 +1,46 @@
# Version 2 Partition Table
This version introduces significant improvements over v1 by adding an `assets` partition to support network-loadable content.
## Key Changes from v1
### Added Assets Partition
The v2 partition table includes a new `assets` partition that stores:
- **Wake word models**: Customizable wake word models that can be loaded from the network
- **Theme files**: Complete theming system including:
- Fonts
- Audio effects
- Background images
- Custom emoji packs
### Partition Layout Comparison
#### v1 Layout (16MB)
- `nvs`: 16KB (non-volatile storage)
- `otadata`: 8KB (OTA data)
- `phy_init`: 4KB (PHY initialization data)
- `model`: 960KB (model storage)
- `ota_0`: 6MB (application partition 0)
- `ota_1`: 6MB (application partition 1)
#### v2 Layout (16MB)
- `nvs`: 16KB (non-volatile storage)
- `otadata`: 8KB (OTA data)
- `phy_init`: 4KB (PHY initialization data)
- `model`: 960KB (model storage)
- `ota_0`: 4MB (application partition 0)
- `ota_1`: 4MB (application partition 1)
- `assets`: 7MB (network-loadable assets)
### Benefits
1. **Dynamic Content**: Users can download and update wake word models and themes without reflashing
2. **Reduced App Size**: Application partitions are smaller, allowing more space for assets
3. **Customization**: Support for custom themes and wake words enhances user experience
4. **Network Flexibility**: Assets can be updated independently of the main application
### Available Configurations
- `8m.csv`: For 8MB flash devices
- `16m.csv`: For 16MB flash devices (standard)
- `16m_c3.csv`: For 16MB flash devices with ESP32-C3 optimization