поискавой системы для электроныых деталей
  Russian  ▼
ALLDATASHEETRU.COM

X  

STM8S датащи(PDF) 142 Page - STMicroelectronics

номер детали STM8S
подробное описание детали  STM8S Series and STM8AF Series 8-bit microcontrollers
PDF  467 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
производитель  STMICROELECTRONICS [STMicroelectronics]
домашняя страница  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

STM8S датащи(HTML) 142 Page - STMicroelectronics

Back Button STM8S Datasheet HTML 138Page - STMicroelectronics STM8S Datasheet HTML 139Page - STMicroelectronics STM8S Datasheet HTML 140Page - STMicroelectronics STM8S Datasheet HTML 141Page - STMicroelectronics STM8S Datasheet HTML 142Page - STMicroelectronics STM8S Datasheet HTML 143Page - STMicroelectronics STM8S Datasheet HTML 144Page - STMicroelectronics STM8S Datasheet HTML 145Page - STMicroelectronics STM8S Datasheet HTML 146Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 142 / 467 page
background image
16-bit advanced control timer (TIM1)
RM0016
142/467
DocID14587 Rev 14
17.3.1
Reading and writing to the 16-bit counter
There is no buffering when writing to the counter. Both TIM1_CNTRH and TIM1_CNTRL
can be written at any time, so it is suggested not to write a new value into the counter while
it is running to avoid loading an incorrect intermediate content.
An 8-bit buffer is implemented for the read. Software must read the MS byte first, after which
the LS byte value is buffered automatically (see Figure 33). This buffered value remains
unchanged until the 16-bit read sequence is completed.
Note:
Do not use the LDW instruction to read the 16-bit counter. It reads the LS byte first and
returns an incorrect result.
Figure 33. 16-bit read sequence for the counter (TIM1_CNTR)
17.3.2
Write sequence for 16-bit TIM1_ARR register
16-bit values are loaded in the TIM1_ARR
register through preload registers. This must be
performed by two write instructions, one for each byte. The MS byte must be written first.
The shadow register update is blocked as soon as the MS byte has been written, and stays
blocked until the LS byte has been written. Do not use the LDW instruction as this writes the
LS byte first which produces incorrect results.
17.3.3
Prescaler
The prescaler implementation is as follows:
The TIM1 prescaler is based on a 16-bit counter controlled through a 16-bit register (in
TIM1_PSCR register). It can be changed on the fly as this control register is buffered. It can
divide the counter clock frequency by any factor between 1 and 65536.
The counter clock frequency is calculated as follows:
fCK_CNT = fCK_PSC/(PSCR[15:0]+1)
The prescaler value is loaded through a preload register. The shadow register, which
contains the current value to be used, is loaded as soon as the LS byte has been written.
To update the 16-bit prescaler, load two bytes in separate write operations starting with the
MSB. Do not use the LDW instruction for this purpose as it writes the LSB first.
The new prescaler value is taken into account in the following period (after the next counter
update event).



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 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


датащи скачать

Go To PDF Page


ссылки URL



Вашему бизинису помогли Аллдатащит?  [ DONATE ] 

Что такое Аллдатащит   |   реклама   |   контакт   |   Конфиденциальность   |   Ссылка на техническое описание    |   обмен ссыками   |   поиск по производителю
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