Skip to content

Instantly share code, notes, and snippets.

View mjeveritt's full-sized avatar

Michael Everitt mjeveritt

View GitHub Profile
root@wand_MJE:/home/debian/py-uio/dts# bin/add-overlay p9.12-irq.dtbo
/sys/kernel/config/device-tree/overlays/p9.12-irq/status: unapplied
rmdir: removing directory, ‘/sys/kernel/config/device-tree/overlays/p9.12-irq’
CONFIG_IMX_IPUV3_CORE=y
CONFIG_DRM_IMX=y
CONFIG_DRM_IMX_FB_HELPER=y
CONFIG_DRM_IMX_PARALLEL_DISPLAY=y
CONFIG_DRM_IMX_TVE=y
CONFIG_DRM_IMX_LDB=y
CONFIG_DRM_IMX_IPUV3=y
CONFIG_DRM_IMX_HDMI=y
[ 3:12am] root@wand_MJE /home/debian/py-uio # ./p9.12-irq.py
Traceback (most recent call last):
File "./p9.12-irq.py", line 6, in <module>
pin = Uio( "p9.12-irq" )
File "/home/debian/py-uio/uio.py", line 63, in __init__
self._fd = os.open( path.path, flags )
AttributeError: 'PosixPath' object has no attribute 'path'
[ 5:24am] root@wand_MJE /home/debian/py-uio/dts # ls /sys/bus/platform/drivers/uio_pdrv_genirq/
bind module uevent unbind
[ 5:26am] root@wand_MJE /home/debian/py-uio/dts # ls /sys/bus/platform/drivers/uio_pdrv_genirq/ -al
total 0
drwxr-xr-x 2 root root 0 May 10 05:26 .
drwxr-xr-x 238 root root 0 Jan 1 1970 ..
--w------- 1 root root 4096 May 10 05:26 bind
lrwxrwxrwx 1 root root 0 May 10 05:26 module -> ../../../../module/uio_pdrv_genirq
--w------- 1 root root 4096 May 9 12:40 uevent
--w------- 1 root root 4096 May 10 05:26 unbind
@mjeveritt
mjeveritt / .bashrc
Last active December 28, 2019 21:05
Updated Pi identification function
# Text to clearly identify server
echo -e "\033[1;34m"
boardRev=`grep Revision /proc/cpuinfo | awk '{ print $3; }'`
#if [ "${boardRev}" == "9000c1" ]
case "${boardRev}" in
#then
000d)
figlet -f slant "Pi - Model B Rev 2"
echo " Raspberry Pi -tastic"
;;
@mjeveritt
mjeveritt / kaptan-0.5.8.ebuild
Last active August 25, 2017 21:52
kaptan-0.5.8
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy pypy3 )
inherit distutils-r1
DESCRIPTION="Configuration manager in your pocket"
HOMEPAGE="https://kaptan.readthedocs.io/"
@mjeveritt
mjeveritt / tmuxp-1.3.0.ebuild
Last active August 25, 2017 21:53
tmuxp-1.3.0
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy pypy3 )
inherit distutils-r1
DESCRIPTION="Tmux session manager built on libtmux"
HOMEPAGE="https://tmuxp.git-pull.com/"
@mjeveritt
mjeveritt / libtmux-0.7.1.ebuild
Last active August 25, 2017 21:54
libtmux-0.7.1
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy pypy3 )
inherit distutils-r1
DESCRIPTION="Python api for tmux"
HOMEPAGE="https://libtmux.git-pull.com/"
@mjeveritt
mjeveritt / gist:3112a2c63c689828ad4f2b8e0ee4ef01
Last active July 29, 2018 15:15
Gentoo mirrorselect on Debian
Download source from https://gitweb.gentoo.org/proj/mirrorselect.git
ssl-fetch library from https://github.com/dol-sen/ssl-fetch
python requests library ("python-requests") >= 2.0.0
netselect package >= 0.3
python dialog library ("python-dialog") >= 2.7
et voila.
@mjeveritt
mjeveritt / mnt_kern.sh
Created September 19, 2018 12:50
mnt_kern.sh
#!/bin/sh
set -eu
if [[ "$#" -ne 1 ]]; then
echo "Usage: mnt_kern <directory>"
exit 1
fi
if [[ ! -r "squash/${1}.sqfs" ]]; then