Skip to content

Instantly share code, notes, and snippets.

View corgan2222's full-sized avatar
🏠
Working from home

Stefan Knaak corgan2222

🏠
Working from home
View GitHub Profile
@corgan2222
corgan2222 / gist:0041e1ec0391867e02f2325cc1a5a54e
Created December 2, 2019 10:19
Kodi reconnect bluetoothctl
echo 'connect F4:B8:5E:7E:8D:19 '|bluetoothctl
@corgan2222
corgan2222 / gist:5216ed8e4da482d2ff123d2060f997b2
Created December 2, 2019 10:21
crontab Kodi bluetoothctl Fire-Tv remote
* * * * * sleep 00;echo 'connect F4:B8:5E:7E:8D:19'|bluetoothctl > /dev/null 2>&1
* * * * * sleep 15;echo 'connect F4:B8:5E:7E:8D:19'|bluetoothctl > /dev/null 2>&1
* * * * * sleep 30;echo 'connect F4:B8:5E:7E:8D:19'|bluetoothctl > /dev/null 2>&1
* * * * * sleep 45;echo 'connect F4:B8:5E:7E:8D:19'|bluetoothctl > /dev/null 2>&1
journalctl | grep blue #get errors from log
hciconfig
hciconfig hci0 down
hciconfig hci0 up
bluetoothctl
power on
agent on
devices
@corgan2222
corgan2222 / gist:5ad6ff9d417e4c7140187f838181b053
Created December 2, 2019 11:47
kodi disable PulseAudio
pasuspender -- env KODI_AE_SINK=ALSA
cp /etc/pulse/client.conf /home/yourusername/.config/pulse
cp /etc/pulse/client.conf /home/yourusername/.config/pulse/client.confbackup
nano /home/yourusername/.config/pulse/client.conf
From:
; autospawn = yes
To:
autospawn = no
@corgan2222
corgan2222 / gist:4af711f9e7032b72ca8e7c84b1f6cdbf
Last active December 2, 2019 12:20
libreelec.tv/config.txt
https://wiki.libreelec.tv/config.txt
mount -o remount,rw /flash
nano /flash/config.txt
mount -o remount,ro /flash
Adding Device Tree Overlays
The current supported DTB's can be found in /flash/overlays. These can be set by using any of the following overlays
docker run \
--name kodi \
--net=host \
--privileged \
--restart unless-stopped \
-e ZBX_HOSTNAME="kodi" \
-e ZBX_SERVER_HOST="192.168.2.25" \
-d aledjones/zabbix-agent:4.2
* install the docker addon in Libreelec using the menu system
o From addons/install from repository/libreelec addons/services/docker
* log in via ssh and install the docker container
> docker pull bltavares/zerotier
docker run --device=/dev/net/tun \
@corgan2222
corgan2222 / gist:f60c3752b9ce1ffd6c5e76e1d0717542
Created April 1, 2020 10:02
IPMI commands for Dell PowerEdge R210 II running pfsense freeBSD
#Dell PowerEdge R210 II
#pfsense freeBSD
kldload ipmi
ipmitool
ipmitool sensor
ipmitool sensor get "FAN 1 RPM"
@corgan2222
corgan2222 / gist:5f7f0345273e364b6c365bbc75ab268d
Created September 7, 2020 12:36
Ender 5 Pro Cura 4.6 Start GCode for heating nozzle and bed while BL Touch bed leveling
; Script based on an original created by tjjfvi (https://github.com/tjjfvi)
; An up-to-date version of the tjjfvi's original script can be found
; here: https://csi.t6.fyi/
; Note - This script will only work in Cura V4.2 and above!
; --- Global Settings
; layer_height = {layer_height}
; smooth_spiralized_contours = {smooth_spiralized_contours}
; magic_mesh_surface_mode = {magic_mesh_surface_mode}
; machine_extruder_count = {machine_extruder_count}
; --- Single Extruder Settings
@corgan2222
corgan2222 / windowTitle.ps1
Last active March 18, 2021 01:15
Open Windows Explorer with the Folder of the current opened Adobe Premiere/After Effects Project
$x = get-process | ? {$_.MainWindowTitle -like "*Adobe Premiere*"} | Select-Object -ExpandProperty mainwindowtitle
if ($x){
$pp_path = $x.SubString($x.IndexOf("-") + 2, $x.LastIndexOf("\") - $x.IndexOf("-") - 1)
$pp_path -replace ' ', '` '
# echo $pp_path
explorer.exe $pp_path
}else {
$ae = get-process | ? {$_.MainWindowTitle -like "*Adobe After Effects*"} | Select-Object -ExpandProperty mainwindowtitle