Design Project 2 Documentation - RichardSwierk/Champlain-Capstone GitHub Wiki
Installing OS on micro sd card
-
Get your micro sd card, micro sd carb reader/writer, and windows 10 computer
-
Insert the micro sd card into the micro sd card reader/writer
-
Plug the male USB type A end of the micro sd card reader/writer into the female USB type A port in your computer
-
On your computer go to the following url: https://downloads.raspberrypi.org/imager/imager_1.4.exe
-
When a pop up box appears click on the Save File button
-
Open File Explorer
-
In File Explorer in the left column under This PC click on Downloads
-
In the right column double click on the file named imager_1.4
-
A User Account Control pop up will appear. Click Yes on this pop up
-
Raspberry Pi Imager Setup will then open
-
Click on the Install button and then wait
-
When Raspberry Pi Imager is finished installing you will see the following
-
Click on the button that says Finish
-
On the bottom of your screen you will see the following icon
-
Click on the icon to open Raspberry Pi Imager
-
Next Click on the button that says CHOOSE OS
-
Select the second option, Raspberry Pi OS (other)
-
Then select Raspberry Pi OS Lite (32-bit)
-
Click on the button that says CHOOSE SD CARD
-
Select your sd card from the list
-
Click on the button that says WRITE
-
A Warning pop up will appear. Click the button that says YES
-
When the OS is successfully written to your sd card you will see the following
-
Click the button that says CONTINUE
-
Click on the X in the top right corner of Raspberry Pi Imager
Setup OS on Raspberry pi
- Take the micro sd card and insert it into the micro sd card slot on the raspberry pi
- Take your micro usb cable to usb female cable and plug the micro usb male connector into the micro usb female connector on the raspberry pi that says PWR IN above it
- Plug your usb wall charger into an outlet
- Plug the usb male connector on the micro usb to usb male cable into the female usb connector on the usb wall charger
- Get your hdmi male to hdmi female cable and monitor/tv
- Connect the hdmi male connector into the hdmi female connector on the monitor/tv
- Connect the hdmi male connector into the hdmi female connector on the raspberry pi
- Power on the monitor/tv
- Get your usb keyboard and connect its usb male connector into a usb female connector on the raspberry pi
- Wait until you see a login prompt on the monitor
- Enter the default credentials for raspbian OS (username: pi, Password: raspberry)
Create new user
-
To create a new user type in the following command change 'username' to the username you want to use
sudo useradd username
-
Next enter the password that you want to use with the new user
-
You will then be prompted to enter the password again
-
Next you will be asked for Full Name, Room Number, Work Phone, Home Phone, Other. Press Enter on each one of these to enter nothing
-
Then you will be asked if the information is correct. Enter Y and then press Enter
-
You have finished creating your new user
Delete pi user
- First you will need to reboot the raspberry pi. Use the following command
sudo reboot
- Wait for the system to finish booting and login using your new user credentials
- To delete the pi user enter the following command
sudo deluser pi
- You will be prompted to enter your users password
- Pi user has now been deleted
Connect raspberry pi to the internet
-
Enter the following command to open the raspberry pi configuration tool
sudo raspi-config
-
Enter your password when prompted to do so
-
Your screen should show the following
-
Hit the down arrow key and then press enter. This will take you to the Network Options
-
Hit the down arrow key and then press enter. This will take you to setup a Wireless LAN connection
-
When it says "Please enter SSID" enter the name of the network that you wish to connect to then press enter
-
Next enter the password to the network that you wish to connect to and press enter
-
You have successfully connected your raspberry pi to the internet
Change the hostname
-
Enter the following command to open the raspberry pi configuration tool
sudo raspi-config
-
Enter your password when prompted to do so
-
Your screen should show the following
-
Hit the down arrow key and then press enter. This will take you to the Network Options
-
Click enter to enter Hostname setup
-
You will get the following prompt. Click enter on
-
When you see "Please enter a hostname" type in Capstone then press enter
-
You have successfully changed the hostname of the raspberry pi
Enable ssh
-
Enter the following command to open the raspberry pi configuration tool
sudo raspi-config
-
Enter your password when prompted to do so
-
Your screen should show the following
-
Click the down arrow key four time and press enter. This will take you to the Interfacing Options
-
Click the down arrow key once and press enter. This will take you to the SSH configuration
-
When you see the following press the left arrow key and click enter. This will enable ssh
-
The following will appear. Click enter
-
You have successfully enabled ssh on the raspberry pi
Install software
usbmon = tool used to get data being sent over usb
python = the language the code for this project will be written in
pip = used to install python packages
usbmon-tools = python package to make interfacing with usbmon easier
usbmon
- Use the following command to load usbmon:
sudo modprobe usbmon
- mount debugfs to /sys/kernel/debug:
sudo mount -t debugfs none_debugs /sys/kernel/debug
python
1.Install python with the following command:
sudo apt-get install python -y
pip
- Install pip with the following command:
sudo apt-get install python3-pip python-pip -y
usbmon-tools
- Install usbmon-tools python package with the following command:
sudo python3 -m pip install usbmon-tools