I dont know much about coding but can anyone tell me how to prevent the adafruit logo in this sketch from showing up, I dont want any logos to apear
here's the sketch:
// Adafruit-GFX-Library - Version: Latest
#include <Adafruit_GFX.h>
#include <Adafruit_SPITFT.h>
#include <Adafruit_SPITFT_Macros.h>
#include <gfxfont.h>
// Adafruit_SSD1306 - Version: Latest
#include <Adafruit_SSD1306.h>
int sensorPin = A0; // select the input pin for ldr
int sensorValue = 0;
bool toggle = false;
int buttonpin;
#define OLED_RESET 4 // not used / nicht genutzt bei diesem Display
Adafruit_SSD1306 display(OLED_RESET);
char inChar;
String string;
void setup() {
pinMode(13, OUTPUT);
buttonpin = 2;
pinMode(buttonpin, INPUT_PULLUP);
// initialize with the I2C addr 0x3C / mit I2C-Adresse 0x3c initialisieren
display.begin(SSD1306_SWITCHCAPVCC, 0x3C);
Serial.begin(9600);
display.display();
delay(2000);
display.clearDisplay();
display.setTextColor(INVERSE);
}
void loop()
{
if (digitalRead(buttonpin) == LOW)
{
toggle = !toggle;
while(digitalRead(buttonpin) == LOW);
}
switch( toggle )
{
case 1:
display.clearDisplay();
sensorValue = analogRead(sensorPin);
Serial.println(sensorValue);
display.setCursor(41,20);
display.setTextSize(1);
display.print("");
display.setCursor(41,20);
display.setTextSize(1);
display.print("DANGER!!!");
delay(500);
break;
case 0:
display.clearDisplay();
break;
}
display.display();
}