ttgobeam.h added
This commit is contained in:
parent
8df149d303
commit
d73f31607f
@ -11,10 +11,11 @@
|
|||||||
|
|
||||||
; ---> SELECT TARGET PLATFORM HERE! <---
|
; ---> SELECT TARGET PLATFORM HERE! <---
|
||||||
[platformio]
|
[platformio]
|
||||||
env_default = heltec
|
;env_default = heltec
|
||||||
;env_default = ttgov1
|
;env_default = ttgov1
|
||||||
;env_default = ttgov2
|
;env_default = ttgov2
|
||||||
;env_default = ttgov21
|
;env_default = ttgov21
|
||||||
|
env_default = ttgobeam
|
||||||
;env_default = lopy
|
;env_default = lopy
|
||||||
;env_default = lopy4
|
;env_default = lopy4
|
||||||
;env_default = fipy
|
;env_default = fipy
|
||||||
@ -101,6 +102,20 @@ build_flags =
|
|||||||
${common_env_data.build_flags}
|
${common_env_data.build_flags}
|
||||||
-include "src/hal/ttgov21.h"
|
-include "src/hal/ttgov21.h"
|
||||||
|
|
||||||
|
[env:ttgobeam]
|
||||||
|
platform = ${common_env_data.platform_espressif32}
|
||||||
|
framework = arduino
|
||||||
|
board = esp32dev
|
||||||
|
board_build.partitions = ${common_env_data.board_build.partitions}
|
||||||
|
board_upload.maximum_size = ${common_env_data.board_upload.maximum_size}
|
||||||
|
monitor_speed = 115200
|
||||||
|
upload_speed = 921600
|
||||||
|
lib_deps =
|
||||||
|
${common_env_data.lib_deps_display}
|
||||||
|
build_flags =
|
||||||
|
${common_env_data.build_flags}
|
||||||
|
-include "src/hal/ttgobeam.h"
|
||||||
|
|
||||||
[env:fipy]
|
[env:fipy]
|
||||||
platform = espressif32@1.0.1
|
platform = espressif32@1.0.1
|
||||||
framework = arduino
|
framework = arduino
|
||||||
|
22
src/hal/ttgobeam.h
Normal file
22
src/hal/ttgobeam.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
// Hardware related definitions for TTGO T-Beam board
|
||||||
|
|
||||||
|
#define CFG_sx1276_radio 1 // HPD13A LoRa SoC
|
||||||
|
|
||||||
|
#define HAS_LED 21 // on board green LED_G1
|
||||||
|
#//define HAS_LED 22 // on board red LED_G3 ? to be checked
|
||||||
|
#define HAS_BATTERY_PROBE ADC1_GPIO35_CHANNEL // battery probe GPIO pin -> ADC1_CHANNEL_7 ? to be checked
|
||||||
|
#define BATT_FACTOR 2 // voltage divider 100k/100k on board
|
||||||
|
// #define HAS_GPS // to be done
|
||||||
|
// GSP serial (9600, SERIAL_8N1, 12, 15); //17-TX 18-RX
|
||||||
|
|
||||||
|
// re-define pin definitions of pins_arduino.h
|
||||||
|
#define PIN_SPI_SS 18 // ESP32 GPIO18 (Pin18) -- HPD13A NSS/SEL (Pin4) SPI Chip Select Input
|
||||||
|
#define PIN_SPI_MOSI 27 // ESP32 GPIO27 (Pin27) -- HPD13A MOSI/DSI (Pin6) SPI Data Input
|
||||||
|
#define PIN_SPI_MISO 19 // ESP32 GPIO19 (Pin19) -- HPD13A MISO/DSO (Pin7) SPI Data Output
|
||||||
|
#define PIN_SPI_SCK 5 // ESP32 GPIO5 (Pin5) -- HPD13A SCK (Pin5) SPI Clock Input
|
||||||
|
|
||||||
|
// non arduino pin definitions
|
||||||
|
#define RST 14 // connected to ESP32 RST/EN
|
||||||
|
#define DIO0 26 // ESP32 GPIO26 <-> HPD13A IO0
|
||||||
|
#define DIO1 33 // ESP32 GPIO33 <-> HPDIO1 <-> HPD13A IO1 // !!needs external wiring!!
|
||||||
|
#define DIO2 32 // ESP32 GPIO32 <-> HPDIO2 <-> HPD13A IO2 // needs external wiring, but not needed for LoRa
|
Loading…
Reference in New Issue
Block a user