xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:SpeedportHybridControl"
- xmlns:model="clr-namespace:SpeedportHybridControl.model"
+ xmlns:model="clr-namespace:SpeedportHybridControl.Model"
StartupUri="MainWindow.xaml">
<Application.Resources>
<ResourceDictionary>
<model:MainWindowModel x:Key="MainWindowModel"></model:MainWindowModel>
+
+ <model:Status x:Key="Status"></model:Status>
+ <model:LTE x:Key="LTE"></model:LTE>
+ <model:LTE x:Key="LTE2"></model:LTE>
+ <model:DSLViewModel x:Key="DSL"></model:DSLViewModel>
+ <model:SyslogData x:Key="SyslogData"></model:SyslogData>
+ <model:TR181 x:Key="TR181"></model:TR181>
+ <model:PhoneCallData x:Key="PhoneCallData"></model:PhoneCallData>
+ <model:DeviceData x:Key="DeviceData"></model:DeviceData>
+ <model:OverviewModel x:Key="OverviewModel"></model:OverviewModel>
</ResourceDictionary>
</Application.Resources>
</Application>
</Style>
</StackPanel.Resources>
- <Button IsEnabled="True" Background="LightGreen" Click="button_click" x:Name="btnLogin" Content="Login"/>
- <Button IsEnabled="True" Background="LightGray" Click="button_click" x:Name="btnStatus" Content="Status"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnOverview" Content="Overview"/>
- <Button IsEnabled="{Binding Path=ButtonDSLPageIsActive}" Command="{Binding Path=SwitchToDSLPage}" Background="LightGray" x:Name="btnDsl" Content="DSL"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnLteInfo" Content="LteInfo"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnSyslog" Content="Syslog"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnTR181" Content="TR-181"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnPhone" Content="Anrufe"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnLan" Content="Lan"/>
- <Button IsEnabled="False" Background="LightGray" Click="button_click" x:Name="btnControls" Content="Controls"/>
+ <Button Command="{Binding Path=SwitchToLoginPage}" Background="LightGreen" x:Name="btnLogin" Content="Login"/>
+ <Button Command="{Binding Path=SwitchToStatusPage}" Background="LightGray" Click="button_click" x:Name="btnStatus" Content="Status"/>
+ <Button Command="{Binding Path=SwitchToOverviewPage}" IsEnabled="{Binding Path=ButtonOverviewPageIsActive}" Background="LightGray" x:Name="btnOverview" Content="Overview"/>
+ <Button Command="{Binding Path=SwitchToDSLPage}" IsEnabled="{Binding Path=ButtonDSLPageIsActive}" Background="LightGray" x:Name="btnDsl" Content="DSL"/>
+ <Button Command="{Binding Path=SwitchToLteInfoPage}" IsEnabled="{Binding Path=ButtonLteInfoPageIsActive}" Background="LightGray" x:Name="btnLteInfo" Content="LteInfo"/>
+ <Button Command="{Binding Path=SwitchToSyslogPage}" IsEnabled="{Binding Path=ButtonSyslogPageIsActive}" Background="LightGray" x:Name="btnSyslog" Content="Syslog"/>
+ <Button Command="{Binding Path=SwitchToTR181Page}" IsEnabled="{Binding Path=ButtonTR181PageIsActive}" Background="LightGray" x:Name="btnTR181" Content="TR-181"/>
+ <Button Command="{Binding Path=SwitchToPhonePage}" IsEnabled="{Binding Path=ButtonPhonePageIsActive}" Background="LightGray" x:Name="btnPhone" Content="Anrufe"/>
+ <Button Command="{Binding Path=SwitchToLanPage}" IsEnabled="{Binding Path=ButtonLanPageIsActive}" Background="LightGray" x:Name="btnLan" Content="Lan"/>
+ <Button Command="{Binding Path=SwitchToControlsPage}" IsEnabled="{Binding Path=ButtonControlsPageIsActive}" Background="LightGray" x:Name="btnControls" Content="Controls"/>
</StackPanel>
<Button Command="{Binding Path=SwitchToAboutPage}" IsEnabled="True" Background="LightGray" x:Name="btnAbout" Content="Über" VerticalAlignment="Top" HorizontalAlignment="Right" Width="32" Margin="0,0,3,0"/>
--- /dev/null
+namespace SpeedportHybridControl.Model {
+ class DSLViewModel : SuperViewModel {
+ private Connection _Connection;
+ private Line _Line;
+ private string _datetime;
+
+ private string _lastCRC;
+ private string _lastHEC;
+ private string _lastFEC;
+
+ public Connection Connection {
+ get { return _Connection; }
+ set { SetProperty(ref _Connection, value); }
+ }
+
+ public Line Line {
+ get { return _Line; }
+ set { SetProperty(ref _Line, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public string lastCRC {
+ get { return _lastCRC; }
+ set { SetProperty(ref _lastCRC, value); }
+ }
+
+ public string lastFEC {
+ get { return _lastFEC; }
+ set { SetProperty(ref _lastFEC, value); }
+ }
+
+ public string lastHEC {
+ get { return _lastHEC; }
+ set { SetProperty(ref _lastHEC, value); }
+ }
+}
+
+ class Connection : SuperViewModel {
+ private string _dsl_operaing_mode;
+ private string _path_mode;
+ private string _state;
+ private string _training_results;
+ private string _mode_lo;
+ private string _vpi_vpc;
+
+ public string dsl_operaing_mode {
+ get { return _dsl_operaing_mode; }
+ set { SetProperty(ref _dsl_operaing_mode, value); }
+ }
+
+ public string path_mode {
+ get { return _path_mode; }
+ set { SetProperty(ref _path_mode, value); }
+ }
+
+ public string state {
+ get { return _state; }
+ set { SetProperty(ref _state, value); }
+ }
+
+ public string training_results {
+ get { return _training_results; }
+ set { SetProperty(ref _training_results, value); }
+ }
+
+ public string mode_lo {
+ get { return _mode_lo; }
+ set { SetProperty(ref _mode_lo, value); }
+ }
+
+ public string vpi_vci {
+ get { return _vpi_vpc; }
+ set { SetProperty(ref _vpi_vpc, value); }
+ }
+ }
+
+ class Line : SuperViewModel {
+ private string _uactual;
+ private string _dactual;
+ private string _uattainable;
+ private string _dattainable;
+ private string _uSNR;
+ private string _dSNR;
+ private string _uSignal;
+ private string _dSignal;
+ private string _uLine;
+ private string _dLine;
+ private string _uBIN;
+ private string _dBIN;
+ private string _uFEC_size;
+ private string _dFEC_size;
+ private string _uCodeword;
+ private string _dCodeword;
+ private string _uInterleave;
+ private string _dInterleave;
+ private int _uCRC;
+ private int _dCRC;
+ private int _uHEC;
+ private int _dHEC;
+ private int _uFEC;
+ private int _dFEC;
+
+ private double _uCRCsec;
+ private double _dCRCsec;
+ private double _uHECsec;
+ private double _dHECsec;
+ private double _uFECsec;
+ private double _dFECsec;
+
+ public string uactual {
+ get { return _uactual; }
+ set { SetProperty(ref _uactual, value); }
+ }
+
+ public string dactual {
+ get { return _dactual; }
+ set { SetProperty(ref _dactual, value); }
+ }
+
+ public string uattainable {
+ get { return _uattainable; }
+ set { SetProperty(ref _uattainable, value); }
+ }
+
+ public string dattainable {
+ get { return _dattainable; }
+ set { SetProperty(ref _dattainable, value); }
+ }
+
+ public string uSNR {
+ get { return _uSNR; }
+ set { SetProperty(ref _uSNR, value); }
+ }
+
+ public string dSNR {
+ get { return _dSNR; }
+ set { SetProperty(ref _dSNR, value); }
+ }
+
+ public string uSignal {
+ get { return _uSignal; }
+ set { SetProperty(ref _uSignal, value); }
+ }
+
+ public string dSignal {
+ get { return _dSignal; }
+ set { SetProperty(ref _dSignal, value); }
+ }
+
+ public string uLine {
+ get { return _uLine; }
+ set { SetProperty(ref _uLine, value); }
+ }
+
+ public string dLine {
+ get { return _dLine; }
+ set { SetProperty(ref _dLine, value); }
+ }
+
+ public string uBIN {
+ get { return _uBIN; }
+ set { SetProperty(ref _uBIN, value); }
+ }
+
+ public string dBIN {
+ get { return _dBIN; }
+ set { SetProperty(ref _dBIN, value); }
+ }
+
+ public string uFEC_size {
+ get { return _uFEC_size; }
+ set { SetProperty(ref _uFEC_size, value); }
+ }
+
+ public string dFEC_size {
+ get { return _dFEC_size; }
+ set { SetProperty(ref _dFEC_size, value); }
+ }
+
+ public string uCodeword {
+ get { return _uCodeword; }
+ set { SetProperty(ref _uCodeword, value); }
+ }
+
+ public string dCodeword {
+ get { return _dCodeword; }
+ set { SetProperty(ref _dCodeword, value); }
+ }
+
+ public string uInterleave {
+ get { return _uInterleave; }
+ set { SetProperty(ref _uInterleave, value); }
+ }
+
+ public string dInterleave {
+ get { return _dInterleave; }
+ set { SetProperty(ref _dInterleave, value); }
+ }
+
+ public int uCRC {
+ get { return _uCRC; }
+ set { SetProperty(ref _uCRC, value); }
+ }
+
+ public int dCRC {
+ get { return _dCRC; }
+ set { SetProperty(ref _dCRC, value); }
+ }
+
+ public int uHEC {
+ get { return _uHEC; }
+ set { SetProperty(ref _uHEC, value); }
+ }
+
+ public int dHEC {
+ get { return _dHEC; }
+ set { SetProperty(ref _dHEC, value); }
+ }
+
+ public int uFEC {
+ get { return _uFEC; }
+ set { SetProperty(ref _uFEC, value); }
+ }
+
+ public int dFEC {
+ get { return _dFEC; }
+ set { SetProperty(ref _dFEC, value); }
+ }
+
+ public double uCRCsec {
+ get { return _uCRCsec; }
+ set { SetProperty(ref _uCRCsec, value); }
+ }
+
+ public double dCRCsec {
+ get { return _dCRCsec; }
+ set { SetProperty(ref _dCRCsec, value); }
+ }
+
+ public double uHECsec {
+ get { return _uHECsec; }
+ set { SetProperty(ref _uHECsec, value); }
+ }
+
+ public double dHECsec {
+ get { return _dHECsec; }
+ set { SetProperty(ref _dHECsec, value); }
+ }
+
+ public double uFECsec {
+ get { return _uFECsec; }
+ set { SetProperty(ref _uFECsec, value); }
+ }
+
+ public double dFECsec {
+ get { return _dFECsec; }
+ set { SetProperty(ref _dFECsec, value); }
+ }
+ }
+}
--- /dev/null
+using System.Collections.Generic;
+
+namespace SpeedportHybridControl.Model {
+ public class DeviceData : SuperViewModel {
+ private List<DeviceList> _deviceList;
+ private string _datetime;
+
+ public List<DeviceList> deviceList {
+ get { return _deviceList; }
+ set { SetProperty(ref _deviceList, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public DeviceData() {
+ }
+ }
+
+ public class DeviceList : SuperViewModel {
+ private int _id;
+ private string _name;
+ private string _mac;
+ private int _type;
+ private int _connected;
+ private string _ipv4;
+ private string _ipv6;
+ private int _static;
+
+ public int id {
+ get { return _id; }
+ set { SetProperty(ref _id, value); }
+ }
+
+ public string name {
+ get { return _name; }
+ set { SetProperty(ref _name, value); }
+ }
+
+ public string mac {
+ get { return _mac; }
+ set { SetProperty(ref _mac, value); }
+ }
+
+ public int type {
+ get { return _type; }
+ set { SetProperty(ref _type, value); }
+ }
+
+ public int connected {
+ get { return _connected; }
+ set { SetProperty(ref _connected, value); }
+ }
+
+ public string ipv4 {
+ get { return _ipv4; }
+ set { SetProperty(ref _ipv4, value); }
+ }
+
+ public string ipv6 {
+ get { return _ipv6; }
+ set { SetProperty(ref _ipv6, value); }
+ }
+
+ public int mstatic {
+ get { return _static; }
+ set { SetProperty(ref _static, value); }
+ }
+
+ public DeviceList() {
+ }
+ }
+}
--- /dev/null
+using System.Windows.Media;
+
+namespace SpeedportHybridControl.Model {
+ public class LTE : SuperViewModel {
+ private string _imei;
+ private string _imsi;
+ private string _device_status;
+ private string _card_status;
+ private string _antenna_mode;
+ private string _antenna_mode2;
+ private string _phycellid;
+ private string _cellid;
+ private string _rsrp;
+ private Brush _rsrp_bg = Brushes.Transparent;
+ private string _rsrq;
+ private Brush _rsrq_bg = Brushes.Transparent;
+ private string _service_status;
+ private string _tac;
+ private string _datetime;
+ private string _frequenz;
+
+ public string imei {
+ get { return _imei; }
+ set { SetProperty(ref _imei, value); }
+ }
+
+ public string imsi {
+ get { return _imsi; }
+ set { SetProperty(ref _imsi, value); }
+ }
+
+ public string device_status {
+ get { return _device_status; }
+ set { SetProperty(ref _device_status, value); }
+ }
+
+ public string card_status {
+ get { return _card_status; }
+ set { SetProperty(ref _card_status, value); }
+ }
+
+ public string antenna_mode {
+ get { return _antenna_mode; }
+ set { SetProperty(ref _antenna_mode, value); }
+ }
+
+ public string antenna_mode2 {
+ get { return _antenna_mode2; }
+ set { SetProperty(ref _antenna_mode2, value); }
+ }
+
+ public string phycellid {
+ get { return _phycellid; }
+ set { SetProperty(ref _phycellid, value); }
+ }
+
+ public string cellid {
+ get { return _cellid; }
+ set { SetProperty(ref _cellid, value); }
+ }
+
+ public string rsrp {
+ get { return _rsrp; }
+ set { SetProperty(ref _rsrp, value); }
+ }
+
+ public Brush rsrp_bg {
+ get { return _rsrp_bg; }
+ set { SetProperty(ref _rsrp_bg, value); }
+ }
+
+ public string rsrq {
+ get { return _rsrq; }
+ set { SetProperty(ref _rsrq, value); }
+ }
+
+ public Brush rsrq_bg {
+ get { return _rsrq_bg; }
+ set { SetProperty(ref _rsrq_bg, value); }
+ }
+
+ public string service_status {
+ get { return _service_status; }
+ set { SetProperty(ref _service_status, value); }
+ }
+
+ public string tac {
+ get { return _tac; }
+ set { SetProperty(ref _tac, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public string frequenz {
+ get { return _frequenz; }
+ set { SetProperty(ref _frequenz, value); }
+ }
+
+ public LTE() {
+ }
+ }
+}
--- /dev/null
+namespace SpeedportHybridControl.Model {
+ public class OverviewModel : SuperViewModel {
+ private string _onlinestatus;
+ private string _dsl_link_status;
+ private string _lte_image = "../assets/lte0.png";
+ private string _number_status;
+ private string _use_dect;
+ private string _dect_devices;
+ private string _devices;
+ private string _use_wlan;
+ private string _use_wlan_5ghz;
+ private string _wlan_enc;
+ private string _wlan_power;
+ private string _external_devices;
+ private string _nas_sync_active;
+ private string _nas_backup_active;
+ private string _mc_state;
+ private string _days_online;
+ private string _datetime;
+
+ public string onlinestatus {
+ get { return _onlinestatus; }
+ set { SetProperty(ref _onlinestatus, value); }
+ }
+
+ public string dsl_link_status {
+ get { return _dsl_link_status; }
+ set { SetProperty(ref _dsl_link_status, value); }
+ }
+
+ public string lte_image {
+ get { return _lte_image; }
+ set { SetProperty(ref _lte_image, value); }
+ }
+
+ public string number_status {
+ get { return _number_status; }
+ set { SetProperty(ref _number_status, value); }
+ }
+
+ public string use_dect {
+ get { return _use_dect; }
+ set { SetProperty(ref _use_dect, value); }
+ }
+
+ public string dect_devices {
+ get { return _dect_devices; }
+ set { SetProperty(ref _dect_devices, value); }
+ }
+
+ public string devices {
+ get { return _devices; }
+ set { SetProperty(ref _devices, value); }
+ }
+
+ public string use_wlan {
+ get { return _use_wlan; }
+ set { SetProperty(ref _use_wlan, value); }
+ }
+
+ public string use_wlan_5ghz {
+ get { return _use_wlan_5ghz; }
+ set { SetProperty(ref _use_wlan_5ghz, value); }
+ }
+
+ public string wlan_enc {
+ get { return _wlan_enc; }
+ set { SetProperty(ref _wlan_enc, value); }
+ }
+
+ public string wlan_power {
+ get { return _wlan_power; }
+ set { SetProperty(ref _wlan_power, value); }
+ }
+
+ public string external_devices {
+ get { return _external_devices; }
+ set { SetProperty(ref _external_devices, value); }
+ }
+
+ public string nas_sync_active {
+ get { return _nas_sync_active; }
+ set { SetProperty(ref _nas_sync_active, value); }
+ }
+
+ public string nas_backup_active {
+ get { return _nas_backup_active; }
+ set { SetProperty(ref _nas_backup_active, value); }
+ }
+
+ public string mc_state {
+ get { return _mc_state; }
+ set { SetProperty(ref _mc_state, value); }
+ }
+
+ public string days_online {
+ get { return _days_online; }
+ set { SetProperty(ref _days_online, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public OverviewModel () {
+
+ }
+ }
+}
--- /dev/null
+using System.Collections.Generic;
+
+namespace SpeedportHybridControl.Model {
+ public class PhoneCallData : SuperViewModel {
+ private List<PhoneCallList> _missedCalls;
+ private List<PhoneCallList> _takenCalls;
+ private List<PhoneCallList> _dialedCalls;
+ private string _datetime;
+
+ public List<PhoneCallList> missedCalls {
+ get { return _missedCalls; }
+ set { SetProperty(ref _missedCalls, value); }
+ }
+
+ public List<PhoneCallList> takenCalls {
+ get { return _takenCalls; }
+ set { SetProperty(ref _takenCalls, value); }
+ }
+
+ public List<PhoneCallList> dialedCalls {
+ get { return _dialedCalls; }
+ set { SetProperty(ref _dialedCalls, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public PhoneCallData () {
+ }
+ }
+
+ public class PhoneCallList : SuperViewModel {
+ private int _id;
+ private string _date;
+ private string _time;
+ private string _who;
+ private string _duration;
+
+ public int id {
+ get { return _id; }
+ set { SetProperty(ref _id, value); }
+ }
+
+ public string date {
+ get { return _date; }
+ set { SetProperty(ref _date, value); }
+ }
+
+ public string time {
+ get { return _time; }
+ set { SetProperty(ref _time, value); }
+ }
+
+ public string who {
+ get { return _who; }
+ set { SetProperty(ref _who, value); }
+ }
+
+ public string duration {
+ get { return _duration; }
+ set { SetProperty(ref _duration, value); }
+ }
+
+ public override string ToString() {
+ return string.Concat(date, " ", time, " ", who, " ", duration);
+ }
+
+ public PhoneCallList () {
+ }
+ }
+}
--- /dev/null
+using System.Collections.Generic;
+
+namespace SpeedportHybridControl.Model {
+ public class Status : SuperViewModel {
+ private string _device_name;
+ private string _lte_status;
+ private string _lte_signal;
+ private string _lte_image = "../assets/lte0.png";
+ private string _datetime;
+ private string _imei;
+ private string _dsl_link_status;
+ private string _status;
+ private string _dsl_downstream;
+ private string _dsl_upstream;
+ private List<StatusPhoneList> _addphonenumber;
+ private string _use_dect;
+ private string _dect_devices;
+ private string _wlan_ssid;
+ private string _wlan_5ghz_ssid;
+ private string _use_wlan;
+ private string _use_wlan_5ghz;
+ private string _wlan_devices;
+ private string _wlan_5ghz_devices;
+ private string _lan1_device = "../assets/x.png";
+ private string _lan2_device = "../assets/x.png";
+ private string _lan3_device = "../assets/x.png";
+ private string _lan4_device = "../assets/x.png";
+ private string _hsfon_status;
+ private string _firmware_version;
+ private string _serial_number;
+ private string _uptime;
+
+ public string device_name {
+ get { return _device_name; }
+ set { SetProperty(ref _device_name, value); }
+ }
+
+ public string lte_status {
+ get { return _lte_status; }
+ set { SetProperty(ref _lte_status, value); }
+ }
+
+ public string lte_signal {
+ get { return _lte_signal; }
+ set { SetProperty(ref _lte_signal, value); }
+ }
+
+ public string lte_image {
+ get { return _lte_image; }
+ set { SetProperty(ref _lte_image, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public string imei {
+ get { return _imei; }
+ set { SetProperty(ref _imei, value); }
+ }
+
+ public string dsl_link_status {
+ get { return _dsl_link_status; }
+ set { SetProperty(ref _dsl_link_status, value); }
+ }
+
+ public string status {
+ get { return _status; }
+ set { SetProperty(ref _status, value); }
+ }
+
+ public string dsl_downstream {
+ get { return _dsl_downstream; }
+ set { SetProperty(ref _dsl_downstream, value); }
+ }
+
+ public string dsl_upstream {
+ get { return _dsl_upstream; }
+ set { SetProperty(ref _dsl_upstream, value); }
+ }
+
+ public List<StatusPhoneList> addphonenumber {
+ get { return _addphonenumber; }
+ set { SetProperty(ref _addphonenumber, value); }
+ }
+
+ public string use_dect {
+ get { return _use_dect; }
+ set { SetProperty(ref _use_dect, value); }
+ }
+
+ public string dect_devices {
+ get { return _dect_devices; }
+ set { SetProperty(ref _dect_devices, value); }
+ }
+
+ public string wlan_ssid {
+ get { return _wlan_ssid; }
+ set { SetProperty(ref _wlan_ssid, value); }
+ }
+
+ public string wlan_5ghz_ssid {
+ get { return _wlan_5ghz_ssid; }
+ set { SetProperty(ref _wlan_5ghz_ssid, value); }
+ }
+
+ public string use_wlan {
+ get { return _use_wlan; }
+ set { SetProperty(ref _use_wlan, value); }
+ }
+
+ public string use_wlan_5ghz {
+ get { return _use_wlan_5ghz; }
+ set { SetProperty(ref _use_wlan_5ghz, value); }
+ }
+
+ public string wlan_devices {
+ get { return _wlan_devices; }
+ set { SetProperty(ref _wlan_devices, value); }
+ }
+
+ public string wlan_5ghz_devices {
+ get { return _wlan_5ghz_devices; }
+ set { SetProperty(ref _wlan_5ghz_devices, value); }
+ }
+
+ public string lan1_device {
+ get { return _lan1_device; }
+ set { SetProperty(ref _lan1_device, value); }
+ }
+
+ public string lan2_device {
+ get { return _lan2_device; }
+ set { SetProperty(ref _lan2_device, value); }
+ }
+
+ public string lan3_device {
+ get { return _lan3_device; }
+ set { SetProperty(ref _lan3_device, value); }
+ }
+
+ public string lan4_device {
+ get { return _lan4_device; }
+ set { SetProperty(ref _lan4_device, value); }
+ }
+
+ public string hsfon_status {
+ get { return _hsfon_status; }
+ set { SetProperty(ref _hsfon_status, value); }
+ }
+
+ public string firmware_version {
+ get { return _firmware_version; }
+ set { SetProperty(ref _firmware_version, value); }
+ }
+
+ public string serial_number {
+ get { return _serial_number; }
+ set { SetProperty(ref _serial_number, value); }
+ }
+
+ public string uptime {
+ get { return _uptime; }
+ set { SetProperty(ref _uptime, value); }
+ }
+
+ public Status() {
+ }
+ }
+
+ public class StatusPhoneList : SuperViewModel {
+ private string _number;
+ private string _status;
+
+ public string number {
+ get { return _number; }
+ set { SetProperty(ref _number, value); }
+ }
+
+ public string status {
+ get { return _status; }
+ set { SetProperty(ref _status, value); }
+ }
+
+ public StatusPhoneList () {
+
+ }
+ }
+}
--- /dev/null
+using System.Collections.Generic;
+
+namespace SpeedportHybridControl.Model {
+ public class SyslogData : SuperViewModel {
+ private List<SyslogList> _syslogList;
+ private string _datetime;
+
+ public List<SyslogList> syslogList {
+ get { return _syslogList; }
+ set { SetProperty(ref _syslogList, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public SyslogData() {
+ }
+ }
+
+ public class SyslogList : SuperViewModel {
+ private string _message;
+ private string _timestamp;
+
+ public string message {
+ get { return _message; }
+ set { SetProperty(ref _message, value); }
+ }
+
+ public string timestamp {
+ get { return _timestamp; }
+ set { SetProperty(ref _timestamp, value); }
+ }
+
+ public override string ToString () {
+ return string.Concat(timestamp, ": ", message);
+ }
+
+ public SyslogList() {
+ }
+ }
+}
--- /dev/null
+namespace SpeedportHybridControl.Model {
+ public class TR181 : SuperViewModel {
+ private string _enable1;
+ private string _status1;
+ private string _mode;
+ private string _servername;
+ private string _severip;
+ private string _bw;
+ private string _errorinfo;
+ private string _hellostatus;
+
+ private string _lte_tunnel;
+ private string _dsl_tunnel;
+ private string _bonding;
+ private string _QueueSkbTimeOut;
+
+ private string _datetime;
+
+ private string _bypass_up_bw;
+ private string _bypass_dw_bw;
+ private string _bypass_up_rb;
+ private string _bypass_dw_rb;
+ private string _bypass_check;
+
+ public string enable1 {
+ get { return _enable1; }
+ set { SetProperty(ref _enable1, value); }
+ }
+
+ public string status1 {
+ get { return _status1; }
+ set { SetProperty(ref _status1, value); }
+ }
+
+ public string mode {
+ get { return _mode; }
+ set { SetProperty(ref _mode, value); }
+ }
+
+ public string servername {
+ get { return _servername; }
+ set { SetProperty(ref _servername, value); }
+ }
+
+ public string severip {
+ get { return _severip; }
+ set { SetProperty(ref _severip, value); }
+ }
+
+ public string bw {
+ get { return _bw; }
+ set { SetProperty(ref _bw, value); }
+ }
+
+ public string errorinfo {
+ get { return _errorinfo; }
+ set { SetProperty(ref _errorinfo, value); }
+ }
+
+ public string hellostatus {
+ get { return _hellostatus; }
+ set { SetProperty(ref _hellostatus, value); }
+ }
+
+ public string lte_tunnel {
+ get { return _lte_tunnel; }
+ set { SetProperty(ref _lte_tunnel, value); }
+ }
+
+ public string dsl_tunnel {
+ get { return _dsl_tunnel; }
+ set { SetProperty(ref _dsl_tunnel, value); }
+ }
+
+ public string bonding {
+ get { return _bonding; }
+ set { SetProperty(ref _bonding, value); }
+ }
+
+ public string QueueSkbTimeOut {
+ get { return _QueueSkbTimeOut; }
+ set { SetProperty(ref _QueueSkbTimeOut, value); }
+ }
+
+ public string datetime {
+ get { return _datetime; }
+ set { SetProperty(ref _datetime, value); }
+ }
+
+ public string bypass_up_bw {
+ get { return _bypass_up_bw; }
+ set { SetProperty(ref _bypass_up_bw, value); }
+ }
+
+ public string bypass_dw_bw {
+ get { return _bypass_dw_bw; }
+ set { SetProperty(ref _bypass_dw_bw, value); }
+ }
+
+ public string bypass_up_rb {
+ get { return _bypass_up_rb; }
+ set { SetProperty(ref _bypass_up_rb, value); }
+ }
+
+ public string bypass_dw_rb {
+ get { return _bypass_dw_rb; }
+ set { SetProperty(ref _bypass_dw_rb, value); }
+ }
+
+ public string bypass_check {
+ get { return _bypass_check; }
+ set { SetProperty(ref _bypass_check, value); }
+ }
+
+ public TR181() {
+ }
+ }
+}
--- /dev/null
+using System.Collections.Generic;
+
+namespace SpeedportHybridControl.Model {
+ class bonding_client : SuperViewModel {
+ private List<user_white_list> _user_white_list;
+ private List<FLI> _FLI;
+ private List<Routing_table> _Routing_table;
+ private List<hybrid_show> _hybrid_show;
+
+ public List<user_white_list> user_white_list {
+ get { return _user_white_list; }
+ set { SetProperty(ref _user_white_list, value); }
+ }
+
+ public List<FLI> FLI {
+ get { return _FLI; }
+ set { SetProperty(ref _FLI, value); }
+ }
+
+ public List<Routing_table> Routing_table {
+ get { return _Routing_table; }
+ set { SetProperty(ref _Routing_table, value); }
+ }
+
+ public List<hybrid_show> hybrid_show {
+ get { return _hybrid_show; }
+ set { SetProperty(ref _hybrid_show, value); }
+ }
+ }
+
+ class user_white_list {
+ public string s_id {
+ get;
+ set;
+ }
+
+ public string s_description {
+ get;
+ set;
+ }
+
+ public string s_type {
+ get;
+ set;
+ }
+
+ public string s_enable {
+ get;
+ set;
+ }
+
+ public string s_filterentry {
+ get;
+ set;
+ }
+ }
+
+ class FLI {
+ public string ID {
+ get;
+ set;
+ }
+
+ public string description {
+ get;
+ set;
+ }
+
+ public string enable {
+ get;
+ set;
+ }
+
+ public string type {
+ get;
+ set;
+ }
+
+ public string filterEntry {
+ get;
+ set;
+ }
+ }
+
+ class Routing_table {
+ public string default_route {
+ get;
+ set;
+ }
+ }
+
+ class hybrid_show {
+ public string haap_addr {
+ get;
+ set;
+ }
+
+ public string t2v4_addr {
+ get;
+ set;
+ }
+
+ public string t2v6_addr {
+ get;
+ set;
+ }
+
+ public string t3v4_addr {
+ get;
+ set;
+ }
+
+ public string t3v6_addr {
+ get;
+ set;
+ }
+
+ public string tunnel_addr {
+ get;
+ set;
+ }
+
+ public string bras_pre {
+ get;
+ set;
+ }
+
+ public string haap_pre {
+ get;
+ set;
+ }
+
+ public string curpre_type {
+ get;
+ set;
+ }
+
+ public string check_hello {
+ get;
+ set;
+ }
+
+ public string hybrid_cin {
+ get;
+ set;
+ }
+
+ public string hybrid_idle_time {
+ get;
+ set;
+ }
+
+ public string hybrid_sessionid {
+ get;
+ set;
+ }
+
+ public string hybrid_magicnum {
+ get;
+ set;
+ }
+
+ public string hybrid_error_code {
+ get;
+ set;
+ }
+
+ public string dsl_state {
+ get;
+ set;
+ }
+
+ public string dsl_timeoutcnt {
+ get;
+ set;
+ }
+
+ public string dsl_intf {
+ get;
+ set;
+ }
+
+ public string dsl_local_addr {
+ get;
+ set;
+ }
+
+ public string dsl_remote_addr {
+ get;
+ set;
+ }
+
+ public string dsl_uploadbw {
+ get;
+ set;
+ }
+
+ public string dsl_downloadbw {
+ get;
+ set;
+ }
+
+ public string lte_state {
+ get;
+ set;
+ }
+
+ public string lte_timeoutcnt {
+ get;
+ set;
+ }
+
+ public string lte_intf {
+ get;
+ set;
+ }
+
+ public string lte_local_addr {
+ get;
+ set;
+ }
+
+ public string lte_remote_addr {
+ get;
+ set;
+ }
+
+ public string rtt_mode {
+ get;
+ set;
+ }
+
+ public string rtt_threshold {
+ get;
+ set;
+ }
+
+ public string rtt_violationtime {
+ get;
+ set;
+ }
+
+ public string rtt_compliancetime {
+ get;
+ set;
+ }
+
+ public string rtt_dsl {
+ get;
+ set;
+ }
+
+ public string rtt_lte {
+ get;
+ set;
+ }
+
+ public string rtt_diff {
+ get;
+ set;
+ }
+
+ public string bypass_up_bw {
+ get;
+ set;
+ }
+
+ public string bypass_dw_bw {
+ get;
+ set;
+ }
+
+ public string bypass_up_rb {
+ get;
+ set;
+ }
+
+ public string bypass_dw_rb {
+ get;
+ set;
+ }
+
+ public string bypass_up_record {
+ get;
+ set;
+ }
+
+ public string bypass_dw_record {
+ get;
+ set;
+ }
+
+ public string bypass_check {
+ get;
+ set;
+ }
+ }
+}
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
- <Compile Include="model\MainWindowModel.cs" />
- <Compile Include="model\SuperViewModel.cs" />
- <Compile Include="page\test.xaml.cs">
- <DependentUpon>test.xaml</DependentUpon>
- </Compile>
- <Compile Include="page\test1.xaml.cs">
- <DependentUpon>test1.xaml</DependentUpon>
- </Compile>
+ <Compile Include="Model\bonding_client.cs" />
+ <Compile Include="Model\DeviceViewModel.cs" />
+ <Compile Include="Model\DSLViewModel.cs" />
+ <Compile Include="Model\LTEViewModel.cs" />
+ <Compile Include="Model\MainWindowModel.cs" />
+ <Compile Include="Model\OverviewModel.cs" />
+ <Compile Include="Model\PhoneCallViewModel.cs" />
+ <Compile Include="Model\StatusViewModel.cs" />
+ <Compile Include="Model\SuperViewModel.cs" />
<Page Include="MainWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
<DependentUpon>MainWindow.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
- <Page Include="page\test.xaml">
+ <Page Include="page\AboutPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\ControlsPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\DslPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\LanPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\LoginPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\LteInfoPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\OverviewPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\PhonePage.xaml">
<Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
</Page>
- <Page Include="page\test1.xaml">
+ <Page Include="page\StatusPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\SyslogPage.xaml">
<Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ <Page Include="page\TR181Page.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
</Page>
</ItemGroup>
<ItemGroup>
+ <Compile Include="Model\SyslogViewModel.cs" />
+ <Compile Include="Model\TR181ViewModel.cs" />
+ <Compile Include="page\AboutPage.xaml.cs">
+ <DependentUpon>AboutPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\ControlsPage.xaml.cs">
+ <DependentUpon>ControlsPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\DslPage.xaml.cs">
+ <DependentUpon>DslPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\LanPage.xaml.cs">
+ <DependentUpon>LanPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\LoginPage.xaml.cs">
+ <DependentUpon>LoginPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\LteInfoPage.xaml.cs">
+ <DependentUpon>LteInfoPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\OverviewPage.xaml.cs">
+ <DependentUpon>OverviewPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\PhonePage.xaml.cs">
+ <DependentUpon>PhonePage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\StatusPage.xaml.cs">
+ <DependentUpon>StatusPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\SyslogPage.xaml.cs">
+ <DependentUpon>SyslogPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="page\TR181Page.xaml.cs">
+ <DependentUpon>TR181Page.xaml</DependentUpon>
+ </Compile>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
<ItemGroup>
<Resource Include="t-com icon.ico" />
</ItemGroup>
+ <ItemGroup>
+ <SplashScreen Include="SplashScreen1.png" />
+ </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Input;
using SpeedportHybridControl.Implementations;
-using SpeedportHybridControl.model;
using System.Windows.Controls;
+using SpeedportHybridControl.page;
-
-namespace SpeedportHybridControl.model {
+namespace SpeedportHybridControl.Model {
class MainWindowModel : SuperViewModel {
private DelegateCommand _switchToLoginPage;
private DelegateCommand _switchToStatusPage;
private DelegateCommand _switchToControlsPage;
private DelegateCommand _sitchToAboutPage;
+ private bool _buttonOverviewPageIsActive = false;
private bool _buttonDSLPageIsActive = false;
- private Page _FrameSource = new page.test();
+ private bool _buttonLteInfoPageIsActive = false;
+ private bool _buttonSyslogPageIsActive = false;
+ private bool _buttonTR181PageIsActive = false;
+ private bool _buttonPhonePageIsActive = false;
+ private bool _buttonLanPageIsActive = false;
+ private bool _buttonControlsPageIsActive = false;
+
+ private Page _FrameSource;
public DelegateCommand SwitchToLoginPage {
get { return _switchToLoginPage; }
set { SetProperty(ref _sitchToAboutPage, value); }
}
+ public bool ButtonOverviewPageIsActive {
+ get { return _buttonOverviewPageIsActive; }
+ set { SetProperty(ref _buttonOverviewPageIsActive, value); }
+ }
+
public bool ButtonDSLPageIsActive {
get { return _buttonDSLPageIsActive; }
set { SetProperty(ref _buttonDSLPageIsActive, value); }
}
+ public bool ButtonLteInfoPageIsActive {
+ get { return _buttonLteInfoPageIsActive; }
+ set { SetProperty(ref _buttonLteInfoPageIsActive, value); }
+ }
+
+ public bool ButtonSyslogPageIsActive {
+ get { return _buttonSyslogPageIsActive; }
+ set { SetProperty(ref _buttonSyslogPageIsActive, value); }
+ }
+
+ public bool ButtonTR181PageIsActive {
+ get { return _buttonTR181PageIsActive; }
+ set { SetProperty(ref _buttonTR181PageIsActive, value); }
+ }
+
+ public bool ButtonPhonePageIsActive {
+ get { return _buttonPhonePageIsActive; }
+ set { SetProperty(ref _buttonPhonePageIsActive, value); }
+ }
+
+ public bool ButtonLanPageIsActive {
+ get { return _buttonLanPageIsActive; }
+ set { SetProperty(ref _buttonLanPageIsActive, value); }
+ }
+
+ public bool ButtonControlsPageIsActive {
+ get { return _buttonControlsPageIsActive; }
+ set { SetProperty(ref _buttonControlsPageIsActive, value); }
+ }
+
public Page FrameSource {
get { return _FrameSource; }
set { SetProperty(ref _FrameSource, value); }
}
- private void OnSwitchToLogiPagenExecute () {
- Console.WriteLine("button...");
+ private void OnSwitchToLoginPageExecute () {
+ FrameSource = new LoginPage();
}
- private void OnSwitchToAboutPageExecute () {
- Console.WriteLine("button...");
- ButtonDSLPageIsActive = true;
- FrameSource = new page.test1();
+ private void OnSwitchToStatusPageExecute () {
+ FrameSource = new StatusPage();
+ }
+
+ private void OnSwitchToOverviewPageExecute () {
+ FrameSource = new OverviewPage();
}
private void OnSwitchToDSLPageExecute () {
- Console.WriteLine("button...");
- ButtonDSLPageIsActive = true;
- FrameSource = new page.test();
+ FrameSource = new DslPage();
+ }
+
+ private void OnSwitchToLteInfoPageExecute () {
+ FrameSource = new LteInfoPage();
+ }
+
+ private void OnSwitchToSyslogPageExecute () {
+ FrameSource = new SyslogPage();
}
- private void ExampleExecute () {
+ private void OnSwitchToTR181PageExecute () {
+ FrameSource = new TR181Page();
+ }
+
+ private void OnSwitchToPhonePageExecute () {
+ FrameSource = new PhonePage();
+ }
+
+ private void OnSwitchToLanPageExecute () {
+ FrameSource = new LanPage();
+ }
+ private void OnSwitchToControlsPageExecute () {
+ FrameSource = new ControlsPage();
}
+ private void OnSwitchToAboutPageExecute () {
+ ButtonOverviewPageIsActive = true;
+ ButtonDSLPageIsActive = true;
+ ButtonLteInfoPageIsActive = true;
+ ButtonSyslogPageIsActive = true;
+ ButtonTR181PageIsActive = true;
+ ButtonPhonePageIsActive = true;
+ ButtonLanPageIsActive = true;
+ ButtonControlsPageIsActive = true;
+ FrameSource = new AboutPage();
+ }
+
public MainWindowModel () {
- SwitchToLoginPage = new DelegateCommand(new Action(OnSwitchToLogiPagenExecute));
- SwitchToStatusPage = new DelegateCommand(new Action(ExampleExecute));
- SwitchToOverviewPage = new DelegateCommand(new Action(ExampleExecute));
+ FrameSource = new LoginPage();
+
+ SwitchToLoginPage = new DelegateCommand(new Action(OnSwitchToLoginPageExecute));
+ SwitchToStatusPage = new DelegateCommand(new Action(OnSwitchToStatusPageExecute));
+ SwitchToOverviewPage = new DelegateCommand(new Action(OnSwitchToOverviewPageExecute));
SwitchToDSLPage = new DelegateCommand(new Action(OnSwitchToDSLPageExecute));
- SwitchToLteInfoPage = new DelegateCommand(new Action(ExampleExecute));
- SwitchToSyslogPage = new DelegateCommand(new Action(ExampleExecute));
- SwitchToTR181Page = new DelegateCommand(new Action(ExampleExecute));
- SwitchToPhonePage = new DelegateCommand(new Action(ExampleExecute));
- SwitchToLanPage = new DelegateCommand(new Action(ExampleExecute));
- SwitchToControlsPage = new DelegateCommand(new Action(ExampleExecute));
+ SwitchToLteInfoPage = new DelegateCommand(new Action(OnSwitchToLteInfoPageExecute));
+ SwitchToSyslogPage = new DelegateCommand(new Action(OnSwitchToSyslogPageExecute));
+ SwitchToTR181Page = new DelegateCommand(new Action(OnSwitchToTR181PageExecute));
+ SwitchToPhonePage = new DelegateCommand(new Action(OnSwitchToPhonePageExecute));
+ SwitchToLanPage = new DelegateCommand(new Action(OnSwitchToLanPageExecute));
+ SwitchToControlsPage = new DelegateCommand(new Action(OnSwitchToControlsPageExecute));
SwitchToAboutPage = new DelegateCommand(new Action(OnSwitchToAboutPageExecute));
}
using System.ComponentModel;
using System.Runtime.CompilerServices;
-namespace SpeedportHybridControl.model {
+namespace SpeedportHybridControl.Model {
public class SuperViewModel : INotifyPropertyChanged {
public event PropertyChangedEventHandler PropertyChanged;
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.AboutPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl.page"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="AboutPage">
+
+ <Grid>
+ <TextBlock HorizontalAlignment="Left" Margin="10,10,0,0" TextWrapping="Wrap" Text="SpeedportHybridControl" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" Margin="10,31,0,0" TextWrapping="Wrap" Text="Copyright © 2015 stricted.net" VerticalAlignment="Top"/>
+
+ <TextBlock HorizontalAlignment="Left" Margin="10,52,0,0" TextWrapping="Wrap" Text="Version:" VerticalAlignment="Top"/>
+ <TextBlock x:Name="tbVersion" HorizontalAlignment="Left" Margin="57,52,0,0" TextWrapping="Wrap" VerticalAlignment="Top"/>
+
+ <Button x:Name="btnBugtracker" Content="Bugtracker" HorizontalAlignment="Left" Margin="10,0,0,10" VerticalAlignment="Bottom" Click="button_click"/>
+ <Button x:Name="btnUpdate" Content="Auf Update prüfen" HorizontalAlignment="Left" Margin="10,73,0,0" VerticalAlignment="Top" Click="button_click"/>
+
+
+ <Button x:Name="btnDonate" BorderBrush="Transparent" Background="Transparent" HorizontalAlignment="Right" Width="106" Height="48" VerticalAlignment="Bottom" Click="button_click" Margin="0,0,10,10">
+ <Image Source="../assets/btn_donateCC_LG.gif" x:Name="image" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ </Button>
+ </Grid>
+</Page>
--- /dev/null
+using System.Diagnostics;
+using System.Windows;
+using System.Windows.Controls;
+using System.Threading;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for AboutPage.xaml
+ /// </summary>
+ public partial class AboutPage : Page {
+ public AboutPage () {
+ InitializeComponent();
+ //tbVersion.Text = MainWindow.VERSION;
+ }
+
+ private void button_click (object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(btnDonate)) {
+ Process.Start("https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=E7EBAC5NP928J");
+ }
+ else if (sender.Equals(btnBugtracker)) {
+ Process.Start("https://stricted.net/bugtracker/index.php/ProductList/");
+ }
+ else if (sender.Equals(btnUpdate)) {
+ if (util.checkUpdate().Equals(true)) {
+ new Thread(() => { MessageBox.Show("Ein Update ist verfügbar.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Warning); }).Start();
+ }
+ else {
+ new Thread(() => { MessageBox.Show("SpeedportHybridControl ist auf dem neuesten Stand.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.ControlsPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="ControlsPage">
+
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" Width="117" Height="282" VerticalAlignment="Top" Margin="10,0,0,0">
+ <StackPanel.Resources>
+ <Style TargetType="{x:Type Button}">
+ <Setter Property="Margin" Value="0,3,0,0"/>
+ </Style>
+ </StackPanel.Resources>
+
+ <Button x:Name="button7" Content="Router Neustarten" Click="button_click"/>
+ <Button x:Name="button9" Content="DSL neu verbinden" Click="button_click"/>
+ <Button x:Name="button10" Content="Firmware-Update" Click="button_click"/>
+ <Button x:Name="btnflushdns" Content="DNS Cache Leeren" Click="button_click"/>
+ <Button x:Name="btnSpeedtest" Content="speedtest.net" Click="button_click"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button x:Name="button17" Content="Werkseinstellungen" Click="button_click" />
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Left" Width="117" Height="282" VerticalAlignment="Top" Margin="132,0,0,0">
+ <StackPanel.Resources>
+ <Style TargetType="{x:Type Button}">
+ <Setter Property="Margin" Value="0,3,0,0"/>
+ </Style>
+ </StackPanel.Resources>
+
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button x:Name="button8" Content="LTE neu verbinden" Click="button_click" />
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button x:Name="btnSpeedtest2" Content="speedtest.t-online.de" Click="button_click"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button x:Name="btnDSLdisconnect" Content="DSL Trennen" Click="button_click"/>
+ <Button x:Name="btnLTEdisconnect" Content="LTE Trennen" Click="button_click"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Left" Width="140" Height="282" VerticalAlignment="Top" Margin="254,0,0,0">
+ <StackPanel.Resources>
+ <Style TargetType="{x:Type Button}">
+ <Setter Property="Margin" Value="0,3,0,0"/>
+ </Style>
+ </StackPanel.Resources>
+
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button IsEnabled="False" x:Name="button" Content="DSL + LTE neu verbinden"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button x:Name="btnDSLconnect" Content="DSL Verbinden" Click="button_click"/>
+ <Button x:Name="btnLTEconnect" Content="LTE Verbinden" Click="button_click"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ <Button Visibility="Hidden" Content="[SPACER]"/>
+ </StackPanel>
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+using System.Threading;
+using System.Diagnostics;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for ControlsPage.xaml
+ /// </summary>
+ public partial class ControlsPage : Page {
+ public ControlsPage() {
+ InitializeComponent();
+ }
+
+ private void button_click (object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(button7)) {
+ MessageBoxResult result = MessageBox.Show("Willst du den Router wirklich neustarten?", "Confirmation", MessageBoxButton.YesNoCancel, MessageBoxImage.Question);
+ if (result.Equals(MessageBoxResult.Yes)) {
+ SpeedportHybridAPI.getInstance().reboot();
+ }
+ }
+ else if (sender.Equals(button8)) {
+ new Thread(() => {
+ bool reconnectLte = SpeedportHybridAPI.getInstance().reconnectLte();
+ if (reconnectLte.Equals(false)) {
+ new Thread(() => { MessageBox.Show("Could not reconnect LTE.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not reconnect LTE.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("LTE reconnected", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }).Start();
+ }
+ else if (sender.Equals(button9)) {
+ new Thread(() => {
+ bool reconnectDSL = SpeedportHybridAPI.getInstance().reconnectDSL();
+ if (reconnectDSL.Equals(false)) {
+ new Thread(() => { MessageBox.Show("Could not reconnect DSL.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not reconnect DSL.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("DSL reconnected", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }).Start();
+ }
+ else if (sender.Equals(button10)) {
+ SpeedportHybridAPI.getInstance().checkFirmware();
+ }
+ else if (sender.Equals(button17)) {
+ MessageBoxResult result = MessageBox.Show("Beim Zurücksetzen auf die Werkseinstellungen gehen alle Ihre Einstellungen verloren.\nSind Sie sicher, dass Sie den Router zurücksetzen möchten ? ", "Confirmation", MessageBoxButton.YesNoCancel, MessageBoxImage.Question);
+ if (result.Equals(MessageBoxResult.Yes)) {
+ bool reconnectDSL = SpeedportHybridAPI.getInstance().resetToFactoryDefault();
+ if (reconnectDSL.Equals(false)) {
+ new Thread(() => { MessageBox.Show("Could not reset the router.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not reset the router.");
+ }
+ }
+ }
+ else if (sender.Equals(btnflushdns)) {
+ new Thread(() => { SpeedportHybridAPI.getInstance().flushDNS(); }).Start();
+ }
+ else if (sender.Equals(btnSpeedtest)) {
+ Process.Start("http://www.speedtest.net/");
+ }
+ else if (sender.Equals(btnSpeedtest2)) {
+ Process.Start("http://speedtest.t-online.de/");
+ }
+ else if (sender.Equals(btnDSLconnect)) {
+ bool status = SpeedportHybridAPI.getInstance().changeDSLStatus("online");
+ if (status.Equals(false)) {
+ new Thread(() => { MessageBox.Show("DSL Verbinden Fehlgeschlagen", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not connect DSL.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("DSL Verbinden erfolgreich.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }
+ else if (sender.Equals(btnDSLdisconnect)) {
+ bool status = SpeedportHybridAPI.getInstance().changeDSLStatus("offline");
+ if (status.Equals(false)) {
+ new Thread(() => { MessageBox.Show("DSL Trennen Fehlgeschlagen", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not disconnect DSL.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("DSL Trennen erfolgreich.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }
+ else if (sender.Equals(btnLTEconnect)) {
+ bool status = SpeedportHybridAPI.getInstance().changeLTEStatus("online");
+ if (status.Equals(false)) {
+ new Thread(() => { MessageBox.Show("LTE Verbinden Fehlgeschlagen", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not connect LTE.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("LTE Verbinden erfolgreich.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }
+ else if (sender.Equals(btnLTEdisconnect)) {
+ bool status = SpeedportHybridAPI.getInstance().changeLTEStatus("offline");
+ if (status.Equals(false)) {
+ new Thread(() => { MessageBox.Show("LTE Trennen Fehlgeschlagen", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Could not disconnect LTE.");
+ }
+ else {
+ new Thread(() => { MessageBox.Show("LTE Trennen erfolgreich.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Information); }).Start();
+ }
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.DslPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl.page"
+ xmlns:d3="http://research.microsoft.com/DynamicDataDisplay/1.0"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="DslPage">
+
+ <Grid DataContext="{StaticResource DSL}">
+ <GroupBox Header="Connection Status" HorizontalAlignment="Left" VerticalAlignment="Top" Width="213">
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Width="120">
+ <TextBlock TextWrapping="Wrap" Text="DSL operating-mode:"/>
+ <TextBlock TextWrapping="Wrap" Text="Path mode:"/>
+ <TextBlock TextWrapping="Wrap" Text="State:"/>
+ <TextBlock TextWrapping="Wrap" Text="Training results:"/>
+ <TextBlock TextWrapping="Wrap" Text="Mode LO/I2:"/>
+ <TextBlock TextWrapping="Wrap" Text="VPI/VCI:"/>
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Width="81" Margin="120,0,0,0">
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.dsl_operaing_mode}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.path_mode}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.state}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.training_results}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.mode_lo}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Connection.vpi_vci}"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <GroupBox Header="Statistik Ø" HorizontalAlignment="Left" VerticalAlignment="Top" Width="213" Margin="0,120,0,0">
+ <Grid>
+ <StackPanel Margin="0,0,150,0">
+ <TextBlock />
+ <TextBlock Text="CRC/min" />
+ <TextBlock Text="HEC/min" />
+ <TextBlock Text="FEC/min" />
+ </StackPanel>
+ <StackPanel Margin="51,0,81,0">
+ <TextBlock TextAlignment="Center" Text="Upstream" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.uCRCsec}" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.uHECsec}" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.uFECsec}" />
+ </StackPanel>
+ <StackPanel Margin="120,0,0,0">
+ <TextBlock TextAlignment="Center" Text="Downstream" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.dCRCsec}" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.dHECsec}" />
+ <TextBlock TextAlignment="Center" Text="{Binding Line.dFECsec}" />
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <StackPanel Margin="0,211,0,0" VerticalAlignment="Top" Height="55">
+ <TextBlock Text="{Binding lastCRC}" />
+ <TextBlock Text="{Binding lastHEC}" />
+ <TextBlock Text="{Binding lastFEC}" />
+ </StackPanel>
+
+ <GroupBox Header="Line Status" HorizontalAlignment="Left" VerticalAlignment="Top" Width="296" Margin="218,0,0,0">
+ <Grid>
+ <StackPanel Margin="0,0,171,0">
+ <TextBlock TextWrapping="Wrap" Text=""/>
+ <TextBlock TextWrapping="Wrap" Text="Actual Data Rate:"/>
+ <TextBlock TextWrapping="Wrap" Text="Attainable Data Rate:"/>
+ <TextBlock TextWrapping="Wrap" Text="SNR Margin:"/>
+ <TextBlock TextWrapping="Wrap" Text="Signal-level:"/>
+ <TextBlock TextWrapping="Wrap" Text="Line Attenuation:"/>
+ <TextBlock TextWrapping="Wrap" Text="FEC Size:"/>
+ <TextBlock TextWrapping="Wrap" Text="Codeword size:"/>
+ <TextBlock TextWrapping="Wrap" Text="Interleave delay:"/>
+ <TextBlock TextWrapping="Wrap" Text="CRC error count:"/>
+ <TextBlock TextWrapping="Wrap" Text="HEC error count:"/>
+ <TextBlock TextWrapping="Wrap" Text="FEC error count:"/>
+ </StackPanel>
+
+ <StackPanel Margin="113,0,96,0">
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="Upstream"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uactual}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uattainable}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uSNR}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uSignal}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uLine}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uFEC_size}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uCodeword}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uInterleave}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uCRC}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uHEC}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.uHEC}"/>
+ </StackPanel>
+
+ <StackPanel Width="94" Margin="188,0,2,0">
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="Downstream"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dactual}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dattainable}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dSNR}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dSignal}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dLine}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dFEC_size}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dCodeword}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dInterleave}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dCRC}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dHEC}"/>
+ <TextBlock TextAlignment="Center" TextWrapping="Wrap" Text="{Binding Line.dFEC}"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <ToggleButton x:Name="autoreload" Content="Automatisch aktualisieren" HorizontalAlignment="Left" VerticalAlignment="Bottom" Click="button_click"/>
+ <ToggleButton x:Name="btnLog" Content="Log" HorizontalAlignment="Left" VerticalAlignment="Bottom" Click="button_click" Margin="145,0,0,0" IsEnabled="False"/>
+
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+using System.Timers;
+using System;
+using SpeedportHybridControl.Model;
+using System.IO;
+
+namespace SpeedportHybridControl.page {
+ public partial class DslPage : Page {
+ public Timer _timer;
+
+ public int lastdFEC;
+ public int lastuFEC;
+ public int lastdHEC;
+ public int lastuHEC;
+ public int lastdCRC;
+ public int lastuCRC;
+ public DateTime lastReload;
+
+ public DslPage () {
+ InitializeComponent();
+ }
+
+ public void StopTimer () {
+ if (Object.Equals(_timer, null).Equals(false)) {
+ _timer.Stop();
+ }
+
+ if (autoreload.IsChecked.Equals(true)) {
+ autoreload.IsChecked = false;
+ }
+
+ if (btnLog.IsChecked.Equals(true)) {
+ btnLog.IsChecked = false;
+ }
+
+ btnLog.IsEnabled = false;
+ }
+
+ private void StartTimer () {
+ _timer = new Timer {
+ Interval = 1000, // every second
+ };
+
+ _timer.Elapsed += timer_Elapsed;
+ _timer.Start();
+ }
+
+ void timer_Elapsed (object sender, ElapsedEventArgs e) {
+ /*
+ util.init("DSL");
+ DSLViewModel dsl = Application.Current.FindResource("DSL") as DSLViewModel;
+
+ Application.Current.Dispatcher.BeginInvoke(new Action(() => {
+ if (btnLog.IsChecked.Equals(true)) {
+ //log
+ string prepare = "State: {0}, Actual Data Rate: up: {1} down: {2}, Attainable Data Rate: up: {3} down: {4}, SNR Margin up: {5} down: {6}, CRC error count: up: {7} down: {8}, HEC error count: up: {9} down: {10}, FEC error count: up: {11} down: {12}";
+ log(string.Format(prepare, dsl.Connection.state, dsl.Line.uactual, dsl.Line.dactual, dsl.Line.uattainable, dsl.Line.dattainable, dsl.Line.uSNR, dsl.Line.dSNR, dsl.Line.uCRC, dsl.Line.dCRC, dsl.Line.uHEC, dsl.Line.dHEC, dsl.Line.uFEC, dsl.Line.dFEC));
+ log(string.Format("CRC/min up: {0} down: {1}, HEC/min up: {2} down: {3}, FEC/min up: {4} down: {5}", dsl.Line.uCRCsec, dsl.Line.dCRCsec, dsl.Line.uHECsec, dsl.Line.dHECsec, dsl.Line.uFECsec, dsl.Line.dFECsec));
+ }
+ }));
+ */
+ }
+
+ private void log (string value) {
+ DateTime time = DateTime.Now;
+
+ if (Directory.Exists("log/").Equals(false))
+ Directory.CreateDirectory("log/");
+
+ if (Directory.Exists("log/dsl/").Equals(false))
+ Directory.CreateDirectory("log/dsl/");
+
+ StreamWriter file = new StreamWriter(string.Concat("log/dsl/", time.ToString("dd.MM.yyyy"), ".txt"), true);
+ file.WriteLine(string.Concat("[", time.ToString("dd.MM.yyyy HH:mm:ss"), "]: ", value));
+ file.Close();
+ }
+
+ private void button_click (object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(reload)) {
+ SpeedportHybrid.initDSL();
+
+ DSLViewModel dsl = Application.Current.FindResource("DSL") as DSLViewModel;
+
+ if (lastReload.Equals(DateTime.MinValue).Equals(false)) {
+ DateTime now = DateTime.Now;
+ double difference = Math.Ceiling(Math.Ceiling((DateTime.Now - lastReload).TotalSeconds) / 60);
+
+ double diffdCRC = Math.Ceiling((dsl.Line.dCRC - lastdCRC) / difference);
+ double diffuCRC = Math.Ceiling((dsl.Line.uCRC - lastuCRC) / difference);
+ dsl.lastCRC = string.Format("CRC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuCRC, diffdCRC);
+
+ double diffdHEC = Math.Ceiling((dsl.Line.dHEC - lastdHEC) / difference);
+ double diffuHEC = Math.Ceiling((dsl.Line.uHEC - lastuHEC) / difference);
+ dsl.lastHEC = string.Format("HEC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuHEC, diffdHEC);
+
+ double diffdFEC = Math.Ceiling((dsl.Line.dFEC - lastdFEC) / difference);
+ double diffuFEC = Math.Ceiling((dsl.Line.uFEC - lastuFEC) / difference);
+ dsl.lastFEC = string.Format("FEC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuFEC, diffdFEC);
+ }
+
+ lastReload = DateTime.Now;
+ lastdCRC = dsl.Line.dCRC;
+ lastuCRC = dsl.Line.uCRC;
+
+ lastdHEC = dsl.Line.dHEC;
+ lastuHEC = dsl.Line.uHEC;
+
+ lastdFEC = dsl.Line.dFEC;
+ lastuFEC = dsl.Line.uFEC;
+
+ // TODO: calculate CRC/HEC/FEC difference betewen 2 refreshes
+
+ }
+ else if (sender.Equals(autoreload)) {
+ if (autoreload.IsChecked.Equals(true)) {
+ btnLog.IsEnabled = true;
+ StartTimer();
+ }
+ else {
+ if (btnLog.IsChecked.Equals(true)) {
+ btnLog.IsChecked = false;
+ }
+
+ btnLog.IsEnabled = false;
+ StopTimer();
+ }
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.LanPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="LanPage">
+
+ <Grid DataContext="{StaticResource DeviceData}">
+ <ListView ItemsSource="{Binding deviceList}" x:Name="listView4" Margin="0,0,0,39">
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Name" DisplayMemberBinding="{Binding Path=name}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="MAC" DisplayMemberBinding="{Binding Path=mac}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Type" DisplayMemberBinding="{Binding Path=type}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Connected" DisplayMemberBinding="{Binding Path=connected}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="IPv4" DisplayMemberBinding="{Binding Path=ipv4}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="IPv6" DisplayMemberBinding="{Binding Path=ipv6}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Static" DisplayMemberBinding="{Binding Path=mstatic}" Width="Auto"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" Click="button_click" VerticalAlignment="Bottom"/>
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for LanPage.xaml
+ /// </summary>
+ public partial class LanPage : Page {
+ public LanPage() {
+ InitializeComponent();
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(reload)) {
+ util.init("Lan");
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.LoginPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Loaded="loaded"
+ Width="Auto" Height="Auto"
+ Title="LoginPage">
+
+ <Grid>
+ <TextBlock x:Name="diTextBlock" HorizontalAlignment="Left" Margin="51,21,0,0" TextWrapping="Wrap" Text="Domain/IP:" VerticalAlignment="Top"/>
+ <TextBox x:Name="tbip" HorizontalAlignment="Left" Height="23" Margin="115,14,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="120"/>
+
+ <TextBlock x:Name="tbpw" Text="Passwort:" HorizontalAlignment="Left" Margin="55,49,0,0" VerticalAlignment="Top" />
+ <PasswordBox x:Name="PasswordBox" HorizontalAlignment="Left" Height="23" Margin="115,42,0,0" VerticalAlignment="Top" Width="120" ForceCursor="True"/>
+ <TextBox x:Name="PasswordTextBox" HorizontalAlignment="Left" Height="23" Margin="115,42,0,0" VerticalAlignment="Top" Width="120" Visibility="Hidden"/>
+ <CheckBox x:Name="PasswordCheckBox" Content="Passwort anzeigen" Margin="240,50,0,0" Checked="CheckBox" Unchecked="CheckBox" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <CheckBox x:Name="cbSave" Content="Passwort speichern" Margin="240,65,0,0" Checked="CheckBox" Unchecked="CheckBox" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <Button x:Name="button1" Content="Login" HorizontalAlignment="Left" Margin="115,70,0,0" VerticalAlignment="Top" Width="75" Click="button_click" IsDefault="True"/>
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+using System.Threading;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for LoginPage.xaml
+ /// </summary>
+ public partial class LoginPage : Page {
+ public bool savePW;
+
+ public LoginPage() {
+ InitializeComponent();
+ }
+
+ void loaded (object sender, RoutedEventArgs e) {
+ /*
+ SettingsModel settings = Settings.load();
+ if (settings.ip.IsNullOrEmpty().Equals(false)) {
+ SpeedportHybridAPI.getInstance().ip = settings.ip;
+ }
+
+ if (settings.password.IsNullOrEmpty().Equals(false)) {
+ savePW = true;
+ cbSave.IsChecked = true;
+ PasswordBox.Password = settings.password;
+ }
+
+ PasswordBox.Focus();
+
+ tbip.Text = SpeedportHybridAPI.getInstance().ip;
+ */
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(button1)) {
+ if (button1.Content.Equals("Login")) {
+ if (SpeedportHybridAPI.getInstance().ip.Equals(tbip.Text).Equals(false)) {
+ SpeedportHybridAPI.getInstance().ip = tbip.Text;
+ }
+
+ if (PasswordCheckBox.IsChecked.Equals(true)) {
+ PasswordBox.Password = PasswordTextBox.Text;
+ PasswordCheckBox.IsChecked = false;
+ }
+
+ if (SpeedportHybridAPI.getInstance().login(PasswordBox.Password).Equals(true)) {
+ util.login();
+ SettingsModel SettingsModel = null;
+
+ if (savePW.Equals(true)) {
+ SettingsModel = new SettingsModel {
+ password = PasswordBox.Password,
+ ip = SpeedportHybridAPI.getInstance().ip
+ };
+ }
+ else {
+ SettingsModel = new SettingsModel {
+ password = string.Empty,
+ ip = SpeedportHybridAPI.getInstance().ip
+ };
+ }
+
+ Settings.save(SettingsModel);
+ }
+ else {
+ new Thread(() => { MessageBox.Show("Login fehlgeschlagen. Sie haben ein falsches Gerätepasswort eingegeben. Bitte versuchen Sie es erneut und achten Sie auf die korrekte Schreibweise.", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Error); }).Start();
+ LogManager.WriteToLog("Login Failed, wrong password");
+ PasswordBox.Focus();
+ }
+ }
+ else if (button1.Content.Equals("Logout")) {
+ if (SpeedportHybridAPI.getInstance().logout().Equals(true)) {
+ util.logout();
+ }
+ }
+ }
+ */
+ }
+
+ private void CheckBox(object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(PasswordCheckBox)) {
+ if (PasswordCheckBox.IsChecked.Equals(true)) {
+ PasswordTextBox.Text = PasswordBox.Password;
+ PasswordBox.Visibility = Visibility.Hidden;
+ PasswordTextBox.Visibility = Visibility.Visible;
+ PasswordTextBox.Focus();
+ }
+ else {
+ PasswordBox.Password = PasswordTextBox.Text;
+ PasswordBox.Visibility = Visibility.Visible;
+ PasswordTextBox.Visibility = Visibility.Hidden;
+ PasswordBox.Focus();
+ }
+ }
+ else if (sender.Equals(cbSave)) {
+ if (cbSave.IsChecked.Equals(true)) {
+ savePW = true;
+ }
+ else {
+ savePW = false;
+ }
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.LteInfoPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="LteInfoPage">
+
+ <Grid DataContext="{StaticResource LTE}">
+ <GroupBox Header="LTE-parameter" HorizontalAlignment="Left" VerticalAlignment="Top">
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" Width="86">
+ <TextBlock Text="IMEI:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="IMSI:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Device Status:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Sim Card Status:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Antenna Mode:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Pysical Cell ID:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Cell ID:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="RSRP:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="RSRQ:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Service Status:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="TAC:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="Frequenz:" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ </StackPanel>
+ <StackPanel Margin="90,0,0,0" HorizontalAlignment="Left">
+ <TextBlock Text="{Binding imei}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding imsi}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding device_status}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding card_status}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding antenna_mode}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding phycellid}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding cellid}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Background="{Binding rsrp_bg}" Text="{Binding rsrp}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Background="{Binding rsrq_bg}" Text="{Binding rsrq}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding service_status}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding tac}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ <TextBlock Text="{Binding frequenz}" HorizontalAlignment="Left" VerticalAlignment="Top" />
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <ToggleButton x:Name="autoreload" Content="Automatisch aktualisieren" HorizontalAlignment="Left" Margin="0,214,0,0" VerticalAlignment="Top" Click="button_click"/>
+ <Button x:Name="btnPopup" Content="Popup" HorizontalAlignment="Left" Margin="145,214,0,0" VerticalAlignment="Top" Click="button_click"/>
+
+ <GroupBox Header="Einstelungen" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="188,209,0,0" Height="45" Width="284">
+ <Grid>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Antennen Modus:" VerticalAlignment="Top"/>
+ <ComboBox x:Name="cbAntenna" SelectedValue="{Binding antenna_mode2}" SelectedValuePath="Name" HorizontalAlignment="Left" Width="91" Margin="101,1,0,0">
+ <ComboBoxItem Content="Automatisch" Name="Auto" HorizontalAlignment="Left" Width="92"/>
+ <ComboBoxItem Content="Intern" Name="Inner" HorizontalAlignment="Left" Width="92"/>
+ <ComboBoxItem Content="Extern" Name="Outer" HorizontalAlignment="Left" Width="92"/>
+ </ComboBox>
+ <Button x:Name="btnSave" Content="Speichern" HorizontalAlignment="Left" Margin="197,1,0,2" Width="75" Click="button_click" />
+ </Grid>
+ </GroupBox>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+using System.Timers;
+using System;
+
+namespace SpeedportHybridControl.page {
+
+
+ /// <summary>
+ /// Interaction logic for LteInfoPage.xaml
+ /// </summary>
+ public partial class LteInfoPage : Page {
+ public Timer _timer;
+ //public ltepopup _ltepopup;
+ public LteInfoPage() {
+ InitializeComponent();
+ }
+
+ public void StopTimer () {
+ if (Object.Equals(_timer, null).Equals(false)) {
+ _timer.Stop();
+ }
+
+ if (autoreload.IsChecked.Equals(true)) {
+ autoreload.IsChecked = false;
+ }
+ }
+
+ private void StartTimer () {
+ _timer = new Timer {
+ Interval = 1000, // every second
+ };
+
+ _timer.Elapsed += timer_Elapsed;
+ _timer.Start();
+ }
+
+ void timer_Elapsed (object sender, ElapsedEventArgs e) {
+ //util.init("LTE");
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(reload)) {
+ util.init("LTE");
+ }
+ else if (sender.Equals(autoreload)) {
+ if (autoreload.IsChecked.Equals(true)) {
+ StartTimer();
+ }
+ else {
+ StopTimer();
+ }
+ }
+ else if (sender.Equals(btnSave)) {
+ ComboBoxItem item = cbAntenna.SelectedItem as ComboBoxItem;
+ SpeedportHybridAPI.getInstance().setAntennaMode(item.Name);
+ util.init("LTE");
+ }
+ else if (sender.Equals(btnPopup)) {
+ if (Object.Equals(_ltepopup, null)) {
+ _ltepopup = new ltepopup();
+ }
+ else if (Object.Equals(_ltepopup, null).Equals(false) && _ltepopup.IsLoaded.Equals(false)) {
+ _ltepopup = null;
+ _ltepopup = new ltepopup();
+ }
+
+ if (_ltepopup.Visibility.Equals(Visibility.Visible).Equals(false)) {
+ _ltepopup.Show();
+ StopTimer();
+ }
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.OverviewPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="OverviewPage">
+
+ <Grid DataContext="{StaticResource OverviewModel}">
+ <GroupBox Header="Internet" HorizontalAlignment="Left" VerticalAlignment="Top" Width="174">
+ <Grid>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding onlinestatus}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding dsl_link_status}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="LTE-Empfangsstärke" VerticalAlignment="Top"/>
+ <Image Source="{Binding lte_image}" HorizontalAlignment="Left" Margin="142,-16,0,0" VerticalAlignment="Top" Height="20"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Telefonie" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,76,0,0" Width="174">
+ <Grid>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Left" Text="{Binding number_status}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_dect}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding dect_devices}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Heimnetzwerk" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="179,0,0,0" Height="264" Width="321">
+ <Grid Margin="0,0,0,7">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Verbundene Geräte:" VerticalAlignment="Top" Width="107" Margin="0,10,0,0"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding devices}" VerticalAlignment="Top" Width="192" Margin="112,10,0,0"/>
+
+ <GroupBox Header="WLAN" HorizontalAlignment="Left" VerticalAlignment="Top" Height="196" Width="154" Margin="0,39,0,0">
+ <Grid>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_wlan}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_wlan_5ghz}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding wlan_enc}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding wlan_power}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Netzwerkspeicher" HorizontalAlignment="Left" VerticalAlignment="Top" Height="196" Width="154" Margin="155,39,0,0">
+ <Grid>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding external_devices}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding nas_sync_active}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding nas_backup_active}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding mc_state}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ </Grid>
+ </GroupBox>
+ <GroupBox Visibility="Collapsed" Header="Sicherheits-Status" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,173,0,0" Width="174">
+ <Grid>
+ <StackPanel>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Firewall aktiv" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Liste der sicheren E-Mail-Server aus" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Telekom-Datenschutz Aus" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for OverviewPage.xaml
+ /// </summary>
+ public partial class OverviewPage : Page {
+ public OverviewPage() {
+ InitializeComponent();
+ }
+
+ private void button_click (object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(reload)) {
+ util.init("Overview");
+ }
+ */
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.PhonePage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="PhonePage">
+ <Page.CommandBindings>
+ <CommandBinding
+ Command="ApplicationCommands.Copy"
+ Executed="CommandBinding_Executed"/>
+ </Page.CommandBindings>
+ <Grid DataContext="{StaticResource PhoneCallData}">
+ <TabControl Margin="0,0,0,39">
+ <TabItem Header="Verpasste Anrufe">
+ <Grid>
+ <ListView ItemsSource="{Binding missedCalls}" x:Name="listView1">
+ <ListView.ContextMenu>
+ <ContextMenu>
+ <MenuItem Header="Copy" Command="ApplicationCommands.Copy"/>
+ </ContextMenu>
+ </ListView.ContextMenu>
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Datum" DisplayMemberBinding="{Binding Path=date}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Uhrzeit" DisplayMemberBinding="{Binding Path=time}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Nummer/Name" DisplayMemberBinding="{Binding Path=who}"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+ </Grid>
+ </TabItem>
+ <TabItem Header="Angenommene Anrufe">
+ <Grid>
+ <ListView ItemsSource="{Binding takenCalls}" x:Name="listView2">
+ <ListView.ContextMenu>
+ <ContextMenu>
+ <MenuItem Header="Copy" Command="ApplicationCommands.Copy"/>
+ </ContextMenu>
+ </ListView.ContextMenu>
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Datum" DisplayMemberBinding="{Binding Path=date}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Uhrzeit" DisplayMemberBinding="{Binding Path=time}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Nummer/Name" DisplayMemberBinding="{Binding Path=who}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Dauer" DisplayMemberBinding="{Binding Path=duration}"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+ </Grid>
+ </TabItem>
+ <TabItem Header="Gewählte Rufnummern">
+ <Grid>
+ <ListView ItemsSource="{Binding dialedCalls}" x:Name="listView3">
+ <ListView.ContextMenu>
+ <ContextMenu>
+ <MenuItem Header="Copy" Command="ApplicationCommands.Copy"/>
+ </ContextMenu>
+ </ListView.ContextMenu>
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Datum" DisplayMemberBinding="{Binding Path=date}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Uhrzeit" DisplayMemberBinding="{Binding Path=time}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Nummer/Name" DisplayMemberBinding="{Binding Path=who}"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Dauer" DisplayMemberBinding="{Binding Path=duration}"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+ </Grid>
+ </TabItem>
+ </TabControl>
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+
+ <Button x:Name="btnClear" Content="Leeren" Click="button_click" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="72" Visibility="Collapsed"/>
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for PhonePage.xaml
+ /// </summary>
+ public partial class PhonePage : Page {
+ public PhonePage() {
+ InitializeComponent();
+ }
+
+ private void CommandBinding_Executed(object sender, RoutedEventArgs e) {
+ string text = string.Empty;
+
+ if (e.Source.Equals(listView1)) {
+ text = listView1.SelectedItem.ToString();
+ }
+ else if (e.Source.Equals(listView2)) {
+ text = listView2.SelectedItem.ToString();
+ }
+ else if (e.Source.Equals(listView3)) {
+ text = listView3.SelectedItem.ToString();
+ }
+ Clipboard.SetText(text);
+ text = null;
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ if (sender.Equals(reload)) {
+ //util.init("Phone");
+ }
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.StatusPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="StatusPage">
+
+ <Grid DataContext="{StaticResource Status}">
+ <GroupBox Header="Status-Informationen" HorizontalAlignment="Left" VerticalAlignment="Top" Width="235">
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" Width="120">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Name des Gerätes:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Firmware-Version:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Seriennummer:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="IMEI-Nummer:" VerticalAlignment="Top"/>
+ <TextBlock Text="Uptime:" />
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Right" Width="103">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding device_name}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding firmware_version}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding serial_number}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding imei}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding uptime}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Internet" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,103,0,0" Width="235">
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" Width="132">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="DSL-Link:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="DSL-Verbindung:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Downstream:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Upstream:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="LTE-Verbindung:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Empfangsstärke:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="WLAN TO GO (HotSpot):" VerticalAlignment="Top"/>
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Right" Width="91">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="NoWrap" Text="{Binding dsl_link_status}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding status}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding dsl_downstream}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding dsl_upstream}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding lte_status}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding lte_signal}" VerticalAlignment="Top"/>
+ <Image Source="{Binding lte_image}" HorizontalAlignment="Left" Margin="70,-18,0,0" VerticalAlignment="Top" Height="20"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding hsfon_status}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Heimnetzwerk" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="240,0,0,0" Width="270">
+ <Grid>
+ <StackPanel Margin="0,0,146,0">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="WLAN 2,4-GHz:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Name (SSID):" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Geräte:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="WLAN 5-GHz:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Name (SSID):" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text=" Geräte:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Geräte an LAN 1-4:" VerticalAlignment="Top"/>
+ </StackPanel>
+
+ <StackPanel Margin="112,0,0,0">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_wlan}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="NoWrap" Text="{Binding wlan_ssid}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding wlan_devices}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_wlan_5ghz}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="NoWrap" Text="{Binding wlan_5ghz_ssid}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding wlan_5ghz_devices}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="1" VerticalAlignment="Top"/>
+ <Image Source="{Binding lan1_device}" HorizontalAlignment="Left" Margin="8,-11,0,0" VerticalAlignment="Top" Height="10"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="2" Margin="21,-16,0,0" VerticalAlignment="Top"/>
+ <Image Source="{Binding lan2_device}" HorizontalAlignment="Left" Margin="29,-11,0,0" VerticalAlignment="Top" Height="10"/>
+ <TextBlock HorizontalAlignment="Left" Margin="42,-16,0,0" TextWrapping="Wrap" Text="3" VerticalAlignment="Top"/>
+ <Image Source="{Binding lan3_device}" HorizontalAlignment="Left" Margin="50,-11,0,0" VerticalAlignment="Top" Height="10"/>
+ <TextBlock HorizontalAlignment="Left" Margin="63,-16,0,0" TextWrapping="Wrap" Text="4" VerticalAlignment="Top"/>
+ <Image Source="{Binding lan4_device}" HorizontalAlignment="Left" Margin="71,-11,0,0" VerticalAlignment="Top" Height="10"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Telefonie" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="240,130,0,0" Width="270" Height="135">
+ <Grid>
+ <ListView ItemsSource="{Binding addphonenumber}" HorizontalAlignment="Left" Width="258" Margin="0,0,0,32">
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="nummer" DisplayMemberBinding="{Binding Path=number}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="status" DisplayMemberBinding="{Binding Path=status}" Width="Auto"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+
+ <StackPanel Margin="0,81,85,0">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="DECT-Basisstation:" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="Angemeldete Schnurlostelefone:" VerticalAlignment="Top"/>
+ </StackPanel>
+
+ <StackPanel Margin="183,81,0,0">
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding use_dect}" VerticalAlignment="Top"/>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="{Binding dect_devices}" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for StatusPage.xaml
+ /// </summary>
+ public partial class StatusPage : Page {
+ public StatusPage() {
+ InitializeComponent();
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ if (sender.Equals(reload)) {
+ //util.init("Status");
+ }
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.SyslogPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="SyslogPage">
+ <Page.CommandBindings>
+ <CommandBinding
+ Command="ApplicationCommands.Copy"
+ Executed="CommandBinding_Executed"/>
+ </Page.CommandBindings>
+ <Grid DataContext="{StaticResource SyslogData}">
+ <TextBlock HorizontalAlignment="Right" Margin="0,0,124,0" Text="Suche:" VerticalAlignment="Top"/>
+ <TextBox x:Name="tbSearch" HorizontalAlignment="Right" VerticalAlignment="Top" Width="120" Text="" TextChanged="TextChanged"/>
+
+ <ListView ItemsSource="{Binding syslogList}" x:Name="listView" Margin="0,23,0,39">
+ <ListView.ContextMenu>
+ <ContextMenu>
+ <MenuItem Header="Copy" Command="ApplicationCommands.Copy"/>
+ </ContextMenu>
+ </ListView.ContextMenu>
+ <ListView.Resources>
+ <Style TargetType="{x:Type GridViewColumnHeader}">
+ <Setter Property="HorizontalContentAlignment" Value="Left" />
+ </Style>
+ </ListView.Resources>
+ <ListView.View>
+ <GridView>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Datum" DisplayMemberBinding="{Binding timestamp}" Width="Auto"/>
+ <GridViewColumn TextBlock.TextAlignment="Left" Header="Meldung" DisplayMemberBinding="{Binding message}" Width="Auto"/>
+ </GridView>
+ </ListView.View>
+ </ListView>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ <Button x:Name="btnClear" Content="Leeren" Click="button_click" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="72"/>
+
+ <Button x:Name="btnReload" Content="Aktualisieren" Margin="218,0,218,0" Click="button_click" VerticalAlignment="Bottom"/>
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System;
+using SpeedportHybridControl.Model;
+using System.Threading.Tasks;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for SyslogPage.xaml
+ /// </summary>
+ public partial class SyslogPage : Page {
+ public SyslogPage() {
+ InitializeComponent();
+ }
+
+ public void init () {
+ tbSearch.Text = string.Empty;
+ }
+
+ private bool SyslogFilter (object item) {
+ //if (tbSearch.Text.IsNullOrEmpty().Equals(false)) {
+ // return ((item as SyslogList).message.IndexOf(tbSearch.Text, StringComparison.OrdinalIgnoreCase) >= 0);
+ //}
+
+ return true;
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ /*
+ if (sender.Equals(btnReload)) {
+ SpeedportHybrid.initSyslog();
+ TextChanged(null, null);
+ }
+ else if (sender.Equals(btnClear)) {
+ MessageBoxResult result = MessageBox.Show("Sollen die System-Informationen wirklich gelöscht werden?", "Confirmation", MessageBoxButton.YesNoCancel, MessageBoxImage.Question);
+ if (result.Equals(MessageBoxResult.Yes)) {
+ SpeedportHybridAPI.getInstance().clearSyslog();
+ util.init("Syslog");
+ tbSearch.Text = string.Empty;
+ }
+ }
+ */
+ }
+
+ public void TextChanged (object sender, TextChangedEventArgs e) {
+ /*
+ SyslogData syslog = Application.Current.FindResource("SyslogData") as SyslogData;
+ CollectionView collectionView = CollectionViewSource.GetDefaultView(syslog.syslogList) as CollectionView;
+ collectionView.Filter = SyslogFilter;
+
+ CollectionViewSource.GetDefaultView(syslog.syslogList).Refresh();
+ */
+ }
+
+ private void CommandBinding_Executed(object sender, RoutedEventArgs e) {
+ string text = string.Empty;
+
+ if (e.Source.Equals(listView)) {
+ text = listView.SelectedItem.ToString();
+ }
+
+ Clipboard.SetText(text);
+ text = null;
+ }
+ }
+}
--- /dev/null
+<Page x:Class="SpeedportHybridControl.page.TR181Page"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:local="clr-namespace:SpeedportHybridControl"
+ mc:Ignorable="d"
+ Width="Auto" Height="Auto"
+ Title="TR181Page">
+
+ <Grid DataContext="{StaticResource TR181}">
+ <GroupBox Header="TR181 Parameter" HorizontalAlignment="Left" VerticalAlignment="Top">
+ <Grid>
+ <StackPanel Margin="0,0,20,0">
+ <TextBlock Text="Enable:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="Status:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="Mode:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="ServerName:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="ServerIP:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="AvailableBW:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="LastErrorInfo:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="HelloStatus:" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ </StackPanel>
+
+ <StackPanel HorizontalAlignment="Left" VerticalAlignment="Top" Margin="76,0,0,0">
+ <TextBlock Text="{Binding enable1}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding status1}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding mode}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding servername}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding severip}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding bw}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding errorinfo}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding hellostatus}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Interface Status" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="335,76,0,0">
+ <Grid>
+ <StackPanel HorizontalAlignment="Left" Width="121" >
+ <TextBlock Text="LTE tunnel (LTE:tun):" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="DSL tunnel (DSL:tun):" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="Bonding (Bond):" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ </StackPanel>
+
+ <StackPanel Margin="121,0,0,0" HorizontalAlignment="Left">
+ <TextBlock Text="{Binding lte_tunnel}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding dsl_tunnel}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ <TextBlock Text="{Binding bonding}" HorizontalAlignment="Left" VerticalAlignment="Top"/>
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="Einstellungen" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="335,0,0,0" Height="76">
+ <Grid>
+ <TextBlock HorizontalAlignment="Left" TextWrapping="Wrap" Text="QueueSkbTimeOut:" VerticalAlignment="Top" Margin="0,3,0,0"/>
+ <TextBox x:Name="tbQueue" HorizontalAlignment="Left" Margin="115,2,0,0" TextWrapping="Wrap" Text="{Binding QueueSkbTimeOut}" VerticalAlignment="Top" Width="42" />
+ <Button x:Name="btnSave" Content="Speichern" HorizontalAlignment="Left" Margin="44,34,0,0" VerticalAlignment="Top" Width="75" Click="button_click" />
+ </Grid>
+ </GroupBox>
+ <GroupBox Header="BYPASS Info" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,151,0,0" Width="208">
+ <Grid>
+ <StackPanel Margin="0,0,61,0">
+ <TextBlock Text="DSL IP Up BandWidth:" />
+ <TextBlock Text="DSL IP Down BandWidth:" />
+ <TextBlock Text="Up ReservedBWRatio:" />
+ <TextBlock Text="Down ReservedBWRatio:" />
+ <TextBlock Text="Bypass Check Interval:" />
+ </StackPanel>
+ <StackPanel Margin="135,0,0,0">
+ <TextBlock TextAlignment="Center" Text="{Binding bypass_up_bw}" />
+ <TextBlock TextAlignment="Center" Text="{Binding bypass_dw_bw}" />
+ <TextBlock TextAlignment="Center" Text="{Binding bypass_up_rb}" />
+ <TextBlock TextAlignment="Center" Text="{Binding bypass_dw_rb}" />
+ <TextBlock TextAlignment="Center" Text="{Binding bypass_check}" />
+ </StackPanel>
+ </Grid>
+ </GroupBox>
+
+ <TextBlock Text="{Binding datetime}" Margin="0,0,10,0" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
+ <Button x:Name="reload" Content="Aktualisieren" Margin="218,0,218,0" VerticalAlignment="Bottom" Click="button_click" />
+ </Grid>
+</Page>
--- /dev/null
+using System.Windows;
+using System.Windows.Controls;
+
+namespace SpeedportHybridControl.page {
+ /// <summary>
+ /// Interaction logic for TR181Page.xaml
+ /// </summary>
+ public partial class TR181Page : Page {
+ public TR181Page() {
+ InitializeComponent();
+ }
+
+ private void button_click(object sender, RoutedEventArgs e) {
+ if (sender.Equals(reload)) {
+ //util.init("TR181");
+ }
+ else if (sender.Equals(btnSave)) {
+ //SpeedportHybridAPI.getInstance().setQueueSkbTimeOut(tbQueue.Text);
+ }
+ }
+ }
+}
+++ /dev/null
-<Page x:Class="SpeedportHybridControl.page.test"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:SpeedportHybridControl.page"
- mc:Ignorable="d"
- d:DesignHeight="300" d:DesignWidth="300"
- Title="test">
-
- <Grid Background="red">
-
- </Grid>
-</Page>
+++ /dev/null
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Data;
-using System.Windows.Documents;
-using System.Windows.Input;
-using System.Windows.Media;
-using System.Windows.Media.Imaging;
-using System.Windows.Navigation;
-using System.Windows.Shapes;
-
-namespace SpeedportHybridControl.page {
- /// <summary>
- /// Interaction logic for test.xaml
- /// </summary>
- public partial class test : Page {
- public test () {
- InitializeComponent();
- }
- }
-}
+++ /dev/null
-<Page x:Class="SpeedportHybridControl.page.test1"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:SpeedportHybridControl.page"
- mc:Ignorable="d"
- Width="Auto" Height="Auto"
- Title="test1">
-
- <Grid>
- <StackPanel HorizontalAlignment="Left" Width="117" Height="282" VerticalAlignment="Top" Margin="10,0,0,0">
- <StackPanel.Resources>
- <Style TargetType="{x:Type Button}">
- <Setter Property="Margin" Value="0,3,0,0"/>
- </Style>
- </StackPanel.Resources>
-
- <Button x:Name="button7" Content="Router Neustarten"/>
- <Button x:Name="button9" Content="DSL neu verbinden"/>
- <Button x:Name="button10" Content="Firmware-Update"/>
- <Button x:Name="btnflushdns" Content="DNS Cache Leeren"/>
- <Button x:Name="btnSpeedtest" Content="speedtest.net"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button x:Name="button17" Content="Werkseinstellungen" />
- </StackPanel>
-
- <StackPanel HorizontalAlignment="Left" Width="117" Height="282" VerticalAlignment="Top" Margin="132,0,0,0">
- <StackPanel.Resources>
- <Style TargetType="{x:Type Button}">
- <Setter Property="Margin" Value="0,3,0,0"/>
- </Style>
- </StackPanel.Resources>
-
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button x:Name="button8" Content="LTE neu verbinden" />
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button x:Name="btnSpeedtest2" Content="speedtest.t-online.de"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button x:Name="btnDSLdisconnect" Content="DSL Trennen"/>
- <Button x:Name="btnLTEdisconnect" Content="LTE Trennen"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- </StackPanel>
-
- <StackPanel HorizontalAlignment="Left" Width="140" Height="282" VerticalAlignment="Top" Margin="254,0,0,0">
- <StackPanel.Resources>
- <Style TargetType="{x:Type Button}">
- <Setter Property="Margin" Value="0,3,0,0"/>
- </Style>
- </StackPanel.Resources>
-
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button IsEnabled="False" x:Name="button" Content="DSL + LTE neu verbinden"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button x:Name="btnDSLconnect" Content="DSL Verbinden"/>
- <Button x:Name="btnLTEconnect" Content="LTE Verbinden"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- <Button Visibility="Hidden" Content="[SPACER]"/>
- </StackPanel>
- </Grid>
-</Page>
+++ /dev/null
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Data;
-using System.Windows.Documents;
-using System.Windows.Input;
-using System.Windows.Media;
-using System.Windows.Media.Imaging;
-using System.Windows.Navigation;
-using System.Windows.Shapes;
-
-namespace SpeedportHybridControl.page {
- /// <summary>
- /// Interaction logic for test1.xaml
- /// </summary>
- public partial class test1 : Page {
- public test1 () {
- InitializeComponent();
- }
- }
-}