Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
03/20/06 09:46
Read: times


 
#112547 - ADC / DAC with ADuC832
Hello!

I joined a few weeks ago and found already some interesting things to use!

Now I'm doing a project with the microconverter developmentboard of Analog Devices ADuC832. At first I'm trying all the possibilities of the pins as I/O's, ADC/DAC, PWM, T/C's,..
Now I'm having some troubles with the ADC. On the board there is a LDR at ADC.3 and i want this value to be displayed on P3 (where there is a LEDbar attached). Véry simple, but the output stays with one value only. Mayby my little program could be some more help with my explenation :

$MOD832 ; use 8082 predefined symbols
CSEG ; defines the following as a code
ORG 1000h

INIT: ANL ADCCON1,#11001000B ;ext ref / f/8 / 3acq
ANL ADCCON2,#00100011B ;cont mod / CH3
OUT: MOV P3,ADCDATAL ;ADC value to P3
WAIT: MOV A,ADCCON3
JB ACC.7,WAIT ;wait for busy flag to be 0
SJMP OUT ;display again

END

OK I see the code is not as nice displayed but it's very small :-).
thx in advance!!

ps : mayby a good exercise for the tutorials :-)

Best Regards,
LJ

List of 10 messages in thread
TopicAuthorDate
ADC / DAC with ADuC832            01/01/70 00:00      
   code formatting            01/01/70 00:00      
      off topic and one idea            01/01/70 00:00      
         just a guess            01/01/70 00:00      
            guessing            01/01/70 00:00      
               blinkey            01/01/70 00:00      
                  KnightriderLED            01/01/70 00:00      
                     try single-shot AD conversion            01/01/70 00:00      
                        ADC to pc with serial            01/01/70 00:00      
                           UART            01/01/70 00:00      

Back to Subject List