-
Ordering information
Call us or mail us for inquiries & availability: info@mtronixtech.com
-
Search projects by Price
-
Project Categories
- Robots and Robotics
- GSM based Projects
- GPS based Projects
- RFID based Projects
- Energy Saving
- Wireless Communication
- DTMF based projects
- SMS based projects
- RF Remote
- Mobile Controlled
- Power Saver
- Sensor based Projects
- Alcohol Sensor
- heartbeat Sensor
- Humidity Sensor
- Infrared Sensor
- Level Sensor
- Light Sensor
- LPG Gas Sensor
- Moisture Sensor
- Temperature Sensor
- Vibration Sensor
- Weight Sensor
-
Search projects by Application
Project Videos:
Landrover Robot Operated by Cellphone
Industrial Automation using Cellphone
Password based door locking
Automatic room light controller
Temperature controlled fan
Electronic voting machine
Search by Components
89c51 89s51 89s52 89v51RD2 555 ADC0808 ADC0809 AT24c16 AT24c64 AT89s52 Battery BC547 Bulb Buzzer Darlington Pair DC motor Decoder EEPROM Fan GPS GSM IR LED Keypad L239D LCD Display LDR LED LM35 LM358 Matrix keypad MAX232 Motor Driver MQ6 PC Interface Relay RFID Card RFID Reader RFID Tags Sim300 sim900 SR86 SR87 Stepper Motor SYHS220 TSOP1738
Assembly code for ADC 0808
Sample code for ADC 0808.
Following code can be using for 8051 and 8052 ICs like: 89c51, 89c52, 89s51, 89s52, 89c2051.
;===================================================== ; Pin Definations ;===================================================== data_bus equ 90h ; Port 0 adc_add_a equ b4h ; P3.4 adc_add_b equ b3h ; P3.3 adc_ale_soc equ b5h ; P3.5 adc_eoc equ b6h ; P3.6 adc_oe equ b7h ; P3.7 ;===================================================== ; Main Program starts from here ;===================================================== adctemp: clr adc_add_a ;Channel 0 is selected clr adc_add_b ;Add b = 0, Add a = 0 nop setb adc_ale_soc ;ale is made high nop nop clr adc_ale_soc ;soc is made low jb adc_eoc,$ ;check for eoc low jnb adc_eoc,$ ;check for eoc hing setb adc_oe ;if eoc high,make oe high nop nop mov a,data_bus ;Read Port0 data to Acc mov 40h,a ;40h contains output data clr adc_oe ;make oe low ret ;===================================================== ; Program ENDS here ;=====================================================