Automation Connect IQ SDK

Regarding setting-related menu operations.
The first half is the same as the code at the beginning here.
Only the subsequent simulator operation part is described here.

# Toggle type menu ON / OFF
$sim.ToggleMenu([Simulator+SettingToggleMenu]::Vibrate, $true);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::ActivityTracking, $false);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::DoNotDisturb, $true);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::LowPowerMode, $false);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::SleepMode, $true);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::Tones, $false);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::UseDeviceHTTPSRequirements, $true);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::AppLockEnabled, $false);
$sim.ToggleMenu([Simulator+SettingToggleMenu]::EnableAlert, $true);

# Language settings

# BLE / Wifi connection type and status

# 12/24 time designation

# unit

# Setting the first day of the week

# Set the notification type to receive
  • Lines 2-10: Menu settings with check ON / OFF
    The second argument is used to set whether to check or not.
  • Line 13: Language settings
    The return is a bool type.
    This is because it seems that the language that can be set is determined by the model, and I wanted to be able to recognize it as an error if the wrong language was specified.
    If it cannot be set, $ false is returned.
  • 21st line: 12-hour display, 24-hour display switching setting
    If $ true, 24-hour display is specified.
  • Line 24: Unit setting
    If $ true, it will be in metric notation.
  • Line 27: Set the first day of the week.
    Settable is DayOfWeek enum type and Saturday, Sunday, Monday.