We have moved at community.getvera.com

Author Topic: New Device Simulator and Positioning Rules for Plugin Development  (Read 2966 times)

Marc Shenker

  • Guest
Our Dev Team and especially Andrei have been working very hard to create tools for you to make developing plugins easier. These new positioning Rules and the Device Simulator will be part of the 7.05 firmware release.

Lets start with positioning rules:
The controls for generic devices are placed inside the device container based on the order in which are found in device .json file and so, each control is drawn to the right of the previous one. If a control doesn?t fit in the remaining space it will be drawn on the following line. This rule will guarantee that the look of a device will be the same on the Web, but also on the mobile apps.
In order to achieve this, but also to maintain backward compatibility with UI5, the developer can add new properties to the device .json, but doesn?t have to change the existing ones.
The new proprieties are:
- line_break : will force the next items to be displayed on the next line;
- spacer : add space between controls;
- HorizontalMultiplier : used for changing size of controls;
Regarding the compatibility with mobile apps, it is still a work in progress and will be available in a future release.

Also attached are three screenshots for Device Simulator. It will be found on "Apps/Develop Apps"
The other two screenshots are from the actual device simulator, one form the JSON tab where developers can paste the JSON code for their device and see how it will look on Dashboard, and the other is from State tab where you can assign values for variables that will also affect the simulated device. In this case, setting "LoadLevelStatus" variable value to 45 is reflected on simulated device by changing the state of the "on/off" button to ON, slider is set at 45% and the icon is also changed.

Currently these changes will only be reflected in web UI. We are working on the mobile apps implementation but I do not have an ETA at this time.

There are more tools in the works, I will share more details as we get closer to them being available.