Skip to content

Instantly share code, notes, and snippets.

View cmoz's full-sized avatar

Christine Farion cmoz

View GitHub Profile
#include <Arduino.h>
/// @file ColorPalette.ino
/// @brief Demonstrates how to use @ref ColorPalettes
/// @example ColorPalette.ino
/// Note this is not my file, but I am linking it here for if you need the code
/// from the youtube video: https://www.youtube.com/watch?v=Wf8HES75ies&ab_channel=CMoz
#include <FastLED.h>
#define LED_PIN 15 // <-- change this to match the pin you have chosen
// 4 oled keyboard current working code
#include <Arduino.h>
#include "T-Keyboard-S3-Pro_Drive.h"
#include "pin_config.h"
#include "Arduino_GFX_Library.h"
#include "USB.h"
#include "USBHIDKeyboard.h"
#include "USBHIDConsumerControl.h"
#include "Arduino_DriveBus_Library.h"
@cmoz
cmoz / testingScreen.ino
Created April 30, 2025 17:33
Checking feather board with screen OLED
#include <Wire.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SH110X.h>
// FeatherWing OLED default I2C address is 0x3C
Adafruit_SH1107 display(64, 128, &Wire);
void setup() {
Serial.begin(115200);
delay(1000);
@cmoz
cmoz / C3LEDs.cpp
Created April 28, 2025 17:28
TestingCode for C3 and WS2812b
#include <FastLED.h>
#define LED_PIN 3
#define NUM_LEDS 20
#define BRIGHTNESS 128 // Half of max (0-255)
#define LED_TYPE WS2812B
#define COLOR_ORDER GRB
CRGB leds[NUM_LEDS];
@cmoz
cmoz / testingC3.cpp
Created April 28, 2025 16:11
TestingCodeForNewC3Boards
/*
* This code is for controlling a strip of WS2812B LEDs using the FastLED library.
* It sets the first two LEDs to blue and turns off the rest.
* The brightness is set to half of the maximum value.
*/
#include <FastLED.h>
#define LED_PIN 3
@cmoz
cmoz / RFID_Code.cpp
Created March 21, 2025 16:50
Basic RFID + ESP32 webpage to save todos
// for platformio
#include <Arduino.h>
#include <SPI.h>
#include <MFRC522.h> // RFID LIBRARY
#include <WiFi.h>
#include <Preferences.h> // To save data in flash memory
// Tag UID: E3 5B 85 0D
// Define the pins used for the RC522 RFID module
@cmoz
cmoz / Main.java
Created February 22, 2024 21:52
First example with linkedList and a Product object
import java.util.LinkedList;
// our product class that we created to create a product
class Product {
private String name;
private double price;
private String description;
// Getters and setters for product properties
@cmoz
cmoz / Main2.java
Created February 22, 2024 21:50
LinkedList example and overriding the toString() method
import java.util.LinkedList;
class ProductItem {
private int productId;
private String productName;
public ProductItem(int productId, String productName) {
this.productId = productId;
this.productName = productName;
}
@cmoz
cmoz / BlinkESP32.ino
Created April 10, 2022 13:55
Blink with generic ESP32 board
const int ledPin = 2; // User LED is connected to Pin 2
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(ledPin, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
@cmoz
cmoz / C6_6.5TouchTogether
Created March 30, 2022 13:08
Touch together, a socially playable instrument
#include <Adafruit_CircuitPlayground.h>
uint8_t pixeln = 0;
int capsense[10];
void setup() {
CircuitPlayground.begin();
for(int i=0; i< CircuitPlayground.strip.numPixels(); i++) {
CircuitPlayground.setPixelColor(i, ( 0, 0, 255));
CircuitPlayground.strip.show();