• 大小: 0.06M
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2020-12-14
  • 语言: C#
  • 标签: C#  串口  c  源代码  

资源简介

进行串口调试用

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

using System.IO.Ports;
namespace SerialCommunicate
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
            System.Windows.Forms.Control.CheckForIllegalCrossThreadCalls = false;
        }

        private void button1_Click(object sender EventArgs e)
        {
            try
            {
                serialPort1.PortName = comboBox1.Text;
                serialPort1.BaudRate = Convert.ToInt32(comboBox2.Text10);//十进制数据转换
                serialPort1.Open();
                button1.Enabled = false;//打开串口按钮不可用

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件      14848  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\bin\Debug\SerialCommunicate.exe

     文件      38400  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\bin\Debug\SerialCommunicate.pdb

     文件      22472  2018-12-08 17:09  SerialCommunicate\SerialCommunicate\bin\Debug\SerialCommunicate.vshost.exe

     文件        490  2016-07-16 19:44  SerialCommunicate\SerialCommunicate\bin\Debug\SerialCommunicate.vshost.exe.manifest

     文件       5219  2013-07-20 00:05  SerialCommunicate\SerialCommunicate\Form1.cs

     文件      13887  2013-07-19 23:53  SerialCommunicate\SerialCommunicate\Form1.Designer.cs

     文件       6189  2013-07-18 00:19  SerialCommunicate\SerialCommunicate\Form1.resx

     文件       1711  2018-12-08 16:57  SerialCommunicate\SerialCommunicate\obj\Debug\DesignTimeResolveAssemblyReferences.cache

     文件       6942  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件       2798  2018-12-08 17:09  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.csproj.FileListAbsolute.txt

     文件        975  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.csproj.GenerateResource.Cache

     文件       3785  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.csprojResolveAssemblyReference.cache

     文件      14848  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.exe

     文件        180  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.Form1.resources

     文件      38400  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.pdb

     文件        180  2018-12-08 16:56  SerialCommunicate\SerialCommunicate\obj\Debug\SerialCommunicate.Properties.Resources.resources

     文件        498  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Program.cs

     文件       1372  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Properties\AssemblyInfo.cs

     文件       2886  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Properties\Resources.Designer.cs

     文件       5612  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Properties\Resources.resx

     文件       1104  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Properties\Settings.Designer.cs

     文件        249  2013-07-16 12:52  SerialCommunicate\SerialCommunicate\Properties\Settings.settings

     文件       3747  2013-07-16 12:54  SerialCommunicate\SerialCommunicate\SerialCommunicate.csproj

     文件        941  2013-07-16 12:52  SerialCommunicate\SerialCommunicate.sln

    ..A..H.     39424  2013-07-20 00:05  SerialCommunicate\SerialCommunicate.v11.suo

     目录          0  2013-12-26 11:20  SerialCommunicate\SerialCommunicate\obj\Debug\TempPE

     目录          0  2018-12-08 16:53  SerialCommunicate\SerialCommunicate\bin\Debug

     目录          0  2018-12-08 16:57  SerialCommunicate\SerialCommunicate\obj\Debug

     目录          0  2018-12-08 16:53  SerialCommunicate\SerialCommunicate\bin

     目录          0  2018-12-08 16:53  SerialCommunicate\SerialCommunicate\obj

............此处省略6个文件信息

评论

共有 条评论