Raspberry PI setup

Reviews and other little ventures that don't quite fit into the other forums
Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Raspberry PI setup

Post by Daniel Wee » Fri 14 Dec 14 2012 9:39 am

sudo apt-get update
sudo apt-get upgrade
sudo raspi-config
sudo apt-get dist-upgrade
sudo apt-get dist-upgrade --fix-missing

#set locale
#do not boot to desktop
#may need to edit /etc/environment to add LANG and LC_CTYPE lines
#enlarge partition

sudo apt-get install netatalk
sudo apt-get install hdparm
sudo apt-get install espeak
sudo apt-get install x11-xserver-utils

#set up ~/.xinitrc

#scan wi-fi networks

wpa_cli scan && sleep 5 && wpa_cli scan_results
iwlist wlan0 scan

#setup wi-fi
https://learn.adafruit.com/adafruits-ra ... cidentalis
http://www.raspberrypi.org/forums/viewt ... 28&t=44044

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Fri 14 Dec 14 2012 9:59 am


Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Fri 14 Dec 14 2012 11:47 am


Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Fri 14 Dec 14 2012 11:51 am

sudo passwd root

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Mon 17 Dec 17 2012 4:22 pm

To enable I2C and SPI ports which are disabled by default:-

sudo nano /etc/modprobe.d/raspi-blacklist.conf

comment out both lines

http://hubcitylabs.org/enabling-i2c-on- ... spberrypi/
http://www.cmdrkeen.net/tag/spi/

also:-

sudo apt-get install libi2c-dev

http://www.raspberrypi.org/phpBB3/viewt ... 31&t=19680
http://www.raspberrypi.org/phpBB3/viewt ... f=7&t=1434

adduser pi i2c
adduser root i2c

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Tue 18 Dec 18 2012 12:08 pm


Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Tue 18 Dec 18 2012 12:23 pm

MySQL

http://www.cyberciti.biz/tips/linux-uni ... ogram.html
http://www.yolinux.com/TUTORIALS/MySQL- ... C-API.html

sudo apt-get install libmysqlclient-dev
sudo apt-get install libmysqld-dev
sudo apt-get install libmysqlclient16
sudo apt-get install libmysqlclient18
sudo apt-get install mysql-workbench
sudo apt-get install mysql-common

The following provides the necessary flags:-

mysql_config --cflags --libs

usage:-

gcc test.c -o test $(mysql_config --clags --libs)

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Re: Raspberry PI setup

Post by Daniel Wee » Tue 01 Jan 01 2013 8:05 pm

Cron jobs

adduser pi crontab

Add the following line after issuing the command "sudo crontab -e"

*/10 * * * * /home/pi/code/test1 > /dev/null

Make sure to start the cron job by issuing:-

sudo /etc/init.d/cron start

If already started, you may want to restart instead of start.

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Installing new image on Mac OS X

Post by Daniel Wee » Sun 05 Oct 05 2014 9:29 pm

Format SD card on Windows to FAT32

Download RASPIAN image (choose ZIP and not Torrent) to Mac desktop from:-
http://www.raspberrypi.org/downloads/
http://downloads.raspberrypi.org/raspbian_latest

On Mac Pro - SD card slot is disk1 so use that in instructions ahead, ie. /dev/disk1
Use Disk Utility in utilities to check this. Can also unmount with the utility.

Follow instructions here:-
http://www.raspberrypi.org/documentatio ... ges/mac.md

Daniel Wee
Site Admin
Posts: 2073
Joined: Wed 25 Feb 25 2009 8:00 pm

Clear dirty bit in SD card

Post by Daniel Wee » Sun 05 Oct 05 2014 9:31 pm


Post Reply