//Here we use a single buffer mode, the microcontroller sends the DAC0832 every 1s
//The output voltages of the five data 3FH, 7FH, F0H, 0FFH, and 00H change cyclically.
//This program must set up the circuit diagram, and all DA pins are set in working state
ORG 0000H
AJMP MAIN
ORG 0030H
MAIN:
MOV A,#3FH
MOV P0,A
SETB P3.6 ;WR1 falling edge to convert
CALL DELAY
CLR P3.6
CALL DELAY
MOV A,#7FH
MOV P0,A
SETB P3.6
CALL DELAY
CLR P3.6
CALL DELAY
MOV A,#0F0H
MOV P0,A
SETB P3.6
CALL DELAY
CLR P3.6
CALL DELAY
MOV A,#0FFH
MOV P0,A
SETB P3.6
CALL DELAY
CLR P3.6
CALL DELAY
MOV A,#00H
MOV P0,A
SETB P3.6
CALL DELAY
CLR P3.6
CALL DELAY
AJMP MAIN
DELAY: ; Delay function
MOV R4,#5
L3:MOV R5,#100
L2:MOV R6,#250
DJNZ R6,$
NOP
NOP
DJNZ R5,L2
DJNZ R4,L3
RET
END
Previous article:Course Design: Matrix Keyboard (c51, implemented using scanning method)
Next article:Course Design: Key Counter (Assembly)
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Learn ARM development(22)
- Learn ARM development(21)
- Learn ARM development(20)
- Learn ARM development(19)
- Learn ARM development(14)
- Learn ARM development(15)
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- 5G in 60: An introduction to 5G
- BLDC motor current abnormality problem
- Battery system state of charge calculation algorithm problem
- I'm a newbie in your place, please take care of me, thank you!
- 【Mil MYS-8MMX】- 3: About Internet access
- MSP430G2553 clock system configuration
- Silicon Labs EFM32PG22 Development Kit enables you to create whatever you want! Application in progress!
- 7. Common Collector Amplifier Circuit (Emitter Follower)
- Verilog state machine programming skills
- Review summary: Qinheng RISC-V core BLE 5.3 wireless MCU CH582