SEmbT7 Arch Bus

Embed Size (px)

Citation preview

  • 8/13/2019 SEmbT7 Arch Bus

    1/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    2/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    3/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

    3

  • 8/13/2019 SEmbT7 Arch Bus

    4/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

    4

  • 8/13/2019 SEmbT7 Arch Bus

    5/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf dev1 dev2

    enq

    ack

    data

  • 8/13/2019 SEmbT7 Arch Bus

    6/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

    time

    enq

    ack

    data

    1

    2

    3

    4

  • 8/13/2019 SEmbT7 Arch Bus

    7/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    8/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf time

    A

    B

    C

    zero

    one

    rising falling

    stable

    changing

    10 ns

  • 8/13/2019 SEmbT7 Arch Bus

    9/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    10/33

  • 8/13/2019 SEmbT7 Arch Bus

    11/33

    RMR2012

    Maths is not everything

    200

    8WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    12/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    13/33

    RMR2012

    Maths is not everything

    2008WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    14/33

  • 8/13/2019 SEmbT7 Arch Bus

    15/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    16/33

    15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0

    (Used by Timer_B) TxSSELx IDx MCx - TxCLR TxIE TxIFG

    Bit Description

    9-8 TxSSELx Timer_x clock source: 0 0 TxCLK0 1 ACLK1 0 SMCLK1 1 INCLK

    7-6 IDx Clock signal divider: 0 0 / 10 1 / 21 0 / 41 1 / 8

    5-4 MCx Clock timer operating mode: 0 0 Stop mode0 1 Up mode1 0 Continuous mode1 1 Up/down mode

    2 TxCLR Timer_x clear when TxCLR = 1

    1 TxIE Timer_x interrupt enable when TxIE = 1

    0 TxIFG Timer_x interrupt pending when TxIFG = 1

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    17/33

    MCx Mode Description

    0 0 Stop The timer is halted.

    0 1 Up The timer repeatedly counts from 0x0000 to

    the value in the TxCCR0 register.

    1 0 Continuous The timer repeatedly counts from 0x0000 to

    0xFFFF.1 1 Up/down The timer repeatedly counts from 0x0000 to

    the value in the TxCCR0 register and

    back down to zero.

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    18/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    19/33

    RMR2012

    Maths is not everything

    SMCLK .set 1200000 ; 1200000 clocks / secondTIME_1MS .set 1000 ; 1 ms = 1/1000 s

    TA_CTL .set TASSEL_2+ID_0+MC_1+TAIE ; SMCLK, /1, UP, IETA_FREQ .set SMCLK/TIME_1MS ; clocks / 1 ms

    clr.w &TAR ; reset timerA mov.w #TA_CTL,&TACTL ; set timerA control reg mov.w #TA_FREQ,&TACCR0 ; set interval (frequency) bis.w #LPM0+GIE,SR ; enter LPM0 w/interrupts jmp $ ; will never get here!

    TA_isr: ; timer A ISR bic.w #TAIFG,&TACTL ; acknowledge interrupt; reti

    .sect ".int08" ; timer A section

    .word TA_isr ; timer A isr

  • 8/13/2019 SEmbT7 Arch Bus

    20/33

    RMR2012

    Maths is not everything

    2008WayneWolf

    host CPU watchdogtimer

    interrupt

    reset

  • 8/13/2019 SEmbT7 Arch Bus

    21/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    22/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    23/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    24/33

    RMR2012

    Maths is not everything

    RESET:

    mov.w #0x0300,SP ; Initialize stack pointer

    mov.w #WDTPW+WDTHOLD,&WDTCTL ; Stop WDT

    bis.b #0x0f,&P1DIR ; Set P1.0-3 output

    mov.w #0,r14

    ...

    passwd = 0x5A

  • 8/13/2019 SEmbT7 Arch Bus

    25/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    26/33

    RMR2012

    Maths is not everything

    2008WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    27/33

    RMR2012

    Maths is not everything

    2008WayneWolf

    row

  • 8/13/2019 SEmbT7 Arch Bus

    28/33

    RMR2012

    Maths is not everything

    2008WayneWolf

  • 8/13/2019 SEmbT7 Arch Bus

    29/33

    RMR2012

    Maths is not everything

  • 8/13/2019 SEmbT7 Arch Bus

    30/33

    RMR2012

    Maths is not everything

    2008WayneWolf

    R

    2R

    4R

    8R

    bn

    bn-1

    bn-2

    bn-3

    Vout

  • 8/13/2019 SEmbT7 Arch Bus

    31/33

    RMR2012

    Maths is not everything

    2008WayneWolf

    encoder

    Vin

    ...

  • 8/13/2019 SEmbT7 Arch Bus

    32/33

    RMR2012

    Maths is not everything

    2008WayneWolf

    Vin timer

  • 8/13/2019 SEmbT7 Arch Bus

    33/33

    RMR2012

    Maths is not everything

    20

    08WayneWolf

    converterVin