- Install Windows7
- Install relevant drivers
- Update
- Update
- Update
- ...a couple more reboots
- Set power button action to suspend and disable lock on resume
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
You may wonder what the heck is going on here. | |
This is simply my take on code reloading with persisting open sockets i thought | |
of using in some future IRC bot. A good way to research a little bit more about | |
exec, file descriptors and sockets. | |
""" | |
import socket | |
import random | |
import time |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#ifndef VERBOSITY_LEVEL | |
#define VERBOSITY_LEVEL 3 | |
#endif | |
#define _stringify2(n) #n | |
#define _stringify(n) _stringify2(n) | |
#define PRINT_MESSAGE(type, color, fmt, ...) printf("\033[0;" color "m" \ | |
__FILE__ "@" _stringify(__LINE__) " \033[1;" color "m" type ":\033[0;" \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import sys, time, math, atexit, select | |
class Screen(object): | |
def __init__(self, width=80, height=24): | |
self.output = sys.stdout | |
atexit.register(self.clear) | |
# FIXME: don't flush on every escapecode | |
def _e(self, s): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -* coding: utf-8 *- | |
''' | |
Guitar Hero® World Tour wireless PS3 drums to MIDI adapter for Linux in python. | |
usage: PROG [hidraw device, default: /dev/hidraw4] [MIDI device number, default: last output] | |
''' | |
# FIXME: I dunno... refactor maybe? ;) | |
# FIXME: Sadly, latency is quite noticable |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const int ROWS_COUNT = 4; | |
const int COLS_COUNT = 8; | |
const int ANALOG_COUNT = 2; | |
// Internal reserved CC ID for pitchbend (which isn't really a CC, but, welp) | |
const int CC_PITCHBEND = 128; | |
const int midiChannel = 0; | |
const int midiVelocity = 127; | |
const int midiBaseNote = 52; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# encoding: utf-8 | |
""" | |
Really simple chunked/gzipped HTTP Request/Response decoder. | |
Might be useful in conjunction with sslsplit and vim. | |
Note: it loads whole body to memory, but might be fixed with zlib.decompressobj | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
from subprocess import call, check_output | |
class CameraSettings: | |
def __init__(self, captureObject, device): | |
self.cap = captureObject | |
self.device = device | |
def getFocus(self): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pygame | |
LEFT, CENTER, RIGHT = range(3) | |
TOP, MIDDLE, BOTTOM = range(3) | |
class RenderText(pygame.sprite.Sprite): | |
pos = None | |
pos_rel = None |
Note: My config is as follows: Ubuntu/KDE Server + Windows 7 Client.
- If you are going to play any games, you want to bind some key/keystroke to
lockCursorToScreen
(switchInDirection
might be usable too, I actually prefer to have cursor locked most of the time, and just switch between screens with a keystroke) and check Advanced server config → Use relative mouse moves on server. - Remember to check Elevate privileges in config on your (Windows) client.
- For Windows to receive
Ctrl+Alt+Del
properly you have to mingle with gpedit, as per http://www.robertwrose.com/2012/06/enabling-ctrl-alt-del-in-windows-7-over-synergy.html - Unless you feel like patching your Windows build, you have to be very patient and try not to switch context too often - https://github.com/synergy/synergy/issues/3241 :^)
- If the only thing you use
Ctrl+Alt+Del
keystroke for in Windows is startingtaskmgr
, you might want to learnCtrl+Shift+Escape
which does just that, without switching running context to
OlderNewer