Skip to content

Instantly share code, notes, and snippets.

View frankkienl's full-sized avatar
🤖
making Android apps

Frank Bouwens frankkienl

🤖
making Android apps
View GitHub Profile
@frankkienl
frankkienl / Main.kt
Last active September 4, 2022 18:18
Words that end with 'tal'
fun main(args: Array<String>) {
val regex = ".{1,}tal$"
val filename = "english-words.txt"
processFile(filename, regex)
}
fun processFile(filename: String, regexString: String) {
val inputStream = object {}.javaClass.getResourceAsStream(filename) ?: return
val lines = inputStream.bufferedReader().readLines()
val regex = Regex(regexString, RegexOption.IGNORE_CASE)
@frankkienl
frankkienl / fish-tank.md
Created August 10, 2022 08:42
Water flow in aquaponics system

Water flow in aquaponics project

stateDiagram-v2
    Filter1: Filter met stenen
    Filter2: Filter met actieve koolstof
    Filter3: Filter met UVC
    note right of Filter3
      UVC dood bacterieën, maar is gevaarlijk!
      Zorg dat het licht alleen op het water schijnt.
 end note
@frankkienl
frankkienl / conventions.md
Last active November 3, 2022 09:56
Conventions list

Convention Calendar

Date Name Location
21-22 mei EponaFest Milano, Italy
---------------- -------------------------------------- ---------------
4-5 Juni Dokomi Germany
10-12 juni Animecon broodjesfabriek
18-19 juni fabel and fantasy
@frankkienl
frankkienl / sketch_rgb_matrix_serial
Created February 4, 2022 14:33
Arduino rgb matrix via serial
// Base64 - Version: Latest
#include <Base64.h>
//#include <base64.hpp>
// FastLED - Version: Latest
#include <FastLED.h>
#define LED_PIN 2
#define MATRIX_WIDTH 8
#define MATRIX_HEIGHT 8
// #define NUM_LEDS 64
@frankkienl
frankkienl / arduino_led_matrix_8x8.ino
Created July 4, 2021 18:41
Arduino 8x8 led matrix
// Base64 - Version: Latest
#include <Base64.h>
//#include <base64.hpp>
// FastLED - Version: Latest
#include <FastLED.h>
#define LED_PIN 2
#define MATRIX_WIDTH 8
#define MATRIX_HEIGHT 8
#define NUM_LEDS 64
@frankkienl
frankkienl / MatrixToBase64.kt
Created July 4, 2021 18:33
Led Matrix 8x8 to Base64
import java.awt.Color
import java.io.File
import java.util.*
import javax.imageio.ImageIO
import kotlin.system.exitProcess
fun main(args: Array<String>) {
if (args.isEmpty()) {
printHelp()
exitProcess(0)
@frankkienl
frankkienl / CarNotifications.kt
Created November 26, 2020 09:37
CarExtender vs CarAppExtender
val ce = NotificationCompat.CarExtender()
ce.setColor() // <-- method exists
val cae = CarAppExtender.builder()
cae.setColor() // <-- method does **not** exist
import 'package:audioplayers/audio_cache.dart';
import 'package:audioplayers/audioplayers.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@frankkienl
frankkienl / androidauto.log
Created July 6, 2020 14:20
Crash in Android Auto
2020-07-06 16:19:16.323 3846-5645/? E/Parcel: Class not found when unmarshalling: com.google.android.gms.carsetup.BinderParcel
java.lang.ClassNotFoundException: com.google.android.gms.carsetup.BinderParcel
at java.lang.Class.classForName(Native Method)
at java.lang.Class.forName(Class.java:453)
at android.os.Parcel.readParcelableCreator(Parcel.java:2843)
at android.os.Parcel.readParcelable(Parcel.java:2797)
at android.os.Parcel.readValue(Parcel.java:2700)
at android.os.Parcel.readArrayMapInternal(Parcel.java:3067)
at android.os.BaseBundle.unparcel(BaseBundle.java:257)
at android.os.BaseBundle.getString(BaseBundle.java:1086)
@frankkienl
frankkienl / song.txt
Last active January 18, 2020 21:26
Heaven can't wait
#ENCODING:UTF8
#TITLE:Heaven can't wait
#ARTIST:Heaven can't wait
#LANGUAGE:English
#MP3:Heaven can't wait.mp3
#BPM:520
#GAP:0
: 16 16 19 Bro
: 32 32 21 thers,
: 76 20 19 sis