mirror of
https://github.com/lora-aprs/LoRa_APRS_iGate.git
synced 2026-02-20 06:34:23 +01:00
cleanup pin definitions
This commit is contained in:
parent
2c655eda47
commit
9bc20ead1f
|
|
@ -9,6 +9,8 @@
|
|||
; https://docs.platformio.org/page/projectconf.html
|
||||
|
||||
[env]
|
||||
platform = espressif32
|
||||
framework = arduino
|
||||
lib_ldf_mode = deep+
|
||||
monitor_speed = 115200
|
||||
lib_deps =
|
||||
|
|
@ -19,12 +21,20 @@ lib_deps =
|
|||
NTPClient
|
||||
APRS-IS-Lib
|
||||
|
||||
[env:heltec_wifi_lora_32]
|
||||
platform = espressif32
|
||||
board = heltec_wifi_lora_32
|
||||
framework = arduino
|
||||
[env:ttgo-lora32-v1]
|
||||
board = ttgo-lora32-v1
|
||||
|
||||
[env:heltec_wifi_lora_32_V2]
|
||||
platform = espressif32
|
||||
board = heltec_wifi_lora_32_V2
|
||||
framework = arduino
|
||||
[env:ttgo-lora32-v2]
|
||||
board = ttgo-lora32-v2
|
||||
|
||||
[env:ttgo-t-beam]
|
||||
board = ttgo-t-beam
|
||||
lib_deps =
|
||||
Adafruit GFX Library
|
||||
Adafruit SSD1306
|
||||
LoRa
|
||||
APRS-Decoder-Lib
|
||||
NTPClient
|
||||
APRS-IS-Lib
|
||||
TinyGPSPlus
|
||||
AXP202X_Library
|
||||
|
|
|
|||
|
|
@ -182,8 +182,8 @@ void setup_ota()
|
|||
void setup_lora()
|
||||
{
|
||||
Serial.println("[INFO] Set SPI pins!");
|
||||
SPI.begin(SCK, MISO, MOSI, SS);
|
||||
LoRa.setPins(SS, RST_LoRa, DIO0);
|
||||
SPI.begin(LORA_SCK, LORA_MISO, LORA_MOSI, LORA_CS);
|
||||
LoRa.setPins(LORA_CS, LORA_RST, LORA_IRQ);
|
||||
Serial.println("[INFO] Set LoRa pins!");
|
||||
|
||||
long freq = 433775000;
|
||||
|
|
|
|||
|
|
@ -5,16 +5,16 @@
|
|||
|
||||
#include "display.h"
|
||||
|
||||
Adafruit_SSD1306 display(DISPLAY_WIDTH, DISPLAY_HEIGHT, &Wire, RST_OLED);
|
||||
Adafruit_SSD1306 display(128, 64, &Wire, OLED_RST);
|
||||
|
||||
void setup_display()
|
||||
{
|
||||
pinMode(RST_OLED, OUTPUT);
|
||||
digitalWrite(RST_OLED, LOW);
|
||||
pinMode(OLED_RST, OUTPUT);
|
||||
digitalWrite(OLED_RST, LOW);
|
||||
delay(20);
|
||||
digitalWrite(RST_OLED, HIGH);
|
||||
digitalWrite(OLED_RST, HIGH);
|
||||
|
||||
Wire.begin(SDA_OLED, SCL_OLED);
|
||||
Wire.begin(OLED_SDA, OLED_SCL);
|
||||
if(!display.begin(SSD1306_SWITCHCAPVCC, 0x3c, false, false))
|
||||
{
|
||||
Serial.println("SSD1306 allocation failed");
|
||||
|
|
|
|||
|
|
@ -11,4 +11,10 @@ void show_display(String header, String line1, String line2, String line3, int w
|
|||
void show_display(String header, String line1, String line2, String line3, String line4, int wait = 0);
|
||||
void show_display(String header, String line1, String line2, String line3, String line4, String line5, int wait = 0);
|
||||
|
||||
#ifdef ARDUINO_T_Beam
|
||||
#define OLED_SDA 21
|
||||
#define OLED_SCL 22
|
||||
#define OLED_RST 4
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in a new issue