Skip to content

Instantly share code, notes, and snippets.

ls
ls (hd0,msdos2)/
set prefix=(hd0,2)/boot/grub
set root=(hd0,2)
insmod normal
normal
<!doctype html>
<html>
<head>
<title>Videojs 7</title>
<meta charset="UTF-8">
<link href="https://unpkg.com/video.js/dist/video-js.min.css" rel="stylesheet">
</head>
<body style="margin-top:50px;">
<div id="importantdiv"/>
#!/bin/bash
set -x
sudo apt-get update
sudo apt-get install -y libatlas-base-dev
sudo pip3 install tensorflow
sudo apt-get install libjpeg-dev libtiff5-dev libjasper-dev libpng12-dev
sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev libv4l-dev
sudo apt-get install libxvidcore-dev libx264-dev
sudo apt-get install qt4-dev-tools
sudo pip3 install opencv-python
#!/bin/bash
#-------------------------------------------------
losetup --show -f -P somediskimage.img
fdisk -l
#----------------------------------------------
fc-list
[
{
"id": "75b64b94.0fd5b4",
"type": "tab",
"label": "sunposition",
"disabled": false,
"info": ""
},
{
"id": "4bffb431.af3aac",
#!/usr/bin/bash
which ansible >/dev/null 2>&1
if [ $? -ne 0 ];
then
echo "Installing Ansible..."
sleep 5
pushd .
cd ~
pacman -S libyaml-devel python2 tar libffi libffi-devel gcc pkg-config make openssl-devel openssh --noconfirm --needed
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
import requests
import json
headers = {'Authorization': 'Bearer 49beba867bca3b08df1252f837197b27ab529166'}
query_graphql = '''
query {
repository(owner: "mohankumargupta", name: "raspberrypi-ansible") {
ref(qualifiedName: "master") {
target {
#!/usr/bin/env bash
#apt-get -y install php5-cli php5-gd php5-curl php5-mysql git
#set -x
disown >/dev/null 2>/dev/null
ps aux|grep php|head -n -1|cut -f6 -d' '| xargs -I {} kill {}
if [ -z "$1" ];
then
echo "Must enter a project name"
exit 1
from functools import reduce
mylist = [
(0,0),
(0,0),
(5, 5),
(10,10),
(10,10),
(-2,-3),
(0,0)
(Taken from http://blog.gbaman.info/?p=791)
1. Install Bonjour Print Services (https://support.apple.com/kb/DL999)
2. Start from scratch, copy Raspian Jessie to SD card (can use SDFormatter to clean SD card).
3. Open SD Card in File Explorer
add to bottom of config.txt:
dtoverlay=dwc2
change cmdline.txt to something like the following:
dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait modules-load=dwc2,g_ether quiet init=/usr/lib/raspi-config/init_resize.sh
4. eject SD card, put into pi zero and boot.
5. Wait 2 minutes, plug in USB cable, and then try to SSH to raspberrypi.local