Electronic Components Datasheet Search
  New Zealand  ▼
ALLDATASHEET.CO.NZ

X  

HCS12 Datasheet(PDF) 353 Page - Freescale Semiconductor, Inc

Part # HCS12
Description  HCS12 Microcontrollers
PDF  452 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  FREESCALE [Freescale Semiconductor, Inc]
Direct Link  http://www.freescale.com
Logo FREESCALE - Freescale Semiconductor, Inc

HCS12 Datasheet(HTML) 353 Page - Freescale Semiconductor, Inc

Back Button HCS12 Datasheet HTML 349Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 350Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 351Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 352Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 353Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 354Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 355Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 356Page - Freescale Semiconductor, Inc HCS12 Datasheet HTML 357Page - Freescale Semiconductor, Inc Next Button
Zoom Inzoom in Zoom Outzoom out
 353 / 452 page
background image
S12CPUV2 Reference Manual, Rev. 4.0
Freescale Semiconductor
353
9.5 REV and REVW Instruction Details
This section provides a more detailed explanation of the rule evaluation
instructions (REV and REVW). The data structures used to specify rules are
somewhat different for the weighted versus unweighted versions of the
instruction. One uses 8-bit offsets in the encoded rules, while the other uses
full 16-bit addresses. This affects the size of the rule data structure and
execution time.
9.5.1 Unweighted Rule Evaluation (REV)
This instruction implements basic min-max rule evaluation. CPU registers
are used for pointers and intermediate calculation results.
Since the REV instruction is essentially a list-processing instruction,
execution time is dependent on the number of elements in the rule list. The
REV instruction is interruptible (typically within three bus cycles), so it does
not adversely affect worst case interrupt latency. Since all intermediate
results and instruction status are held in stacked CPU registers, the interrupt
service code can even include independent REV and REVW instructions.
9.5.1.1 Set Up Prior to Executing REV
Some CPU registers and memory locations need to be set up prior to
executing the REV instruction. X and Y index registers are used as index
pointers to the rule list and the fuzzy inputs and outputs. The A accumulator
is used for intermediate calculation results and needs to be set to $FF
initially. The V condition code bit is used as an instruction status indicator to
show whether antecedents or consequents are being processed. Initially,
the V bit is cleared to zero to indicate antecedents are being processed. The
fuzzy outputs (working RAM locations) need to be cleared to $00. If these
values are not initialized before executing the REV instruction, results will
be erroneous.
The X index register is set to the address of the first element in the rule list
(in the knowledge base). The REV instruction automatically updates this
pointer so that the instruction can resume correctly if it is interrupted. After
the REV instruction finishes, X will point at the next address past the $FF
separator character that marks the end of the rule list.



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


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