Issues ranging from Auto-start to scripts to wlan0 to I don't know what else

Disclaimer, Complete newbie to the world of Raspberry Pi. I have enough experience googlefu-ing my way around problems but constantly failing has lead me to ask on the forum.

My week has consisted of experimenting on a friends R-pi1 through Ethernet. And now just recently getting an Raspberry Pi zero Wireless. Below are the steps + issues I have encountered, not included the actual amount of time and face palm moments. Each problem encountered has lead to me try a different route.

###Raspberry Pi 1 Model B

  • Install Hassbian using etcher and SSH’ing into the unit.
  • Run Home assistant, update .yaml file reboot Rpi (installed yaml script no problem)
  • Home assistant didn’t come up, PANIC. (Find out later this is due to Auto-start not working)
  • Start home assistant through SSH: Laptop goes to sleep and home assistant stops working.
    Once again learn something new, when SSH instance is turned off so is what ever was in said instance.

###Part 2 of Raspberry Pi Model B

  • Reflash card with Rassbian Lite and connect via ssh
  • Follow step by step instructions to install Home Assistant
  • Start and Run Home assistant
  • Go to install yaml script. Can’t do it. I dont remember the exact error, however it was something along the lines of home assistant script doesnt exist. I tried to install the script through both the Pi and the (homeassistant) homeassistant user accounts with similar results.
  • Give up on yaml script, try and get home assistant to auto start with daemon instructions. “Hass” can not be found. Use whereis
whereis hass
hass:
  • Cant find anything in documentation about this, Give up until Pi Zero wireless comes in the mail.

###Pi Zero Wireless

  • Exact Repeat of part 2 above. With the added steps of setting up wireless networking via wpa_supplicant.conf file
  • Go binge eat crummy fast food to forget this shitshow.

###Part 2 of Pi Zero Wireless

  • This time we’re gonna try the Hassbian image, maybe, just maybe this will work.
  • Update wpa_supplicant.conf file.

ifconfig

  • No wlan0 listed at all. Only the i0 or l0
  • Give up, post this exessivly long post and hope someone out there can help me in my plight.

Thanks for reading, and any input would be appreciated. I’ve tasted the home assistant life (basic hue card came up) and I really do want this to work.

Hmmm Seems familiar :stuck_out_tongue:

I started out with 2 RPI1MB and quickly decided to try a RPI3MB for pretty much the above reasons. My take on it is get the networking working 1st, the rest is easy :P, just use the AIO install (All In One) tho’ that has it’s own problems :stuck_out_tongue: Mainly to do with permissions and the environment!

Google is your friend for setting up the WIFI networking and Bluetooth plus of course the forums here :slight_smile:

I have no experience with a PI0 but the steps should be the same as for a RPI3…

This is what I did for a RPI3…
PI - update firmware
sudo rpi-update

To upgrade PI
sudo apt-get update
sudo apt-get upgrade --fix-missing
sudo apt-get clean
sudo apt-get autoremove

WIFI setup

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
add network={ssid="your_network_ssid" psk="your_pw"}
sudo nano /etc/network/interfaces
add
####################
#; start of wireless bits
#; this command stays for all configs
allow-hotplug wlan0
auto wlan0
###################
#; comments indicated by #;
#; commands indicated by #
#; remove the # to enable the command
####################
#; if using static IP then....#
#iface wlan0 inet static
# address UR_IP
#gateway UR_ROUTER_IP
#netmask 255.255.255.0
##################
#; otherwise use dhcp #
iface wlan0 inet dhcp
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
###################
#; OPEN wireless config #
#wireless-essid UR_ESSID
#wireless-mode managed

###################
#; WEP wireless config #
wireless-essid "Home2"
wireless-key "budshavenude"
#; end of WEP config

########################
#; WPA and WPA2 wireless config #
#; all command config lines above HERE to be #'ed except the entry auto wlan0
########################
#wpa-driver wext
#wpa-ssid UR_ESSID
#; wpa-ap-scan is 1 for visible and 2 for hidden hubs

sudo systemctl restart wpa_supplicant
sudo ifdown wlan0
sudo ifup wlan0
#restart the network software
sudo /etc/init.d/networking restart

Of course this depends how your network is setup ie. static or dynamic IP’s etc, my setup is dynamic IP’s but then I set up the router to always serve the same IP forever :stuck_out_tongue:

Anyway the important thing is to NEVER give up and have fun!

Hope this helps a bit :slight_smile: