Use the System objectΒΆ
Introduction
To display and edit the system settings, the dedicated widgets available in Q Studio can be used, or all the graphic components and logics desired (e.g., linking the DHCP enabled property to the Active property of a Switch) can be manually configured.
In any case, the System object must be configured and, depending on requirements, the DateTimeConfiguration and WiFiConfiguration objects.
Important
use a single System object in the project.
Available widgets
Widget |
Purpose |
---|---|
Display and edit the settings for WAN, LAN and WiFi network interfaces. |
|
Display and edit system date, time and time zone manually or via remote NTP server. |
Create the System object
In Project, right-click Model, then select All > System > System: the System object appears in the project.
Configure the reading of the network interface settings
In the System object, next to the Network interfaces property, click to add a network interface in which to display/edit the settings at runtime.
In the Interface name property, type the desired interface type.
Important
insert the interface types written exactly as in System Manager: LAN, WAN, Wi-Fi.
Repeat steps 1 and 2 for each desired network interface.
Use the HMI50 Network Configurator widget
Click to open the template library, then from Widgets drag HMI50 Network Configurator into Project: the widget appears in the project.
To associate the system settings with the widget, drag the System object on the SystemNode property of HMI50NetworkConfiguratorDialog(type).
At runtime, perform the desired edits, then click Apply.
Use the Date and time configurator widget
Click to open the template library, then from Widgets drag Date and time configurator into Project in the UI folder: the widget appears in the project.
To associate the system settings with the widget, drag the System object on the SystemNode property of DateTimeConfiguratorDialog(type).
At runtime, perform the desired edits, then click Apply: for the date and time changes to take effect, close the application and restart the system (see Create a button to restart the system).
Create a button to restart the system
Create a Button object.
Associate the following methods with a button event, for example MouseUp Event, in the order:
Close global method
Restart method exposed by the System object
See also
Related concepts
References