Skip to content

Instantly share code, notes, and snippets.

View tablatronix's full-sized avatar

Shawn A tablatronix

View GitHub Profile
@tablatronix
tablatronix / gist:4772549
Last active December 12, 2015 12:29 — forked from anonymous/gist:4772547
bboy compass config xml snippets
<com><!-- hold a prop -->
<type>menu</type>
<trigger>parrot</trigger>
<do>
<var>My Things/quickbar/prop/SB+-+Macaw+Parrot/Hold</var>
</do>
<return>Hold Parrot</return>
</com>
<com><!-- teleport to a doid -->
@tablatronix
tablatronix / gist:9766306
Last active August 29, 2015 13:57
getsimple heirarchy test set
<?php
/**
* Generate random pagesArray with parent heirarchy
* 500 pages, 8 character slugs, 10% root level parents
*/
function getrandomstring($length) {
global $template;
@tablatronix
tablatronix / themesample.php
Created April 15, 2014 20:43
gs theme color test
<div id="themecolors">
<hr>
<style>
#themecolors{
width:100%;
}
.tags {
@tablatronix
tablatronix / GSEditorPatch.php
Last active August 29, 2015 14:13
GS plugin - removes ckeditor and inserts lepture markdown editor in its place
<?php
/**
* GSEditorPatch.php
* @name GS Editor plugin
*
* removes ckeditor and inserts lepture markdown editor in its place
* https://github.com/lepture
*
* @version 0.1
@tablatronix
tablatronix / user48736353001_discog_2015
Last active August 29, 2015 14:14
user48736353001 discography 2015-soundcloud / fly away babies, good luck!
-1|status|tag|no|name|duration|about
112||afx||luke vibert spiral staircase [future music competition] [afx remix]|5:05
111||afx|19|[Slo]w early morning clissold sunrise|4:49|
110||afx|7|lsb [slo]|4:05|
109||afx|4|Red Calx[slo]|5:41|
108||Art|2|Dual Acid Ab6|4:36|94 ish, fuk knows
107||afx|5|How To Science 2 Ab6|4:51|
106||afx|4|how to science ab6|3:47|
105||afx|3|hollow alias ab6|2:14|ab6
@tablatronix
tablatronix / raspizerotestpads_flat.png
Last active December 4, 2015 19:09
rasberry pi zero
raspizerotestpads_flat.png
@tablatronix
tablatronix / wifiscan_debug.ino
Created April 8, 2016 18:08
arduino esp8266 wifiscanner with detail, rssi sorting and duplicate filtering
/*
* This sketch demonstrates how to scan WiFi networks.
* The API is almost the same as with the WiFi Shield library,
* the most obvious difference being the different file you need to include:
*/
#include "ESP8266WiFi.h"
void setup() {
Serial.begin(115200);
// Serial.setDebugOutput(true);
@tablatronix
tablatronix / esptelnetansi.ino
Created August 25, 2016 14:52
Arduino ESP8266 telnet server with some ansi experiments
/**
* Arduino ESP8266 telnet server with some ansi experiments
* @author: shawn_a
*/
#include <ESP8266WiFi.h>
#include <Arduino.h>
/* Set these to your desired AP credentials. */
const char *APssid = "ESPap";
@tablatronix
tablatronix / configfragment.js
Last active June 17, 2017 15:09
getsimple ckeditor upload handler
// add to config.js editorconfig section. you can add ?path= query to this to use a subfolder
config.imageUploadUrl = "../admin/upload.php"
// add to config.js
CKEDITOR.on( 'instanceReady', function( ev ) {
// code for fileupload and response
ev.editor.on( 'fileUploadRequest', function( evt ) {
var fileLoader = evt.data.fileLoader,
formData = new FormData(),
xhr = fileLoader.xhr;
uint8_t *pixels; // global pixel array
uint8_t NUMPIXELS = 8; // number of leds/pixels
uint8_t NUMBYTES = 3; // bytes per pixel, RGBW = 4, RGB = 3
uint16_t BUFFBYTES = NUMPIXELS*NUMBYTES; // bytes to allocate for pixel array
void allocPixelArray(uint8_t numPixels,uint8_t numBytes){
NUMPIXELS = numPixels;
NUMBYTES = numBytes;
BUFFBYTES = numPixels*numBytes;
Serial.println("allocating " + (String)BUFFBYTES + " bytes");