trunk it baby

This commit is contained in:
Thomas Göttgens 2023-03-29 13:07:27 +02:00
parent 7930aa1635
commit 82ba59765c
9 changed files with 96 additions and 138 deletions

View File

@ -1,6 +1,6 @@
{ {
"build": { "build": {
"arduino":{ "arduino": {
"ldscript": "esp32s3_out.ld", "ldscript": "esp32s3_out.ld",
"memory_type": "qio_opi" "memory_type": "qio_opi"
}, },
@ -15,29 +15,17 @@
"f_cpu": "240000000L", "f_cpu": "240000000L",
"f_flash": "80000000L", "f_flash": "80000000L",
"flash_mode": "qio", "flash_mode": "qio",
"hwids": [ "hwids": [["0x303A", "0x1001"]],
[
"0x303A",
"0x1001"
]
],
"mcu": "esp32s3", "mcu": "esp32s3",
"variant": "my-esp32s3-diy-oled" "variant": "my-esp32s3-diy-oled"
}, },
"connectivity": [ "connectivity": ["wifi"],
"wifi"
],
"debug": { "debug": {
"default_tool": "esp-builtin", "default_tool": "esp-builtin",
"onboard_tools": [ "onboard_tools": ["esp-builtin"],
"esp-builtin"
],
"openocd_target": "esp32s3.cfg" "openocd_target": "esp32s3.cfg"
}, },
"frameworks": [ "frameworks": ["arduino", "espidf"],
"arduino",
"espidf"
],
"name": "Clone ESP32-S3-DevKitC-1 v1.1 (16 MB FLASH, 8 MB PSRAM)", "name": "Clone ESP32-S3-DevKitC-1 v1.1 (16 MB FLASH, 8 MB PSRAM)",
"upload": { "upload": {
"flash_size": "16MB", "flash_size": "16MB",

View File

@ -1,6 +1,6 @@
{ {
"build": { "build": {
"arduino":{ "arduino": {
"ldscript": "esp32s3_out.ld", "ldscript": "esp32s3_out.ld",
"memory_type": "qio_opi" "memory_type": "qio_opi"
}, },
@ -15,29 +15,17 @@
"f_cpu": "240000000L", "f_cpu": "240000000L",
"f_flash": "80000000L", "f_flash": "80000000L",
"flash_mode": "qio", "flash_mode": "qio",
"hwids": [ "hwids": [["0x303A", "0x1001"]],
[
"0x303A",
"0x1001"
]
],
"mcu": "esp32s3", "mcu": "esp32s3",
"variant": "my_esp32s3_diy_eink" "variant": "my_esp32s3_diy_eink"
}, },
"connectivity": [ "connectivity": ["wifi"],
"wifi"
],
"debug": { "debug": {
"default_tool": "esp-builtin", "default_tool": "esp-builtin",
"onboard_tools": [ "onboard_tools": ["esp-builtin"],
"esp-builtin"
],
"openocd_target": "esp32s3.cfg" "openocd_target": "esp32s3.cfg"
}, },
"frameworks": [ "frameworks": ["arduino", "espidf"],
"arduino",
"espidf"
],
"name": "Clone ESP32-S3-DevKitC-1 v1.1 (16 MB FLASH, 8 MB PSRAM)", "name": "Clone ESP32-S3-DevKitC-1 v1.1 (16 MB FLASH, 8 MB PSRAM)",
"upload": { "upload": {
"flash_size": "16MB", "flash_size": "16MB",

View File

@ -16,21 +16,16 @@
*/ */
#include "variant.h" #include "variant.h"
#include "nrf.h"
#include "wiring_constants.h" #include "wiring_constants.h"
#include "wiring_digital.h" #include "wiring_digital.h"
#include "nrf.h"
const uint32_t g_ADigitalPinMap[] = const uint32_t g_ADigitalPinMap[] = {
{
// P0 // P0
0, 1, 2, 3, 4, 5, 6, 7, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
8, 9, 10, 11, 12, 13, 14, 15,
16, 17, 18, 19, 20, 21, 22, 23,
24, 25, 26, 27, 28, 29, 30, 31,
// P1 // P1
32, 33, 34, 35, 36, 37, 38, 39, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47};
40, 41, 42, 43, 44, 45, 46, 47};
void initVariant() void initVariant()
{ {

View File

@ -16,21 +16,16 @@
*/ */
#include "variant.h" #include "variant.h"
#include "nrf.h"
#include "wiring_constants.h" #include "wiring_constants.h"
#include "wiring_digital.h" #include "wiring_digital.h"
#include "nrf.h"
const uint32_t g_ADigitalPinMap[] = const uint32_t g_ADigitalPinMap[] = {
{
// P0 // P0
0, 1, 2, 3, 4, 5, 6, 7, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
8, 9, 10, 11, 12, 13, 14, 15,
16, 17, 18, 19, 20, 21, 22, 23,
24, 25, 26, 27, 28, 29, 30, 31,
// P1 // P1
32, 33, 34, 35, 36, 37, 38, 39, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47};
40, 41, 42, 43, 44, 45, 46, 47};
void initVariant() void initVariant()
{ {

View File

@ -56,7 +56,6 @@ static const uint8_t A0 = PIN_A0;
// Other pins // Other pins
#define PIN_AREF (-1) // AREF Not yet used #define PIN_AREF (-1) // AREF Not yet used
static const uint8_t AREF = PIN_AREF; static const uint8_t AREF = PIN_AREF;
/* /*
@ -101,7 +100,6 @@ static const uint8_t SCK = PIN_SPI_SCK;
//#define SX128X_RXEN (0 + 12) //#define SX128X_RXEN (0 + 12)
#define SX128X_RESET LORA_RESET #define SX128X_RESET LORA_RESET
#define PIN_GPS_EN (-1) #define PIN_GPS_EN (-1)
#define PIN_GPS_PPS (-1) // Pulse per second input from the GPS #define PIN_GPS_PPS (-1) // Pulse per second input from the GPS
@ -125,7 +123,7 @@ static const uint8_t SCK = PIN_SPI_SCK;
#undef AREF_VOLTAGE #undef AREF_VOLTAGE
#define AREF_VOLTAGE 3.0 #define AREF_VOLTAGE 3.0
#define VBAT_AR_INTERNAL AR_INTERNAL_3_0 #define VBAT_AR_INTERNAL AR_INTERNAL_3_0
#define ADC_MULTIPLIER VBAT_DIVIDER_COMP //REAL_VBAT_MV_PER_LSB #define ADC_MULTIPLIER VBAT_DIVIDER_COMP // REAL_VBAT_MV_PER_LSB
#define VBAT_RAW_TO_SCALED(x) (REAL_VBAT_MV_PER_LSB * x) #define VBAT_RAW_TO_SCALED(x) (REAL_VBAT_MV_PER_LSB * x)
#ifdef __cplusplus #ifdef __cplusplus

View File

@ -10,8 +10,8 @@
#define NUM_DIGITAL_PINS 48 #define NUM_DIGITAL_PINS 48
#define NUM_ANALOG_INPUTS 20 #define NUM_ANALOG_INPUTS 20
#define analogInputToDigitalPin(p) (((p)<20)?(analogChannelToDigitalPin(p)):-1) #define analogInputToDigitalPin(p) (((p) < 20) ? (analogChannelToDigitalPin(p)) : -1)
#define digitalPinToInterrupt(p) (((p)<48)?(p):-1) #define digitalPinToInterrupt(p) (((p) < 48) ? (p) : -1)
#define digitalPinHasPWM(p) (p < 46) #define digitalPinHasPWM(p) (p < 46)
// The default Wire will be mapped to PMU and RTC // The default Wire will be mapped to PMU and RTC
@ -24,8 +24,6 @@ static const uint8_t SCK = 5;
static const uint8_t MOSI = 6; static const uint8_t MOSI = 6;
static const uint8_t SS = 7; static const uint8_t SS = 7;
//#define SPI_MOSI (11) //#define SPI_MOSI (11)
//#define SPI_SCK (14) //#define SPI_SCK (14)
//#define SPI_MISO (2) //#define SPI_MISO (2)

View File

@ -8,15 +8,14 @@
//#define USE_SSD1306 //#define USE_SSD1306
#define I2C_SDA 18 //1 // I2C pins for this board #define I2C_SDA 18 // 1 // I2C pins for this board
#define I2C_SCL 17 //2 #define I2C_SCL 17 // 2
//#define LED_PIN 38 // This is a RGB LED not a standard LED //#define LED_PIN 38 // This is a RGB LED not a standard LED
#define BUTTON_PIN 0 // This is the BOOT button #define BUTTON_PIN 0 // This is the BOOT button
#define BUTTON_NEED_PULLUP #define BUTTON_NEED_PULLUP
//#define USE_RF95 // RFM95/SX127x //#define USE_RF95 // RFM95/SX127x
//#define USE_SX1262 //#define USE_SX1262
#define USE_SX1280 #define USE_SX1280
@ -46,7 +45,7 @@
#endif #endif
#define USE_EINK #define USE_EINK
/* /*
* eink display pins * eink display pins
*/ */
#define PIN_EINK_CS 13 #define PIN_EINK_CS 13

View File

@ -10,8 +10,8 @@
#define NUM_DIGITAL_PINS 48 #define NUM_DIGITAL_PINS 48
#define NUM_ANALOG_INPUTS 20 #define NUM_ANALOG_INPUTS 20
#define analogInputToDigitalPin(p) (((p)<20)?(analogChannelToDigitalPin(p)):-1) #define analogInputToDigitalPin(p) (((p) < 20) ? (analogChannelToDigitalPin(p)) : -1)
#define digitalPinToInterrupt(p) (((p)<48)?(p):-1) #define digitalPinToInterrupt(p) (((p) < 48) ? (p) : -1)
#define digitalPinHasPWM(p) (p < 46) #define digitalPinHasPWM(p) (p < 46)
// The default Wire will be mapped to PMU and RTC // The default Wire will be mapped to PMU and RTC
@ -24,8 +24,6 @@ static const uint8_t SCK = 5;
static const uint8_t MOSI = 6; static const uint8_t MOSI = 6;
static const uint8_t SS = 7; static const uint8_t SS = 7;
//#define SPI_MOSI (11) //#define SPI_MOSI (11)
//#define SPI_SCK (14) //#define SPI_SCK (14)
//#define SPI_MISO (2) //#define SPI_MISO (2)

View File

@ -8,15 +8,14 @@
#define USE_SSD1306 #define USE_SSD1306
#define I2C_SDA 18 //1 // I2C pins for this board #define I2C_SDA 18 // 1 // I2C pins for this board
#define I2C_SCL 17 //2 #define I2C_SCL 17 // 2
//#define LED_PIN 38 // This is a RGB LED not a standard LED //#define LED_PIN 38 // This is a RGB LED not a standard LED
#define BUTTON_PIN 0 // This is the BOOT button #define BUTTON_PIN 0 // This is the BOOT button
#define BUTTON_NEED_PULLUP #define BUTTON_NEED_PULLUP
//#define USE_RF95 // RFM95/SX127x //#define USE_RF95 // RFM95/SX127x
//#define USE_SX1262 //#define USE_SX1262
#define USE_SX1280 #define USE_SX1280
@ -46,7 +45,7 @@
#endif #endif
//#define USE_EINK //#define USE_EINK
/* /*
* eink display pins * eink display pins
*/ */
//#define PIN_EINK_CS 13 //#define PIN_EINK_CS 13