CTS – Your Technology Partner

Raspberry Pi – Delicious Dessert or Door to the Future?

Written by Wayne Keadle on January 6, 2016

The Internet of Things (IoT) is quite the buzz in the modern day of Geekdom. IoT is the networking of any sensor, software or electronic device. The devices or “things” manage other “things” through the Internet, which is obviously a very large network. Can you imagine a world where all electronic devices and software communicate with each other? Many of these devices are embedded systems; systems in which the operating system on a device performs a particular task or function. DVD players, microwave ovens or the computers in your cars are just a few examples.

The Raspberry Pi is one of these devices.  It is a computer in the palm of your hand. This device has PINs that can interface with embedded or complex systems. The PINs send signals to the other devices to control them. I can turn the lights on/off in my house, create a menu on my TV (which interfaces with my DVD player), or watch a live video from a camera attached to the Pi.

This blog is part of a two part series about the Raspberry Pi.  Part 1 will explain how to install Windows 10 on this device, the first step in connecting your “things” to other “things.” Part 2 will explain how to create the demo program.

To get me started on my mission, I did some research and found some information on Microsoft’s web site.  After reading up on the process, I was ready for the next step – shopping!

I went to Frye’s and purchased the following hardware: 1 Raspberry Pi 2, a Micro SD card with an adapter, an LED, a resistor, a small breadboard, and some jumpers to wire the circuit. The total cost was about $70. The picture below contains only the Raspberry Pi and the SD card.

Raspberry Pi

I then downloaded the Windows 10 IoT Core image from this site. Under the section, Download Windows 10 IoT Core, I selected the blue button/link for Raspberry Pi 2. Once the download was complete, I double clicked the ISO, and Windows 10 mounted the image automatically. Next, I selected the MSI package and the program installed two utilities on my system: Windows IoT Core Image Helper and Windows IoT Core Watcher. These programs help set up the image on the SD card and connect to the Raspberry Pi. Next, I inserted the SD card into my Windows 10 computer. I launched the Windows IoT Core Image Helper program, which detected the SD card and appeared in the top window. I browsed to the .ffu image, which is usually at the following location: “C:\Program Files (x86)\Microsoft IoT\FFU\RaspberryPi2\flash.ffu”.  I selected the Flash button and the program flashed the Windows 10 Operating System onto the SD card.

IoT

A word of warning here – note the red circle around the word Lock for the SD card?

MicroSD card

The card must be unlocked in order to flash the OS onto the SD card. If the slide is in the “Lock” position, you will receive an error when the program tries to flash the drive.

Finally, after the program finished flashing the drive, I inserted the micro SD card into the Raspberry PI, and connected any peripherals: monitor (HDMI), keyboard(USB), mouse(USB), network cable, and the Micro USB adapter to power the device. Once the Micro USB was connected, the device booted right up. Conveniently, the flash drive contains a default program that automatically launches when the device powers on. For this first time though, the device took about 10 minutes to finish booting up and to start the first application. Patience is key during the initial set up.  It boots much faster after the first time.  Below is a screen shot of the device connected to my TV.

Raspberry Pi set up

After the application launches, a celebration is in order! Trust me, you deserve it! I highly recommend the “Centipede (Worm)” dance; see here for instruction/demonstration. Go ahead and dance – no one is watching.

After the Pi is running, there are two ways to manage the device: Windows Device Portal and PowerShell. A simple way to access the Windows Device Portal is to launch the Windows IoT Core Watcher, select your PI that is running, right click and select the “Web Browser Here” option.

IoT Core Watcher

The default browser will open after you enter your credentials: username – administrator, and password –  p@ssw0rd. I recommend you change the credentials once you are connected. The browser has numerous options to manage your device.

screen shot PI

The power shell option is all command line. There are several commands in order to connect to the device. First, the WinRM service must be running on your PC. Second, establish a trust between your computer and the Pi. Third, create a session between the Pi and your computer. Here is a screen shot of what my PowerShell session looked like after I connected with my device. Notice at the command prompt that the name of my Pi device appears “RaspWin10”.

screen shot PI command prompt

That’s it for now!  Join me for Part 2 that will depict my journey with writing the first demo app.

Comments

comments