631 lines
46 KiB
XML
631 lines
46 KiB
XML
<UserControl x:Class="OperationControl.Views.Operacao.Monitoramento.DiagnosticoView"
|
|
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:OperationControl.Views.Operacao"
|
|
xmlns:scott="clr-namespace:ScottPlot.WPF;assembly=ScottPlot.WPF"
|
|
mc:Ignorable="d"
|
|
d:DesignHeight="900"
|
|
d:DesignWidth="1600">
|
|
|
|
<UserControl.Resources>
|
|
<BooleanToVisibilityConverter x:Key="BoolToVisibilityConverter"/>
|
|
|
|
<Style x:Key="DiagnosticoModuloButtonStyle" TargetType="Button">
|
|
<Setter Property="Width" Value="58"/>
|
|
<Setter Property="Height" Value="24"/>
|
|
<Setter Property="FontSize" Value="10"/>
|
|
<Setter Property="FontWeight" Value="SemiBold"/>
|
|
<Setter Property="Cursor" Value="Hand"/>
|
|
<Setter Property="Padding" Value="4,0"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="Button">
|
|
<Border x:Name="Bd"
|
|
Background="{TemplateBinding Background}"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
BorderThickness="{TemplateBinding BorderThickness}"
|
|
CornerRadius="10"
|
|
SnapsToDevicePixels="True">
|
|
<ContentPresenter HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"
|
|
RecognizesAccessKey="True"/>
|
|
</Border>
|
|
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsMouseOver" Value="True">
|
|
<Setter TargetName="Bd" Property="Opacity" Value="0.92"/>
|
|
</Trigger>
|
|
|
|
<Trigger Property="IsPressed" Value="True">
|
|
<Setter TargetName="Bd" Property="Opacity" Value="0.82"/>
|
|
</Trigger>
|
|
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter TargetName="Bd" Property="Opacity" Value="0.45"/>
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
</UserControl.Resources>
|
|
|
|
<Grid Margin="12">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1.55*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<!-- COLUNA ESQUERDA | MAPA VISUAL DO ROBÔ -->
|
|
<Border Grid.Column="0"
|
|
Margin="0,0,10,0"
|
|
Padding="16"
|
|
CornerRadius="10"
|
|
Background="#202020"
|
|
BorderBrush="#353535"
|
|
BorderThickness="1">
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<!-- CABEÇALHO -->
|
|
<StackPanel Grid.Row="0" Margin="0,0,0,12">
|
|
<TextBlock Text="Diagnóstico do rover"
|
|
FontSize="18"
|
|
FontWeight="SemiBold"
|
|
Foreground="#E6E6E6"/>
|
|
|
|
<TextBlock Text="{Binding ImpedimentoOperacaoTexto}"
|
|
Margin="0,6,0,0"
|
|
FontSize="12"
|
|
Foreground="#B8B8B8"
|
|
TextWrapping="Wrap"/>
|
|
</StackPanel>
|
|
|
|
<!-- ÁREA DO ROBÔ -->
|
|
<Viewbox Grid.Row="1" Stretch="Uniform">
|
|
<Grid Width="700" Height="820">
|
|
<Border CornerRadius="12"
|
|
Background="#1A1A1A"
|
|
BorderBrush="#2F2F2F"
|
|
BorderThickness="1"/>
|
|
|
|
<Image Source="/Resources/robo_superior.jpg"
|
|
Width="800"
|
|
Height="750"
|
|
Stretch="Uniform"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"/>
|
|
|
|
<ItemsControl ItemsSource="{Binding DiagnosticoModulos}">
|
|
<ItemsControl.ItemsPanel>
|
|
<ItemsPanelTemplate>
|
|
<Canvas />
|
|
</ItemsPanelTemplate>
|
|
</ItemsControl.ItemsPanel>
|
|
|
|
<ItemsControl.ItemContainerStyle>
|
|
<Style TargetType="ContentPresenter">
|
|
<Setter Property="Canvas.Left" Value="{Binding Left}" />
|
|
<Setter Property="Canvas.Top" Value="{Binding Top}" />
|
|
</Style>
|
|
</ItemsControl.ItemContainerStyle>
|
|
|
|
<ItemsControl.ItemTemplate>
|
|
<DataTemplate>
|
|
<Button Content="{Binding TextoExibicao}"
|
|
Style="{StaticResource DiagnosticoModuloButtonStyle}"
|
|
Background="{Binding BackgroundBrush}"
|
|
Foreground="{Binding ForegroundBrush}"
|
|
BorderBrush="{Binding BorderBrushColor}"
|
|
BorderThickness="{Binding BorderThicknessValue}"
|
|
Command="{Binding DataContext.SelecionarModuloCommand, RelativeSource={RelativeSource AncestorType=UserControl}}"
|
|
CommandParameter="{Binding}" />
|
|
</DataTemplate>
|
|
</ItemsControl.ItemTemplate>
|
|
</ItemsControl>
|
|
</Grid>
|
|
</Viewbox>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<!-- COLUNA DIREITA | DETALHES -->
|
|
<Border Grid.Column="1" Margin="10,0,0,0" Padding="16" CornerRadius="10" Background="#202020" BorderBrush="#353535" BorderThickness="1">
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<!-- TÍTULO -->
|
|
<StackPanel Grid.Row="0">
|
|
<TextBlock Text="{Binding TituloModuloSelecionado}" FontSize="18" FontWeight="SemiBold" Foreground="#E6E6E6"/>
|
|
|
|
<TextBlock Text="{Binding DescricaoModuloSelecionado}" Margin="0,6,0,0" FontSize="12" Foreground="#A8A8A8" TextWrapping="Wrap"/>
|
|
</StackPanel>
|
|
|
|
<!-- RESUMO -->
|
|
<Border Grid.Row="1" Margin="0,14,0,12" Padding="12" Background="#181818" BorderBrush="#2F2F2F" BorderThickness="1" CornerRadius="8">
|
|
<Grid>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<WrapPanel Grid.Row="0" Margin="0,0,0,8">
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoModulo}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoLabel}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoSCode}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
</WrapPanel>
|
|
|
|
<WrapPanel Grid.Row="1" Margin="0,0,0,8">
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoStatus}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoSaude}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoIniciado}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
</WrapPanel>
|
|
|
|
<WrapPanel Grid.Row="2" Margin="0,0,0,8">
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoCan}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoLatencia}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
|
|
<Border Background="#2B2B2B" CornerRadius="6" Padding="8,4" Margin="0,0,8,8">
|
|
<TextBlock Text="{Binding InfoIdVisual}" Foreground="#D8D8D8" FontSize="12"/>
|
|
</Border>
|
|
</WrapPanel>
|
|
|
|
<TextBlock Grid.Row="3" Text="{Binding ImpedimentoModuloSelecionado}" Foreground="#C8C8C8" FontSize="12" TextWrapping="Wrap"/>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<!-- AÇÕES -->
|
|
<StackPanel Grid.Row="2" Orientation="Horizontal" Margin="0,0,0,12">
|
|
<CheckBox Content="Mandatório" Margin="0,0,14,0" Foreground="#D8D8D8" VerticalAlignment="Center" IsChecked="{Binding MandatorioSelecionado, Mode=TwoWay}"/>
|
|
|
|
<CheckBox Content="Em uso" Margin="0,0,14,0" Foreground="#D8D8D8" VerticalAlignment="Center" IsChecked="{Binding EmUsoSelecionado, Mode=TwoWay}"/>
|
|
|
|
<Button Content="Salvar" Width="80" Height="28" Background="#2E5C8A" Foreground="White" BorderBrush="#4F7EAD" Command="{Binding SalvarSaudeCommand}"/>
|
|
</StackPanel>
|
|
|
|
<!-- TABS -->
|
|
<TabControl Grid.Row="3" Background="#181818" BorderBrush="#2F2F2F" Foreground="#DDDDDD">
|
|
<TabItem Header="Condições Operacionais">
|
|
<Grid Background="#181818">
|
|
<ListBox ItemsSource="{Binding CondicoesOperacionais}" Margin="8" Background="#121212" Foreground="#DDDDDD" BorderBrush="#2D2D2D"/>
|
|
</Grid>
|
|
</TabItem>
|
|
|
|
<TabItem Header="Acompanhamento">
|
|
<Grid Background="#181818">
|
|
<scott:WpfPlot x:Name="pltSaude_Acompanhamento" Margin="8"/>
|
|
</Grid>
|
|
</TabItem>
|
|
|
|
<TabItem Header="Opções">
|
|
<Grid Background="#181818">
|
|
<ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled" Padding="8">
|
|
<Grid>
|
|
<TextBlock Text="Nenhum teste disponível para este módulo." FontSize="12" Foreground="#A8A8A8" HorizontalAlignment="Center" VerticalAlignment="Center" TextWrapping="Wrap" Visibility="{Binding OpcoesVM.MostrarOpcoesSemDados, Converter={StaticResource BoolToVisibilityConverter}}"/>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesSensoriamento, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<StackPanel Orientation="Horizontal" Margin="0,10,0,0">
|
|
<Label Content="Reinicia o módulo" Foreground="#DDDDDD"/>
|
|
<Button Content="Reiniciar" Width="90" Margin="8,0,0,0" Command="{Binding OpcoesVM.SensoriamentoReiniciarCommand}"/>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesAtuador, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<StackPanel Orientation="Horizontal" Margin="0,10,0,0">
|
|
<Label Content="Reinicia o módulo" Foreground="#DDDDDD"/>
|
|
<Button Content="Reiniciar" Width="90" Margin="8,0,0,0" Command="{Binding OpcoesVM.AtuadorReiniciarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,10,0,0">
|
|
<Label Content="Altura" Foreground="#DDDDDD"/>
|
|
<Slider Width="120" Margin="8,0" Minimum="50" Maximum="80" Value="{Binding OpcoesVM.BarraAltura, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.BarraAlturaTexto}" Foreground="#DDDDDD"/>
|
|
<Button Content="Mover" Width="60" Margin="8,0,0,0" Command="{Binding OpcoesVM.BarraMoverCommand}"/>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesBico, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="{Binding OpcoesVM.BicoTitulo}" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
<Button Content="Ligar" Width="80" Margin="0,0,5,0" Command="{Binding OpcoesVM.BicoLigarCommand}"/>
|
|
<Button Content="Desligar" Width="80" Command="{Binding OpcoesVM.BicoDesligarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,8,0,0">
|
|
<Label Content="Movimento" Foreground="#DDDDDD"/>
|
|
<Slider Width="160" Margin="8,0" Minimum="-90" Maximum="90" Value="{Binding OpcoesVM.BicoAngulo, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.BicoAnguloTexto}" Foreground="#DDDDDD"/>
|
|
<Button Content="Mover" Width="60" Margin="8,0,0,0" Command="{Binding OpcoesVM.BicoMoverCommand}"/>
|
|
</StackPanel>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,8,0,0">
|
|
<Label Content="Ângulo abertura" Foreground="#DDDDDD"/>
|
|
<TextBox Width="60" Margin="8,0" Text="{Binding OpcoesVM.BicoAnguloAbertura, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
|
<Button Content="Salvar" Width="60" Command="{Binding OpcoesVM.BicoSalvarAnguloAberturaCommand}"/>
|
|
</StackPanel>
|
|
|
|
<TextBlock Text="Bico - Leituras" Foreground="#DDDDDD" FontWeight="SemiBold" Margin="0,10,0,4"/>
|
|
|
|
<UniformGrid Rows="2" Columns="3">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Comando enviado" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoComando}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Status real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoStatusReal}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Tempo ligado" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoTempoLigado}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Vazão" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoVazao}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Pressão" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoPressao}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Atuações" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBicoAtuacoes}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesBomba, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="{Binding OpcoesVM.BombaTitulo}" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
<Button Content="Ligar" Width="80" Margin="0,0,5,0" Command="{Binding OpcoesVM.BombaLigarCommand}"/>
|
|
<Button Content="Desligar" Width="80" Margin="0,0,10,0" Command="{Binding OpcoesVM.BombaDesligarCommand}"/>
|
|
<TextBlock Text="Pressão alvo:" VerticalAlignment="Center" Margin="0,0,5,0" FontSize="10" Foreground="#DDDDDD"/>
|
|
<Slider Width="120" Minimum="0" Maximum="150" Margin="0,0,5,0" Value="{Binding OpcoesVM.BombaPressaoAlvo, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.BombaPressaoAlvoTexto}" VerticalAlignment="Center" FontSize="10" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
<StackPanel Orientation="Horizontal" Margin="172 5 0 0">
|
|
<TextBlock Text="Potencia alvo:" VerticalAlignment="Center" Margin="0,0,5,0" FontSize="10" Foreground="#DDDDDD"/>
|
|
<Slider Width="120" Minimum="0" Maximum="100" Margin="0,0,5,0" Value="{Binding OpcoesVM.BombaPotenciaAlvo, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.BombaPotenciaAlvoTexto}" VerticalAlignment="Center" FontSize="10" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="2" Columns="2" Margin="0,10,0,0">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Comando enviado" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBombaComando}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Status real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBombaStatusReal}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Pressão linha" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBombaPressaoLinha}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Potência" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtBombaPotencia}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesDirecional, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="{Binding OpcoesVM.DirTitulo}" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
<Button Content="Referenciar" Width="90" Margin="0,0,5,0" Command="{Binding OpcoesVM.DirReferenciarCommand}"/>
|
|
<Button Content="Mover" Width="80" Command="{Binding OpcoesVM.DirMovimentarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,8,0,0">
|
|
<ComboBox Width="130" Margin="0,0,8,0" ItemsSource="{Binding OpcoesVM.DirMovimentosDisponiveis}" SelectedItem="{Binding OpcoesVM.DirMovimentoSelecionado, Mode=TwoWay}"/>
|
|
<ComboBox Width="130" Margin="0,0,8,0" ItemsSource="{Binding OpcoesVM.DirDirecoesDisponiveis}" SelectedItem="{Binding OpcoesVM.DirDirecaoSelecionada, Mode=TwoWay}"/>
|
|
<Slider Width="120" Minimum="0" Maximum="180" Margin="0,0,8,0" Value="{Binding OpcoesVM.DirAngulo, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.DirAnguloTexto}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="2" Columns="2" Margin="0,10,0,0">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Sentido controle" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtDirSentidoSP}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Sentido real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtDirSentido}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Ângulo controle" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtDirAnguloSP}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Ângulo real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtDirAngulo}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesGps, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="Lever Arm" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,0,0,8">
|
|
<Label Content="Lateral" Foreground="#DDDDDD"/>
|
|
<Slider Width="110" Minimum="-100" Maximum="100" Margin="8,0" Value="{Binding OpcoesVM.GpsLeverArmLateral, Mode=TwoWay}" TickFrequency="1" IsSnapToTickEnabled="True" SmallChange="1" LargeChange="1"/>
|
|
<Label Content="{Binding OpcoesVM.GpsLeverArmLateralTexto}" Foreground="#DDDDDD" Margin="0,0,10,0"/>
|
|
|
|
<Label Content="Frontal" Foreground="#DDDDDD"/>
|
|
<Slider Width="110" Minimum="-100" Maximum="100" Margin="8,0" Value="{Binding OpcoesVM.GpsLeverArmFrontal, Mode=TwoWay}" TickFrequency="1" IsSnapToTickEnabled="True" SmallChange="1" LargeChange="1"/>
|
|
<Label Content="{Binding OpcoesVM.GpsLeverArmFrontalTexto}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
|
|
<Button Content="Salvar" Width="80" Margin="0,0,0,8" Command="{Binding OpcoesVM.GpsSalvarCommand}"/>
|
|
|
|
<UniformGrid Rows="2" Columns="3">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Correção" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsCorrecao}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Idade" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsIdade}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Precisão" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsPrecisao}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Satélites" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsNSatelites}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Distância base" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsDistBase}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Orientação" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtGpsOrientacao}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesTrajetoria, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="Status do trabalho" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,0,0,8">
|
|
<CheckBox Content="Bateria Liberada" Margin="0,0,12,0" Foreground="#DDDDDD" IsChecked="{Binding OpcoesVM.TrajetoriaBatLiberada, Mode=TwoWay}"/>
|
|
<CheckBox Content="Pulverizador Liberado" Margin="0,0,12,0" Foreground="#DDDDDD" IsChecked="{Binding OpcoesVM.TrajetoriaHerbLiberado, Mode=TwoWay}"/>
|
|
<Button Content="Confirmar" Width="80" Command="{Binding OpcoesVM.TrajetoriaConfirmarCommand}" IsEnabled="{Binding OpcoesVM.TrajetoriaPodeConfirmar}"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="2" Columns="3">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Distância corredor" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaDistCorredor}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Distância segura bateria" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaDistBateria}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Distância segura pulverizador" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaDistPulverizador}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Status" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaStatus}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Bateria suficiente" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaBatOk}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Herbicida suficiente" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtTrajetoriaHerbOk}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesRele, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="{Binding OpcoesVM.ReleTitulo}" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
<Button Content="Ligar" Width="80" Margin="0,0,5,0" Command="{Binding OpcoesVM.ReleLigarCommand}"/>
|
|
<Button Content="Desligar" Width="80" Command="{Binding OpcoesVM.ReleDesligarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="1" Columns="2" Margin="0,10,0,0">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Comando enviado" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtReleComando}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Status real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtReleStatusReal}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesServo, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<TextBlock Text="Servo - Testes" FontWeight="Bold" Foreground="#DDDDDD" Margin="0,0,0,8"/>
|
|
|
|
<StackPanel Orientation="Horizontal">
|
|
<Label Content="Controle" Foreground="#DDDDDD"/>
|
|
<Slider Width="160" Margin="8,0" Minimum="0" Maximum="90" Value="{Binding OpcoesVM.ServoAngulo, Mode=TwoWay}"/>
|
|
<Label Content="{Binding OpcoesVM.ServoAnguloTexto}" Foreground="#DDDDDD"/>
|
|
<Button Content="Enviar" Width="80" Margin="8,0,0,0" Command="{Binding OpcoesVM.ServoEnviarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="1" Columns="3" Margin="0,10,0,0">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Comando enviado" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtServoComando}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Status real" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtServoLeitura}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Modo" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtServoIncremental}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
|
|
<StackPanel Visibility="{Binding OpcoesVM.MostrarOpcoesNpc, Converter={StaticResource BoolToVisibilityConverter}}">
|
|
<StackPanel Orientation="Horizontal" Margin="0,0,0,8">
|
|
<Label Content="Modo de Controle" Foreground="#DDDDDD"/>
|
|
<ComboBox Width="120" Margin="8,0" ItemsSource="{Binding OpcoesVM.NpcCoolerModosDisponiveis}" SelectedItem="{Binding OpcoesVM.NpcCoolerModoSelecionado, Mode=TwoWay}"/>
|
|
<CheckBox Content="Entrada" Margin="10,0,0,0" Foreground="#DDDDDD" IsChecked="{Binding OpcoesVM.NpcCoolerEntrada, Mode=TwoWay}"/>
|
|
<CheckBox Content="Saída" Margin="10,0,0,0" Foreground="#DDDDDD" IsChecked="{Binding OpcoesVM.NpcCoolerSaida, Mode=TwoWay}"/>
|
|
</StackPanel>
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,0,0,8">
|
|
<Label Content="Temperatura ligar" Foreground="#DDDDDD"/>
|
|
<TextBox Width="50" Margin="8,0" Text="{Binding OpcoesVM.NpcCoolerTempOn, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
|
<Label Content="Temperatura turbo" Foreground="#DDDDDD" Margin="12,0,0,0"/>
|
|
<TextBox Width="50" Margin="8,0" Text="{Binding OpcoesVM.NpcCoolerTempTurbo, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
|
<Button Content="Enviar" Width="80" Margin="10,0,0,0" Command="{Binding OpcoesVM.NpcCoolerEnviarCommand}"/>
|
|
</StackPanel>
|
|
|
|
<UniformGrid Rows="2" Columns="2">
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Modo controle" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtNpcCoolerModo}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Temperatura" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtNpcCoolerTemperatura}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Cooler entrada" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtNpcCoolerEntrada}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
<Border BorderBrush="#444" BorderThickness="1" Margin="2" Padding="4">
|
|
<StackPanel>
|
|
<TextBlock Text="Cooler saída" FontSize="10" Foreground="#AAAAAA"/>
|
|
<TextBlock Text="{Binding OpcoesVM.TxtNpcCoolerSaida}" Foreground="#DDDDDD"/>
|
|
</StackPanel>
|
|
</Border>
|
|
</UniformGrid>
|
|
</StackPanel>
|
|
</Grid>
|
|
</ScrollViewer>
|
|
</Grid>
|
|
</TabItem>
|
|
|
|
<TabItem Header="Logs">
|
|
<Grid Background="#181818">
|
|
<ListBox ItemsSource="{Binding LogsModuloSelecionado}"
|
|
Margin="8"
|
|
Background="#121212"
|
|
Foreground="#DDDDDD"
|
|
BorderBrush="#2D2D2D"/>
|
|
</Grid>
|
|
</TabItem>
|
|
</TabControl>
|
|
</Grid>
|
|
</Border>
|
|
</Grid>
|
|
</UserControl> |