This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SAR ADC - TMS320vc5505 EVM

Other Parts Discussed in Thread: TMS320VC5505

hi

i have a TMS320vc5505 EVM and i need to use SAR ADC to convert an analog signal. I wrote below assembly code but it didn't work:

;**************************************************************************
;       ADC CONFIGURATION
;**************************************************************************
    MOV        #0x2000, port(#SARCTRL)
     MOV        #800,    port(#SARCLKCTRL)    ;SARCLKCTRL
    MOV        #0x3200, port(#SARPINCTRL)    ;SARPINCTRL
    MOV        #0x0000, port(#SARGPOCTRL)

;**************************************************************************
;       PROGRAM BODY
;**************************************************************************

     OR        #1000000000000000b, port(#SARCTRL)        ;SARCTRL start

ADC:

Wait_START_ADC:
    BTST    #15, port(#SARDATA), TC1        
    BCC     Wait_START_ADC, !TC1

Wait_busy_ADC:
    BTST    #15, port(#SARDATA), TC1         
    BCC        Wait_busy_ADC, TC1
    
    MOV        port(#SARDATA), T2

    NOP
    NOP
    NOP


;**************************************************************************

I really appropriate you if you could send me assembly  sample of using SAR ADC on TMS320vc5505 EVM.