-
Notifications
You must be signed in to change notification settings - Fork 5
Home
write SD from a disk image on mac. use diskutil list
to find the appropriate value for "DISK".
export DISK=disk2; diskutil umountDisk /dev/${DISK} && sudo dd if=~/Downloads/2018-11-13-raspbian-stretch-lite.img of=/dev/r${DISK} bs=1m && sync && sleep 5 && scp {$USER}@${HOST}:/etc/wpa_supplicant/wpa_supplicant.conf /Volumes/boot/ && touch /Volumes/boot/ssh
first boot as root on new image:
apt -y update && apt -y dist-upgrade && apt -y install g++ automake vim git fswebcam nginx && dpkg-reconfigure tzdata && vim /etc/hostname && vim /etc/hosts && vim /etc/rc.local && passwd pi && raspi-config
- enable raspi cam under advanced
example cam monitor using raspberry cam
raspistill -w 1600 -h 1200 -q 20 -n -o /tmp/camera.jpg -l /var/www/html/camera.jpg -tl 1000 -t 10000000 -ss 40000 -rot 270
using usb webcam
fswebcam -q -d /dev/video0 -i 0 -S 10 -r 1280x720 --jpeg 30 --loop 1 --exec 'cp /var/www/html/camera.jpg.tmp /var/www/html/camera.jpg' -b /var/www/html/camera.jpg.tmp