I realized that I need a timer like this for various purposes with switching capability.
Here are the planed usage:
- Control the deep fryer above
- Small, desktop timer (it may requires LCD instead of LED display because of the battery operation)
- Control my (planed) UV lightbox what will used for PCB solder mask developing
- Soldering station watchdog (I always fear if once I will leave my soldering station switched on unattended. Therefore I'd like to have a watchdog what starts when I put the soldering iron back to the holder and switch of the entire station after five minutes)
The project will be based on an MSP430 value line MCU. Here are the design principles what I will follow:
- The connections of the MCU should fit in max 20 pins. This gives me the versatility to build the circuit with trough hole or SMD components.
- Use as few external components as possible. To be honest I don't like to use any external active components except the two transistors driving the display digits.
- Have an SMD design what fits under the display except the switches and breadboard compatitble.
- Have external user programing capability through computer interface (most probably UART)
- The use of the MCU itself: take 4 pins (VCC, GND, RST, TEST) these pins are needed all time
- Two digit 7-Segment display: 10 pins (7 Segment pin, 1 decimal point, 2 digit multiplex pin)
- External clock crystal: 2 pins
- PC communication: 2 pins (UART: TXD, RXD)
- Push buttons: 2 pins
- External trigger: 1 pin
- Switch the load: 1 pin
- Piezo Buzzer (beep at the end of time): 1 pin
So I've the following choices:
- Use some kind of GPIO expander (some I2C, SPI based or a simple shift register like 74HC595)
- Use a 7 Segment deccoder
- Use the pins smarter
- We can't do anything with the MCU own pins. Period. 4 pin left
- Use the second digit driving transistor as an inverter (driven from the collector of the first transistor). -1 pin. Concept proved. 9 pins left
- Use internal DCO instead of the crystal. I don't like this concept, so the pins stay. 2 pins left
- PC communication. Unfortunately no tricks possible here. 2 pins left
- Push buttons. Multiplex the push buttons from the digit driver transistors and sense them with a single pin. Concept proved. 1 pin left.
- External trigger. No tricks here. 1 pin left.
- Switch the load. No tricks here. 1 pin left.
- Piezo Buzzer: I need only one of the decimal point of the display. What if I connect the buzzer instead of the second DP. Concept. If I can prove it: 0 pin left.
Lets count once more: 4+9+2+2+1+1+1+0 = 20 pin Done!!!
Things are done:
- Schematics (the work of the buzzer must be proved)
- Working circuit on breadboard
- Display multiplex code
- Debounced button driver
- The countdown timer (with button setup)
Things what ahead (not necessary in this order):
- Buzzer code (prove the concept above)
- Homebrew PCB
- Writing to the flash in runtime (required to store data came from the PC interface)
- Serial communication
- Character based Menu driven UI (inside the MCU)
- Serial Binary command set (for the desktop UI)
- Extending the timer code for the programmable functionality (like the watchdog)
- Desktop UI (most probably in C#)
- SMD design/PCB ordering
Nincsenek megjegyzések:
Megjegyzés küldése