Skip to content

Commit 3a6516b

Browse files
committed
feat(esp32c61): Add support for ESP32-C61
1 parent aabf62d commit 3a6516b

File tree

5 files changed

+75
-36
lines changed

5 files changed

+75
-36
lines changed

.github/workflows/push.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,17 @@ jobs:
2525
runs-on: ubuntu-latest
2626
strategy:
2727
matrix:
28-
target: [esp32, esp32s2, esp32s3, esp32c2, esp32c3, esp32c6, esp32h2, esp32p4, esp32c5]
28+
target:
29+
- esp32
30+
- esp32c2
31+
- esp32c3
32+
- esp32c5
33+
- esp32c6
34+
- esp32c61
35+
- esp32h2
36+
- esp32p4
37+
- esp32s2
38+
- esp32s3
2939
fail-fast: false
3040
steps:
3141
- name: Checkout repository

configs/builds.json

Lines changed: 42 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"file":"libspi_flash.a",
55
"src":"build/esp-idf/spi_flash/libspi_flash.a",
66
"out":"lib/libspi_flash.a",
7-
"targets":["esp32","esp32c2","esp32c3","esp32s2","esp32s3","esp32c6","esp32h2","esp32p4","esp32c5"]
7+
"targets":["esp32","esp32c2","esp32c3","esp32c5","esp32c6","esp32c61","esp32h2","esp32p4","esp32s2","esp32s3"]
88
},
99
{
1010
"file":"libesp_psram.a",
@@ -45,7 +45,7 @@
4545
],
4646
"targets":[
4747
{
48-
"target": "esp32c5",
48+
"target": "esp32",
4949
"features":["qio_ram"],
5050
"idf_libs":["qio","80m"],
5151
"bootloaders":[
@@ -58,20 +58,6 @@
5858
["dio","80m"]
5959
]
6060
},
61-
{
62-
"target": "esp32p4",
63-
"features":["qio_ram","esp_sr"],
64-
"idf_libs":["qio","80m_200m"],
65-
"bootloaders":[
66-
["qio","80m_200m"],
67-
["dio","80m_200m"],
68-
["qio","40m_200m"],
69-
["dio","40m_200m"]
70-
],
71-
"mem_variants":[
72-
["dio","80m_200m"]
73-
]
74-
},
7561
{
7662
"target": "esp32c2",
7763
"skip": 1,
@@ -88,22 +74,22 @@
8874
]
8975
},
9076
{
91-
"target": "esp32h2",
77+
"target": "esp32c3",
9278
"features":[],
93-
"idf_libs":["qio","64m"],
79+
"idf_libs":["qio","80m"],
9480
"bootloaders":[
95-
["qio","64m"],
96-
["dio","64m"],
97-
["qio","16m"],
98-
["dio","16m"]
81+
["qio","80m"],
82+
["dio","80m"],
83+
["qio","40m"],
84+
["dio","40m"]
9985
],
10086
"mem_variants":[
101-
["dio","64m"]
87+
["dio","80m"]
10288
]
10389
},
10490
{
105-
"target": "esp32c6",
106-
"features":[],
91+
"target": "esp32c5",
92+
"features":["qio_ram"],
10793
"idf_libs":["qio","80m"],
10894
"bootloaders":[
10995
["qio","80m"],
@@ -116,7 +102,7 @@
116102
]
117103
},
118104
{
119-
"target": "esp32c3",
105+
"target": "esp32c6",
120106
"features":[],
121107
"idf_libs":["qio","80m"],
122108
"bootloaders":[
@@ -130,7 +116,8 @@
130116
]
131117
},
132118
{
133-
"target": "esp32",
119+
"target": "esp32c61",
120+
"skip": 1,
134121
"features":["qio_ram"],
135122
"idf_libs":["qio","80m"],
136123
"bootloaders":[
@@ -143,6 +130,34 @@
143130
["dio","80m"]
144131
]
145132
},
133+
{
134+
"target": "esp32h2",
135+
"features":[],
136+
"idf_libs":["qio","64m"],
137+
"bootloaders":[
138+
["qio","64m"],
139+
["dio","64m"],
140+
["qio","16m"],
141+
["dio","16m"]
142+
],
143+
"mem_variants":[
144+
["dio","64m"]
145+
]
146+
},
147+
{
148+
"target": "esp32p4",
149+
"features":["qio_ram","esp_sr"],
150+
"idf_libs":["qio","80m_200m"],
151+
"bootloaders":[
152+
["qio","80m_200m"],
153+
["dio","80m_200m"],
154+
["qio","40m_200m"],
155+
["dio","40m_200m"]
156+
],
157+
"mem_variants":[
158+
["dio","80m_200m"]
159+
]
160+
},
146161
{
147162
"target": "esp32s2",
148163
"features":["qio_ram"],

configs/defconfig.esp32c5

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@ CONFIG_BT_NIMBLE_NVS_PERSIST=y
1515
CONFIG_RTC_CLK_CAL_CYCLES=576
1616
# CONFIG_ESP_TASK_WDT_CHECK_IDLE_TASK_CPU0 is not set
1717
CONFIG_FREERTOS_IDLE_TASK_STACKSIZE=2304
18-
# This Enables RISCV LP for C6 - but it can't be used within Arduino at this time.
19-
#CONFIG_ULP_COPROC_ENABLED=y
20-
#CONFIG_ULP_COPROC_LP_CORE=y
21-
#CONFIG_ULP_COPROC_RESERVE_MEM=4096
2218

2319
#
2420
# OpenThread

configs/defconfig.esp32c61

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
CONFIG_SPIRAM=y
2+
3+
CONFIG_BT_ENABLED=y
4+
CONFIG_BTDM_CTRL_MODE_BLE_ONLY=y
5+
CONFIG_BTDM_CTRL_MODE_BR_EDR_ONLY=n
6+
CONFIG_BTDM_CTRL_MODE_BTDM=n
7+
CONFIG_BT_BLUEDROID_ENABLED=n
8+
CONFIG_BT_NIMBLE_ENABLED=y
9+
CONFIG_BT_NIMBLE_BLUFI_ENABLE=y
10+
CONFIG_BT_NIMBLE_NVS_PERSIST=y
11+
CONFIG_RTC_CLK_CAL_CYCLES=576
12+
# CONFIG_ESP_TASK_WDT_CHECK_IDLE_TASK_CPU0 is not set
13+
CONFIG_FREERTOS_IDLE_TASK_STACKSIZE=2304

tools/copy-libs.sh

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -452,10 +452,15 @@ for item; do
452452
mkdir -p "$out_cpath$rel_p"
453453
cp -n $f "$out_cpath$rel_p/"
454454
done
455-
# Temporary measure to fix issues caused by https://github.com/espressif/esp-idf/commit/dc4731101dd567cc74bbe4d0f03afe52b7db9afb#diff-1d2ce0d3989a80830fdf230bcaafb3117f32046d16cf46616ac3d55b4df2a988R17
456-
if [[ "$fname" == "bt" && "$out_sub" == "/include/$IDF_TARGET/include" && -f "$ipath/controller/$IDF_TARGET/esp_bt_cfg.h" ]]; then
457-
mkdir -p "$AR_SDK/include/$fname/controller/$IDF_TARGET"
458-
cp -n "$ipath/controller/$IDF_TARGET/esp_bt_cfg.h" "$AR_SDK/include/$fname/controller/$IDF_TARGET/esp_bt_cfg.h"
455+
456+
# Copy the respective file if any /include/esp32*/include is found and copy the respective file for the soc found
457+
if [[ "$out_sub" =~ ^/include/esp32[^/]+/include$ ]]; then
458+
soc_name=$(echo "$out_sub" | sed -n 's|/include/\(esp32[^/]*\)/include$|\1|p')
459+
echo "Copying bt config file for soc: $soc_name"
460+
if [ -n "$soc_name" ] && [ -f "$ipath/controller/$soc_name/esp_bt_cfg.h" ]; then
461+
mkdir -p "$AR_SDK/include/$fname/controller/$soc_name"
462+
cp -n "$ipath/controller/$soc_name/esp_bt_cfg.h" "$AR_SDK/include/$fname/controller/$soc_name/esp_bt_cfg.h"
463+
fi
459464
fi
460465
fi
461466
done

0 commit comments

Comments
 (0)