Added support for ESP32-C3
This commit is contained in:
@@ -14,18 +14,18 @@ Use twai(Two-Wire Automotive Interface) driver instead of can driver.
|
||||
# Hardware requirements
|
||||
1. SN65HVD23x CAN-BUS Transceiver
|
||||
|
||||
|SN65HVD23x||ESP32|ESP32-S2||
|
||||
|:-:|:-:|:-:|:-:|:-:|
|
||||
|D(CTX)|--|GPIO21|GPIO17|(*1)|
|
||||
|GND|--|GND|GND||
|
||||
|Vcc|--|3.3V|3.3V||
|
||||
|R(CRX)|--|GPIO22|GPIO18|(*1)|
|
||||
|Vref|--|N/C|N/C||
|
||||
|CANL|--|||To CAN Bus|
|
||||
|CANH|--|||To CAN Bus|
|
||||
|RS|--|GND|GND|(*2)|
|
||||
|SN65HVD23x||ESP32|ESP32-S2|ESP32-C3||
|
||||
|:-:|:-:|:-:|:-:|:-:|:-:|
|
||||
|D(CTX)|--|GPIO21|GPIO17|GPIO9|(*1)|
|
||||
|GND|--|GND|GND|GND||
|
||||
|Vcc|--|3.3V|3.3V|3.3V||
|
||||
|R(CRX)|--|GPIO22|GPIO18|GPIO10|(*1)|
|
||||
|Vref|--|N/C|N/C|N/C||
|
||||
|CANL|--||||To CAN Bus|
|
||||
|CANH|--||||To CAN Bus|
|
||||
|RS|--|GND|GND|GND|(*2)|
|
||||
|
||||
(*1) You can change using menuconfig.
|
||||
(*1) You can change using menuconfig. But it may not work with other GPIOs.
|
||||
|
||||
(*2) N/C for SN65HVD232
|
||||
|
||||
@@ -55,11 +55,11 @@ I used 150 ohms.
|
||||
| | | | | |
|
||||
+--^^^--+ | | +--^^^--+
|
||||
| R1 | | | | R2 |
|
||||
|---+-------|-----+-------|-----+-------|---| BackBorn H
|
||||
|---+-------|-------+-------|-------+-------|---| BackBorn H
|
||||
| | |
|
||||
| | |
|
||||
| | |
|
||||
|-----------+-------------+-------------+---| BackBorn L
|
||||
|-----------+---------------+---------------+---| BackBorn L
|
||||
|
||||
+--^^^--+:Terminaror register
|
||||
R1:120 ohms
|
||||
@@ -89,6 +89,15 @@ idf.py menuconfig
|
||||
idf.py flash
|
||||
```
|
||||
|
||||
# Installation for ESP32-C3
|
||||
```
|
||||
git clone https://github.com/nopnop2002/esp-idf-can2http
|
||||
cd esp-idf-can2http
|
||||
idf.py set-target esp32c3
|
||||
idf.py menuconfig
|
||||
idf.py flash
|
||||
```
|
||||
|
||||
# Configuration
|
||||

|
||||

|
||||
|
||||
@@ -44,7 +44,7 @@ menu "Application Configuration"
|
||||
config CTX_GPIO
|
||||
int "CTX GPIO number"
|
||||
range 0 34
|
||||
default 2 if IDF_TARGET_ESP32C3
|
||||
default 9 if IDF_TARGET_ESP32C3
|
||||
default 17 if IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
|
||||
default 21 if IDF_TARGET_ESP32
|
||||
help
|
||||
@@ -55,7 +55,7 @@ menu "Application Configuration"
|
||||
config CRX_GPIO
|
||||
int "CRX GPIO number"
|
||||
range 0 34
|
||||
default 3 if IDF_TARGET_ESP32C3
|
||||
default 10 if IDF_TARGET_ESP32C3
|
||||
default 18 if IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
|
||||
default 22 if IDF_TARGET_ESP32
|
||||
help
|
||||
|
||||
@@ -1,8 +1,3 @@
|
||||
#
|
||||
# Serial flasher config
|
||||
#
|
||||
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y
|
||||
|
||||
#
|
||||
# Partition Table
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user