Esempio n. 1
0
        private void btn_send_Click(object sender, EventArgs e)
        {
            dataToWrite = textBox1.Text;
            UInt32 numBytesWritten = 0;

            // Note that the Write method is overloaded, so can write string or byte array data
            ftStatus = myFtdiDevice.Write(dataToWrite, dataToWrite.Length, ref numBytesWritten);
            if (ftStatus != FTDI.FT_STATUS.FT_OK)
            {
                MessageBox.Show("Somthing wrong happend!");
            }
            Reciever.RunWorkerAsync();
        }