Tuesday, March 31, 2009
Digital Clock with Alarm Using DS1307
DS1307 is a hardware realtime clock, which works on I2C protocol.
Better graphics using the same old fashioned alphanumeric LCD
(type HD44780). Icons which shows the status for Alarm ON/OFF
state, which gives a nice and cute look to the clock.
PIC Digital Clock Timer
This clock timer uses a PIC16F628 microcontroller to display 3
and 1/2 digit time and control an external load. The clock includes
a calendar with leap year and optional daylight savings adjustments.
The timer output can be set from 1 to 59 minutes and manually
switched on and off. The clock also has a correction feature that
allows an additional second to be added every so many hours to
compensate for a slightly slow running oscillator. The oscillator
uses a common 32.768 KHz watch crystal and the frequency can
be adjusted slightly with the 24pF capacitor on the right side of the
crystal.
PIC Digital Multiple Clock Timer
This circuit uses the PIC16F628 microcontroller to provide 4
timed outputs that can be programmed from 1 minute to 1 week.
An extra 8 bit shift register (74HC164) is used for the 4 timer
outputs and to display four additional indicator lights.
Digital Clock with Timer and Solar Panel Regulator
This is a combination digital clock timer and solar panel charge
controller used to maintain a deep cycle battery from a solar panel.
The timer output is used to control a 12 volt load for a 32 minute
time interval each day. Start time is set using 9 dip switches and
ends 32 minutes later. The 32 minute duration is set by selecting
the 5th bit (2^5 = 32) of a 4040 binary counter (pin 2). The timer
also has a manual toggle switch so the load can be manually
switched on or off and automatically shuts off after 32 minutes.
The time duration can be longer or shorter (8,16,32,64,128,256
minutes etc.) by selecting the appropriate bit of the counter.
The timer circuit is shown in the lower schematic just above the
regulator.
Labels: Digital Timer Circuit, Timer Circuit
Digital Clock with Alarm Using DS1307
DS1307 is a hardware realtime clock, which works on I2C protocol.
Better graphics using the same old fashioned alphanumeric LCD
(type HD44780). Icons which shows the status for Alarm ON/OFF
state, which gives a nice and cute look to the clock.
PIC Digital Clock Timer
This clock timer uses a PIC16F628 microcontroller to display 3
and 1/2 digit time and control an external load. The clock includes
a calendar with leap year and optional daylight savings adjustments.
The timer output can be set from 1 to 59 minutes and manually
switched on and off. The clock also has a correction feature that
allows an additional second to be added every so many hours to
compensate for a slightly slow running oscillator. The oscillator
uses a common 32.768 KHz watch crystal and the frequency can
be adjusted slightly with the 24pF capacitor on the right side of the
crystal.
PIC Digital Multiple Clock Timer
This circuit uses the PIC16F628 microcontroller to provide 4
timed outputs that can be programmed from 1 minute to 1 week.
An extra 8 bit shift register (74HC164) is used for the 4 timer
outputs and to display four additional indicator lights.
Digital Clock with Timer and Solar Panel Regulator
This is a combination digital clock timer and solar panel charge
controller used to maintain a deep cycle battery from a solar panel.
The timer output is used to control a 12 volt load for a 32 minute
time interval each day. Start time is set using 9 dip switches and
ends 32 minutes later. The 32 minute duration is set by selecting
the 5th bit (2^5 = 32) of a 4040 binary counter (pin 2). The timer
also has a manual toggle switch so the load can be manually
switched on or off and automatically shuts off after 32 minutes.
The time duration can be longer or shorter (8,16,32,64,128,256
minutes etc.) by selecting the appropriate bit of the counter.
The timer circuit is shown in the lower schematic just above the
regulator.
Labels: Digital Timer Circuit, Timer Circuit
Monday, March 30, 2009
Build a digital clock that turns AC load on/off with preset time
Figure 1 shows a circuit diagram of the Clock Controller V1.1.
P10-P1.7 drives 7-segment common anode LED with sink current.
P3.0-P3.3 also drives a base pin of 4-PNP transistor, 2n2907 with
sink current. As shown in the figure, the 2nd 2-digit LED that
connected to P3.2 and P3.3 is rotated 180 degrees to the 1st
2-digit allowing the pt. segment to be used for 1 second blinking.
P3.0-P3.3 also connects four momentary switches while the other
legs are tied to input port P3.4. During display and key switch
scanning, a logic '0' is shifted from P3.0 to P3.3, if there was a
key pressed, P3.4 then became low. P3.7 is a 1-bit sink current
driving, an example in the circuit uses a 2n2907 to drive a small
electromechanical relay 5V, say.
Blue Clock (Atmel Atmega8535 microcontroller)
The power comes in at the top left of the schematic. A bridge
rectifier is used so the polarity of the input signal doesn't matter.
A small SOT223 package, 5V regulator is used to provide
regulated voltage the Atmega8535, RTC, and the LED display
drivers. The Real Time Clock data is comes in from the PCF8563P.
This IC has a 32.768 crystal to keep time and a uses a 3V
CR2032 lithium battery when powered down. SW1 - SW4 are
the four pushbuttons for user input. The MBI5027 constant current
display drivers (24 pin DIP) from Macroblock can be a little hard
to find. They use power directly from the wall transform to turn
on the 7 segment LED's.
AVR 7-segment clock
The circuit can be viewed in every electronic book. Some
7-segments and LED's arranged as a matrix in rows and
colums and a multiplex routine written in assembler. The two
buttons are for setting the time.
Realtime clock with LED display and 89S8252
A real time clock using six 7-segment displays is used in this
project to display the time in HH-MM-SS format using a micro
controller ATMEL-89s8252 with minimum number of external
components. Five switches are used to set the HOURS
MINUTES (+/-) and one for zero reset of the clock display.
The micro controller runs of a 6Mhz crystal which also acts as
the time base for the clock.
Digital Clock with PIC16F84A
This is a small ajustable clock, I made based on PIC16F84A
microchip.The hardware part is very simple because it only
uses 74hct238 demultiplexer, 4x7 segments, and some rezistors.
The software part is programmed through a device connected to
serial port with icprog and made/debuged with MPlab.
Labels: 7-Segment, Digital Timer Circuit, Timer Circuit
Build a digital clock that turns AC load on/off with preset time
Figure 1 shows a circuit diagram of the Clock Controller V1.1.
P10-P1.7 drives 7-segment common anode LED with sink current.
P3.0-P3.3 also drives a base pin of 4-PNP transistor, 2n2907 with
sink current. As shown in the figure, the 2nd 2-digit LED that
connected to P3.2 and P3.3 is rotated 180 degrees to the 1st
2-digit allowing the pt. segment to be used for 1 second blinking.
P3.0-P3.3 also connects four momentary switches while the other
legs are tied to input port P3.4. During display and key switch
scanning, a logic '0' is shifted from P3.0 to P3.3, if there was a
key pressed, P3.4 then became low. P3.7 is a 1-bit sink current
driving, an example in the circuit uses a 2n2907 to drive a small
electromechanical relay 5V, say.
Blue Clock (Atmel Atmega8535 microcontroller)
The power comes in at the top left of the schematic. A bridge
rectifier is used so the polarity of the input signal doesn't matter.
A small SOT223 package, 5V regulator is used to provide
regulated voltage the Atmega8535, RTC, and the LED display
drivers. The Real Time Clock data is comes in from the PCF8563P.
This IC has a 32.768 crystal to keep time and a uses a 3V
CR2032 lithium battery when powered down. SW1 - SW4 are
the four pushbuttons for user input. The MBI5027 constant current
display drivers (24 pin DIP) from Macroblock can be a little hard
to find. They use power directly from the wall transform to turn
on the 7 segment LED's.
AVR 7-segment clock
The circuit can be viewed in every electronic book. Some
7-segments and LED's arranged as a matrix in rows and
colums and a multiplex routine written in assembler. The two
buttons are for setting the time.
Realtime clock with LED display and 89S8252
A real time clock using six 7-segment displays is used in this
project to display the time in HH-MM-SS format using a micro
controller ATMEL-89s8252 with minimum number of external
components. Five switches are used to set the HOURS
MINUTES (+/-) and one for zero reset of the clock display.
The micro controller runs of a 6Mhz crystal which also acts as
the time base for the clock.
Digital Clock with PIC16F84A
This is a small ajustable clock, I made based on PIC16F84A
microchip.The hardware part is very simple because it only
uses 74hct238 demultiplexer, 4x7 segments, and some rezistors.
The software part is programmed through a device connected to
serial port with icprog and made/debuged with MPlab.
Labels: 7-Segment, Digital Timer Circuit, Timer Circuit
Sunday, March 29, 2009
Relay Toggle Circuit Using a 555 Timer
This 555 timer circuit below toggles a relay when a button is
pressed. Pins 2 and 6, the threshold and trigger inputs, are
held at 1/2 the supply voltage by the two 10K resistors.
When the output is high, the capacitor charges through the
100K resistor, and discharges when the output is low. When
the button is pressed, the capacitor voltage is applied to pins
2 and 6 which causes the output to change to the opposite
state. When the button is released, the capacitor will charge
or discharge to the new level at the output (pin 3).
Relay Toggle Circuit Using a 556 Timer
This toggle circuit operates by using a couple 555 timers wired
as inverters. Pins 2 and 6 are the threshold and trigger inputs to
the first timer and pin 5 is the output. The output at pin 5 will
always be the inverse of the input at pins 2 and 6. Likewise, the
output at pin 9 of the second timer will always be the inverse
of the input at pins 8 and 12. A 100K resistor connects the
output of one inverter to the input of the other so the state of
one will be the opposite of the other.
Single Transistor Relay Toggle Circuit
The circuit below requires a double pole, double throw relay in
conjunction with a single transistor to allow toggling the relay
with a momentary push button. One set of relay contacts is used
to control the load, while the other is used to provide feedback
to keep the relay activated or deactivated. Several push buttons
can be wired in parallel to allow toggling the relay from different
locations.
CMOS Toggle Flip Flop Using Push Button
The circuit below uses a CMOS dual D flip flop (CD4013) to
toggle a relay or other load with a momentary push button.
Several push buttons can be wired in parallel to control the
relay from multiple locations.
Toggle Switch from A Push On Switch
When there is no toggle switch available, maybe this circuit
can be used for changes. I made this circuit to run a toggle
foot switch, controlling blower table.
Labels: Relay Circuit
Relay Toggle Circuit Using a 555 Timer
This 555 timer circuit below toggles a relay when a button is
pressed. Pins 2 and 6, the threshold and trigger inputs, are
held at 1/2 the supply voltage by the two 10K resistors.
When the output is high, the capacitor charges through the
100K resistor, and discharges when the output is low. When
the button is pressed, the capacitor voltage is applied to pins
2 and 6 which causes the output to change to the opposite
state. When the button is released, the capacitor will charge
or discharge to the new level at the output (pin 3).
Relay Toggle Circuit Using a 556 Timer
This toggle circuit operates by using a couple 555 timers wired
as inverters. Pins 2 and 6 are the threshold and trigger inputs to
the first timer and pin 5 is the output. The output at pin 5 will
always be the inverse of the input at pins 2 and 6. Likewise, the
output at pin 9 of the second timer will always be the inverse
of the input at pins 8 and 12. A 100K resistor connects the
output of one inverter to the input of the other so the state of
one will be the opposite of the other.
Single Transistor Relay Toggle Circuit
The circuit below requires a double pole, double throw relay in
conjunction with a single transistor to allow toggling the relay
with a momentary push button. One set of relay contacts is used
to control the load, while the other is used to provide feedback
to keep the relay activated or deactivated. Several push buttons
can be wired in parallel to allow toggling the relay from different
locations.
CMOS Toggle Flip Flop Using Push Button
The circuit below uses a CMOS dual D flip flop (CD4013) to
toggle a relay or other load with a momentary push button.
Several push buttons can be wired in parallel to control the
relay from multiple locations.
Toggle Switch from A Push On Switch
When there is no toggle switch available, maybe this circuit
can be used for changes. I made this circuit to run a toggle
foot switch, controlling blower table.
Labels: Relay Circuit
Friday, March 27, 2009
USB to Microcontroller UART Interface Circuit
An example of using the FT232R as a USB to Microcontroller
(MCU) UART interface is shown in Figure 7.4. In this application
the FT232R uses TXD and RXD for transmission and reception of
data, and RTS# / CTS# signals for hardware handshaking. Also
in this example CBUS0 has been configured as a 12MHz output to
clock the MCU. Optionally, RI# could be connected to another I/O
pin on the MCU and used to wake up the USB host controller from
suspend mode. If the MCU is handling power management functions,
then a CBUS pin can be configured as PWREN# and would also be
connected to an I/O pin of the MCU.
USB to Microcontroller parallel Interface Circuit
a MicroController ( MCU ). This examples uses two IO Ports of the
MCU, one port ( 8 bits ) to transfer data and the other port ( 4 / 5 bits )
to monitor the TXE# and RFE# status bits and generate the RD# and
WR strobes to the FT245BM as required. Optionally, SI / WU can be
Connected to another IO pin if this function is required. If the SI / WU
function is not required, tie this pin of the FT245M high. If the MCU is
handling power management functions, then PWREN# should also
be connected to an IO pin of the MCU. The 8 data bits of Port 1 can
be shared with other peripherals when the MCU is not accessing the
FT245BM.
FT245BM datasheet pdf
USB from RS-232 UART with Minimal Impact on
INTRODUCTION
The RS-232 serial interface is no longer a common port
found on a personal computer (PC). This is a problem
because many embedded applications use the RS-232
interface to communicate with external systems, such as
PCs. A solution is to migrate the application to the
Universal Serial Bus (USB) interface. There are many
different ways to convert an RS-232 interface to USB,
each requiring different levels of expertise. The simplest
method is to emulate RS-232 over the USB bus. An
advantage of this method is the PC application will see
the USB connection as an RS-232 COM connection and
thus, require no changes to the existing software.
Another advantage is this method utilizes a Windows®
driver included with Microsoft® Windows® 98SE and
later versions, making driver development unnecessary.
The objectives of this application note are to explain
some background materials required for a better understanding
of the serial emulation over USB method and
to describe how to migrate an existing application to
USB. A device using the implementation discussed in
this document shall be referred to as a USB RS-232
emulated device. The author assumes that the reader
has some basic knowledge of the USB standard. All
references to the USB specification in this
more pdf
PIC-USB-4550 PROTOTYPE BOARD FOR PIC18F4550
MICROCONTROLLER WITH USB
INTRODUCTION:
This is handly prototype board for development of USB
application with PIC18F4550 microcontroller. The great all about
it is that if you want only to load code to it i.e. to program it you
can do this without any additional programmer. Microchip provides
these free USB solutions for their microcontrollers which are
available for you to use off the shelf: USB HID Class firmware you
can build mouse or other Himan Interface Device for Windows,
USB CDC Communication class device, USB Mass Storage
firmware - add your own USB disk drives to your computer,
USB-to-RS232 driver. The planty of prototype space allow you easy
to add on sensors, relays and other peripherial devices to interface
to USB. The board can take power from USB or from External supply
with small jumper selection. RESET button, User button and LED
are on-board.
PIC-USB-STK PIC USB STARTERKIT PROTOTYPE BOARD
FOR PIC18F4550 MICROCONTROLLER WITH USB
INTRODUCTION:
This is starterkit which allow you to explore all capabilities of
PIC18F4550 and the Microchip's USB firmwares. The software
examples include: USB HID mouse which allow you to move the
mouse cursor with the four buttons on the board, USB Mass
storage device on SD-MMC card simple adds USB disk to your
computer, USB to RS232 converter all these firmware under your
control and ready to be customized and embedded in your next
application. The debugging is In-Circuit through ICSP connector,
the free available ports are put on EXTension connector.
more
AVR-USB-162 AVR USB AT90USB162 MICROCONTROLLER
PROTOTYPE BOARD WITH USB AND ICSP
AT90USB162 is the easiest way to add USB functionality to your
next device, Atmel provide free open source HID (mouse, keyboard)
and CDC (USB-to-RS232) code and on top of this AT90USB162
cost is same as ATMega16, so what you are waitng for?
AVR-USB-162 board provide the basic circuit necessary to work with
your circuit require more power than 100mA which usually USB port
provide, button, status LED, reset button. All AT90USB162 come from
Atmel pre-programmed with bootloader which allow code to be
programmed inside the chip without any external programmer, just
download the FLIP software from Atmel web site and load your HEX
code inside
Implementation USB into microcontroller: IgorPlug-USB (AVR)
Purpose of this article is to inform readers about implementation
USB interface into singlechip microcontroller, which this interface
directly not supports. Simply: implementation USB interface on
firmware level (similar as emulation of RS232 interface in
microcontrollers, which not have RS232 support). This project
includes development of firmware on microcontroller side, driver
development on computer side (for Windows operating system) ,
development of DLL library for functions calling from another
programs (programmers level) and development of demo program
(users level), which shows all functions of this device. Device is
named IgorPlug-USB (AVR) (as successor of my previous device
for computer remote control IgorPlug - serial port version).
Labels: Microcontroller, USB
USB to Microcontroller UART Interface Circuit
An example of using the FT232R as a USB to Microcontroller
(MCU) UART interface is shown in Figure 7.4. In this application
the FT232R uses TXD and RXD for transmission and reception of
data, and RTS# / CTS# signals for hardware handshaking. Also
in this example CBUS0 has been configured as a 12MHz output to
clock the MCU. Optionally, RI# could be connected to another I/O
pin on the MCU and used to wake up the USB host controller from
suspend mode. If the MCU is handling power management functions,
then a CBUS pin can be configured as PWREN# and would also be
connected to an I/O pin of the MCU.
USB to Microcontroller parallel Interface Circuit
a MicroController ( MCU ). This examples uses two IO Ports of the
MCU, one port ( 8 bits ) to transfer data and the other port ( 4 / 5 bits )
to monitor the TXE# and RFE# status bits and generate the RD# and
WR strobes to the FT245BM as required. Optionally, SI / WU can be
Connected to another IO pin if this function is required. If the SI / WU
function is not required, tie this pin of the FT245M high. If the MCU is
handling power management functions, then PWREN# should also
be connected to an IO pin of the MCU. The 8 data bits of Port 1 can
be shared with other peripherals when the MCU is not accessing the
FT245BM.
FT245BM datasheet pdf
USB from RS-232 UART with Minimal Impact on
INTRODUCTION
The RS-232 serial interface is no longer a common port
found on a personal computer (PC). This is a problem
because many embedded applications use the RS-232
interface to communicate with external systems, such as
PCs. A solution is to migrate the application to the
Universal Serial Bus (USB) interface. There are many
different ways to convert an RS-232 interface to USB,
each requiring different levels of expertise. The simplest
method is to emulate RS-232 over the USB bus. An
advantage of this method is the PC application will see
the USB connection as an RS-232 COM connection and
thus, require no changes to the existing software.
Another advantage is this method utilizes a Windows®
driver included with Microsoft® Windows® 98SE and
later versions, making driver development unnecessary.
The objectives of this application note are to explain
some background materials required for a better understanding
of the serial emulation over USB method and
to describe how to migrate an existing application to
USB. A device using the implementation discussed in
this document shall be referred to as a USB RS-232
emulated device. The author assumes that the reader
has some basic knowledge of the USB standard. All
references to the USB specification in this
more pdf
PIC-USB-4550 PROTOTYPE BOARD FOR PIC18F4550
MICROCONTROLLER WITH USB
INTRODUCTION:
This is handly prototype board for development of USB
application with PIC18F4550 microcontroller. The great all about
it is that if you want only to load code to it i.e. to program it you
can do this without any additional programmer. Microchip provides
these free USB solutions for their microcontrollers which are
available for you to use off the shelf: USB HID Class firmware you
can build mouse or other Himan Interface Device for Windows,
USB CDC Communication class device, USB Mass Storage
firmware - add your own USB disk drives to your computer,
USB-to-RS232 driver. The planty of prototype space allow you easy
to add on sensors, relays and other peripherial devices to interface
to USB. The board can take power from USB or from External supply
with small jumper selection. RESET button, User button and LED
are on-board.
PIC-USB-STK PIC USB STARTERKIT PROTOTYPE BOARD
FOR PIC18F4550 MICROCONTROLLER WITH USB
INTRODUCTION:
This is starterkit which allow you to explore all capabilities of
PIC18F4550 and the Microchip's USB firmwares. The software
examples include: USB HID mouse which allow you to move the
mouse cursor with the four buttons on the board, USB Mass
storage device on SD-MMC card simple adds USB disk to your
computer, USB to RS232 converter all these firmware under your
control and ready to be customized and embedded in your next
application. The debugging is In-Circuit through ICSP connector,
the free available ports are put on EXTension connector.
more
AVR-USB-162 AVR USB AT90USB162 MICROCONTROLLER
PROTOTYPE BOARD WITH USB AND ICSP
AT90USB162 is the easiest way to add USB functionality to your
next device, Atmel provide free open source HID (mouse, keyboard)
and CDC (USB-to-RS232) code and on top of this AT90USB162
cost is same as ATMega16, so what you are waitng for?
AVR-USB-162 board provide the basic circuit necessary to work with
your circuit require more power than 100mA which usually USB port
provide, button, status LED, reset button. All AT90USB162 come from
Atmel pre-programmed with bootloader which allow code to be
programmed inside the chip without any external programmer, just
download the FLIP software from Atmel web site and load your HEX
code inside
Implementation USB into microcontroller: IgorPlug-USB (AVR)
Purpose of this article is to inform readers about implementation
USB interface into singlechip microcontroller, which this interface
directly not supports. Simply: implementation USB interface on
firmware level (similar as emulation of RS232 interface in
microcontrollers, which not have RS232 support). This project
includes development of firmware on microcontroller side, driver
development on computer side (for Windows operating system) ,
development of DLL library for functions calling from another
programs (programmers level) and development of demo program
(users level), which shows all functions of this device. Device is
named IgorPlug-USB (AVR) (as successor of my previous device
for computer remote control IgorPlug - serial port version).
Labels: Microcontroller, USB