aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Controls/HiveComboControl.xaml
blob: 692b3f818124a7e3d76c27794dd1742965daf992 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<UserControl x:Class="Tango.MachineStudio.Common.Controls.HiveComboControl"
             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:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
             xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
             xmlns:shapes="clr-namespace:Tango.SharedUI.Shapes;assembly=Tango.SharedUI"
             xmlns:local="clr-namespace:Tango.MachineStudio.Common.Controls"
             mc:Ignorable="d" 
             Height="250" Width="415">
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="1*"/>
            <ColumnDefinition Width="70"/>
            <ColumnDefinition Width="50"/>
        </Grid.ColumnDefinitions>

        <Viewbox Stretch="Uniform" Grid.Column="0" Margin="5">
            <controls:HiveControl x:Name="hive" x:FieldModifier="public" Height="250" HexagonSelected="OnHexagonSelected" MaxSelections="1" Width="250" BorderThickness="1"  />
        </Viewbox>

        <Grid Grid.Column="1" ClipToBounds="True">
            <Viewbox Stretch="Fill" Width="160" Height="200" HorizontalAlignment="Right" Margin="0 0 -20 0">
                <controls:HiveControl  Height="290" HexagonSelected="OnRowHiveHexagonSelected" MaxSelections="1" Width="100" Margin="0 0 50 0" HiveWidth="1" HiveHeight="5" BorderThickness="1"  />
            </Viewbox>
        </Grid>

        <Grid Grid.Column="2">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="45"/>
                    <RowDefinition Height="1*"/>
                </Grid.RowDefinitions>
                <Button ToolTip="Increase Delta Resolution" Click="OnResolutionUpClicked" Style="{StaticResource MaterialDesignFlatButton}" Height="50" Padding="0" Foreground="#202020" VerticalAlignment="Bottom">
                    <materialDesign:PackIcon Kind="ArrowUp" Width="24" Height="24" />
                </Button>

                <Grid Grid.Row="1">
                    <shapes:Hexagon Stroke="#202020" StrokeThickness="1" Margin="5" />
                    <TextBlock TextAlignment="Center" HorizontalAlignment="Center" VerticalAlignment="Center" FontWeight="Bold" FontStyle="Italic" FontSize="10">
                        <Run Text="&#916;"></Run>
                        <Run Text="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=Resolution,FallbackValue=1}"></Run>
                    </TextBlock>
                </Grid>

                <Button ToolTip="Decrease Delta Resolution" Click="OnResolutionDownClicked" Grid.Row="2" Style="{StaticResource MaterialDesignFlatButton}" Height="50" Padding="0" Foreground="#202020" VerticalAlignment="Top">
                    <materialDesign:PackIcon Kind="ArrowDown" Width="24" Height="24" />
                </Button>
            </Grid>
        </Grid>
    </Grid>
</UserControl>
n> ThreadPrepareState(void *JobDetails); uint32_t ThreadPreSegmentState(void *SegmentDetails, uint32_t SegmentId); uint32_t ThreadSegmentState(void *SegmentDetails, int SegmentId); uint32_t ThreadDistanceToSpoolState(void); uint32_t ThreadEndState(); bool Set_Thread_Rockers_Bypass (int value); uint32_t StoreDancerConfigMessage(void); uint32_t LoadDancerConfigMessage(void); //uint32_t MotorPidRequestMessage(HardwarePidControl* request); extern float NumberOfRotationPerPassage; //debug for rotation per passage trials uint32_t Winder_Init(void); uint32_t Winder_Prepare(void *JobDetails); uint32_t Winder_Presegment(void *JobDetails, uint32_t SegmentId); uint32_t WinderDistanceToSpoolState(void ); uint32_t Winder_End(void); typedef enum { /*00*/ THREAD_LOAD_INIT, /*01*/ THREAD_LOAD_REDUCE_HEAT, //HEATERS OFF, DRYER BLOWER OFF, BLOWER LOW, /*02*/ THREAD_LOAD_LIFT_ROCKERS, //MACHINE IS READY. SEND MESSAGE, START TIMER TO CLOSE LIDS, WAIT FOR OPERATOR RESPONSE /*03*/ THREAD_LOAD_SET_LOAD_ARM_TO_START_POSITION,//USE NOTATION HOW MANY ROTATIONS IN THE DRYER, OR CHECK AGAINST STOPPER. MOVE SLOWLY /*04*/ THREAD_LOAD_OPEN_COVERS, //OPEN DYEING HEAD COVER AND DRYER LID /*05*/ THREAD_LOAD_LIFT_DANCERS, /*06*/ THREAD_LOAD_INITIAL_TENSION,//CHECK SPOOL PRESENCERUN WINDER UNTIL BREAK SENSOR IS IDENTIFIEING MOVEMENT FOR A SECOND /*07*/ THREAD_LOAD_CLOSE_ROCKERS, /*08*/ THREAD_LOAD_CLOSE_DANCERS, //SEND DANCER MOTORS TO PRESET LOCATION, CHECK THAT THE DANCERS ARE ON THE THREAD /*09*/ THREAD_LOAD_CLOSE_LIDS, /*10*/ THREAD_LOAD_JOG_FEEDER_TO_MIDDLE_POINT,//JOG THE FEEDER MOTOR UNTIL THE FEEDER DANCER IS AT MIDDLE POSITION /*11*/ THREAD_LOAD_DRYER_LOADING, //START FEEDER PID, ROTATE LOADING ARM COUNTER THREAD DIRECTION X CIRCLES ACCORDING TO RML. FEEDER SPEED IS 40 //KEEP NOTATION HOW MANY ROTATIONS IN THE DRYER /*12*/ THREAD_LOAD_RESUME_HEATING, /*13*/ THREAD_LOAD_JOG_THREAD, //JOG THREAD SHORTLY TO MAKE SURE SPOOL IS RUNNING. REPORT END OF LOADING /*14*/ THREAD_LOAD_END }THREAD_LOAD_STAGES_ENUM; uint32_t ThreadLoadButton(THREAD_LOAD_STAGES_ENUM ReadValue); bool ThreadLoadingActive(void); void ThreadLoadPollRequest(MessageContainer* requestContainer); void ThreadLoadRequest(MessageContainer* requestContainer); uint32_t StartThreadLoadingFunc(MessageContainer* requestContainer); uint32_t ContinueThreadLoadingFunc(MessageContainer* requestContainer); uint32_t StopThreadLoadingFunc(MessageContainer* requestContainer); uint32_t TryThreadLoadingFunc(MessageContainer* requestContainer); void ThreadCheckArcHeadCovers(void); uint32_t Thread_Load_End(void); #endif