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

X  

PIC17C44-08/P датащи(PDF) 69 Page - Microchip Technology

номер детали PIC17C44-08/P
подробное описание детали  High-Performance 8-Bit CMOS EPROM/ROM Microcontroller
PDF  240 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
производитель  MICROCHIP [Microchip Technology]
домашняя страница  http://www.microchip.com
Logo MICROCHIP - Microchip Technology

PIC17C44-08/P датащи(HTML) 69 Page - Microchip Technology

Back Button PIC17C44-08/P Datasheet HTML 65Page - Microchip Technology PIC17C44-08/P Datasheet HTML 66Page - Microchip Technology PIC17C44-08/P Datasheet HTML 67Page - Microchip Technology PIC17C44-08/P Datasheet HTML 68Page - Microchip Technology PIC17C44-08/P Datasheet HTML 69Page - Microchip Technology PIC17C44-08/P Datasheet HTML 70Page - Microchip Technology PIC17C44-08/P Datasheet HTML 71Page - Microchip Technology PIC17C44-08/P Datasheet HTML 72Page - Microchip Technology PIC17C44-08/P Datasheet HTML 73Page - Microchip Technology Next Button
Zoom Inzoom in Zoom Outzoom out
 69 / 240 page
background image
© 1996 Microchip Technology Inc.
DS30412C-page 69
PIC17C4X
11.3
Read/Write Consideration for TMR0
Although TMR0 is a 16-bit timer/counter, only 8-bits at
a time can be read or written during a single instruction
cycle. Care must be taken during any read or write.
11.3.1
READING 16-BIT VALUE
The problem in reading the entire 16-bit value is that
after reading the low (or high) byte, its value may
change from FFh to 00h.
Example 11-1 shows a 16-bit read. To ensure a proper
read, interrupts must be disabled during this routine.
EXAMPLE 11-1: 16-BIT READ
MOVPF
TMR0L, TMPLO
;read low tmr0
MOVPF
TMR0H, TMPHI
;read high tmr0
MOVFP
TMPLO, WREG
;tmplo
−> wreg
CPFSLT
TMR0L
;tmr0l < wreg?
RETURN
;no then return
MOVPF
TMR0L, TMPLO
;read low tmr0
MOVPF
TMR0H, TMPHI
;read high tmr0
RETURN
;return
11.3.2
WRITING A 16-BIT VALUE TO TMR0
Since writing to either TMR0L or TMR0H will effectively
inhibit increment of that half of the TMR0 in the next
cycle (following write), but not inhibit increment of the
other half, the user must write to TMR0L first and
TMR0H next in two consecutive instructions, as shown
in Example 11-2. The interrupt must be disabled. Any
write to either TMR0L or TMR0H clears the prescaler.
EXAMPLE 11-2: 16-BIT WRITE
BSF
CPUSTA, GLINTD ; Disable interrupt
MOVFP RAM_L, TMR0L
;
MOVFP RAM_H, TMR0H
;
BCF
CPUSTA, GLINTD ; Done, enable interrupt
11.4
Prescaler Assignments
Timer0 has an 8-bit prescaler. The prescaler assign-
ment is fully under software control; i.e., it can be
changed “on the fly” during program execution. When
changing the prescaler assignment, clearing the pres-
caler is recommended before changing assignment.
The value of the prescaler is “unknown,” and assigning
a value that is less then the present value makes it dif-
ficult to take this unknown time into account.
FIGURE 11-4: TMR0 TIMING: WRITE HIGH OR LOW BYTE
Q1 Q2 Q3 Q4 Q1 Q2 Q3 Q4
Q1 Q2 Q3 Q4
Q1 Q2 Q3 Q4
Q1 Q2 Q3 Q4
AD15:AD0
ALE
TMR0L
TMR0H
MOVFP W,TMR0L
Write to TMR0L
MOVFP TMR0L,W
Read TMR0L
(Value = NT0)
MOVFP TMR0L,W
Read TMR0L
(Value = NT0)
MOVFP TMR0L,W
Read TMR0L
(Value = NT0 +1)
T0
T0+1
New T0 (NT0)
New T0+1
PC
PC+1
PC+2
PC+3
PC+4
Fetch
Instruction
executed



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