Mountain Wave Avionics 3.5 EFIS How-To – Part 2
SSH into the unit
Alternate Direct Method
Prior to boot, you’ll need to modify the config.txt file as well as the cmdline.txt file. This alternate method will allow you to access your raspberry pi at “raspberrypi.local”
open the file config.txt with Wordpad. Using Notepad to edit the file will make it hard to tell where the line breaks are, and this file uses line breaks to separate the commands. Scroll down to the bottom of the file and add dtoverlay=dwc2 to a new line
Now open the cmdline.txt file with Notepad. Make sure “Word Wrap” is off to view the file as a single line. You don’t want to add any line breaks to this file. All of the commands need to be in a single line. If you use Wordpad to edit this file, you may create unintentional line breaks, so using Notepad is best. Scroll across the line and find the command rootwait. After the rootwait command, add modules-load=dwc2,g_ether
These instructions were found at the link below:
Wi-Fi Network Method
From Part 1, you should have setup your wpa_supplicant.confg to match your wireless network settings. If so, upon boot your raspberry pi will connect to your wi-fi.
Most home networks don’t support host names, so we’ll need to find the ip address of the raspberry pi and connect to it using it’s IP address.
To find the raspberry pi’s ip address, we need to log into to the router. To find the router’s IP address, go to the network and sharing center, click on your wireless network, then click details. Your DHCP server should be the same as your router.
Next, type that IP address into your web browser. It should launch the configuration page for your router. If you don’t know the password, look at the bottom of your router for a sticker.
Once logged in, you’re looking for DHCP Reservations, or something similar. This will tell us what is connected to our network and what it’s IP address has been assigned.
Scroll down, or look for “Raspberry Pi” and take note of it’s IP address:
In this case, it’s 192.168.0.26
Now we can ssh into it!
I prefer smarTTY ( a Sysprogs smart terminal) but for this demo, we’ll use puTTY. On mac OSX, the stock terminal works great!
puTTY can be downloaded here:
Once you’ve downloaded and installed putty (or the terminal of your choice) SSH away!
Upon successful connection, you should see:
The user name is Pi, and for the mwavoinics image, the password is “blueberry”. For stock Raspberry pi, the password would be “raspberry”
Now you are successfully logged into your flight instrument!
Chances are that the flight instrument is displaying the instrument at the moment.
Let’s stop the program by typing “sudo pkill ExEFIS”
The flight instrument program should have stopped running, and then started again after a few seconds. That’s because we have the LXDE desktop setup to run it during autostart.
To stop it from running on boot (temporarily), we’ll type “ls” to let us see what’s in the home directory, then we’ll type “nano startExEFIS.sh” and edit the start script
Now, put a “#” in front of “sudo /home/pi/ExEFIS” so it won’t run again
Once you’ve done that, hit ctrl O and then ctrl X
Again, type “sudo pkill ExEFIS” to stop the program. It should stay stopped this time:
“ls” again will show us the contents of the home directory. Notice that there isn’t (maybe there is, if you have a newer version of the image) a “sensorcal.txt” file. This is the file that calibrates the drift out of the gyros, the offset out of the accelerometers, and scales and offsets the magnetometer. To create a sensorcal.txt file, type “nano sensorcal.txt”.
A sensorcal.txt looks like this:
How do you come up with your own calibration? Find out in the next post!!!