| 전자부품 데이터시트 검색엔진 |
|
HT45F5R 데이터시트(PDF) 99 Page - Holtek Semiconductor Inc |
|
|
|||||||||||||||||||||||||||||
HT45F5R 데이터시트(HTML) 99 Page - Holtek Semiconductor Inc |
|
99 / 138 page ![]() Rev. 1.10 98 De�e��e� 1�� �01� Rev. 1.10 99 De�e��e� 1�� �01� HT45F5R Charger ASSP Flash MCU HT45F5R Charger ASSP Flash MCU A/D Conversion Programming Examples ThefollowingtwoprogrammingexamplesillustratehowtosetupandimplementanA/Dconversion. Inthefirstexample,themethodofpollingtheADBZbitintheSADC0registerisusedtodetect whentheconversioncycleiscomplete,whereasinthesecondexample,theA/Dinterruptisusedto determinewhentheconversioniscomplete. Example: using an ADBZ polling method to detect the end of conversion clr ADE ; disable ADC interrupt mov a,03H mov SADC1,a ; select fSYS/8 as A/D clock set ADCEN mov a,0Ch ; setup PAS0 to configure pin AN0 mov PAS0,a mov a,20h mov SADC0,a ; enable and connect AN0 channel to A/D converter : start_conversion: clr START ; high pulse on start bit to initiate conversion set START ; reset A/D clr START ; start A/D polling_EOC: sz ADBZ ; poll the SADC0 register ADBZ bit to detect end of A/D conversion jmp polling_EOC ; continue polling mov a,SADOL ; read low byte conversion result value mov SADOL_buffer,a ; save result to user defined register mov a,SADOH ; read high byte conversion result value mov SADOH_buffer,a ; save result to user defined register : : jmp start_conversion ; start next A/D conversion |
|
링크 URL |
| ALLDATASHEET 가 귀하에 도움이 되셨나요? [ DONATE ] |
Alldatasheet는? | 광고문의 | 운영자에게 연락하기 | 개인정보취급방침 | 링크 투 데이터시트 | 링크교환 | 제조사별 검색 All Rights Reserved©Alldatasheet.com |
| 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 |