configuration raspi

7
Setting the email address 1. Connect the Raspberry Pi to a Monitor/Television and attach a keyboard and mouse via USB. 2. Boot up the Raspberry Pi. 3. Run LXTerminal which can be found on the desktop. 4. Update necessary software by typing: "sudo apt-get update" "sudo apt-get upgrade" 5. After finishing the download and installing of updates, type in the following command: "sudo nano /etc/ssmtp/ssmtp.conf" 6. Edit these lines(do not add the instructions after # sign): [email protected] #Replace YourUsername with the email address you are going to use for sending. AuthUser=YourUsername #Replace YourUsername with the Username of the email AuthPass=YourPassword #Replace YourPassword with the Password of the email 7. After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes. 8. Type the following "sudo nano /home/pi/motion-mmalcam.conf". 9. Edit this line: “on_picture_save value” to : on_picture_save mpack -s Alert %f [email protected] #Replace YourUsername with the username of the email address 10. After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes. 11. Type “sudo reboot” to restart the raspberry pi.

Upload: azerbaijangalac

Post on 17-Jul-2016

230 views

Category:

Documents


0 download

DESCRIPTION

Raspberry pi configuration

TRANSCRIPT

Page 1: Configuration Raspi

Setting the email address

1. Connect the Raspberry Pi to a Monitor/Television and attach a keyboard and mouse via USB.

2. Boot up the Raspberry Pi.3. Run LXTerminal which can be found on the desktop. 4. Update necessary software by typing:

"sudo apt-get update" "sudo apt-get upgrade"

5. After finishing the download and installing of updates, type in the following command:

"sudo nano /etc/ssmtp/ssmtp.conf"6. Edit these lines(do not add the instructions after # sign):

[email protected] #Replace YourUsername with the email address you are going to use for sending.

AuthUser=YourUsername #Replace YourUsername with the Username of the email

AuthPass=YourPassword #Replace YourPassword with the Password of the email

7. After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes.

8. Type the following  "sudo nano /home/pi/motion-mmalcam.conf".

9. Edit this line: “on_picture_save value” to : on_picture_save mpack -s Alert %f [email protected] #Replace YourUsername with the username of the email address

10.After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes.

11.Type “sudo reboot” to restart the raspberry pi.

Page 2: Configuration Raspi

Changing the image resolution

1. Connect the Raspberry Pi to a Monitor/Television and attach a keyboard and mouse via USB.

2. Boot up the Raspberry Pi.3. Run LXTerminal which can be found on the desktop. 4. Update necessary software by typing(without the apostrophe):

"sudo apt-get update" "sudo apt-get upgrade"

5. After finishing the download and installing of updates, type in the following command:

" sudo nano /home/pi/motion-mmalcam.conf"6. Edit these lines:

For Resolution of the image (available resolutions are 640x1280, 1024x576 and 1280x720):

width=640 height=1280

For sensitivity of capturing image(default is 3000): Threshold=3000

Many other settings are available here(some may have compatibility issues with the design of the project).

7. After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes.

8. Type the following:  " sudo nano /boot/config.txt".

9. Edit this line: (Set 1 to disable and set 0 to enable) “disable_camera_led=1”

10.After editing commands to your preference, press CTRL + X, then type Y, ENTER to save changes.

11.Type “sudo reboot” to restart the raspberry pi.

Page 3: Configuration Raspi

TROUBLESHOOTING:

If the camera is not working correctly, there are number of things to try. • Are the ribbon connectors all firmly seated and the right way round? They must be straight in their sockets. • Is the camera module connector firmly attached to the camera PCB? This is the connection from the smaller black camera module itself to the camera PCB. Sometimes this connection can come loose. Using a fingernail, flip up the connector on the PCB, then reseat it with gentle pressure, it engages with a very slight click. • Have sudo apt-get update and sudo apt-get upgrade been run? • Has raspi-config been run and the camera enabled? If things are still not working, try the following: Error : raspistill/raspivid not found. This probably means your update/upgrade failed in some way. Try it again. Error : ENOMEM displayed. Camera is not starting up. Check all connections again. Error : ENOSPC displayed. Camera is probably running out of GPU memory. Check config.txt in the /boot/ folder. The gpu_mem option should be at least 128.

If, after all the above, the camera is still not working, it may have a defect (most likely because it has suffered static shock). Try posting on the Raspberry Pi forum in the camera board section to see if there is any more help available there.

Note:Execute the following instructions on the command line to download and install the latest kernel, GPU firmware and applications. You will need an internet connection for this to work correctly.sudo apt-get update sudo apt-get upgradeIn case the keyboard or mouse is not responding quite well, the supply of the Raspberry is insufficient to sustain the device itself. Get a much higher current power supply(i.e. 10W 5V power supply). During the programing of the prototype, our keyboard is not responding well and we used a different power supply to sustain

Page 4: Configuration Raspi

a bigger power because of the power the USB WIFI is consuming. In another event, we replaced with a compatible keyboard with a low power consumption and replaced the original power supply and everything went well.

Page 5: Configuration Raspi

PRECAUTIONSThe camera board itself is prone to static shock. Avoid touching the board itself when turned ON or even turned OFF. If handling the camera board is unavoidable, use the following steps to avoid or atleast minimize the static electricity in contact with the board:

Wear an Antistatic wrist strap The wrist strap is usually worn on the nondominant hand (the left wrist for a right-handed person). It is connected to ground through a coiled retractable cable and 1 mega ohm resistor, which allows high-voltage charges to leak through but prevents a shock hazard when working with low-voltage parts. Where higher voltages are present, extra resistance (0.75 mega ohm per 250 V) is added in the path to ground to protect the wearer from excessive currents; this typically takes the form of a 4 mega ohm resistor in the coiled cable (or, more usually, a 2 mega ohm resistor at each end).

Use antistatic mat in conclusive of the above device. If the above are not available, release the static by holding a metal

that is with no direct contact to the electric of your workplace and the raspberry and place the metal in a insulative material(big enough to insulate the metal you are using)