Ejemplo n.º 1
0
        protected override void WndProc(ref Message m)
        {
            if (m.Msg == 0x0219)
            {
                availableComPorts = RobotHandler.getAllAvailablePorts();
                RobotSelector.Items.Clear();
                RobotSelector.Items.AddRange(availableComPorts);
            }

            base.WndProc(ref m);
        }
Ejemplo n.º 2
0
        public Form1()
        {
            InitializeComponent();
            pictureBox1.SizeMode = PictureBoxSizeMode.StretchImage;

            availableComPorts           = RobotHandler.getAllAvailablePorts();
            RobotSelector.DropDownStyle = ComboBoxStyle.DropDownList;
            RobotSelector.Items.AddRange(availableComPorts);


            deviceList = CamManager.GetCameras();
            videoDevices.DropDownStyle = ComboBoxStyle.DropDownList;
            detector = new Detector(1.7);
            foreach (FilterInfo device in deviceList)
            {
                videoDevices.Items.Add(device.Name);
            }
        }
Ejemplo n.º 3
0
 private void RobotSelector_SelectedIndexChanged_1(object sender, EventArgs e)
 {
     Console.WriteLine($"Selected Com Port: {availableComPorts[RobotSelector.SelectedIndex]}");
     robotHandler?.Dispose();
     robotHandler = new RobotHandler(availableComPorts[RobotSelector.SelectedIndex]);
 }