示例#1
0
 private void test3( )
 {
     short  d100_short  = melsecSerial.ReadInt16("D100").Content;
     ushort d100_ushort = melsecSerial.ReadUInt16("D100").Content;
     int    d100_int    = melsecSerial.ReadInt32("D100").Content;
     uint   d100_uint   = melsecSerial.ReadUInt32("D100").Content;
     long   d100_long   = melsecSerial.ReadInt64("D100").Content;
     ulong  d100_ulong  = melsecSerial.ReadUInt64("D100").Content;
     float  d100_float  = melsecSerial.ReadFloat("D100").Content;
     double d100_double = melsecSerial.ReadDouble("D100").Content;
     // need to specify the text length
     string d100_string = melsecSerial.ReadString("D100", 10).Content;
 }
 private void button_read_string_Click(object sender, EventArgs e)
 {
     // 读取字符串
     readResultRender(melsecSerial.ReadString(textBox3.Text, ushort.Parse(textBox5.Text)), textBox3.Text, textBox4);
 }