Given a stream of TPI opcodes, translates it into its human-readable form:
C:\> decode_tpi.py
[ 72 ] [ 00 ]
[ F3 00 ] [ ]
[ 68 C0 ] [ ]
[ 69 3F ] [ ]
[ 24 ] [ 1E ]
[ 24 ] [ 90 ]
| #!/usr/bin/python | |
| # | |
| # scrapes MRT information from sgwiki.com for FareBot | |
| # outputs Java statements to be copied & pasted into EZLinkTransitData.java | |
| # | |
| import urllib, urllib2 | |
| import re | |
| WIKI_URL = 'http://sgwiki.com/index.php?' |
| #!/bin/sh | |
| # | |
| # assembles a short ARM assembly file/line and shows the opcode + disassembly | |
| # useful for compiling one-liners into opcode | |
| # | |
| # usage: | |
| # arm_asm src-file.S -> assembles src-file.S | |
| # echo "mov r1, r4" | arm_asm -> assemble a single instruction | |
| # |
| % | |
| % random focus patterns in a text wall | |
| % the pattern contains black bars for the AF system to pickup | |
| % and the surrounding text helps you determine the area of focus | |
| % | |
| \documentclass[a4paper,12pt]{report} | |
| \usepackage[margin=0.8in]{geometry} | |
| \usepackage{hyperref} | |
| \usepackage{color} |
| public static String hexdump(byte[] data) { | |
| final int perRow = 16; | |
| final String hexChars = "0123456789ABCDEF"; | |
| StringBuilder dump = new StringBuilder(); | |
| StringBuilder chars = null; | |
| for (int i = 0; i < data.length; i++) { | |
| int offset = i % perRow; | |
| if (offset == 0) { | |
| chars = new StringBuilder(); |
Given a stream of TPI opcodes, translates it into its human-readable form:
C:\> decode_tpi.py
[ 72 ] [ 00 ]
[ F3 00 ] [ ]
[ 68 C0 ] [ ]
[ 69 3F ] [ ]
[ 24 ] [ 1E ]
[ 24 ] [ 90 ]
| @echo off | |
| : | |
| : signapk.bat | |
| : signs an APK with the debug key | |
| : | |
| setlocal | |
| if [%1]==[] goto end |
| #!/bin/sh | |
| # ASUS app autorun script | |
| # $1: device name, $2: mounted path. | |
| # wait for everything to be up first | |
| i=0 | |
| while [ $i -le 20 ]; do | |
| success_start_service=`nvram get success_start_service` | |
| if [ "$success_start_service" == "1" ]; then |
| sudo yum install -y \ | |
| autoconf automake libtool pkgconfig \ | |
| lib{xml2,usb1}-devel gnutls-devel libgcrypt-devel python-devel gcc-c++ | |
| # add user for usbmux daemon | |
| sudo useradd --system usbmux | |
| # installed in /usr/local/ | |
| export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig |
| #!/usr/bin/python | |
| # | |
| # renames a directory of files with their image extension | |
| # currently works with only JPEG and PNG files | |
| # | |
| # 2014.02.25 darell tan | |
| # | |
| import os | |
| import sys |
| http://cdn.sstatic.net/img/error-cats/159762931.jpg | |
| http://cdn.sstatic.net/img/error-cats/226603842.jpg | |
| http://cdn.sstatic.net/img/error-cats/287477922.jpg | |
| http://cdn.sstatic.net/img/error-cats/322899972.jpg | |
| http://cdn.sstatic.net/img/error-cats/365705759.jpg | |
| http://cdn.sstatic.net/img/error-cats/371419778.jpg | |
| http://cdn.sstatic.net/img/error-cats/375440801.jpg | |
| http://cdn.sstatic.net/img/error-cats/381472803.jpg | |
| http://cdn.sstatic.net/img/error-cats/385604943.jpg | |
| http://cdn.sstatic.net/img/error-cats/457516628.jpg |