Skip to content

Commit 9d0274b

Browse files
ladyadahathach
andauthored
Pin fixes for the Camera board (espressif#9021)
* update pins * re-fix pinout that was reverted * more pins * Update esp32-hal-tinyusb.c --------- Co-authored-by: Ha Thach <[email protected]>
1 parent ad4f0ac commit 9d0274b

File tree

8 files changed

+19
-12
lines changed

8 files changed

+19
-12
lines changed
0 Bytes
Binary file not shown.

Diff for: variants/adafruit_camera_esp32s3/pins_arduino.h

+6-9
Original file line numberDiff line numberDiff line change
@@ -24,18 +24,18 @@ static const uint8_t LED_BUILTIN = PIN_NEOPIXEL+SOC_GPIO_PIN_COUNT;
2424
#define RGB_BRIGHTNESS 64
2525

2626

27-
//static const uint8_t TFT_BACKLIGHT = 41;
27+
static const uint8_t TFT_BACKLIGHT = 45;
2828
static const uint8_t TFT_DC = 40;
2929
static const uint8_t TFT_CS = 39;
3030
static const uint8_t TFT_RESET = 38;
3131
static const uint8_t TFT_RST = 38;
3232

3333
static const uint8_t SD_CS = 48;
3434
static const uint8_t SD_CHIP_SELECT = 48;
35-
static const uint8_t SPEAKER = 41;
35+
static const uint8_t SPEAKER = 46;
3636

37-
static const uint8_t SDA = 33;
38-
static const uint8_t SCL = 34;
37+
static const uint8_t SCL = 33;
38+
static const uint8_t SDA = 34;
3939

4040
static const uint8_t SS = 48;
4141
static const uint8_t MOSI = 35;
@@ -55,19 +55,16 @@ static const uint8_t DAC2 = 18;
5555

5656
#define AWEXP_SPKR_SD 0
5757
#define AWEXP_BUTTON_SEL 1
58-
#define AWEXP_BACKLIGHT 2
59-
#define AWEXP_CAM_PWDN 7
6058
#define AWEXP_SD_DET 8
6159
#define AWEXP_SD_PWR 9
62-
#define AWEXP_CAM_RST 10
6360
#define AWEXP_BUTTON_OK 11
6461
#define AWEXP_BUTTON_RIGHT 12
6562
#define AWEXP_BUTTON_UP 13
6663
#define AWEXP_BUTTON_LEFT 14
6764
#define AWEXP_BUTTON_DOWN 15
6865

69-
#define PWDN_GPIO_NUM -1 // connected through expander
70-
#define RESET_GPIO_NUM -1 // connected through expander
66+
#define RESET_GPIO_NUM 47
67+
#define PWDN_GPIO_NUM 21
7168
#define XCLK_GPIO_NUM 8
7269
#define SIOD_GPIO_NUM SDA
7370
#define SIOC_GPIO_NUM SCL

Diff for: variants/adafruit_camera_esp32s3/tinyuf2.bin

-8.67 KB
Binary file not shown.

Diff for: variants/adafruit_camera_esp32s3/variant.cpp

+10-1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,15 @@ extern "C" {
3131
// Initialize variant/board, called before setup()
3232
void initVariant(void)
3333
{
34-
34+
pinMode(TFT_BACKLIGHT, OUTPUT);
35+
digitalWrite(TFT_BACKLIGHT, LOW);
36+
pinMode(SD_CS, OUTPUT);
37+
digitalWrite(SD_CS, HIGH);
38+
pinMode(TFT_CS, OUTPUT);
39+
digitalWrite(TFT_CS, HIGH);
40+
pinMode(TFT_RESET, OUTPUT);
41+
digitalWrite(TFT_RESET, LOW);
42+
delay(1);
43+
digitalWrite(TFT_RESET, HIGH);
3544
}
3645
}
0 Bytes
Binary file not shown.

Diff for: variants/adafruit_metro_esp32s3/pins_arduino.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#define BUILTIN_LED LED_BUILTIN // backward compatibility
1515

1616
// Neopixel
17-
#define PIN_NEOPIXEL 45
17+
#define PIN_NEOPIXEL 46
1818
// RGB_BUILTIN and RGB_BRIGHTNESS can be used in new Arduino API neopixelWrite() and digitalWrite() for blinking
1919
#define RGB_BUILTIN (PIN_NEOPIXEL+SOC_GPIO_PIN_COUNT)
2020
#define RGB_BRIGHTNESS 64

Diff for: variants/adafruit_metro_esp32s3/tinyuf2.bin

0 Bytes
Binary file not shown.

Diff for: variants/adafruit_metro_esp32s3/variant.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ extern "C" {
3030

3131
// Initialize variant/board, called before setup()
3232
void initVariant(void) {
33-
// default SD_CS to input pullup
33+
// default SD_CS to input pullup (we cannot have built in pullup since its
34+
// a strapping pin!)
3435
pinMode(SS, INPUT_PULLUP);
3536
}
3637

0 commit comments

Comments
 (0)