Step 4: Connect Peripherals and Initial Configuration
Connect Peripherals
Now that we have a working microsdhc flash card with the Raspbian OS, we want to insert it into the Pi, as well as connect our other peripherals and power.
- Remove the microsdhc card from the adapter.

With the power supply NOT connected, insert the microsdhc card into the Pi.
- Note that it may help to turn the Pi over.

- With the power supply NOT connected to a wall-socket, connect the power, monitor, USB keyboard, and USB mouse.

- Plug-in the power-supply to a wall-socket and wait for the Pi to boot.

Pi Initial Configuration
The Raspbian OS needs some initial configuration to set things such as your location and to connect to a WiFi network.
- Click Next on the initial Raspbian start pop-up.
- Set your Country, Language, TimeZone, Use English language (if applicable), and Use US keyboard (if applicable), then click Next.

- Enter and Confirm a new password, then click Next.

- If applicable, check the This screen shows a black border around the desktop checkbox, and click Next.

- Select an appropriate WiFi network, and click Next.

- Enter the WiFi password, and click Next.

On the Update Software screen, it is recommended to click Skip.
- If you have a microsdhc card with 16GB or more, then you may click Next to peform an OS update.
- Note that this process may be time-intensive... 30+ minutes.

- If you performed an OS update, and it has completed with a System is up to date pop-up, click OK.

When the Setup is complete, click Restart.
- After the reboot, you will be automatically re-logged into Raspbian.

Step 5: Install EMS
Now that the Pi is fully setup, you want to download the Edge MicroServer (EMS) onto the Pi.
- On the Raspberry Pi, open a web browser and navigate to this guide, then download MED-61060-CD-054_SP10_Microserver-Linux-arm-hwfpu-openssl-5-4-10-1509.zip.
- Click the download's options drop-down, and select Show in folder.


- Right-click on the .zip file and select Extract Here.


- Navigate into the newly-extracted /microserver folder.

The primary executables which enable the EMS functionality are the following:
File Name | Description |
wsems | An executable file that runs the Edge MicroServer. |
luascriptresource | The Lua utility that is used to run Lua scripts, configure remote things, and integrate with the host system. |
Create Additional Directories
New folders may be added to the /microserver directory for various purposes.
Some of these will be utilized within this guide, while others may be utilized in future guides using the EMS.
- In the /microserver folder, create a /logs directory.
- Create a /other directory.
- Create a /staging directory.
- Create a /tw directory.
- Create a /updates directory.

Create Test Files
It can also be helpful during testing to have some small files in these folders to further demonstrate connectivity.
As these files were custom-created for the guide, seeing them within ThingWorx Foundation ensures that the connection between Foundation and the EMS is real and current.
- In the /tw directory, create a text file named tw_test_01.txt.
- In the /other directory, create a text file named other_test_01.txt.

Click here to view Part 3 of this guide.