Electronic Components Datasheet Search
  English  ▼
ALLDATASHEET.NET

X  

AN2658 Datasheet(PDF) 10 Page - STMicroelectronics

Part # AN2658
Description  Using the analog to digital converter of the STM8S microcontroller
PDF  23 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN2658 Datasheet(HTML) 10 Page - STMicroelectronics

Back Button AN2658 Datasheet HTML 6Page - STMicroelectronics AN2658 Datasheet HTML 7Page - STMicroelectronics AN2658 Datasheet HTML 8Page - STMicroelectronics AN2658 Datasheet HTML 9Page - STMicroelectronics AN2658 Datasheet HTML 10Page - STMicroelectronics AN2658 Datasheet HTML 11Page - STMicroelectronics AN2658 Datasheet HTML 12Page - STMicroelectronics AN2658 Datasheet HTML 13Page - STMicroelectronics AN2658 Datasheet HTML 14Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 10 / 23 page
background image
Summary of features
AN2658
10/23
Doc ID 14152 Rev 2
2.7
Data storage
The 10 bits of ADC converted data are stored in two 8-bit registers (and in ADC1 type also
in the buffer registers - see Figure 6.: Data alignment).
The STM8 ADC has selectable data alignment. You can choose to left or right align the 10-
bit ADC result in the two 8-bit data registers.
You must read the data registers in a particular order to ensure that the data retrieved from
the registers is consistent (resulting from the same conversion). When the first data register
is read, the second data register is latched so it can be read later and to prevent it being
overwritten by the next conversion. The order in which you must read the data registers
depends on the alignment mode. In right alignment mode, the LSB must be read first and
then the MSB. In left alignment mode, the MSB must be read first and then the LSB.
Figure 6.
Data alignment
2.8
Extended functions
These extended functions are present only in devices with ADC1.
2.8.1
Buffers
Devices with ADC1 have a set of registers for data storage which are used when buffered
mode is enabled. The converted data are stored cyclically in these registers (ring buffer).
This makes data storage and collection more efficient (less CPU load and less data buffer
overrun issues).
The number of data buffer registers is equal to the number of ADC1 input channels and
depends on the STM8 device type.
2.8.2
Buffer overrun flag
This flag is set when the values in the ADC1 data buffer registers are overwritten before
being read by the CPU. The user firmware can use this flag detect an overrun event and can
then perform appropriate actions (for example restart A/D conversion).
D1 D0
D1 D0
D3 D2
D5 D4
D7 D6
D9 D8
D9 D8
D3 D2
D5 D4
D7 D6
ADC_DRH
70
ADC_DRL
70
ADC_DRH
70
ADC_DRL
70
Left alignment mode:
Right alignment mode:



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


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