Skip to content

Instantly share code, notes, and snippets.

View JohnnyCurran's full-sized avatar

John Curran JohnnyCurran

  • Austin, TX
View GitHub Profile
@mcrumm
mcrumm / component_under_test.ex
Last active December 4, 2025 16:59
Testing Phoenix.LiveComponent in Isolation
# lib/party_web/components/example_component.ex
defmodule PartyWeb.ExampleComponent do
@moduledoc """
An example LiveComponent under test.
"""
use Phoenix.LiveComponent
def render(assigns) do
~H"""
<div>
@bjornvaktaren
bjornvaktaren / minimal_spi.cpp
Last active December 16, 2025 14:05
Simple SPI example with libftdi and FTDI UM232H
// Quite minimal example showing how to configure MPSSE for SPI using libftdi
// compile like this: g++ minimal_spi.cpp -o minimal_spi -lftdipp -lftdi
#include <ftdi.hpp>
#include <usb.h>
#include <stdio.h>
#include <iostream>
#include <string.h>
// UM232H development module
#define VENDOR 0x0403
@mplewis
mplewis / android_ble_char_props_cheat_sheet.md
Last active May 15, 2023 17:45
A cheat sheet for the bits in the bitmask of Android characteristic properties.

Characteristic Property Cheat Sheet

for Android Bluetooth Low Energy

Tired of remembering which properties go with which bits in the properties bitmask of a BluetoothGattCharacteristic? Me too. Here's an easy-to-read table. Source.

BluetoothGattCharacteristic

Properties

Bit Value | Meaning

@0xF1o
0xF1o / ssh.cs
Last active July 21, 2025 21:06
ssh.net Example - Keybased Authentication, File Upload, Shell Commands
/*
get SSH.NET (BSD License: http://sshnet.codeplex.com/license)
with NuGet:
>Install-Package SSH.NET -Version 2013.4.7
or just get the dll from here: http://j.mp/sshNet
*/
using System;
@macintux
macintux / erlang-resources.md
Last active December 15, 2025 22:31
Erlang online resources

This is not intended to be comprehensive or authoritative, just free online resources I've found valuable while learning more about Erlang.

Joe Armstrong's Swedish Institute of Computer Science homepage (Wayback Machine)

https://web.archive.org/web/20070429181654/http://www.sics.se/~joe/

Similar lists