Skip to content

Instantly share code, notes, and snippets.

Chih-Hsuan Yen yan12125

Block or report user

Report or block yan12125

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
yan12125 / aagGen.cpp
Created Dec 31, 2012
AAG Circuit file generator version 2
View aagGen.cpp
#include <iostream>
#include <ctime>
#include <cstdlib>
#include <vector>
#include <sstream>
#include <fstream>
#include <cstring>
using namespace std;
enum GateType { PI, AIG, UNDEF };
yan12125 / build.cmd
Last active Dec 11, 2015
Win32 Assembly example
View build.cmd
ml /c winapi.asm
link winapi.asm /subsystem:console
yan12125 / hornet-1.0.patch
Last active May 13, 2018
Build instruction and patch file for hornet-1.0
View hornet-1.0.patch
diff -ur hornet-1.0/src/boost.task-0.4.2/boost/task/detail/bind_processor.hpp hornet-1.0-mod2/src/boost.task-0.4.2/boost/task/detail/bind_processor.hpp
--- hornet-1.0/src/boost.task-0.4.2/boost/task/detail/bind_processor.hpp 2011-06-01 21:51:37.000000000 +0800
+++ hornet-1.0-mod2/src/boost.task-0.4.2/boost/task/detail/bind_processor.hpp 2014-05-04 02:58:12.144146742 +0800
@@ -7,7 +7,7 @@
-#include <boost/task/detail/config.hpp>
+//#include <boost/task/detail/config.hpp>
yan12125 / Makefile
Last active Apr 26, 2020
v4l2 test
View Makefile
v4l2: v4l2.cpp
g++ v4l2.cpp -o v4l2 -ljpeg
import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothDevice;
import android.bluetooth.BluetoothSocket;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
yan12125 /
Last active Feb 23, 2018
Print the dependencies of Windows EXE/DLL using winedump (deprecated; check instead)
#!/usr/bin/env python3
# WTFPL – Do What the Fuck You Want to Public License
import subprocess
import os
import sys
prefixes = {
'i386': '/usr/i686-w64-mingw32/bin',
'AMD64': '/usr/x86_64-w64-mingw32/bin'
yan12125 / gist:1399c9103354c2614351
Created Mar 6, 2015
Send a comment request to facebook with tagging
View gist:1399c9103354c2614351
curl -v '' -H 'Cookie: c_user=[my_uid]; xs=[xs]' --data 'ft_ent_identifier=[object_id]&comment_text=[coment text]&client_id=1:1[any number:any number]&fb_dtsg=[fb_dtsg]'
yan12125 /
Created Apr 14, 2017
Build a custom kernel for Android emulator
git clone -b android-goldfish-3.18
git clone
cd goldfish
export CROSS_COMPILE=x86_64-linux-android-
export ARCH=x86_64
export PATH=$PATH:/path/to/x86_64-linux-android-4.9/bin
make x86_64_ranchu_defconfig
make menuconfig  # enable overlayfs and namespaces support here
make -j8
View Makefile
COMMON_OBJECTS=sparse_crc32.o \
backed_block.o \
output_file.o \
sparse.o \
sparse_err.o \
sparse_read.o \
TARGETS=simg2img \
append2simg \
yan12125 /
Created Jun 3, 2017
Firefox OS resources
You can’t perform that action at this time.