diff -r 43e37759235e -r 51a74ef9ed63 Symbian3/SDK/Source/GUID-934AEB9C-77EA-5F50-BB84-2446DDD432C8.dita --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/SDK/Source/GUID-934AEB9C-77EA-5F50-BB84-2446DDD432C8.dita Wed Mar 31 11:11:55 2010 +0100 @@ -0,0 +1,49 @@ + + + + + +How +to Send Data: TutorialThis tutorial describes how to send and receive data with the Serial +Communications Server. +

This tutorial follows the tutorial How to Open a Port: TutorialHow to Open a Port: Tutorial.

+ + +All data sent from the serial device is 8-bit even on a Unicode system. +Create a TDesC8 Descriptor and fill the Descriptor +with the data to send. + + +Create a request object of type TRequestStatus. + + +Call RComm::Write() and set the aDes parameter +as a reference to the Descriptor, and set the aStatus parameter to the request +object. +The RComm API does not allow another request to be made until the first +request has completed. + + +The write request completes when the last character in the supplied +buffer has been written to the serial hardware. There are three alternative +ways the write request can complete: +

    +
  1. If the aTimeOut parameter +was set with the RComm::Write() function then the request +completes with KErrTimedOut if the Descriptor was not filled +during the aTimeOut time.

  2. +
  3. If the write request +is in progress, the write request can be cancelled by calling WriteCancel().

  4. +
  5. A port can be configured +to automatically terminate data transfer requests early when various error +conditions occur.

  6. +

+
+
+
\ No newline at end of file