công cụ tìm kiếm bảng dữ liệu linh kiện điện tử
  Vietnamese  ▼
ALLDATASHEET.VN

X  

AN1812 bảng dữ liệu(PDF) 31 Page - STMicroelectronics

tên linh kiện AN1812
Giải thích chi tiết về linh kiện  In general the ADC embedded in the ST7 microcontroller
PDF  34 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
nhà sản xuất  STMICROELECTRONICS [STMicroelectronics]
Trang chủ  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN1812 bảng dữ liệu(HTML) 31 Page - STMicroelectronics

Back Button AN1812 Datasheet HTML 26Page - STMicroelectronics AN1812 Datasheet HTML 27Page - STMicroelectronics AN1812 Datasheet HTML 28Page - STMicroelectronics AN1812 Datasheet HTML 29Page - STMicroelectronics AN1812 Datasheet HTML 30Page - STMicroelectronics AN1812 Datasheet HTML 31Page - STMicroelectronics AN1812 Datasheet HTML 32Page - STMicroelectronics AN1812 Datasheet HTML 33Page - STMicroelectronics AN1812 Datasheet HTML 34Page - STMicroelectronics  
Zoom Inzoom in Zoom Outzoom out
 31 / 34 page
background image
AN1812
13 References and bibliography
31/34
Appendix D Software flow
The fCPU chosen is 8 MHz. Koffset and Kgain are calculated by taking the reading for two known
inputs. The flow of the software, use to implement the algorithm, is as follows:
1.
First the I/O pins, Timer, SCI (Tx @ 9600 baud rate) and some global variables used in the
ADC are initialized.
2.
Then a string is transmitted to check that SCI is working fine.
3.
The settling time is kept fixed at 1 second for fCPU = 8 MHz.
4.
Some initial readings are taken and ignored while the ADC stabilizes.
5.
The control enters an infinite loop.
6.
Inside the infinite loop, there is a loop in which ADC captures the timer values 17 times.
But the first reading is ignored.
7.
The remaining 16 captured values are converted into the corresponding voltages (up to 10
µV precision) and then transmitted a PC for display by the Hyperterminal after being
converted into a buffer of ASCII characters.
8.
The average of 16 timer readings is taken and sent to the Hyperterminal as a time value
and a corresponding voltage in the same manner as described above.
9.
The difference between the maximum and minimum captured value is also sent to the
Hyperterminal in the same way as in step 8.
10. After this step, the software enters an ‘IF’ loop “if (mCount == 18)”, where the ADC is reset
in order to measure the next input value. Again a few readings are ignored while the ADC
stabilizes. The counter and other global variables are also initialized.
11. After this, the software re-enters the loop of 17 conversions and executes step 6 to step 9.
This process continues until you reset the system manually.
D.1
Code size
The software given is for guidance only. Here the display is done for up to 10 uV precision. You
can modify and use your own code for the display of the data. The following table summarizes
the code size. Depending on the compiler and memory placement, these values can change.
The RAM requirements are not provided and you have the choice to place the variables as
global or local.
Table 4.
.Code size
No.
Function Name
Code size
( Bytes)
ADCSys
1
Acquisition
128
2
Start_Capturing
7
3
Reset_ADC
5
4
ADC_InitializeVar
29
5
IsCaptured
13
6
Delay_Second
44



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


bảng dữ liệu tải về

Go To PDF Page


Link URL



Cho đến nay ALLDATASHEET có giúp ích cho doanh nghiệp của bạn hay không?  [ DONATE ] 

Alldatasheet là   |   Quảng cáo   |   Liên lạc với chúng tôi   |   Chính sách bảo mật   |   Liên kết đến bảng dữ liệu    |   Trao đổi link   |   Tìm kiếm theo nhà sản xuất
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