[PYTHON] Use Remotte as a user

[Last time](https://qiita.com/remotte_jp/items/324f99727c68392b80e5 "I tried running the app on the IoT platform" Rimotte "") tried running the app on the management tool. This time it is more practical. As a usage method, try using it from an Android and iOS device as a user while the application is running on the station.

Rimotte divides users into three categories: users, administrators, and developers. It is positioned as the role of the "administrator" to prepare the station, install the application, and manage the execution, which has been done so far. On the other hand, "users" are the ones who let you do what you want, regardless of where the app is running or how it runs. A "developer" is a person who modifies an app or component downloaded from the "Rimotte Store" or writes Python code to create a new app. Most people reading Qiita fall into all three.

Preparation

Check your web browser! </ strong> </ font> Limotte uses a peer-to-peer communication technology called WebRTC to connect a web browser and a station directly without going through a server, but due to the adult circumstances of each browser manufacturer, we support this technology. Some are present and some are not supported. When you open the User Guide on the Limotte website, the supported browser types are written, and at the moment it is as follows. .. Windows: Chrome (recommended), new Microsoft Edge (* 1), Firefox    MacOS : Safari Linux: Chrome (recommended), Firefox Android: Chrome (recommended), Firefox    iOS : Safari

  • 1 The function that handles voice may not work properly. Please note that it will not work properly with browsers other than these.

To log in as a user, access the [Homepage] of Rimotte (https://www.remotte.jp "Rimotte Technologies Co., Ltd.") and press the "Login" button at the top right of the screen. image.png image.png Then, as mentioned above, you can see that you can log in in three ways, but be careful here. As will be explained later, in Limotte, the user is specified by an email address. There is no problem when logging in with a "Google account", but when logging in with facebook or Twitter, if only the phone number and user name are registered, it is necessary to register the email address in advance.

Set the user's email address

Let's go back to the management tool and set the "Station Management" app we used last time as an example. Enter the details screen of the app and open the "Usage Page" tab. On the left side of the screen, there are three usage page "current status", "log", and "control" selection menus, and on the right side, each "user", "display item", and "layout" can be displayed. If you select the "Users" tab here, you can set the users who can access the selected page. image.png By default, as mentioned above, only the administrator can use it. Here, click the "Add User" button at the top right of the screen to add another email address. image.png In the above example, I added the email address "[email protected]". Next, select "Log" from the menu on the left side of the screen. image.png On this screen, the slide switch to the left of the newly added email address is off. Similarly, it is turned off when the "Control" page is selected from the menu on the left side of the screen. With this on / off switch, you can set whether to allow a specific user to access each usage page (display or not), and if so, the switch is on the right side, so it is not allowed. If there is, switch to the left side. When you're done, press the "Save" button at the top of the screen, then the "Start" button to run the app.

User login

Now let's log in as a user. This time, I will try using an Android tablet (hereinafter, the margin part of the screen is omitted and attached). image.png On the screen above, click one of the buttons and enter your ID, phone number, and password. image.png If the login is successful, the license agreement will be displayed. Read it carefully and if there are no problems, select the check box and press the "OK" button. image.png When you log in for the first time as a user or when a new station is added, the above screen will be displayed. Press the menu button on the upper left of the screen according to the displayed contents. image.png Press the name of your station that says "Unapproved Station". image.png When the "Approve Station" dialog appears, select "Trust Connect and View Page" at the top. image.png Then, you will be able to display the usage page permitted by the management tool.

If you cannot connect normally

With the peer-to-peer communication technology called WebRTC adopted by Limotte, the station and the user may not be able to connect correctly depending on the network environment. In such a case, errors such as "Available page not found", "Unable to connect station", and "P2P establishment failure" are displayed as shown below. image.png image.png

For example, in a network environment that can be used in public Wi-Fi, cafes, and libraries, routers are set so that devices connected to the same network cannot connect to each other. In this case, for example, you can avoid it by setting VPN on both the station and the terminal you are using, but I will explain it if there is an opportunity.

Summary

As mentioned above, I tried using Limotte as a user. Next time will try using the details screen of the usage page. Let's perform an operation to display the data acquired and accumulated by the application neatly in chronological order using a line graph or table.

Recommended Posts