Exemple #1
0
        private void FormMain_Load(object sender, EventArgs e)
        {
            this.udpSender   = new UdpSender();
            this.udpReciever = new UdpReciever();
            this.carData     = new CarData(this.udpReciever);

            showSettingsForm();
        }
        public SendPacketForm(UdpSender udpSender)
        {
            InitializeComponent();

            this.udpSender = udpSender;
            this.looping   = false;

            this.btnReset.Enabled   = !looping;
            this.btnLoop.Enabled    = !looping;
            this.btnSend.Enabled    = !looping;
            this.tbLoopRate.Enabled = !looping;

            this.canPacket = new CanPacket(samplePacket);

            updateInputFields();
        }
        public ReceivePacketForm(UdpReciever udpReciever, UdpSender udpSender)
        {
            InitializeComponent();

            this.udpReciever = udpReciever;
            this.udpSender   = udpSender;

            this.isPaused      = false;
            this.btnPause.Text = "Stop";

            this.fromTb.Text            = fromFilter.ToString();
            this.toTb.Text              = toFilter.ToString();
            this.filterCheckBox.Checked = true;
            this.cbAutoScroll.Checked   = true;

            this.isNewPacket = false;
            this.idCounter   = 0;
        }