Skip to content

Instantly share code, notes, and snippets.

#include <OneWire.h>
#include <DallasTemperature.h>
DeviceAddress DS18B20_Address;
OneWire oneWire(3); // digitaler Pin 3
DallasTemperature sensor(&oneWire);
void setup(void) {
Serial.begin(9600);
#include <Stepper.h>
#define STEPS 2038 // the number of steps in one revolution of your motor (28BYJ-48)
Stepper stepper(STEPS, 8, 9, 10, 11);
void setup() {
// nothing to do
}
void loop() {
#include "ssd1306.h"
void setup()
{
/* Select the font to use with menu and all font functions */
ssd1306_setFixedFont(ssd1306xled_font6x8);
ssd1306_128x64_i2c_init();
ssd1306_clearScreen();
}
// Include the correct display library
// For a connection via I2C using Wire include
#include <Wire.h> // Only needed for Arduino 1.6.5 and earlier
#include "SSD1306Wire.h" // legacy include: `#include "SSD1306.h"`
// Initialize the OLED display using Wire library
SSD1306Wire display(0x3c, D3, D5);
void setup() {
Serial.begin(115200);
int latchPin = 5; // RCLK (Register Clock / Latch) Pin des 74HC595 ist verbunden mit dem digitalen Pin 5
int clockPin = 6; // SRCLK (Shit Register Clock) Pin des 74HC595 ist verbunden mit dem digitalen Pin 6
int dataPin = 4; // SER (Serial input) Pin des 74HC595 ist verbunden mit dem digitalen Pin 4
byte leds = 0; // Hier speichern wir den Zustand der acht LEDs
void setup()
{
// Alle Pins für den 74HC595 des Arduino auf OUTPUT (=Ausgang) setzen
pinMode(latchPin, OUTPUT);
#include <Relay.h> // https://github.com/sekdiy/Relay
// create a Relay instance
Relay Lamp = Relay();
void setup() {
Lamp.on();
}
void loop() {
@MrCerealGuy
MrCerealGuy / mandelbrot.c
Created September 3, 2018 12:56 — forked from andrejbauer/mandelbrot.c
A simple program for computing the Mandelbrot set.
/*
This program is an adaptation of the Mandelbrot program
from the Programming Rosetta Stone, see
http://rosettacode.org/wiki/Mandelbrot_set
Compile the program with:
gcc -o mandelbrot -O4 mandelbrot.c
Usage: