Skip to content

Instantly share code, notes, and snippets.

private void setupLibraries() {
HashMap<String, Integer> libraries = new HashMap<>();
libraries.put("libbiomini.so", R.raw.libbiomini);
libraries.put("libcard_reader.so", R.raw.libcard_reader);
libraries.put("libcollect.so", R.raw.libcollect);
libraries.put("libdecode.so", R.raw.libdecode);
libraries.put("libidcard.so", R.raw.libidcard);
libraries.put("libled.so", R.raw.libled);
libraries.put("libmoneybox.so", R.raw.libmoneybox);
libraries.put("libpicc.so", R.raw.libpicc);
private void print() {
showProgressDialog();
try {
try {
ThermalPrinter.start(mContext);
} catch (Exception ex) {
ex.printStackTrace();
}
ThermalPrinter.reset();
ThermalPrinter.setGray(4);
<a href="itms-services://?action=download-manifest&amp;url=@@@ LINK TO PLIST">
click this link to install
</a>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>items</key>
<array>
<dict>
<key>assets</key>
<array>
<dict>
@witochandra
witochandra / gist:a097206fe686c55b8b75
Created July 14, 2015 04:51
Contoh body push notification ke GCM
{
"to" : "aaaa",
"notification" : {
"title":"Judul",
"body":"Halo",
"icon":"ic_notification",
"color": "#3ba4f6",
"click_action":"com.suitmedia.nuna.OPEN_CUSTOMER"
},
"data": {
@witochandra
witochandra / designer.html
Last active August 29, 2015 14:20
designer
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-item/core-item.html">
<polymer-element name="sign-up">
<template>
<style>
:host {
@witochandra
witochandra / RangeSeekBar.java
Created March 25, 2015 09:39
RangeSeekBar with interval
/*
Copyright 2014 Stephan Tittel and Yahoo Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@witochandra
witochandra / designer.html
Last active August 29, 2015 14:17
designer
<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-menu/core-submenu.html">
<link rel="import" href="../paper-input/paper-input.html">
<link rel="import" href="../paper-radio-group/paper-radio-group.html">
<link rel="import" href="../paper-radio-button/paper-radio-button.html">
package com.witochandra;
import org.ksoap2.SoapEnvelope;
import org.ksoap2.SoapFault;
import org.ksoap2.serialization.PropertyInfo;
import org.ksoap2.serialization.SoapObject;
import org.ksoap2.serialization.SoapSerializationEnvelope;
import org.ksoap2.transport.HttpTransportSE;
import org.kxml2.io.KXmlParser;
import org.kxml2.io.KXmlSerializer;
import json
import logging
import os
import socket
import ssl
import struct
import sys
import time
import uuid