project summary
- Software only
- 2 PWM outputs in 8051 90deg out of phase
- ONE DAY
skills
- 8051 Assembly Language
- PWM (Pulse Width Modulation)
- Gathering Requirements
- Quick Turn!
Background
Similar to many of my other projects, this project was to be kept fairly confidential, so I am limited in what I can describe of the project. The general overview is below, however, and it highlights the experience and accomplishments associated with the project.
A colleague described a customer need over the phone to me. The customer had an actuator that was controlled by two PWM signals that had to be 90 degrees out of phase with each other. The actuator was also reversible, so it would operate in the forward direction when signal 1 led signal 2 by 90 degrees, and it would operate in the reverse direction when signal 2 led signal 1 by 90 degrees.
My Role
My colleague had already done the part selection, knowing that driving the PWM signals from a Silicon Laboratories 8051 microcontroller would be sufficient. My job was simply to write the software to make the micro produce the PWM signals on two of its outputs based on two switch inputs that determined the direction.
Final Results
I wrote the code and tested the code on actual hardware within one day. Here are the key accomplishments:
- Less than 50 lines of assembly code in 3 modular files (main, initialization, and timer interrupt)
- Duty cycle easily configurable for each channel independently prior to assembling the code
- Excel sheet provided containing automatic formulas for duty cycle adjustment
- Written and tested on hardware within ONE DAY (worth reiterating!)