Skip to content

Instantly share code, notes, and snippets.

View KenN7's full-sized avatar
🍍
🦀 🐍

Ken KenN7

🍍
🦀 🐍
View GitHub Profile
@vsigler
vsigler / _readme.md
Last active May 13, 2024 11:24 — forked from stecman/_readme.md
Brother P-Touch PT-P300BT bluetooth driver python

Controlling the Brother P-Touch Cube label maker from a computer

The Brother PTP300BT label maker is intended to be controlled using the official Brother P-Touch Design & Print iOS/Android app. The app has arbitrary limits on what you can print (1 text object and up to 3 preset icons), so I thought it would be a fun challenge to reverse engineer the protocol to print whatever I wanted.

Python code at the bottom if you want to skip the fine details.

Process

Intitially I had a quick peek at the Android APK to see if there was any useful information inside. The code that handles the communication with the printer in Print&Design turned out to be a native library, but the app clearly prepares a bitmap image and passes it to this native library for printing. Bitmaps are definitely something we can work with.

@parastuffs
parastuffs / ULB Exchange on Thunderbird.md
Last active November 28, 2023 10:37
ULB Exchange on Thunderbird

So you want to use your professional @ulb.be email address in a non-Outlook application? Silly you, as if it would be straightforward and a well thought out entreprise-wide migration.

Easy, but not free way

Install the ExQuilla extension, then add your account through its dedicated menu in the options. By the end of the 30-days trial, you should receive a banner notification in Thunderbird to purchase a licence (10€/year).

Almost as easy and free

  1. Install DavMail.
  2. Do yourself a favor and autostart it at boot.
@lbatteau
lbatteau / sse-fastapi-redis.py
Last active April 26, 2024 17:46
Server-Sent Events in FastAPI with async Redis Pub/Sub
from aioredis import Channel, Redis
from fastapi import FastAPI
from fastapi.params import Depends
from fastapi_plugins import depends_redis, redis_plugin
from sse_starlette.sse import EventSourceResponse
from starlette.responses import HTMLResponse
html = """
<!DOCTYPE html>
<html>
@MightyPork
MightyPork / usb_hid_keys.h
Last active June 22, 2024 00:16
USB HID Keyboard scan codes
/**
* USB HID Keyboard scan codes as per USB spec 1.11
* plus some additional codes
*
* Created by MightyPork, 2016
* Public domain
*
* Adapted from:
* https://source.android.com/devices/input/keyboard-devices.html
*/
@Overbryd
Overbryd / hacking-club-mate-imatate.md
Created June 22, 2011 13:46
Hacking Club Mate "imatate"

Hacking Club Mate "imatate"

Read about the end result here

Join me when I start brewing my first batch of Club Mate. Inspired by a podcast from chaos radio express on the topic "Hackerbrausen" (Hacker's soda, listen here) I want to try this by myself.

So far I have bought all the necessary ingrediends and tools to get started. And with the help from Jan (@janl) I can even carbonate the end result :)

When? Where?