コード例 #1
0
ファイル: MainGUI.cs プロジェクト: labJunky/DDS
        private void setChannelButton_Click(object sender, EventArgs e)
        {
            // Parse information
            AD9958         selectedDDS = ddsList[deviceListBox.SelectedIndex];
            ChannelSetting setting     = ((IChannelSetting)channelTabControl.SelectedTab.Controls[0]).ChannelSetting;

            setChannel(selectedDDS, setting);
        }
コード例 #2
0
ファイル: ChannelUserControl.cs プロジェクト: labJunky/DDS
        private ChannelSetting getChannelSetting()
        {
            ChannelSetting setting = new ChannelSetting();

            setting.Channel   = Convert.ToInt32(comboBox1.Text);
            setting.Frequency = Convert.ToDouble(frequencyTextBox.Text);
            return(setting);
        }
コード例 #3
0
        private ChannelSetting getChannelSetting()
        {
            ChannelSetting setting = new ChannelSetting();

            setting.Channel   = 2;
            setting.Frequency = Convert.ToDouble(frequencyComboBox.Text);
            setting.Phase     = Convert.ToDouble(phaseComboBox.Text);
            return(setting);
        }
コード例 #4
0
ファイル: MainGUI.cs プロジェクト: labJunky/DDS
 private void setChannel(AD9958 dds, ChannelSetting Setting)
 {
     if (Setting.Channel == 2)
     {
         dds.SetTwoChannelRelativePhase(Setting.Frequency, Setting.Phase);
     }
     else
     {
         dds.SetFrequency(Setting.Channel, Setting.Frequency);
     }
 }