import colorsys
H, S, V = colorsys.rgb_to_hsv(R, G, B)
V = V * brightness
R, G, B = colorsys.hsv_to_rgb(H, S, V)
import sys, socket
def listen():
try:
s = socket.socket(socket.AF_INET,socket.SOCK_RAW,socket.IPPROTO_ICMP)
s.setsockopt(socket.SOL_IP, socket.IP_HDRINCL, 1)
except socket.error, err:
print err
print "run with sudo"
sys.exit(2)
s.settimeout(10)
try:
data, addr = s.recvfrom(1508)
print "Packet from %r: %r" % (addr,data)
except socket.timeout:
print "timeout"
listen()
os.system('ping -c 1 pimote')
sudo apt-get update
sudo apt-get upgrade
wget https://www.waveshare.com/w/upload/5/5d/1.3inch_LCD_Module_code.7z
p7zip -d 1.3inch_LCD_Module_code.7z
sudo apt-get install p7zip-full
sudo apt-get install p7zip
wget https://www.waveshare.com/w/upload/d/d8/Bcm2835-1.45.tar.gz
tar zxvf Bcm2835-1.45.tar.gz
cd bcm2835-1.45/
sudo ./configure
sudo make
sudo make check
sudo make install
sudo raspi-config
sudo apt-get install git
sudo git clone git://git.drogon.net/wiringPi
cd wiringPi/
sudo ./build
sudo apt-get install python-pip
sudo pip install RPi.GPIO
sudo pip install spidev
sudo apt-get install python-imaging
sudo pip install numpy
sudo apt-get install ttf-wqy-zenhei
cd code/
cd RaspberryPi/
cd bcm2835/
make
sudo main
cd ..
cd wiringPi/
rm main
make
sudo main
cd ../python/
sudo python main.py
git clone https://github.com/robgithub/mote.git
cd mote/
git checkout master
git branch fixgetpixeluse
git checkout fixgetpixeluse
git add *; git commit -m "Added brightness parameter as fix"
git push --set-upstream origin fixgetpixeluse
linux-rpi-4.19.y/drivers/usb/host/dwc_otg/dwc_otg_driver.c
sudo vi /boot/cmdline.txt
dwc_otg.cap=2 dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=3ae9fe6d-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
Indeed it is in host mode hprt0 = 00021d01
time dd bs=4M if=/home/user/2018-11-13-raspbian-stretch-lite.img of=/dev/sdd status=progress conv=fsync
1866465280 bytes (1.9 GB, 1.7 GiB) copied, 131 s, 14.2 MB/s
445+0 records in
445+0 records out
1866465280 bytes (1.9 GB, 1.7 GiB) copied, 190.474 s, 9.8 MB/s
real 3m10.651s
user 0m0.010s
sys 0m2.744s
cp wpa_supplicant.conf /mnt/sdd2/etc/wpa_supplicant/wpa_supplicant.conf
echo "pimote" > /mnt/sdd2/etc/hostname
touch /mnt/sdd2/.ssh
touch /mnt/sdd2/ssh
touch /mnt/sdd1/ssh
ping pimote
ssh pi@pimote
curl https://get.pimoroni.com/mote | bash
Traceback (most recent call last): File "test.py", line 41, in <module> r, g, b = [int(c * 0.99) for c in mote.get_pixel(channel + 1, pixel)] ValueError: too many values to unpack
Indeed it is in host mode hprt0 = 00041d01
pi@pimote:~/src $ git clone https://github.com/raspberrypi/linux.git
Cloning into 'linux'...
remote: Enumerating objects: 6950699, done.
error: index-pack died of signal 9950699), 1.90 GiB | 16.00 KiB/s
fatal: index-pack failed
email
root
flog archives
Disclaimer:
This page is by me for me, if you are not me then please be aware of the following
I am not responsible for anything that works or does not work including files and pages made available at www.jumpstation.co.uk
I am also not responsible for any information(or what you or others do with it) available at www.jumpstation.co.uk
In fact I'm not responsible for anything ever, so there!