Skip to content

Instantly share code, notes, and snippets.

View fbiego's full-sized avatar

Felix Biego fbiego

View GitHub Profile
// This requires LVGL 9.3+ (currently in dev)
void rounder_event_cb(lv_event_t *e)
{
lv_area_t *area = lv_event_get_invalidated_area(e);
uint16_t x1 = area->x1;
uint16_t x2 = area->x2;
uint16_t y1 = area->y1;
#include <Adafruit_GFX.h>
#include <Adafruit_ST7735.h>
#include <ChronosESP32.h>
// Button pins
#define BTN_UP 12
#define BTN_DOWN 13
@fbiego
fbiego / convert.py
Created December 2, 2024 07:58
Convert LVGL 8 c array to LVGL 9 c array
import re
import os
import glob
def read_c_array(input_file):
"""Reads the C array from the input file and extracts the hex data."""
with open(input_file, "r") as f:
content = f.read()
# Use a regex to find the array of hex values
@fbiego
fbiego / challenge.kt
Created July 16, 2023 11:16
Kotlin Challenge #11
import junit.framework.TestCase.assertEquals
import junit.framework.TestCase.assertTrue
fun main() {
val attendee = Attendee(sessions = listOf("Android","Kotlin"))
assertEquals(
true, // expected
attendee is Collection<String> // actual
)