Skip to content

Instantly share code, notes, and snippets.

View sammonius's full-sized avatar

Samuel Ammonius sammonius

View GitHub Profile
#ifndef DEBUG_H
#define DEBUG_H
#define PROG_NAME "my_app"
/* USAGE: puts(ERROR "Could not find wallet"); */
/* No licence cuz i don't care */
#define IHATETHECPREPROCESSORSOMUCHRIGHTNOW(X) #X
@llbit
llbit / water.c
Last active September 5, 2024 07:42
Raspberry Pi GPIO pins via C
// Compile with $ gcc water.c -o water
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
// Pin modes:
#define INPUT (0)
#define OUTPUT (1)
#define LOW (0)
#define HIGH (1)