Electronic Components Datasheet Search
  English  ▼

X  

CP2103 Datasheet(PDF) 6 Page - Silicon Laboratories

Part # CP2103
Description  PROGRAMMERS GUIDE
PDF  36 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  SILABS [Silicon Laboratories]
Direct Link  http://www.silabs.com
Logo SILABS - Silicon Laboratories

CP2103 Datasheet(HTML) 6 Page - Silicon Laboratories

Back Button CP2103 Datasheet HTML 2Page - Silicon Laboratories CP2103 Datasheet HTML 3Page - Silicon Laboratories CP2103 Datasheet HTML 4Page - Silicon Laboratories CP2103 Datasheet HTML 5Page - Silicon Laboratories CP2103 Datasheet HTML 6Page - Silicon Laboratories CP2103 Datasheet HTML 7Page - Silicon Laboratories CP2103 Datasheet HTML 8Page - Silicon Laboratories CP2103 Datasheet HTML 9Page - Silicon Laboratories CP2103 Datasheet HTML 10Page - Silicon Laboratories Next Button
Zoom Inzoom in Zoom Outzoom out
 6 / 36 page
background image
AN169
6
Rev. 2.3
3.5. SI_Read
Description:
Reads the available number of bytes into the supplied buffer and retrieves the number of bytes
that were read (this can be less than the number of bytes requested). This function returns syn-
chronously if the overlapped object is set to NULL (this happens by default) but will not block sys-
tem execution. If an initialized OVERLAPPED object is passed then the function returns
immediately. If the read completed then the status will be SI_SUCCESS but if I/O is still pending
then it will return STATUS_IO_PENDING. If STATUS_IO_PENDING is returned, the OVER-
LAPPED object can then be waited on using WaitForSingleObject(), and retrieve data or cancel
using GetOverlappedResult() (as documented on MSDN by Microsoft) or SI_CancelIo() respec-
tively. This functionality allows for multiple reads to be issued and waited on at a time. If any data
is available when SI_Read is called it will return so check NumBytesReturned to determine if all
requested data was returned. To make sure that SI_Read returns the requested number of bytes
use SI_CheckRxQueue() described in Section "3.11. SI_CheckRXQueue" on page 9.
Supported Devices:
C8051F320/1/6/7, C8051F340/1/2/3/4/5/6/7/8/9/A/B/C/D,
C8051F380/1/2/3/4/5/6/7, C8051T320/1/2/3/6/7, C8051T620/1/2/3, CP2101/2/3/4/5/8/9
Prototype:
SI_STATUS SI_Read (HANDLE Handle, LPVOID Buffer, DWORD NumBytesToRead,
DWORD *NumBytesReturned, OVERLAPPED* o = NULL)
Parameters:
1. Handle—Handle to the device to read as returned by SI_Open.
2. Buffer—Address of a character buffer to be filled with read data.
3. NumBytesToRead—Number of bytes to read from the device into the buffer (0–64 kB).
4. NumBytesReturned—Address of a DWORD which will contain the number of bytes actually
read into the buffer on return.
5. (Optional)—Address of an initialized OVERLAPPED object that can be used for asynchronous
reads.
Return Value:
SI_STATUS =
SI_SUCCESS or
SI_READ_ERROR or
SI_INVALID_PARAMETER or
SI_INVALID_HANDLE or
SI_SI_READ_TIMED_OUT or
SI_IO_PENDING or
SI_SYSTEM_ERROR_CODE or
SI_INVALID_REQUEST_LENGTH or
SI_DEVICE_IO_FAILED



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com