Skip to content

Instantly share code, notes, and snippets.

View PierrickKoch's full-sized avatar

Pierrick Koch PierrickKoch

View GitHub Profile
#set -g status-interval 2
#set -g status-left "#S #[fg=green,bg=black]#(tmux-mem-cpu-load --colors 2)#[default]"
#set -g default-terminal "screen-256color"
#set -g status-utf8 on
bind M source-file ~/.tmux/mac.session
bind L source-file ~/.tmux/linux.session
# set -g terminal-overrides 'xterm*:smcup@:rmcup@'
From eaa546e274f1c58379c4ad716f2f13ce8db75f13 Mon Sep 17 00:00:00 2001
From: xianpu.liang <xianpu.liang@mediatek.com>
Date: Fri, 29 Nov 2013 12:44:44 +0800
Subject: [PATCH] Using rild funcs to do EAP-SIM/AKA authentication.
Connect smart card via rild, using socket rild-oem.
Add a new field in eap_peer_config, as the identity
when end-user select eap method of SIM/AKA.
Signed-off-by: xianpu.liang <xianpu.liang@mediatek.com>
@PierrickKoch
PierrickKoch / test_atlaas.py
Created January 14, 2014 14:02
morse script to test atlaas
from morse.builder import *
from robots.dala import Dala
# AGV
agv = Dala(use_velodyne = True)
agv.configure()
agv.pose.add_stream('pocolibs', 'morse.middleware.pocolibs.sensors.pom.PomPoster', poster = 'pomPos')
cam = VideoCamera()
cam.translate(x=-4,z=4)
cam.rotate(y=-0.3)
#! /usr/bin/env python
import sys
import time
import collections
class Bitrate:
def __init__(self, iface='eth0'):
self.iface = iface
self._log = collections.deque([], 10)
#! /usr/bin/env blender -b -P
from mathutils import Matrix, Euler
from math import radians as rad
rot = (rad(60), 0, rad(-90))
tra = (-1, 0, 2)
mat = Matrix.Translation(tra) * Euler(rot, 'XYZ').to_matrix().to_4x4()
res = Matrix( [[round(elt, 3) for elt in vec] for vec in mat] )
@PierrickKoch
PierrickKoch / morse-autodoc.bash
Last active August 29, 2015 13:55
morse doc gen publish script - for post-update hook
#! /bin/bash -e
git pull --rebase git://git.openrobots.org/robots/morse master
mkdir -p build && cd build
source /opt/ros/groovy/setup.bash
cmake -DCMAKE_INSTALL_PREFIX=$(pwd)/tmp \
-DPYMORSE_SUPPORT=ON \
-DPYTHON_EXECUTABLE=~/devel/bin/python3.3 \
-DBUILD_POCOLIBS_SUPPORT=ON \
@PierrickKoch
PierrickKoch / post-receive
Last active August 29, 2015 13:56
git post-receive hook
#!/bin/sh
#
# hook script for the "post-receive" event.
# used when push to web server
#
cd ${PWD%.git} || exit
# $GIT_DIR prevent from using git in hook
unset GIT_DIR
git pull --rebase
# implies that you already did `cd ..; git clone $OLDPWD`
@PierrickKoch
PierrickKoch / agv_atlaas.py
Last active August 29, 2015 13:56
simu atlaas + p3d
from morse.builder import *
from robots.dala import Dala
# AGV
agv = Dala(use_velodyne = True)
agv.set_mass(20)
agv.velodyne.properties(cam_width=128, cam_height=128)
agv.configure()
#agv.pose.add_stream('pocolibs',
# 'morse.middleware.pocolibs.sensors.pom.PomPoster',
@PierrickKoch
PierrickKoch / p3d.py
Last active August 29, 2015 13:56
lot of fun debugging p3d!!
#! /usr/bin/env python
import sys
path = sys.argv[1]
with open(path) as f:
lines = f.readlines()
# python does not have sscanf
def get(types, line):
return [ t(s) for t,s in zip( types, line.split() ) ]
[ 18.418]
X.Org X Server 1.11.3
Release Date: 2011-12-16
[ 18.418] X Protocol Version 11, Revision 0
[ 18.418] Build Operating System: Linux 2.6.42-37-generic x86_64 Ubuntu
[ 18.418] Current Operating System: Linux champa 3.5.0-46-generic #70~precise1-Ubuntu SMP Thu Jan 9 23:55:12 UTC 2014 x86_64
[ 18.418] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-3.5.0-46-generic root=UUID=98664dfb-9b9e-4220-a0d4-81d783bb630a ro quiet splash
[ 18.418] Build Date: 16 October 2013 04:41:23PM
[ 18.418] xorg-server 2:1.11.4-0ubuntu10.14 (For technical support please see http://www.ubuntu.com/support)
[ 18.418] Current version of pixman: 0.30.2