Orientation sensor connection
Most of you already have an orientation sensor integrated in your smartphone or tablet. You can get the most out of the built-in accelerometer and gyro by using your device as an Ozeki 10 client. Do this by logging in through your browser. The phone collects measurements to the webbrowser's JS and forwards it to your own Ozeki 10 server, which is most likely running on a PC.
In this tutorial you will see how to add an orientation sensor manually and use it on your smart device, which has an integrated accelerometer and gyro. You will find the option available next to many other interesting connections. Keep in mind that your connections can work together in an IoT network, we call Ozeki 10.
Follow these steps
STEP 1: Add Orientation sensor connection
STEP 2: Open Ozeki 10 on your smart device
STEP 3: Test Orientation sensor
Prerequisites
- A smartphone or tablet with an orientation sensor
- Orientation sensor installed on your computer
How to add your orientation sensor
Most of you already have an orientation sensor integrated in your smartphone or tablet. Why not forward your device orientation data to an IoT network? An easy way to control software and hardware no man ever controlled before. Ozeki 10 can connect your orientation data to everything you have programmed or built.
Take in hand your Ozek 10 client, which can be a smartphone, tablet, PC or laptop. Using a mouse is the quickest way to reach your goal, which makes the PC the best choice to add your connections.
STEP 1: Add Orientation sensor connection
First you need to know that every connection can be viewed at a single place, called the 'Control Panel'. Simply start Ozeki 10 and reach the 'Control Panel' from the desktop GUI (Figure 2)
Now that you are in the 'Control Panel', please click the big blue 'Create new Connection' button as seen on Figure 3. On the right side of the page a typeselector window will open. It provides various connection types.
Please select 'Sensor' (Figure 3).
The Orientation sensor works with JavaScript codes running in your browser.
Please select 'Browser sensor' (Figure 4).
Finally select 'Orientation' (Figure 5) to enter sensor configuration.
Click 'Ok' to create the 'Orientation' connection (Figure 6). You can set the threshold later on when testing the sensor.
You can see the connection added to the 'Connections' list (Figure 7).
Basicly it is faster to add your connection with PC or laptop. Although the yellow exclamation mark will show that the Ozeki 10 client doesn't have an integrated accelerometer and gyro. If you have done STEP 1 on your smart device, you shouldn't see the yellow exclamation mark as seen above on Figure 7 and you can jump to STEP 3.
STEP 2: Open Ozeki 10 on your smart device
If you have worked on a PC like we did, please take your smart device in your hands. Shut down the firewall of the machine running Ozeki 10's service, so you can login through other devices. Look at the IP address and port number of your Ozeki 10 service (Figure 7, above) and type these details into your smartphone's browser.
On your smartphone or tablet you will find yourself on Ozeki 10's login screen. Please provide the same login credentials used before and click 'Ok' to continue (Figure 8). The smart device will serve as an Ozeki 10 client.
STEP 3: Test Orientation sensor
Since you already started the 'Control Panel' in STEP 1. You will see it on the system tray. User states and settings are always stored by Ozeki 10, which means the state of the system tray and the icon positions are stored as well. Click on the icon (Figure 9) to find the orientation sensor connection you have already added to your Ozeki 10 server.
On the connection list click the orientation sensor connection (Figure 10)
On the sensor screen you can see the orientation of your tablet or mobile phone (Figure 11).
Forward orientation data
Later on you can route orientation data to any Ozeki 10 connection (Figure 12). You can choose from a huge list of connections to make routing to. Keep in mind that Ozeki 10 is a messaging platform. It can send messages between more and more connections of the IoT world. Although C# coding in Ozeki Robot Controller is the smartest way to create routes.
More information