Skip to content

Instantly share code, notes, and snippets.

View FantomJAC's full-sized avatar

Shotaro Uchida FantomJAC

  • SF Bay Area, California
View GitHub Profile
@FantomJAC
FantomJAC / oatuh2-dev-note
Created September 1, 2012 10:42
Restlet OAuth2.0 draft30 extension development note.
OAuth 2.0 draft30 Note.
1.7. HTTP Redirections
* We use '307 Temporary Redirect' via #redirectTemporary method generally.
1.8. Interoperability
* TBD: Client implementations.
2. Client Registration
* ClientStore has 2 methods to specify client type(confidential/public).
@FantomJAC
FantomJAC / gist:6007794
Created July 16, 2013 11:07
適当JSON
import java.nio.CharBuffer;
import java.util.HashMap;
import java.util.Map;
public class Parser {
public static final char START_OBJECT = '{';
public static final char KEY = ':';
public static final char VALUE = ',';
public static final char END_OBJECT = '}';
@FantomJAC
FantomJAC / openjfx8-armv7hf-beagleboard.patch
Last active December 30, 2015 07:39
Beagleboard(armv7hf) build patch for OpenJFX8 (b118)
diff -r 25d3cad95e8b build.gradle
--- a/build.gradle Thu Nov 28 08:49:58 2013 -0800
+++ b/build.gradle Wed Dec 04 15:35:16 2013 -0800
@@ -1128,8 +1128,8 @@
if (IS_COMPILE_PANGO) {
// TODO: embedded support
- addNative(project, "fontFreetype", ["linux"])
- addNative(project, "fontPango", ["linux"])
+ addNative(project, "fontFreetype", ["linux", "armv7hf"])
@FantomJAC
FantomJAC / update-jfx.sh
Created December 4, 2013 23:40
A rootfs tool for OpenJFX8 custom sdk build.
#!/bin/bash
#
# Copyright (c) 2013 Shotaro Uchida <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
@FantomJAC
FantomJAC / armv7hf-pandaboard.patch
Created February 20, 2014 23:58
OMAP4/5(armv7hf) build patch for OpenJFX8 (b129) based on https://github.com/robclark/kmscube
diff -r b8d6295f4672 build.gradle
--- a/build.gradle Fri Feb 07 13:27:40 2014 -0800
+++ b/build.gradle Thu Feb 20 15:57:51 2014 -0800
@@ -1146,8 +1146,8 @@
if (IS_COMPILE_PANGO) {
// TODO: embedded support
- addNative(project, "fontFreetype", ["linux"])
- addNative(project, "fontPango", ["linux"])
+ addNative(project, "fontFreetype", ["linux", "armv7hf"])
@FantomJAC
FantomJAC / gist:8dca0f47d72dab098274
Last active August 29, 2015 14:01
OpenNakamoto

Common

Ingredients of Miso Base

  • 1 cup aka-miso
  • 1 cup shiro-miso
  • Red pepper powder
  • Curry powder
  • Lard (for stir frying)
public static int bitReverse(int i, int bit) {
if (bit == 1) return i;
int s = bit / 2;
int mask = 0xFFFFFFFF >>> (32 - s);
return bitReverse(i >> s, s) | bitReverse(i & mask, s) << s;
}
@FantomJAC
FantomJAC / gist:f80d0014f4fed3fe016c
Created July 22, 2014 10:57
objfw Ubuntu 14.04 error
[OFThread] -[start]: testing...
Runtime error: Unhandled exception:
Starting a thread of type TestThread failed!
Backtrace:
0x2af66ab9fcc8 <??> at ./libobjfw.so.7
0x2af66aba3a0e <??> at ./libobjfw.so.7
0x2af66aba3942 <??> at ./libobjfw.so.7
0x2af66ab62ca1 <??> at ./libobjfw.so.7
0x425a80 <??> at ./tests
@FantomJAC
FantomJAC / gist:fb6ccccb34fa3dd8289e
Last active August 29, 2015 14:10
オープン家系
/*
 * ----------------------------------------------------------------------------
 * "THE BEER-WARE LICENSE" (Revision 42):
 * <[email protected]> wrote this file. As long as you retain this notice you
 * can do whatever you want with this stuff. If we meet some day, and you think
 * this stuff is worth it, you can buy me a beer in return.
 * ----------------------------------------------------------------------------
 */
@FantomJAC
FantomJAC / edison-force-spidev.patch
Created February 3, 2016 21:21
Enable SPI CS0 (spidev5.0) on Intel Edison
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 82b8dca..e1a4789 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -457,6 +457,9 @@ config X86_INTEL_MID
nor standard legacy replacement devices/features. e.g. It does not
contain i8259, i8254, HPET, legacy BIOS, most of the io ports.
+config INTEL_MID_FORCE_SPIDEV
+ bool "Force spidev"