Skip to content

Instantly share code, notes, and snippets.

View jackhumbert's full-sized avatar

Jack Humbert jackhumbert

View GitHub Profile
:root {
--code: "Fira Code", monospace;
--monospace: "Fira Code", monospace;
--monospace-font: 12px/1.5 var(--monospace);
}
.cmt-keyword {
color: #7cd5f1;
}
.cmt-number {
color: #bda0f8;
{
"layout": "LAYOUT_ortho_4x12",
"keyboard": "planck/rev6",
"author": "jackhumbert",
"layers": [
[
"KC_TAB",
"KC_Q",
"KC_W",
"KC_F",
@jackhumbert
jackhumbert / lsc.sublime-build
Created September 5, 2019 14:06
If you name your livescript files like <desired_file_name>.ls, this build system will automatically generate the desired files.
{
"cmd": ["lsc", "${file_path}/${file_name}", ">", "${file_path}/${file_base_name}"],
"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
"working_dir": "${file_path}",
"path": "D:/msys64/mingw64/bin/",
"shell": true
}
@jackhumbert
jackhumbert / Makefile
Created November 7, 2018 17:50
BootloaderHID Makefile for Planck THK
# Name: Makefile
# Project: bootloadHID
# Author: Christian Starkjohann
# Creation Date: 2007-03-19
# Tabsize: 4
# Copyright: (c) 2007 by OBJECTIVE DEVELOPMENT Software GmbH
# License: GNU GPL v2 (see License.txt)
# This Revision: $Id$
###############################################################################
enum {
PIN_INPUT,
PIN_INPUT_HIGH,
PIN_INPUT_LOW,
PIN_OUTPUT,
PIN_OUTPUT_HIGH,
PIN_OUTPUT_LOW
}
#ifdef __AVR__
diff --git a/os/hal/include/hal_i2c.h b/os/hal/include/hal_i2c.h
index c9c8409cb..4a90ba98d 100644
--- a/os/hal/include/hal_i2c.h
+++ b/os/hal/include/hal_i2c.h
@@ -1,5 +1,5 @@
/*
- ChibiOS - Copyright (C) 2006..2016 Giovanni Di Sirio
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
Licensed under the Apache License, Version 2.0 (the "License");
@jackhumbert
jackhumbert / keymap.c
Created March 16, 2018 22:45
preonic with encoder
/* Copyright 2015-2017 Jack Humbert
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@jackhumbert
jackhumbert / keymap.c
Created March 16, 2018 21:40
encoder
static uint8_t encoder_state = 0;
static int8_t encoder_value = 0;
static int8_t encoder_LUT[] = { 0, -1, 1, 0, 1, 0, 0, -1, -1, 0, 0, 1, 0, 1, -1, 0 };
void matrix_init_user(void) {
encoder_state = PIND & 0x3;
}
void matrix_scan_user(void) {
#include "kb.h"
#include "led.h"
void matrix_init_kb(void) {
// put your keyboard start-up code here
// runs once when the firmware starts up
matrix_init_user();
led_init_ports();
};
{"version":1,"keyboard":{"keys":[{"id":0,"legend":"Tab","state":{"x":0,"y":0,"r":0,"rx":0,"ry":0,"w":1,"h":1,"x2":0,"y2":0,"w2":0,"h2":0,"a":7},"row":0,"col":0,"keycodes":[{"id":"KC_TAB","fields":[]},{"id":"KC_LSFT","fields":[]},{"id":"KC_GRV","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]}]},{"id":1,"legend":"Q","state":{"x":1,"y":0,"r":0,"rx":0,"ry":0,"w":1,"h":1,"x2":0,"y2":0,"w2":0,"h2":0,"a":7},"row":0,"col":1,"keycodes":[{"id":"KC_Q","fields":[]},{"id":"KC_LSFT","fields":[]},{"id":"KC_1","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":[]},{"id":"KC_TRNS","fields":