-
Datei
sketch_oct06b.ino
#include <Streaming.h> // die Lib findest du selber ;-) Print &cout = Serial; // cout Emulation für "Arme" #include "test.h" char *getA(); char *getB(); void setup() { Serial.begin(9600); cout << F("Start: ") << F(__FILE__) << endl; cout << testStr << endl; cout << getA() << endl; cout << getB() << endl; } void loop() { }
in „Konstanten-Datei in C“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
20221011b-interrupt-Einspeise.ino
// Einspeisewechselrichter // https://www.etechnophiles.com/how-to-change-the-pwm-frequency-of-arduino-nano/ // TCCR2B = TCCR2B & B11111000 | B00000001; // for PWM frequency of 31372.55 Hz on D3 & D11 // https://www.arduino.cc/reference/de/language/functions/external-interrupts/attachinterrupt/ int lpumppin = 11; int dcdcanpin = 7; int modulationspin = 3; // OVLO mit Auszeit int drainpin = 6; int dcdcauspin = 4; unsigned long drainist; unsigned long drainstart; unsigned long drainvz = 10000; bool drain; bool ovlodrain; bool dcdcaus; // UVLO Batterie mit Hysterese int battpin = A0; unsigned long
-
Datei
sketch_oct07a.ino
#include <SPI.h> #include <Wire.h> #include <Adafruit_GFX.h> #include <Adafruit_SSD1306.h> #define DISPLAY_I2C_ADDRESS 0x3C #define DISPLAY_WIDTH 128 #define DISPLAY_HEIGHT 64 Adafruit_SSD1306 display(DISPLAY_WIDTH, DISPLAY_HEIGHT, &Wire, -1); /*#include "Arduino.h" #include "SoftwareSerial.h" #include "DFRobotDFPlayerMini.h" SoftwareSerial mySoftwareSerial(10, 11); DFRobotDFPlayerMini myDFPlayer;*/ int motor = 6; int in1 = 9; int in2 = 8; int f = 0; int i = 0; void setup() { if (!display.begin(SSD1306_SWITCHCAPVCC, DISPLAY_I2C_ADDRESS)) { Serial.println("SSD1306 nicht gefunden"); for (;;); } /*if
in „DFPlayer Mini“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
20221014a-interrupt-Einspeise.ino
// Einspeisewechselrichter // https://www.etechnophiles.com/how-to-change-the-pwm-frequency-of-arduino-nano/ // TCCR2B = TCCR2B & B11111000 | B00000001; // for PWM frequency of 31372.55 Hz on D3 & D11 // https://www.arduino.cc/reference/de/language/functions/external-interrupts/attachinterrupt/ // https://www.mikrocontroller.net/topic/542674?page=3#7218665 int lpumppin = 11; int dcdcanpin = 7; int modulationspin = 3; // OVLO mit Auszeit int drainpin = 6; int dcdcauspin = 4; unsigned long drainist; unsigned long drainstart; unsigned long drainvz = 10000; bool drain; bool ovlodrain; bool dcdcaus; //
-
Datei
20221015b-interrupt-Einspeise.ino
// Einspeisewechselrichter // https://www.etechnophiles.com/how-to-change-the-pwm-frequency-of-arduino-nano/ // TCCR2B = TCCR2B & B11111000 | B00000001; // for PWM frequency of 31372.55 Hz on D3 & D11 // https://www.arduino.cc/reference/de/language/functions/external-interrupts/attachinterrupt/ // https://www.mikrocontroller.net/topic/542674?page=3#7218665 int lpumppin = 11; int dcdcanpin = 7; // OVLO mit Auszeit int drainpin = 6; int dcdcauspin = 4; unsigned long drainist; unsigned long drainstart; unsigned long drainvz = 10000; bool drain; bool ovlodrain; bool dcdcaus; // UVLO Batterie mit Hysterese
-
Datei
20221021b-interrupt-Einspeise.ino
// Einspeisewechselrichter // https://www.etechnophiles.com/how-to-change-the-pwm-frequency-of-arduino-nano/ // TCCR2B = TCCR2B & B11111000 | B00000001; // for PWM frequency of 31372.55 Hz on D3 & D11 // https://www.arduino.cc/reference/de/language/functions/external-interrupts/attachinterrupt/ // https://www.mikrocontroller.net/topic/542674?page=3#7218665 // OVLO mit Auszeit int drainpin = 6; unsigned long drainist; unsigned long drainstart; unsigned long drainvz = 10000; bool drain; bool ovlodrain; // UVLO Batterie mit Hysterese int elkoladepin = 5; int battpin = A0; unsigned long battist; unsigned
-
Datei
sketch_oct27a.ino
#include <Wire.h> #include "ledkey.h" constexpr byte addr = 0x40; LEDKey led {addr}; void setup() { Serial.begin(9600); led.begin(); led.pinOn(0); led.pinOn(1); led.pinOn(2); led.pinOff(3); } void loop(){}
in „mal wieder: Arduino Klasse in Klasse - bitte Hilfe!“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
sketch_nov21a.ino
#include <Wire.h> #include "RTClib.h" RTC_DS1307 rtc; #include <SD.h> #include <SPI.h> File myFile; int pinCS = 10; // Pin 10 auf Arduino Uno int temperatur = 20; int i = 0; void setup() { Serial.begin(9600); while (!Serial); if (! rtc.begin()) { Serial.println("Couldn't find RTC"); while (1); } rtc.adjust(DateTime(F(__DATE__), F(__TIME__))); Serial.println("RTC adjusted!"); DateTime now = rtc.now(); String zeit = ((String) (now.year()) + (now.month()) + (now.day()) + (now.hour())); String wetterdaten= (String) temperatur + "|Temperatur"; pinMode(pinCS, OUTPUT); if (SD.begin()) { Serial.println("SD card
in „SD-KArte jede stunde einen Wert speichern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
sketch_nov21a.ino
#include <Wire.h> #include "RTClib.h" #include <SD.h> #include <SPI.h> #define pinCS 10 // Pin 10 auf Arduino Uno RTC_DS1307 rtc; File myFile; int temperatur = 20; DateTime now, last; TimeSpan ts; void setup() { // init UART Serial.begin(9600); while (!Serial); // init RTC if (!rtc.begin()) { Serial.println("Couldn't find RTC!"); while (1); } rtc.adjust(DateTime(F(__DATE__), F(__TIME__))); Serial.println("RTC adjusted."); last = rtc.now(); // init SD card pinMode(pinCS, OUTPUT); if (SD.begin()) { Serial.println("SD card is ready to use."); } else { Serial.println("SD card initialization failed!"); while
in „SD-KArte jede stunde einen Wert speichern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
WebLogMinExmpl.ino
// benoetigte Lib: // * "AsyncTCP" by dvarell // * "ESPAsyncWebServer" by lacamera #include <Arduino.h> //Server #include <WiFi.h> #include <WiFiClient.h> #include <AsyncTCP.h> #include <ESPAsyncWebServer.h> #include "index.h" //Web page header file // SD #include "FS.h" #include "SD.h" #include "SPI.h" #define PIN_CS 5 const int baudrate = 115200; const char* ssid = "ESPServ"; const char* password = "ESPtest"; AsyncWebServer server(80); IPAddress local_ip(192, 168, 1, 1); IPAddress gateway(192, 168, 1, 1); IPAddress subnet(255, 255, 255, 0); void SD_Init(void) { if(!SD.begin(PIN_CS)){ Serial.println
in „ESP32 Webserver Download Logfile von SD-Karte, Arduino“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Bosch_Athlet_DIY_240416.ino
/* this code is an aternative software for Bosch vaccuumcleaner, tested and working on the BCH6L2560 & BBH7360K model. Other Bosch models may work, but YOU must chek first if your hardware is supported ! We take no responsability at all for this code, use it on your own risk. Here you find basic schematics (uncomplete) and fotos…. https://www.mikrocontroller.net/topic/513088 Many thaks to Daniel F.(per48or) for programming with me Lena S.(lena_s) this piece of code to awaken this vaccuumclears again. */ // SET your Board to MiniCore ATmega328PB @ 8Mhz Internal, BOD=2.7V, no Bootloader // https://github.com
in „Bosch Athlet 25,2 V Akku 7 Stück Tauschen“ · Analoge Elektronik und Schaltungstechnik ·
-
Datei
Bosch_Athlet_DIY_240619.ino
/* this code is an aternative software for Bosch vaccuumcleaner, tested and working on the BCH6L2560 & BBH7360K model. Other Bosch models may work, but YOU must chek first if your hardware is supported ! We take no responsability at all for this code, use it on your own risk. Here you find basic schematics (uncomplete) and fotos…. https://www.mikrocontroller.net/topic/513088 Many thaks to Daniel F.(per48or) for programming with me Lena S.(lena_s) this piece of code to awaken this vaccuumclears again. */ // SET your Board to MiniCore ATmega328PB @ 8Mhz Internal, BOD=2.7V, no Bootloader // https://github.com
in „Bosch Athlet 25,2 V Akku 7 Stück Tauschen“ · Analoge Elektronik und Schaltungstechnik ·
-
Datei
BastelMotorSerialMess.ino
/* One Pole Motor - Field Coil - Rotor Coil - AS5600 hall encoder - current sensors ACS712x05B - L298 dual motor bridge - PiPico MCU 2024-07-09 ch */ // L298 pins #define EnA 16 #define EnB 17 #define In1 21 #define In2 20 #define In3 19 #define In4 18 // current sensors #define PIN_ROTORCURRENT A1 #define PIN_FIELDCURRENT A0 #define PIN_AS5600ANALOG A2 #define MySerial Serial // Serial1 is output for pipico debug probe float VALUE_field = 0; float VALUE_rotor = 0; float VALUE_angle = 0; void setFieldCoil(int16_t value) { if (value > 0) { digitalWrite(In1, LOW); digitalWrite(In2, HIGH); } else
-
Datei
sketch_feb26a.ino
#include <Wire.h> #include <SoftwareSerial.h> #include <LiquidCrystal_I2C.h> #define DEBUG true #define STARTUP true #define RX 10 //pin layout #define TX 11 // #define measureO A0// #define measureU A1// #define relay 8 // #define button 4 // #define dimmer 9 // SoftwareSerial Esp8266(RX, TX); String ssid = "FRITZ!Box 6591 Cable VW"; String pwd = "15974136204554170633"; int connectionId; bool skipWifiSetup = false; bool on = true;//is pump regulation turned on LiquidCrystal_I2C lcd(0x27, 16, 2); int displayPage; int disTimeout = 10000; //display timeout time in milliseconds unsigned long disTimer
in „HTML code not working on Ipad“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
sketch_feb26a.ino
#include <Wire.h> #include <SoftwareSerial.h> #include <LiquidCrystal_I2C.h> #define DEBUG true #define STARTUP true #define RX 10 //pin layout #define TX 11 // #define measureO A0// #define measureU A1// #define relay 8 // #define button 4 // #define dimmer 9 // SoftwareSerial Esp8266(RX, TX); String ssid = "FRITZ!Box 6591 Cable VW"; String pwd = "15974136204554170633"; int connectionId; bool skipWifiSetup = false; bool on = true;//is pump regulation turned on LiquidCrystal_I2C lcd(0x27, 16, 2); int displayPage; int disTimeout = 10000; //display timeout time in milliseconds unsigned long disTimer
in „HTML code not working on Ipad“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Lauflicht_Schweif_Begegungsmelder_Zeit.ino
#include <Adafruit_NeoPixel.h> #define PIN 6 //LED-Stripe #define NUMPIXELS 66 #define SENSORPIN1 A3 //Schalter hell #define SENSORPIN2 A5 //Schalter dunkel Adafruit_NeoPixel pixels(NUMPIXELS, PIN, NEO_GRBW + NEO_KHZ800); int Sensorstatus1 = 0; int Sensorstatus2 = 0; int a=0; int b=0; void setup() { pinMode(SENSORPIN1, INPUT); pinMode(SENSORPIN2, INPUT); digitalWrite(SENSORPIN1, LOW); //10KOhm-R digitalWrite(SENSORPIN2, LOW); //10KOhm-R pixels.begin(); } void EinschaltsequenzTag() { for(int i=-7; i<66; i++) { pixels.setPixelColor(i, pixels.Color(100,100,200,250)); // weiß wird hell dargestellt
in „Probleme mit High- und Low-Eingängen Arduino Nano“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
sketch_sep10a.ino
#include <SD.h> #include <Wire.h> #include <Adafruit_Sensor.h> #include <Adafruit_BME280.h> #include <TinyGPS++.h> // Pins definieren const int GPS_PPS_PIN = 2; // PPS-Signal vom GPS für Sekundentakt const int LICHTSCHRANKE_PIN = 3; // Signal von der Lichtschranke const int SD_CS_PIN = 10; // Chip Select für SD-Kartenleser // Speicher-Intervall für die Lichtschranke (jeder 1800. Impuls) const unsigned long SPEICHER_INTERVALL_IMPULSE = 1800; // Instanzen TinyGPSPlus gps; Adafruit_BME280 bme; // Volatile Variablen für die Interrupts volatile unsigned long ppsMicrosRef = 0; // Systemzeit der letzten GPS-Sekunde
in „Datenlogger Pendeluhr“ · Mikrocontroller und Digitale Elektronik ·
-
PDF
AP3019A-318144-1.pdf
oEDs, 188 200 212 mV FB TA=-40 C to 85 C FB Pin Bias Current IFB 35 100 nA Quiescent Current Q VFBV ,INo switching 1.5 2.5 3.2 mA Shutdown Quiescent Current ISHDN VCTRL=0V 2.0 4.0 6.0 µA Switching Frequency f 0.9 1.2 1.5 MHz Maximum Duty Cycle D 90 93 % MAX D=40% 550 Switch Current Limit (Note 3) ILIMIT
in „StepUp Regler mit wenig Aussenbeschaltung“ · Analoge Elektronik und Schaltungstechnik ·
-
PDF
UNI-T_210E_Modding_Part2.pdf
flash. Switch UT210E to ~V mode then plug in Arduino into the USB. Open the attached i2cArduino210E.ino sketch in Arduino IDE. Open Serial Monitor window (CTRL+SHIFT+M). Now upload the sketch. You should see your eeprom dump in Serial Monitor window. You better Copy/Paste it for backup. Now you must edit
in „UT210E Zangenmultimeter hacken“ · Analoge Elektronik und Schaltungstechnik ·
-
PDF
tsop752w.pdf
PRODUCT LABEL (finished goods) PLAIN WRITING ABBREVIATION LENGTH Item-description - 18 Item-number INO 8 Selection-code SEL 3 LOT-/serial-number BATCH 10 Data-code COD 3 (YWW) Plant-code PTC 2 Quantity QTY 8 Accepted by ACC - Packed by PCK - Mixed code indicator MIXED CODE - Origin xxxxxxx+ Company logo
in „Startzeit IR Empfänger“ · Mikrocontroller und Digitale Elektronik ·
-
PDF
photodiode_frontends.pdf
5 (let’s just ignore REfor contribution from Q , wh1ch rises with ing C f0.5 pF overcomes C , and ino- now).TransistorQ faithfullytransmitsits frequency; it is much more benign than duces a 1.1 MHz 3 dB bandwidth overall. 1 emittercurrenttoitscollector,whilekeep- the e Namp problem with transimpedance
in „Photodioden-Frontend hohe Empfindlichkeit, mittlere Bandbreite?“ · Analoge Elektronik und Schaltungstechnik ·
-
PDF
tssp960.pdf
PRODUCT LABEL (finished goods) PLAIN WRITING ABBREVIATION LENGTH Item-description - 18 Item-number INO 8 Selection-code SEL 3 LOT-/serial-number BATCH 10 Data-code COD 3 (YWW) Plant-code PTC 2 Quantity QTY 8 Accepted by ACC - Packed by PCK - Mixed code indicator MIXED CODE - Origin xxxxxxx+ Company logo
in „was ist das für ein Bauteil??“ · Analoge Elektronik und Schaltungstechnik ·
-
Datei
sloeber.txt
project testESP **** "C:\\sloeber\\arduinoPlugin\\tools\\make\\make" all 'Building file: ..\sloeber.ino.cpp' 'Starting C++ compile' "C:\sloeber\/arduinoPlugin/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IC:\sloeber
in „Arduino Sloeber - C Code einbinden“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
GB_Geschenk_Abgespeckt_2sensoren.ino
/********************************************************************************** * Allgemeine Deklaration **********************************************************************************/ // Lautsprecherausgang const byte Ton = 0; // Analog-Pins 0, 1, 2, 3, 4, 5 const int TP1A = A0; const int TP1B = A1; const int TP2A = A2; const int TP2B = A3; const int TP3A = A4; const int TP3B = A5; int sensorValue1 = 0; int sensorValue2 = 0; int sensorValue3 = 0; int Kalibration1 = 0; int Kalibration2 = 0; int Kalibration3 = 0; /****************************************************************************
in „ADC mit ATmega8A“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
sketch_jan26e_minimal.ino
#include <avr/sleep.h> #include <avr/wdt.h> #include <util/atomic.h> #include <Streaming.h> // die Lib findest du selber ;-) Print &cout = Serial; // cout Emulation für "Arme" constexpr uint8_t LED_PIN = PB5; uint32_t wdt_ticks; int bufferSize; void setup() { Serial.begin(9600); bufferSize = Serial.availableForWrite(); cout << F("Start: ") << F(__FILE__) << endl; cout << F("bufferSize: ") << bufferSize << endl; DDRB = (1 << LED_PIN); //LED_PIN als Ausgang ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { wdt_reset(); WDTCSR |= (1 << WDCE) | (1 << WDE); WDTCSR = (1 << WDIE) | (1 << WDP2) | (1 << WDP1); // 1s } } void loop()
in „AVR: Watchdog löst keinen Interrupt aus“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Doorbell_attiny85-5v.ino
/*********************************************************** * _____ +-----\/-----+ * * RESET PB5 1 --|o |-- 8 Vcc * * | | * * XALT1 PB3 2 --| |-- 7 PB2 SCK SCL * * | ATTINY85 | * * XALT2 PB4 3 --| |-- 6 PB1 MISO DO * * | | * * GND 4 --| |-- 5 PB0 MOSI DI SDA * * +------------+ * * * * compiled with ATtiny Microcontrollers from * * David A. Mellis https://github.com/damellis/attiny * * * ***********************************************************/ #include <avr/sleep.h> #include <avr/power.h> #define PIN_LED PCINT0 // PIN 5 PB0 for debugging, remove later #define PIN_DOORBELL PCINT1 // PIN 6 PB1
in „Türklinger verstärken ohne elektrischen Eingriff in Hausanlage“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
_LiquidCrystal_PCF8574_Test.ino
// This example shows various featues of the library for LCD with 16 chars and 2 lines. #include <Arduino.h> #include <Wire1.h> #include <LiquidCrystal_PCF8574.h> LiquidCrystal_PCF8574 lcd(0x27); // set the LCD address to 0x27 for a 16 chars and 2 line display int show = -1; // 2 custom characters byte dotOff[] = { 0b00000, 0b01110, 0b10001, 0b10001, 0b10001, 0b01110, 0b00000, 0b00000 }; byte dotOn[] = { 0b00000, 0b01110, 0b11111, 0b11111, 0b11111, 0b01110, 0b00000, 0b00000 }; void showStatus(uint8_t data_){ Serial.print(" status==");Serial.print(data_);Serial.println(""); } void setup() { int error
in „TWI1 auf Atmega328PB schlägt fehl“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
WIFI-Kit-8-DateTime.ino
#include <ESP8266WiFi.h> #include "oled.h" #define SSID "Muschikatze" #define PASSWORD "Geheim" #define SERVER "ptb.de" // There are 2 different versions of the board // static OLED display=OLED(2,14,4); static OLED display=OLED(4,5,16); static WiFiClient client; static char buffer[200]; /** * Sammle eine Zeile Text ein. * Rufe diese Funktion wiederholt auf, bis sie true zurück gibt. Dann hast * du eine Zeile im Puffer. Wenn die Zeile nicht in den Puffer passt, wird * sie abgeschnitten. * * @param source Der Quell-Stream. * @param buffer Der Ziel-Puffer, muss bereits mit '\0' terminiert sein. *
in „Zeitschaltuhr + PWM“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Mini-Cam-FTP-Timer-web.ino
#include <WiFi.h> #include <WiFiclient.h> #include "esp_camera.h" #define DEBUG #define DEBUG_FTP false // true #define DEBUG_CAM false // FTP-Userdaten direkt in Zeile 41 eintragen, also xxxx und yyyy anpassen // da wohl verschiedene Kameramodule im Umlauf sind ab Zeile 180 hmirror und vflip anpassen wenn das Bild falsch rum ist. // PIR-Cam ist das Modul mit PIR und OLED, M5Cam ist die kleine M5Stack-Cam, diese mit ESP32 Devkit ohne PSRAM compilieren. #define PIR_CAM // für M5Cam auskommentieren const char* ssid = "xxxxxxx"; const char* password = "yyyyyyyyy"; // DeepSleep Timer #define uS_TO_S_FACTOR
in „ov2640 Bild schießen und speichern“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ESP8266_Robi_v2.ino
//*********************************************************************** //*** Programm-Version ************************************************ //*********************************************************************** #define PrgVer 1.00 // Datum: 2016-05-26 #define PrgVer 1.01 // Datum: 2016-05-27 // Debug-Meldungen abschaltbar #define PrgVer 1.02 // Datum: 2016-05-27 // Komplettüberarbeitung #define PrgVer 1.03 // Datum: 2016-06-03 // RSSI #define PrgVer 1.03 // Datum: 2016-06-03 // int statt char lesen // < 255 durch <= 255 ersetzt #define PrgVer 1.04 // Datum: 2016-06-17 // Anzeige Programm-Version
in „Automower G3 mit USB Diagnoseport fernsteuern?“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
OLED_i2C_Test.ino
/* http://blog.simtronyx.de/ein-096-zoll-oled-display-i%C2%B2c-mit-128x64-pixel-und-ein-arduino/ geladen 06.05.2019 A4 (SDA) SDA A5 (SCL) SCL 5V VCC GND GND */ #include <SPI.h> #include <Wire.h> #include <Adafruit_GFX.h> #include <Adafruit_SSD1306.h> #define OLED_RESET 4 // not used / nicht genutzt bei diesem Display Adafruit_SSD1306 display(OLED_RESET); void setup() { // initialize with the I2C addr 0x3C / mit I2C-Adresse 0x3c initialisieren display.begin(SSD1306_SWITCHCAPVCC, 0x3C); // random start seed / zufälligen Startwert für Random-Funtionen initialisieren randomSeed(analogRead(0)); } /
in „OLed Farbdisplay 128x64 mit 6 Pins“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Zx81_Debugger_debugger3.ino
// 2020 September, programmed by chris_ // // mcurses library for Arduino needed ( github ) // // you need a VT100 compatible terminal like minicom // // minicom -c on -b 115200 -D /dev/ttyACM0 #include "ZX81_debug_drv.h" // mcurses VT100 editor #include "hexedit.h" void Arduino_putchar(uint8_t c) { Serial.write(c); } char Arduino_getchar() { while (!Serial.available()); return Serial.read(); } /* The ZX81 saves data to tape by sending bursts of pulses, four pulses for a zero, and nine pulses for a one, each pulse being 150µS high and 150µS low, with a 1300µs low space between "bursts". So the
-
Datei
TCB_32Bit_Counter_Pulsweite.ino
/* Arduino IDE 1.8.13 AVR128DB48 Curiosity Nano Board https://github.com/SpenceKonde/DxCore 32Bit Counter Takteingang Pin PA4 Interruptmesspin für Oszi PB3 und PC3 */ #include <avr/io.h> #include <avr/interrupt.h> #include <util/atomic.h> volatile unsigned long countTimerTCB0; volatile unsigned long countTimerTCB1; volatile unsigned long countTimerCCMP_LSB; volatile unsigned long countTimerCCMP_MSB; volatile unsigned long countTimerTotal; volatile bool finishTCB0 = false; volatile bool finishTCB1 = false; void setup (void) { Serial1.begin(115200); // Package Pin 10/11 bzw. PC0/PC1, Tx/Rx Serial1
in „AVR128DB48 - TCB 32Bit Counter“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
OLED_LCD_Testcode_mit_Interrupt_Drehgeber.ino
/* This is an example of how to use the OLED 128x64 I2C with SSD1306 driver using the Adafruit library. It also applies to the 128x32 version, but not all components would fit the smaller screen. Pins: * GND = GND * VCC = 5V * SCL = A5 * SDA = A4 You can connect VCC to 3.3V to reduce the amount of high pitched noise that the display produces. It's a good idea to put a resistor between A4-5V and A5-5V to help stabilize the connection. What that does is pull-up the I2C pins to make it more reliable and prevents lock-ups. Libraries needed: https://github.com/adafruit/Adafruit_SSD1306 https://github.com
in „Arduino OLED Display hakt bei zu schneller Werteingabe“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
OLED_LCD_Testcode_mit_Interrupt_Drehgeber.ino
/* This is an example of how to use the OLED 128x64 I2C with SSD1306 driver using the Adafruit library. It also applies to the 128x32 version, but not all components would fit the smaller screen. Pins: * GND = GND * VCC = 5V * SCL = A5 * SDA = A4 You can connect VCC to 3.3V to reduce the amount of high pitched noise that the display produces. It's a good idea to put a resistor between A4-5V and A5-5V to help stabilize the connection. What that does is pull-up the I2C pins to make it more reliable and prevents lock-ups. Libraries needed: https://github.com/adafruit/Adafruit_SSD1306 https://github.com
in „Arduino OLED Display hakt bei zu schneller Werteingabe“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
MCnetCANBUS_reader_A4.ino
#include <stdint.h> #include "TouchScreen.h" #include <SPI.h> #include <Adafruit_GFX.h> #include "Adafruit_HX8357.h" #include <MCUFRIEND_kbv.h> #define TFT_RST 8 #define TFT_DC 9 #define TFT_CS 10 #define YP A1 #define XM A0 #define YM 28 #define XP 29 TouchScreen ts = TouchScreen(XP, YP, XM, YM, 300); Adafruit_HX8357 tft = Adafruit_HX8357(TFT_CS, TFT_DC, TFT_RST); #include <Fonts/FreeSans9pt7b.h> #include <Fonts/FreeSans12pt7b.h> #include <Fonts/FreeSerif12pt7b.h> #include <FreeDefaultFonts.h> #include <Fonts/FreeSansBold18pt7b.h> #include <Fonts/FreeSansBold24pt7b.h> #define width 320 #define
in „CAN-Bus mit Arduino auswerten“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ESP8266_Robi_v2.ino
//*********************************************************************** //*** Programm-Version ************************************************ //*********************************************************************** #define PrgVer 1.00 // Datum: 2016-05-26 #define PrgVer 1.01 // Datum: 2016-05-27 // Debug-Meldungen abschaltbar #define PrgVer 1.02 // Datum: 2016-05-27 // Komplettüberarbeitung #define PrgVer 1.03 // Datum: 2016-06-03 // RSSI #define PrgVer 1.03 // Datum: 2016-06-03 // int statt char lesen // < 255 durch <= 255 ersetzt #define PrgVer 1.04 // Datum: 2016-06-17 // Anzeige Programm-Version
in „Automower G3 mit USB Diagnoseport fernsteuern?“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
ER-OLEDM015-1C.ino
/*************************************************** //Web: http://www.buydisplay.com EastRising Technology Co.,LTD Examples for ER-OLEDM015-1C Display is Hardward SPI 4-Wire SPI Interface Tested and worked with: Works with Arduino 1.6.0 IDE Test OK : Arduino DUE,Arduino mega2560,Arduino UNO Board ****************************************************/ /* == Hardware connection == OLED => Arduino *1. GND -> GND *2. VCC -> 3.3 *3. SCL -> SCK *4. SDA -> MOSI *5. RES -> 8 *6. DC -> 9 *7. CS -> 10 */ #include "OLED_Driver.h" #include "OLED_GFX.h" #include <SPI.h> #include <Wire.h> OLED_GFX oled = OLED_GFX
in „OLED ER-OLEDM015-1c“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
NRF24l01-Sender.ino
#include <Arduino.h> #include <SPI.h> #include <RH_NRF24.h> #include "LowPower.h" // Singleton instance of the radio driver RH_NRF24 nrf24; uint8_t pos = 4; uint8_t counter = 0; uint8_t chk = 0; void setup() { Serial.begin(9600); while (!Serial) ; // wait for serial port to connect. Needed for Leonardo only if (!nrf24.init()) { Serial.println("init failed"); } // Defaults after init are 2.402 GHz (channel 2), 2Mbps, 0dBm if (!nrf24.setChannel(3)) { Serial.println("setChannel failed"); } if (!nrf24.setRF(RH_NRF24::DataRate2Mbps, RH_NRF24::TransmitPower0dBm)) { Serial.println("setRF failed"); } Serial.println
in „Arduino mit NRF04l01 - Problem im PowerDown“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
AbsauganlageV2.11Nano.ino
// -- -- Abschaltautomatik -- -- // Anselm Hintermann // November 2020 // Version 2.1 // Arduino Nano // -- Einstellungen -- //Nachlaufzeiten in Millisekunden unsigned long NachlaufSaugerMaschine1 = 3000; unsigned long NachlaufSaugerMaschine2 = 3000; unsigned long NachlaufSaugerMaschine3 = 3000; unsigned long NachlaufSaugerMaschine4 = 3000; unsigned long NachlaufSaugerMaschine5 = 3000; unsigned long NachlaufVKlappeMaschine1 = 3000; unsigned long NachlaufVKlappeMaschine2 = 3000; unsigned long NachlaufVKlappeMaschine3 = 3000; unsigned long NachlaufVKlappeMaschine4 = 3000; unsigned long NachlaufVKlappeMaschine5
in „Absauganlage, Fehlersuche, Hallo“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Multi_DS18x20.ino
/* */ #include <OneWire.h> #include <DallasTemperature.h> // Taster der die Initialisierung auslöst ist an Pin 7 angeschlossen #define INIT_TAST 7 // Die Sensoren sind an Pin 4 angeschlossen #define ONE_WIRE_BUS 4 // Genauigkeit 11 Bit #define TEMPERATURE_PRECISION 11 // Maximale Anzahl Messtellen #define TEMPERATURE_ARR_SIZE 5 OneWire oneWire(ONE_WIRE_BUS); DallasTemperature sensors(&oneWire); DeviceAddress DS1820Address; // Speicher für die Messwerte float TemperatureArr[TEMPERATURE_ARR_SIZE]; // Speichert bei gültigem Index den Messwert ab void SetTemperature(uint8_t pos, float Temperature)
-
Datei
Multi_DS18x20.ino
/* Identifikation und Verwaltung von DS18x20 Temperatursensoren Identifikation über Abkühlung/Erwärmung einzelner Sensoren Speicherung der ID im EEPROM der Sensoren */ #include <OneWire.h> #include <DallasTemperature.h> #define ONE_WIRE_BUS 22 // IO-Pin für One Wire Bus #define TASTER 24 // IO-Pin für Taster zum Start der Identifikation, Taster schaltet gegen GND #define TEMPERATURE_PRECISION 11 // Auflösung der Sensoren /Bit #define SENSOR_CNT 5 // Maximale Anzahl Messtellen #define DELTA_T 5 // minimale Temperaturdifferenz für Erkennung /K OneWire oneWire(ONE_WIRE_BUS); DallasTemperature sensors
-
Datei
Death_Bell_TLV493D.ino
// *********************************** // * >>> Dead Bell <<< * // * * // * - Tim Timsen * // * - 03.12.2024 * // * - V. 0.97 * // * - Arduino Nano V3 * // * - TLV493D Modul * // * - Tischglocke * // * - Push-Pull DC Hubmagnet, 9 V * // * - Poti mit Schaltkontakt * // * - 2N 2222 NPN Transistor * // *********************************** #include <Wire.h> #include <TLx493D_inc.hpp> // Initialisiere den TLx493D-Sensor using namespace ifx::tlx493d; TLx493D_A1B6 sensor(Wire, TLx493D_IIC_ADDR_A0_e); // Hardware-Pins const int transistorPin = 9; // Pin, Transistor für Hubmagnet const int potPin = A0;
in „Dead Bell Schaltplan und Arduiono Code“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Kai_EEprom_Page_Write_02.ino
// https://www.mikrocontroller.net/topic/578561?reply_to=7895508#7895423 #define EXT_EE_ADDR 0x50 // I2C address of 1. external eeprom new 15.05.2025 #define EXT_EE_SIZE 32768 // Max address for 32k-eeprom 22.05.2025 #define EXT_EE_LIMIT 30 // Write buffer limit #define EXT_EE_PAGE 64 // Page size #define EXT_EE_MELODY 0 // Melody data start address in external eeprom #define EXT_EE_CALENDAR 5000 // Calendar data start address in external eeprom 02.06.2025 #define EXT_EE_TEST1 12000 // Test-data 1 start address in external eeprom ++++ 18.06.2025 10000 -> 12000 #define EXT_EE_TEST2 17000 // Test-data
in „Arduino: page-write in I2C eeprom verliert sporadisch ein Byte“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
kc85keyboard_V0.ino
/* KC85 Keyboard changes to make consistent output - "A" is now 0x03 like in my chart - debounce - happiness version 26.07.2025 V0: USB-keyboard function: ********************************************* FOR EASIER FLASHING: pin 9 is inputpullup: wen tied to ground the pro micro does not act like a keyboard ********************************************* * * */ /* * scannumber * * * * */ #include <Keyboard.h> #define Serialbaudrate 115200 #define jumperin 9 // Times, wir bleiben daruntger, weil wir nachher der größe nach abfragen, ob größer als #define TIME_MINIMUM 1000 #define TIME_ZERO 4800//unter 5000
in „Tastatur KC85 mit USB-Anschluss ausrüsten“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Arrduino_R4_Melodien_aus_EEPROM.ino
void melodie(){ // Play melody 1- number mel from external eeprom - new if (snd > 0){ // Melody not stopped ofset = (snd-1) * ((length*4) +15); // Offset = 0*50*2= 0, 1*50*2 = 100 integers! *2 -> *4 int ext_ee_adr = EXT_EE_MELODY_R+1 + ofset; // Address base + offset - ignore first byte which is the data-type - moved to here 26-09-2025 tempo=read_ext_eeprom(ext_ee_adr + 14); // Melody tempo starts at address +14 int wholenote = (60000 * 4) / tempo; // Calculate note (tempo is integer) int divider = 0, noteDuration = 0; // Clear divider and note duration divider=read_integer(ext_ee_adr+15+thisNote
in „Arduino Uno R4: Besonderheiten und Abhilfen“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Kurz_und_knapp_copy_20251111A.ino
// Dateiname: Kurz_und_knapp_Jahr_Monat_Tag_lfd Buchstabe // // Arduino UNO SMD R3 und QHV5160 Version 1.0 E (TMC5160) über Spi-Schnittstelle // Letzte Änderung: 11.11.25 22:25 Uhr // Strom fliesst; keine Drehzahl //#include <arduino.h> #include <SPI.h> // Konstanten definieren // SPI Pins #define sck 13 //SPI clock #define mosi 11 //master transmit out slave receive input #define miso 12 //master receive input slave transmit out const int PIN_CS = 10; // Chip Select const int PIN_EN = 9; // Drive-Enable Lowaktiv // Variablen definieren uint32_t result; // Funktion: 32-Bit Register schreiben void
in „Arduino Uno mit QHV5160 über SPI keine Drehzahl“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
LED_2_Schalter_hell_dunkel.ino
#include <Adafruit_NeoPixel.h> #define NEOPIXEL_PIN 6 // Datenausgang für LEDs #define NUMPIXELS 66 // Anzahl der LEDs #define SENSORPIN1 A3 // Schalter hell #define SENSORPIN2 A5 // Schalter dunkel #define INPUT1 (1<<0) // Bitmuster für Codeauswertung #define INPUT2 (1<<1) // Bitmuster für Codeauswertung #define INPUT12 (INPUT1 | INPUT2) // Bitmuster für Codeauswertung, beide Eingänge Adafruit_NeoPixel pixels(NUMPIXELS, NEOPIXEL_PIN, NEO_GRBW + NEO_KHZ800); int code, flanke; int code_old; bool led_active = false; void setup() { pinMode(SENSORPIN1, INPUT); pinMode(SENSORPIN2, INPUT); pixels.begin();
in „Probleme mit High- und Low-Eingängen Arduino Nano“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
LED_2_Schalter_hell_dunkel.ino
#include <Adafruit_NeoPixel.h> #define NEOPIXEL_PIN 6 // Datenausgang für LEDs #define NUMPIXELS 66 // Anzahl der LEDs #define SENSORPIN1 A3 // Schalter hell #define SENSORPIN2 A5 // Schalter dunkel #define INPUT1 (1<<0) // Bitmuster für Codeauswertung #define INPUT2 (1<<1) // Bitmuster für Codeauswertung #define INPUT12 (INPUT1 | INPUT2) // Bitmuster für Codeauswertung, beide Eingänge Adafruit_NeoPixel pixels(NUMPIXELS, NEOPIXEL_PIN, NEO_GRBW + NEO_KHZ800); int code, flanke; int code_old; bool led_active = false; void setup() { pinMode(SENSORPIN1, INPUT_PULLUP); pinMode(SENSORPIN2, INPUT_PULLUP); pixels.begin
in „Probleme mit High- und Low-Eingängen Arduino Nano“ · Mikrocontroller und Digitale Elektronik ·
-
Datei
Timer1_non_volatile_provozieren.ino
// Devil-Elec // https://www.mikrocontroller.net/topic/570524?goto=7735213 #include <util/atomic.h> #include <Streaming.h> // https://github.com/janelia-arduino/Streaming Stream &out {Serial}; volatile unsigned long countVolatile; unsigned long countNonVolatile; class SimpleTimer { private: unsigned long lastMillis; const unsigned long intervall; public: SimpleTimer (unsigned long i) : lastMillis {0}, intervall {i} {} bool expired (void) { bool state {false}; const unsigned long ms {millis()}; if (ms - lastMillis >= intervall) { lastMillis = ms; state = true; } return state; } void reset (void
in „volatile und Arduino“ · Mikrocontroller und Digitale Elektronik ·