Skip to content

Instantly share code, notes, and snippets.

@ggirou
ggirou / carmp3.lircd.conf
Last active June 16, 2022 20:33
LIRC carmp3 remote config
# Please take the time to finish this file as described in
# https://sourceforge.net/p/lirc-remotes/wiki/Checklist/
# and make it available to others by sending it to
# <lirc@bartelmus.de>
#
# This config file was automatically generated
# using lirc-0.10.1(default) on Wed Jun 15 19:30:21 2022
# Command line used: -d /dev/lirc0 this_special_remote.conf
# Kernel version (uname -r): 5.10.92+
#
@ggirou
ggirou / .proxy.md
Last active September 18, 2021 07:38 — forked from yougg/proxy.md
complete ways to set http/socks/ssh proxy environment variables

set http or socks proxy environment variables

# set http proxy
export http_proxy=http://PROXYHOST:PROXYPORT

# set http proxy with user and password
export http_proxy=http://USERNAME:PASSWORD@PROXYHOST:PROXYPORT

# set http proxy with user and password (with special characters)
#!/usr/bin/env node
const fs = require('fs');
const readline = require('readline');
const commitFile = process.argv[2];
const fromIDE = !process.stdout.isTTY;
if (fromIDE) {
process.exit(0);
@ggirou
ggirou / gulpfile.js
Created September 15, 2019 17:12
Gulp Regex scanner
var gulp = require('gulp');
var regexScanner = require('./regex-scanner');
gulp.task('find-usage:myprefix', function() {
    // Répertoire où se situe les sources
    var sourceFolder= './application/';
    // Les fichiers sources à vérifier
    var filesToCheck= [
        sourceFolder+ '**/*.ts',
@ggirou
ggirou / gen_cert.sh
Created May 31, 2018 11:59 — forked from adamrunner/gen_cert.sh
bash script to generate a self signed certificate for development use
#!/bin/bash
# Bash shell script for generating self-signed certs. Run this in a folder, as it
# generates a few files. Large portions of this script were taken from the
# following artcile:
#
# http://usrportage.de/archives/919-Batch-generating-SSL-certificates.html
#
# Additional alterations by: Brad Landers
# Date: 2012-01-27
@ggirou
ggirou / HowToOTGFast.md
Created May 29, 2018 19:56 — forked from gbaman/HowToOTGFast.md
Simple guide for setting up OTG modes on the Raspberry Pi Zero, the fast way!

###Setting up Pi Zero OTG - The quick way (No USB keyboard, mouse, HDMI monitor needed)
More details - http://blog.gbaman.info/?p=791

For this method, alongside your Pi Zero, MicroUSB cable and MicroSD card, only an additional computer is required, which can be running Windows (with Bonjour, iTunes or Quicktime installed), Mac OS or Linux (with Avahi Daemon installed, for example Ubuntu has it built in).
1. Flash Raspbian Jessie full or Raspbian Jessie Lite onto the SD card.
2. Once Raspbian is flashed, open up the boot partition (in Windows Explorer, Finder etc) and add to the bottom of the config.txt file dtoverlay=dwc2 on a new line, then save the file.
3. If using a recent release of Jessie (Dec 2016 onwards), then create a new file simply called ssh in the SD card as well. By default SSH is

@ggirou
ggirou / VoCore2.md
Last active May 20, 2018 12:03
VoCore2
@ggirou
ggirou / rainbow.py
Last active April 30, 2020 13:08
Rainbow hat XP
import rainbowhat as rh
rh.rainbow.set_pixel(0, 255, 0, 0)
rh.rainbow.show()
#######################
import rainbowhat as rh
import time
@ggirou
ggirou / bluetooth-adapter.sh
Last active April 30, 2020 20:08
Raspberry pi bluetooth speaker
hciconfig
hciconfig hci0 up
hciconfig hci0 reset
# Scan for Bluetooth devices
hcitool scan
@ggirou
ggirou / jukebox.sh
Last active October 22, 2017 20:53
Keyboard jukebox
#!/bin/bash
cd songs/1
while true
do
clear
echo 'Running Keyboard Jukebox...'
echo 'Tape a key to play a song'