sexta-feira, 17 de junho de 2011

Electronic design

Today we finally arrived to the domain of electronics, let's design the bindings for the clock with the microcontroller MSP430F2013. To start let's review the components that we use: MSP (14-pin), lcd (10 pins), HT1380 (8-pin), LM35 (3 pins) and buttons (2-pin). We start then the connection between peripherals and micro, as we see in the table in the previous post pin 2 is an analog input then this will be connected to the LM35, pins 3, 4 and 5 are i/o therefore are to be connected to the 3 buttons, pins 6, 7, 8, 9, 12 and 13 are also I/logo will be attached to 6-pin lcd data, but the same 7, 8 and 9 are also serial, so connect to HT1380, because the pins 10 and 11 are PIN connected to the recorder, but as the 10 is to reset this will have a reset button, finally the pins 1 and 14 are respectively connected to the source and Earth.
Ready the micro is already connected, now let's think in connection of other components, in HT1380 your pin 1 is not connected, the pins 2 and 3 go to Crystal, pin 4 is grounded, the pins 5, 6 and 7 go to the MSP and the 8 is the pin of the font.
The lcd has 5 grounded pins 1 and 2, and 3 direct at source connected to the source by a potentiometer, already the pins 4, 6, 7, 8, 9 and 10, go to the micro.
LM35, by default simply plug a PIN in a source on Earth and the other on micro.
The first should have buttons, pull up resistors, activate the micro in low State (0). In addition, to be more efficient and require less work in software, which sometimes ends up being more economically feasible, must have debounce by hardware.
The bouncing occurs on switches due to mechanical strength in component, thus when squeezed the button fluctuates several times before stabilize:

To minimize is done the debounce, softening the effect, and can be performed in software, hardware, or both:

In the case of the switch hardware debounce is connected in series to a resistor and capacitor in parallel to a.
Now the components are all connected, but still lack something ... Yes the power supply, of course! Good, as our clock should be something portable and inexpensive an external AC/DC source is not a good option, so the power supply should be made with a battery.
As the battery should be long-lasting it will have a heavy load and not to fry up the MSP will have to put a voltage regulator (LM7805), whose link is similar to (LM35). In addition, for the greater protection of the microcontroller you must put a capacitor filter between the source and ground of this, plus a resistor between source the reset.
Now the project is already taking shape, next week we'll look at the infamous Schematic of the circuit.

Nenhum comentário:

Postar um comentário