# ASPi - Software Installation Steps
(internal document for the time being)
## Phase 1: On your computer
1. Download the raspberry pi image from
https://files.janastu.org/s/D6ga9aNWLxP7JGg
2. Burn the image on a **class 10 microSD** card. **Minimum size 16GB**. For burning
* On ubuntu - use *startup disk creator*
* On windows and other OSs including ubuntu - download *raspberry pi imager*
https://www.raspberrypi.org/software/
## Phase 2: With the Raspberry Pi
### A: If you have Screen, Keyboard, and Mouse
1. Connect your pi to screen, keyboard, and mouse (minimum)
Optionally you can connect speakers and camera too
2. Insert the microSD card in the pi and now power it on.
**Note:** Once powered on, there should be **no interruption in power for** the next **5 mins**. If there is a break in power, you will likely have to restart from *Phase 1 - Step 2*
4. It will restart a couple of times. Let it stabilize. Go to [Phase 3](#Phase-3:-The-setup-script).
### B: If you do not have Screen, Keyboard, and Mouse
1. Insert the microSD card in the pi and then power it on.
**Note:** Once powered on, there should be **no interruption in power for** the next **5 mins**. If there is a break in power, you will likely have to restart from *Phase 1 - Step 2*
2. You will have to access the pi from your laptop using VNC Viewer. Download from below link and install
https://www.realvnc.com/en/connect/download/viewer/
3. To connect to the pi using VNC, we will need
1. [pi and your computer to be on the same network](#3.a.-To-connect-pi-with-computer)
2. [hostname/IP address and password of the pi](#3.b.-Hostname-and-Password-of-the-Pi)
4. After you successfully log in to the pi using VNC, go to [Phase 3](#Phase-3:-The-setup-script)
#### 3.a. To connect pi with computer
There are two ways to do it
1. Ethernet
1. You can connect the pi to your router via ethernet cable
2. Your computer should be connected to the same network either via ethernet or via WiFi
2. WiFi
The pi will automatically connect to a WiFi signal with SSID **cowifi** and password **2143658709**
1. Change your mobile hotspot/wifi tethering settings to the above specs
2. Turn on the mobile hotspot
3. In about 10 seconds or more, you should see a device connected to your hotspot
#### 3.b. Hostname and Password of the Pi
1. Hostname
The hostname of the pi will be of the form **cowpi-xxxx** where **xxxx** is the last 4 digits of the MAC id. To identify the **xxxx**
1. If the pi is connected via **Ethernet** then go to your router page and look for connected clients. You will get hostname and ip address. You can use either.
2. If the pi is connected via **WiFi** then go to mobile hotspot settings page. In the list of connected devices you should find hostname/ip address.
* If no details are given under connected devices, you could scan for devices under Bluetooth in your phone. The pi's bluetooth name and hostname are the same
* If nothing shows up on bluetooth scan, then restart pi (by powering off and on) and start scan after 30s.
3. Password - ping on Telegram or send an email to anyone from **janastu** team.
## Phase 3: The setup script
1. Once booted and stable, open your terminal (by pressing Ctrl+Alt+T) and execute the following command
> `bash <(curl -sSL https://gitlab.com/jivjanastu/cowpi/setup/-/raw/master/install.sh)`
<style type="text/css">
ol {list-style-type: decimal;}
ol ol {list-style-type: lower-alpha;}
</style>