Showing posts with label Choice and Hobby. Show all posts
Showing posts with label Choice and Hobby. Show all posts

Easy Simulate Smartphone Screen Lock/Unlock Application

An Android phone allows itself to be locked/unlocked using a password, pattern on a grid of nine dots, fingerprint or facial recognition. An Android phone using a password needs a sequence of four digits or numbers to unlock the screen. This article describes the design, testing and working of the smartphone screen lock/unlock application using Simulink and Stateflow toolboxes of MATLAB R2014a software.

Working

The design of the phone screen lock/unlock application, as given in Fig. 3, contains paths S and E for the password (1 3 2 5). Path S is S0→S1→S2→S3→S4, whereas path E is E1→E2→E3→E4. All Android phones can be unlocked by entering the four magic digits set as password by users.

The screen lock/unlock application is designed in such a way that a correct four-digit password entered by the user chooses path S (S0→S1→S2→S3→S4) to unlock the phone. However, entering a wrong password causes the transition jump from path S to path E, leading to the failure of the password and the screen to remain locked.

When a wrong password is entered, the phone remains locked. Some examples are given below:
  1.     For password 9 3 2 5, the phone takes path S0→E1→E2 →E3→E4 and remains locked.
  2.     For password 1 4 2 5, the phone takes path S0→ S1→E2→E3→E4 and remains locked.
  3.     For password 1 3 5 5, the phone takes path S0→ S1→S2→E3→E4 and remains locked.
  4.     For password 1 3 2 1, the phone takes path S0→ S1→S2→S3→E4 and remains locked.

The phone screen lock application presented here can also be used in other places where four-digit authentication is required, for, say, unlocking a digital door lock, drawing cash from an ATM machine and so on.

The Stateflow model of the application

Modelling simulation

Steps for creating the phone screen lock application using MATLAB software are given below.
  1.     Open MATLAB software and enter simulink command to open Simulink Library Browser.
  2.     Open a new blank model for creating the screen lock application by selecting File→New→Model from Simulink Library Browser.
  3.     Take three blocks—Signal Builder, Chart and Scope—as shown in Fig. 1 from Simulink Library Browser to build the model. First, click on Simulink toolbox in Simulink Library Browser and then Sources library to select Signal Builder block. Then, take Scope block from Sinks library in Simulink toolbox. Last, take Chart block from Stateflow toolbox.
  4.     Pick, drag and place the three blocks—Signal Builder, Chart and Scope—from Simulink Library Browser into Model.
  5.     Double-click on the chart to open the internal structure or state machine of the simulation. A new window will open, as shown in Fig. 3. States and transitions are the key graphical elements used for building the logic of the screen lock application inside the chart.
  6.     Graphical elements (states, transitions, etc) needed to create the logics are available on Object Palette inside the chart.
  7.     Create the logic inside the chart using the states and drawing transitions, as given in Fig. 3. Right-click anywhere inside the chart, select Properties option. Next, choose Update Method as Discrete, and enter Sample Time as 1.
  8.     After creating the logic, select View→Model Explorer from the menu to add input and output to the chart.
  9.     In Model Explorer window, click on Add menu and select Data to add input (KeypadInput) and two output variables (Pass and Fail) to the chart.
  10.     To create a test stimulus in Signal Builder block for verifying the accuracy of the model, double-click on the block to open it. A new window will open, as shown in Fig. 2. Select Signal→Replace with→Custom… option, and enter y value as [0 0 1 1 3 3 2 2 5 5 4 4 2 2 1 1 3 3 1 and time value as [0 1 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9].
  11.     Connect the three blocks as shown in Fig. 1 and run the simulation to view the results.
Input waveform for the stored password

Internal structure (chart) of simulation


Testing and simulation results
  1.     Open MATLAB and go to Simulink Library Browser under FileOpen and locate the .slx file (MOBILELockUnlock.slx).
  2.     After clicking on .slx file, a simulation window will open, which is the block diagram of the simulation(Fig. 1). It comprises three blocks, namely, input (Signal Builder), system (Chart) and output (Scope).
  3.     Double-click on Signal Builder block to see input. A waveform will open (Fig. 2). This waveform indicates the stored password, of which one is correct (1 3 2 5) and the other is incorrect (4 2 1 3).
  4.     Click on Chart block to open the internal structure/programming. Here, you will see shells S and E, and the stored password (that is, 1 3 2 5), as shown in Fig. 3.

After designing the simulation, testing is required to ensure the correctness of the design. For testing the simulation, compile the block diagram. When compiling is done, open the output or scope by double-clicking it. Input test stimulus and outputs (Pass and Fail) will be displayed in the waveform window, as shown in Fig. 4.

Output waveform of simulation


Top waveform is the input test stimulus containing a series of values (0 1 3 2 5 4 2 1 3 1) in the form of waveforms that are fed as inputs to the application.

Middle waveform shows the correct password (1 3 2 5), which produces output value 1 at the fourth clock input, indicating successful unlocking of the Android phone screen.

Bottom waveform shows the wrong password (4 2 1 3), which produces output value 1 at the eighth clock input, indicating an unsuccessful attempt.
Steps for changing the password

From Signal Builder block, select Signal→Replace with→Custom… and a Custom Waveform dialogue box will appear. Here, you can change time values and y values as per the new password. Time values (also known as t values) will be on x axis and y values on y axis.

1 3 2 5 is the default password and 4 2 1 3 is a random incorrect password. Values of x-y waveform for 1 3 2 5 numbers are as given below.

T- values = [0 1 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8]

Y- values = [0 0 1 1 3 3 2 2 5 5 4 4 2 2 1 1 3]

Note that, t values may remain constant. You just have to change y values according to your new password.

After putting waveform values, go to the chart and update the same password in keypad input (Fig. 3). Then go back to the block diagram of the simulation. Run the simulation and check output on the scope. Make sure you have entered the correct new password, or else you will not be able to get the pass output graph.



Sourced By : EFY
Read More

Video Streaming Camera with Raspberry Pi

Live streaming video cameras can be used for security or personal purposes. A variety of webcams, camcorders, DSLRs and mirrorless cameras for streaming live video are a vailable in the market. You want to own one too but can’t afford it! Don’t worry, we will help you build one yourself at less than Rs 2000.

Today, in this DIY project, we are going to make a live streaming camera that can be accessed over Wi-Fi. The best part of this project is that you can view the video live streaming on multiple devices like computer, tablet and phones. You can also move its camera lens wirelessly for wide-angel views. Another interesting thing is that you can set this camera in a motion detection mode to enable it to take picture or record video when motion is detected. However, you may experience video lag depending on the Wi-Fi network.

Fig 1. Prototype

We can make this project by applying two methods, which will be explained below.
Setting Raspberry Pi for camera

First, you have to set up the Raspberry Pi for camera interface. Open the terminal and run this command “sudo raspi-config”. Then you will get a blue colour window with several options. Select the “Interfacing” option and enable the camera interface. (Refer Fig 2,3,4).

Fig 2. Configuration of Raspberry Pi

Fig 3. Setting interfaces

Fig 4. Setting Camera

Now, your Raspberry Pi is ready for camera interface, meaning you can start streaming camera video over Wi-Fi. You can archive this using the following two methods.

Streaming Camera Video using VLC player.

In the first method, we are going to stream the camera video using VLC player. To do this, first open the terminal window and type the following command to install VLC on your Raspberry Pi.

“Sudo apt-get install vlc”

After the successful installation, you can stream your camera video using the following command

 “raspivid -o – -t 0 -n | cvlc -vvv stream:///dev/stdin –sout ‘#rtp{sdp=rtsp://:8554/}’ :demux=h264”

To obtain the output of the video streamed by the camera, connect your PC or phone to the same Wi-Fi network on which Raspberry Pi is connected. Next open the VCL player, then go on stream menu and paste the url.

rtsp://ip address of your pi:8554/


Now, open the text editor and put the following code in it

And save it as cam.py and whenever you want to live stream a video, run this program.
Streaming Video Using Motion

Open the terminal and run the following command to install motion  “sudo apt-get install motion”

Then setup setting to run the camera server continuously on background

“sudo nano /etc/default/motion”

 start_motion_daemon=yes

Then make some changes in motion config as described below (Refer Fig 5).

Run this command

“sudo nano /etc/motion/motion.conf”

Do these changes according to your need

Stream_port=8081

Stream quality 50 # set the quality according to your need

# Allow motion to run the daemon we’ve set earlier
daemon on

# set the framerate of the stream (100 for higher quality)
framerate 100

# set the width and height of your video
width 640
height 480

# control de port 8080 by default
webcontrol_port 8080

# careful! don’t set the stream_port just like the webcontrol port

When you done with the above setting, save and exit the config file using key “CTRL + X”. Then hit the Y key and then press enter.

To start camera video streaming, open the terminal and run this command

“sudo service motion start”

“Sudo motion”

Now, connect your PC and Raspberry Pi on the same network. After that open any web browser and type the following url



https:// ip address of your raspberry pi:8081

Now you can get the camera video streaming on your web browser.

Fig 5.Configration of motion

Cam video output either over HDMI or RCA composite

If you want to get video output like other surveillance cameras on RCA composite or on HDMI without any video lag, then create the following python code and run that code to get Raspberry Pi camera video on your TV screen.



Giving movement to camera

Create a python program as in code snippet below and run the code for movement of servo motor.



As you have completed the setting and software part, it’s time to put together the whole stuff in an enclosure.

First connect the servo motor to Raspberry Pi pins as illustrated below

Motor PWM signal pin (Orange colour wire) to Raspberry Pi GPIO

Servo motor VCC  to   5V power supply

GND to Power supply GND

Raspberry Pi GND to Servo Motor GND

Now, put the Raspberry Pi in camera case and fix everything according to the pics shown below –

Fig 6. Raspberry pi cover.

Fig 7. Raspberry pi inside case

Fig 8 Solder the wires to GPIO pinouts

Fig 9. Mount the Raspberry pi case over servo motor



Author : Ashwini Kumar Sinha Sourced By : EFY
Read More

Electronic Lock Circuit Diagram

There are six (or more) push switches. To 'unlock' you must press all the correct ones at the same time, but not press any of the cancel switches. Pressing just one cancel switch will prevent the circuit unlocking. When the circuit unlocks it actually just turns on an LED for about one second, but it is intended to be adapted to turn on a relay which could be used to switch on another circuit. Please Note: This circuit just turns on an LED for about one second when the correct switches are pressed. It does not actually lock or unlock anything!

Circuit diagram :


Simple Electronic Lock Circuit Diagram
Simple Electronic Lock Circuit Diagram

Stripboard Layout :


Parts :
  • resistors: 470, 100k ×2, 1M
  • capacitors: 0.1μF, 1μF 16V radial
  • on/off switch
  • push-switch ×6 (or more)
  • stripboard 12 rows × 25 holes
  • red LED
  • 555 timer IC
  • 8-pin DIL socket for IC
  • battery clip for 9V PP3
  •  
A kit for this project is available from RSH Electronics: www.kpsec.freeuk.com



Read More

Light Phone -The concept of ultra-thin phone

Joe Collier and Kai Wei Tang created a concept cell phone Light Phone size of a credit card, which is connected to the main cell phone and has only the function calls. 



Read More

Cranial Electrotherapy Stimulator Circuit Diagram

Owing to the recent launching in Europe of Cranial Electrotherapy Stimulation (CES) portable sets, we have been "Electronically Stimulated" in designing a similar circuit for the sake of hobbyists. CES is the most popular technique for electrically boosting brain power, and has long been prescribed by doctors, mainly in the USA, for therapeutic reasons, including the treatment of anxiety, depression, insomnia, and chemical dependency. CES units generate an adjustable current (80 to 600 microAmperes) that flows through clips placed on the earlobes. 

The waveform of this device is a 400 milliseconds positive pulse followed by a negative one of the same duration, then a pause of 1.2 seconds. The main frequency is 0.5 Hz, i.e. a double pulse every 2 seconds. Some people report that this kind of minute specialized electrical impulses contributes to achieve a relaxed state that leaves the mind alert. Obviously we can't claim or prove any therapeutic effectiveness for this device, but if you are interested in trying it, the circuit is so cheap and so simple to build that an attempt can be made with quite no harm.

Circuit diagram:
cranial-electrotherapy-stimulator-circuit diagram
Parts:
R1___________1M5 1/4W Resistor
R2___________15K 1/4W Resistor
R3___________100K Linear Potentiometer
R4___________2K2 1/4W Resistor
C1___________330nF 63V Polyester Capacitor
C2___________100µF 25V Electrolytic Capacitor
D1___________3mm. Red LED
IC1___________7555 or TS555CN CMos Timer IC
IC2___________4017 Decade counter with 10 decoded outputs IC
SW1__________SPST Slider Switch
B1____________9V PP3 Battery Clip for PP3 Battery
Two Earclips with wires (see notes)

Circuit operation:

IC1 forms a narrow pulse, 2.5Hz oscillator feeding IC2. This chip generates the various timings for the output pulses. Output is taken at pins 2 & 3 to easily obtain negative going pulses also. Current output is limited to 600µA by R2 and can be regulated from 80 to 600µA by means of R3. The LED flashes every 2 seconds signaling proper operation and can also be used for setting purposes. It can be omitted together with R4, greatly increasing battery life.

Notes:
  • In order to obtain a more precise frequency setting take R1=1M2 and add a 500K trimmer in series with it.
  • In this case use a frequency meter to read 2.5Hz at pin 3 of IC1, or an oscilloscope to read 400msec pulses at pins 2, 3 or 10, adjusting the added trimmer.
  • A simpler setting can be made adjusting the trimmer to count exactly a LED flash every 2 seconds.
  • Earclips can be made with little plastic clips and cementing the end of the wire in a position suited to make good contact with earlobes.
  • Ultra-simple earclips can be made using a thin copper foil with rounded corners 4 cm. long and 1.5 cm. wide, soldering the wire end in the center, and then folding the foil in two parts holding the earlobes.
  • To ensure a better current transfer, this kind of devices usually has felt pads moistened with a conducting solution interposed between clips and skin.
  • Commercial sets have frequently a built-in timer. Timing sessions last usually 20 minutes to 1 hour. For this purpose you can use the Timed Beeper the Bedside Lamp Timer or the Jogging Timer circuits available on this website, adjusting the timing components in order to suit your needs.

Read More

Heart Rate Monitor Circuit Diagram

Strictly speaking, this simple circuit shouldn't work! How could anyone expect an ordinary light dependent resistor photo cell to 'see' through a fingertip in natural daylight and detect the change in blood flow as the heart pulsates? The secret is a high gain circuit, based on a dual op amp IC which can be either the low power LM358 or the JFET TL072. The LDR is connected in series across the 9V battery supply via a 100kO resistor (R1) and the minute signal caused by the blood pulsing under the skin is fed to the non-inverting (+) input, pin 3, of IC1a via a 0.µF capacitor.

Pin 3 is biased by a high impedance voltage divider consisting of two 3.3MO resistors. The feedback resistors to pin 2 set the gain to 11 times. The output of IC1a is fed via a 0.47µF capacitor and 220kO resistor to IC1b. This is configured as an inverting op amp with a gain of 45 so that the total circuit gain is about 500. The output of IC1b is used to drive an analog meter which may be a multimeter set to the 10V DC range or any panel meter in series with a resistor to limit the current to less than its full-scale deflection. The prototype used an old VU meter with a 47kO resistor fitted in series.

Circuit diagram:

heart-rate-monitor circuit diagram
Heart Rate Monitor Circuit Diagram

Note that the unit was designed to use the Dick Smith Electronics light dependent resistor (Z-4801). Other LDRs may require a change in the value of resistor R1. A light source such as a high brightness LED is not required. All that is needed is a reasonably well-lit room, preferably natural daylight, to produce a healthy swing of the needle. Only when the hands are very cold does it make it a little more difficult to accurately count the pulses. To check your heart rate, carefully position your thumb or finger over the LDR and count the meter fluctuations for a period of 15 seconds. Then multiply the result by four to obtain your pulse rate. The circuit can not be used if you are walking or running, etc.
Read More

Wire Loop Game Circuir Diagram

In the ‘Wire Loop Game’, a test of dexterity,  the player has to pass a metal hoop along a  twisted piece of wire without letting the hoop  touch the wire. Usually all the associated electronics does is ring a bell to indicate when the  player has lost. The version described here has  a few extra features to make things a bit more  exciting, adding a time limit to the game and a ticking sound during play. 

Two 555 timer ICs are used to provide these  functions. IC1 is configured as a monostable which controls the time allowed for the  game, adjustable using potentiometer P1. IC2  is a multivibrator to provide the ticking and Two 555 timer ICs are used to provide these  functions. IC1 is configured as a monostable which controls the time allowed for the  game, adjustable using potentiometer P1. IC2  is a multivibrator to provide the ticking and he continuous buzz that indicates when the  player has touched the wire with the hoop. 

Circuit diagram :
Wire Loop Game-Circuit Diagram
Wire Loop Game Circuit Diagram

When the monostable is in its steady state,  the output of IC1 (pin 3) is low. T1 acts as  an inverter, and D2 is thus forward biased.  R8 and R4 are therefore effectively in parallel, with the result that IC2 produces a low audible tone. The value of R4 is considerably  greater than that of R8, and so the frequency  of the buzz generated by IC2 is chiefly deter-mined by the value of R8.

When the monostable is triggered, the high  level at the output of IC1 is again inverted  by T1. D2 is reverse biased and so R8 is effectively removed from the circuit. The frequency of IC2 is now largely determined by  the value of R4. The ratio of R4 to R5 and the  value of C4 affect the mark and space periods for the multivibrator: for a satisfactory  ticking sound short pulses with long gaps  between work well. 

Whether a sound is produced also depends  on the voltage on pin 4 of IC2. When the 9 V  supply is connected the monostable is initially inactive and there is no voltage across  C1. Pin 4 (reset) on IC2 is thus low and no tone  is produced. IC1 is activated by a brief press of  S1, which generates a low-going trigger signal  on pin 2 to start the game. C1 now charges via  D1 and IC2 is allowed to oscillate, generating  the ticking sound. 

The pulse width of the monostable sets the  game duration, and can be adjusted using  P1. If the allowed time expires, or if the reset  input to IC1 is taken low (which happens when the hoop touches the wire), the monostable  returns to the quiescent state. This causes IC2  to generate the low buzz sound. D1 is now  reverse biased and C1 discharges through the  relatively high-valued resistor R9. After a few  seconds the voltage across C1 falls sufficiently  that the buzz stops and the circuit is ready for  the next player. 

The circuit can be built first on a breadboard,  so that the component values can easily be changed to suit particular preferences for  game duration and buzz pitch. When suitable  values have been selected the circuit can be  built more permanently on a printed circuit  board. The author used a sheet of plywood  to form a base for the game, the twisted wire  being fixed to the board and wired to the electronics mounted below it. 


Read More

Whistling Kettle Circuit Diagram

Most electric kettles do not produce a whistle and just switch off when they have boiled. Fitting a box of electronics directly onto an electric kettle (or even inside!) to detect when the kettle has boiled is obviously out of the question. The circuit shown here detects when the kettle switches off, which virtually all kettles do when the water has boiled. In this way, the electronics can be housed in a separate box so that no modification is required to the kettle. The box is prefer-ably a type incorporating a mains plug and socket. 

Cap

In this application, the current flowing in coil L1 provides a magnetic field that actuates reed switch S1. Since the current drawn by the kettle element is relatively large (typically 6 to 8 amps), the coil may consist of a few turns of wire around the reed switch. The reed switch is so fast it will actually follow the AC current flow through L1 and produce a 100-Hz buzz. The switching circuit driven by the reed switch must, therefore, disregard these short periods when the contacts open, and respond only when they remain open for a relatively long period when the kettle has switched off. 

Circuit diagram :
Whistling Kettle Circuit d
Whistling Kettle Circuit Diagram
 
The circuit is based on a simple voltage controlled oscillator formed around T2 and T3. Its operation is best understood by considering the circuit with junction R4/R5 at 0 V and C4 discharged. T2 will receive base current through R5 and turn on, causing T3 to turn on as well. The falling collector voltage of T3 is transmitted to the base of T2 by C4 causing this transistor to conduct harder. Since the action is regenerative, both transistors will turn on quickly and con-duct heavily. C4 will therefore charge quickly through T2’s base-emitter junction and T3. Once the voltage across C4 exceeds about 8.5 V (leaving less than 0.5 V across T2’s b-e junction), T2 will begin to turn off. This action is also regenerative so that soon both transistors are switched off and the collector volt-age of T3 rises rapidly to +9 V. With C4 still charged to 8.5 V, the base of T2 will rise to about 17.5 V holding T2 (and thus T3) off. C4 will now discharge relatively slowly via R5 until T2 again begins to conduct whereupon the cycle will repeat. The voltage at the collector of T3 will therefore be a series of short negative going pulses whose basic frequency will depend on the value of C4 and R5. The pulses will be reproduced in the piezo sounder as a tone. 

The oscillation frequency of the regenerative circuit is heavily dependent on the voltage at junction R4/R5. As this voltage increases, the frequency will fall until a point is reached when the oscillation stops altogether. With this in mind, the operation of the circuit around T1 can be considered. In the standby condition, when the kettle is off, S1 will be open so that C1 and C2 will be discharged and T1 will remain off so that the circuit will draw no current. When the kettle is switched on, S1 is closed, causing C1 and C2 to be discharged and T1 will remain off. C3 will remain discharged so that T2 and T3 will be off and only a small current will be drawn by R1. Although S1 will open periodically (at 100 Hz), the time constant of R1/C1 is such that C1 will have essentially no voltage on it as the S1 contacts continue to close. 

When the kettle switches off, S1 will be permanently open and C1/C2 will begin to charge via R1, causing T1 to switch on. C3 will then begin to charge via R4 and the falling voltage at junction R4/R5 will cause T2/T3 to start oscillating with a rising frequency. However, once T1 has switched off, C3 will no longer be charged via R4 and will begin to discharge via R3 and R5 causing the voltage at R4/R5 to rise again. The result is a falling frequency until the oscillator switches off, returning the circuit to its original condition. As well as reducing the current drawn by the circuit to zero, this mimics the action of a conventional whistling kettle, where the frequency rises as more steam is produced and then falls when it is taken off the boil. 

The circuit is powered directly by the mains using a ‘lossless’ capacitive mains dropper, C6, and zener a diode, D2, to provide a nominal 8 V dc supply for the circuit.  A 1-inch reed switch used in the prototype required about 9 turns of wire to operate with a 2-kW kettle element. Larger switches or lower current may require more turns. In general, the more turns you can fit on the reed switch, the better, but do remember that the wire has to be thick enough to carry the current. It is strongly recommended to test the circuit using a 9-volt battery instead of the mains-derived supply voltage shown in the circuit diagram. A magnet may be used to operate S1 and so simulate the switching of the kettle. 

Warning. This circuit is connected directly to the 230-V mains and none of the components must be touched when the circuit is in use. The circuit must be housed in an approved ABS case and carry the earth connection to the load as indicated. Connections and solder joints to components with a voltage greater than 200 volts across them (ac or dc) must have an insulating clearance of least 6 mm. An X2 class capacitor must be used in position C6.
Read More

Soldering Iron Tip Preserver Circuit Diagram

Although 60/40 solder melts at about 200&degC, the tip temperature of a soldering iron should be at about 370&degC. This is necessary to make a good quick joint, without the risk of overheating delicate components because the iron has to be kept on the joint for too long. Unfortunately, at this temperature, the tip oxidises rapidly and needs constant cleaning. That's where this circuit can help - it keeps the soldering tip to just below 200&degC while the iron is at rest. Oxidisation is then negligible and the iron can be brought back up to soldering temperature in just a few seconds when needed. In addition, normal soldering operation, where the iron is returned to rest only momentarily, is unaffected because of the thermal inertia of the iron. Two 555 timers (IC1 & IC2) form the heart of the circuit. 

Circuit diagram:
soldering-iron-tip-preserver circuit diagram
Soldering Iron Tip Preserver Circuit Diagram

IC1 is wired as a monostable and provides an initial warm-up time of about 45 seconds to bring the iron up to temperature. At the end of this period, its pin 3 output switches high and IC2 (which is wired in astable configuration) switches the iron on - via relay RLY1 - for about one second in six to maintain the standby temperature. The presence of the iron in its stand is sensed by electrical contact between the two and some slight modification of the stand may be necessary to achieve this. When the iron is at rest, Q1's base is pulled low and so Q1 is off. Conversely, when the iron is out of its stand, Q1 turns on and pulls pins 2 & 6 of IC2 high, to inhibit its operation. During this time, pin 3 of IC2 is low and so the iron is continuously powered via RLY1's normally closed (NC) contacts. Note that the particular soldering iron that the circuit was designed for has its own 24V supply transformer. Other irons may need different power supply arrangements. The warm-up time and standby temperature can be varied by altering R2 and R5, as necessary.
Read More

Electronic Cricket Match Game Circuit

This electronic cricket is a present for Kids. This simple battery powered circuit can be used to play Cricket Match with your friends. Each LED in the circuit indicates various status of the cricket match like Sixer, Run out, Catch etc. The Circuit uses two ICs ,one in the Astable mode and the second in the display driver mode. IC1 is wired as an Astable Multivibrator with the timing elements R1, R2 and C1. With the shown values of these components very fast output pulses are generated from the Astable.

Output from IC1 passes into the input of IC2 which is the popular Johnson Decade counter CD4017. It has 10 outputs. Of these 8 outputs are used. Output 9 ( pin9) is tied to the reset pin 15 to repeat the cycle. When the input pin 14 of IC2 gets low to high pluses, its output turns high one by one. Resistor R3 keeps the input of IC2 low in stand by state to avoid false indications.

Electronic Cricket Circuit Diagram
Cricuit Project: Electronic Cricket Match Game
When the Push Switch S1 is pressed momentarily, the Astable operates and all the LEDs run very fast sequentially. When S1 is released, any one of the LED stands lit which indicates the status of the match. For example, if LED D7 remains lit, it indicates Sixer and if LED 8 remains lit, it indicates Catch out. Label each LED for its status as shown in the diagram. Pressing of S1 simulates Bowling and Running LEDs indicates running of Batsman.
Read More

Acoustic Distress Beacon Circuit diagram

An ELT (Emergency Locator Transmitter, also known as a distress beacon) is an emergency radio transmitter that is activated either manually or automatically by a crash sensor to aid the detection and location of aircraft in distress. This acoustic ELT project is intended for radio control (RC) model aircraft, which every now and then decide to go their own way and disappear into the undergrowth.

Circuit diagram :
Acoustic Distress Beacon-Circuit Diagram
Acoustic Distress Beacon Circuit Diagram

The audio locating device described here enables model aircraft that have landed ‘off limits’ to be found again and employs its own independent power supply. The small cam-era battery shown in the circuit activates an acoustic sounder when radio contact is lost and produces a short signal tone (bleep) every ten seconds for more than 25 hours. Current consumption in standby and passive (with jumper J1 set) modes is negligible. The timing generator for the alarm tone is the Schmitt trigger AND-gate IC1.B; its asymmetric duty cycle drives a 5 V DC sounder via MOSFET transistor T1. All the time that the RC receiver output is delivering positive pulses, the oscillator is blocked by IC1.A and diode D1. Setting jumper J1 parallel to C2 also disables the oscillator and serves to ‘disarm’ the distress beacon. 



Read More

Wire Loop Game Circuit Diagram

In the ‘Wire Loop Game’, a test of dexterity,  the player has to pass a metal hoop along a  twisted piece of wire without letting the hoop  touch the wire. Usually all the associated electronics does is ring a bell to indicate when the  player has lost. The version described here has  a few extra features to make things a bit more  exciting, adding a time limit to the game and a ticking sound during play. 

Two 555 timer ICs are used to provide these  functions. IC1 is configured as a monostable which controls the time allowed for the  game, adjustable using potentiometer P1. IC2  is a multivibrator to provide the ticking and Two 555 timer ICs are used to provide these  functions. IC1 is configured as a monostable which controls the time allowed for the  game, adjustable using potentiometer P1. IC2  is a multivibrator to provide the ticking and he continuous buzz that indicates when the  player has touched the wire with the hoop. 

Circuit diagram :
Wire Loop Game-Circuit Diagram
Wire Loop Game Circuit Diagram

When the monostable is in its steady state,  the output of IC1 (pin 3) is low. T1 acts as  an inverter, and D2 is thus forward biased.  R8 and R4 are therefore effectively in parallel, with the result that IC2 produces a low audible tone. The value of R4 is considerably  greater than that of R8, and so the frequency  of the buzz generated by IC2 is chiefly deter-mined by the value of R8.

When the monostable is triggered, the high  level at the output of IC1 is again inverted  by T1. D2 is reverse biased and so R8 is effectively removed from the circuit. The frequency of IC2 is now largely determined by  the value of R4. The ratio of R4 to R5 and the  value of C4 affect the mark and space periods for the multivibrator: for a satisfactory  ticking sound short pulses with long gaps  between work well. 

Whether a sound is produced also depends  on the voltage on pin 4 of IC2. When the 9 V  supply is connected the monostable is initially inactive and there is no voltage across  C1. Pin 4 (reset) on IC2 is thus low and no tone  is produced. IC1 is activated by a brief press of  S1, which generates a low-going trigger signal  on pin 2 to start the game. C1 now charges via  D1 and IC2 is allowed to oscillate, generating  the ticking sound. 

The pulse width of the monostable sets the  game duration, and can be adjusted using  P1. If the allowed time expires, or if the reset  input to IC1 is taken low (which happens when the hoop touches the wire), the monostable  returns to the quiescent state. This causes IC2  to generate the low buzz sound. D1 is now  reverse biased and C1 discharges through the  relatively high-valued resistor R9. After a few  seconds the voltage across C1 falls sufficiently  that the buzz stops and the circuit is ready for  the next player. 

The circuit can be built first on a breadboard,  so that the component values can easily be changed to suit particular preferences for  game duration and buzz pitch. When suitable  values have been selected the circuit can be  built more permanently on a printed circuit  board. The author used a sheet of plywood  to form a base for the game, the twisted wire  being fixed to the board and wired to the electronics mounted below it. 


Read More

RGB Solar Lamp Circuit Diagram

This deluxe solar-powered light  uses a battery and solar cells salvaged from a solar lamp with a four-cell battery (4.8 V nominal terminal  voltage).

Circuit diagram :
RGB Solar Lamp-Circuit Diagram
RGB Solar Lamp Circuit Diagram

The circuit can operate from any  DC voltage around this value and  its current consumption, at 20 mA,  is low. This means that the battery  can give up to five days of operation. The circuit consists of an Atmel  ATtiny microcontroller which drives  a red, a green and a blue LED directly  from three port pins. Series resistors are of course included to limit  the LED current. The microcontroller  drives the LEDs in sequence to produce an  RGB running light effect. The microcontroller  is also responsible for ensuring that the light automatically switches on when it gets dark  and off when it is light. The light sensor is  made from one of the solar cells from a bro-ken solar lamp (it is more common  for the battery to fail rather than  the solar cells). 

The power output of this cell is not  important, as the microcontroller  only measures its output voltage  using its internal A/D converter  connected to pin PB4. The project is  ideal for beginners, as a ready-programmed microcontroller is avail-able from the Elektor Shop (order  code 100581-41). 



Source by : Streampowers
Read More

Simple UV Torch Light Circuit Diagram

This is the Simple UV Torch Light Circuit Diagram. UV (ultra-violet) LEDs can produce eye-catching effects when their light is allowed to interfere with certain colours, particularly with reflected light under near-dark conditions. Also try shining some UV light on a diamond.

Circuit diagram :
UV Torch Light-Circuit Diagram
 UV Torch Light Circuit Diagram

Most UV LEDs require about 3.6 V (the ‘blue’ diode voltage) to light. Here, a MAX761 step-up switching IC is used to provide constant current to bias the UV diode. The IC employs PWM in high-cur-rent mode and automatically changes to PFM mode in low or medium power mode to save (battery) power. To allow it to be used with two AA cells, the MAX761 is configured in bootstrapped mode with voltage-adjustable feedback. Up to four cells may be used to power the circuit but they may add more weight than you would like for a torchlight. 

To prolong the switch life, R1 is connected to the IC’s SHDN (shutdown) pin. Less than 50 nA will be measured in shutdown mode. Electrolytic capacitor C1 is used to decouple the circuit supply voltage. With-out it, ripple and noise may cause instability. The one inductor in the circuit, L1, may have any value between about 10 and 50 µH. It stores current in its magnetic field while the MOSFET inside the MAX761 is switched. A toroid inductor is preferred in this position as it will guarantee low stray radiation. D1 has to be a relatively fast diode so don’t be tempted to use an 1N400x because it has a too slow recovery time.
The circuit efficiency was measured at about 70%. R2, the resistor on the feed-back pin of the MAX761 effectively determines the amount of constant current, I, sent through the UV LEDs, as follows: R2 = 1.5 / I
where I will be between 2 mA and 35 mA. 

Zener diode D4 clamps the output voltage when the load is disconnected, which may happen when one of the UV LEDs breaks down. Without a load, the MAX761 will switch L1 right up to the boost voltage and so destroy itself.
Read More

Steam Whistle Circuit Diagram

This is a simple Steam Whistle Circuit Diagram. This circuit consists of six square wave oscillators. Square waves are made up of a large number of harmonics. If six square waves with different frequencies are added together, the result will be a signal with a very large number of frequencies. When you listen to the result you’ll find that it is very similar to a steam whistle. The circuit should be useful in modelling or even in a sound studio.

Steam Whistle Circuit Diagram

Simple Steam Whistle-Circuit Diagram
Simple Steam Whistle Circuit Diagram

This circuit uses only two ICs. The first IC, a 40106, contains six Schmitt triggers, which are all configured as oscillators. Different frequencies are generated by the use of different feedback resistors. The output signals from the Schmitt triggers are mixed via resistors. The resulting signal is amplified by IC2, an LM386. This IC can deliver about 1 W of audio power, which should be sufficient for most applications. If you leave out R13 and all components after P1, the output can then be connected to a more powerful amplifier. In this way a truly deafening steam whistle can be created. The ‘frequency’ of the signal can be adjusted with P2, and P1 controls the volume.
Read More

Long-Delay Stop Switch

Presettable times for train stops in stations are indispensable if you want to operate your model railway more or less realistically according to a timetable. This circuit shows how a 555 timer can be used with a relatively small timing capacitor to generate very long delay times as necessary by using a little trick (scarcely known among model railway electronic technicians): pulsed charging of the timing net-work. Such long delays can be used in hidden yards with through tracks, for instance.  As the timer is designed for half-wave operation, it requires only a single lead to the transformer and one to the switching track or reed contact when used with a Märklin AC system (H0 or H1). The other lead can be connected to any desired grounding point for the common ground of the track and lighting circuits.

Circuit diagram :
Long-Delay Stop Switch-Circuit Diagram
Long-Delay Stop Switch Circuit Diagram

As seen from the outside, the timer acts as a monostable flip-flop. The output (pin 3) is low in the quiescent state. If a negative signal is applied to the trigger input (pin 2), the output goes high and C4 starts charging via R3 and R4. When the voltage on C4 reaches 2/3 of the supply voltage, it discharges via an internal transistor connected to pin 7 to 1/3 of the supply voltage and the output (pin 3) goes low. The two threshold values (1/3 and 2/3) are directly proportional to the supply voltage. The duration of the output signal is independent of the supply voltage: t= 1.1(R4 + R5) × C4 

if the potentiometer is connected directly to the supply line (A and B joined). The maximum delay time that can be generated using the component values shown in the schematic diagram is 4.8 minutes. How-ever, it can be increased by a factor of approximately 10 if the timing network is charged using positive half-waves of the AC supply voltage (reduced to the 10–16-V level) instead of a constant DC voltage. 

The positive half-waves of the AC voltage reach the timing network via D2, the transistor, and D3. Diode D3 prevents C4 from being discharged between the pulses. The total resistance of R4 and R5 should not be too high (no more than 10 MΩ if possible), since electrolytic capacitors (such as are needed for C4) have significant leakage currents. Incidentally, the leakage current of aluminium electrolytic capacitors can be consider-ably reduced by using a supply voltage well below the rated voltage. Capacitor C6 is intended to suppress noise. It forms a filter network in combination with an internal voltage-divider resistor.
If a vehicle happens to remain standing over the reed switch so the magnet holds the contacts constantly closed, the timer will automatically be retriggered when the preset delay times out. In this case the relay armature will not release and the locomotive will come to the ‘end of the line’ in violation of the timetable. This problem can be reliably eliminated using R6, R7 and C5. This trigger circuit ensures that only one trigger pulse is generated, regardless of how long the reed switch remains closed. RC network R8/C7 on the reset pin ensures that the timer behaves properly on switch-on (which is far from being something to be taken for granted with many versions of the 555 or 556 dual timer).
Reed switches have several special characteristics that must be kept in mind when fitting them. The contact blades, which are made from a ferromagnetic material, assume opposite magnetic polarities under the influence of a magnetic field and attract each other. Here the position and orientation of the magnet, the distance between the magnet and the reed switch, and the direction of motion of the magnet relative to the switch are important factors. The fragility of the glass hous-ing and the thermal stress from soldering (stay at least 3 mm away from the glass housing) require a heat sink to be used between the soldering point and the glass/metal seal. A suitable tweezers or flat-jawed pliers can be used for this pur-pose. If you need to bend the leads, use flat-jawed pliers to protect the glass/metal seal against mechanical stresses. 

Matching magnets in various sizes are available from toy merchants and electronics mail-order firms. They should preferably be fitted underneath the loco-motive or carriage. However, the magnet can also be fitted on the side of a vehicle with a plastic body. In this case the reed switch can be hidden in a mast, bridge column or similar structure or placed in a tunnel, since the distance must be kept to less than around 10 mm, even with a strong magnet. If fitting the circuit still presents problems (especially with Märklin Z-gauge Mini-Club), one remedy is to generate the trigger using a unipolar digital Hall switch, such as the Siemens TLE4905L or Allegro UGN3120. To avoid coupled-in interference, the stop timer should be fitted relatively close to the Hall sensor (use screened cable if necessary). Pay attention to the polarity of the magnet when fitting it to the bottom of the vehicle. With both types of sensors, the South pole must point toward the front face of the Hall IC (the face with the type marking). The North pole is sometimes marked by a dab of paint. Generally speaking, the polarity must be determined experimentally. 

Fitting the circuit is not a problem with Z-gauge and 1-gauge tracks, since the distance between the iron parts (rails) and the Hall switch is sufficiently large. In an HO system, some modifications must be made to the track bed of the Märklin metal track. Cut a suitably sized ‘window’ between one wheel rail and the centre rail in order to prevent secondary magnetic circuits from interfering with the operation of the sensor. Keep the distance between the magnet and the case of the Hall switch between 5 and 10 mm, depending on the strength of the magnet, to ensure reliable actuation.




Source by : Streampowers
Read More

Model Railway Short-Circuit Beeper

Short circuits in the tracks, points or wiring are almost inevitable when building or operating a model railway. Although transformers for model systems must be protected against short circuits by built-in bimetallic switches, the response time of such switches is so long that is not possible to immediately localise a short that occurs while the trains are running, for example. Furthermore, bimetallic protection switches do not always work properly when the voltage applied to the track circuit is relatively low.


Circuit diagram :

Model Railway Short-Circuit Beeper-Circuit Diagram
Model Railway Short-Circuit Beeper Circuit Diagram

The rapid-acting acoustic short-circuit detector described here eliminates these problems. However, it requires its own power source, which is implemented here in the form of a GoldCap storage capacitor with a capacity of 0.1 to 1 F. A commonly available reed switch (filled with an inert gas) is used for the current sensor, but in this case it is actuated by a solenoid instead of a permanent magnet. An adequate coil is provided by several turns of 0.8–1 mm enamelled copper wire wound around a drill bit or yarn spool and then slipped over the glass tube of the reed switch. This technique generates only a negligible voltage drop. The actuation sensitivity of the switch (expressed in ampèreturns or A-t)) deter-mines the number of turns required for the coil. For instance, if you select a type rated at 20–40 A-t and assume a maxi-mum allowable operating current of 6 A, seven turns (40 ÷ 6 = 6.67) will be sufficient. As a rule, the optimum number of windings must be determined empirically, due to a lack of specification data. 

As you can see from the circuit diagram, the short-circuit detector is equally suitable for AC and DC railways. With Märklin transformers (HO and I), the track and lighting circuits can be sensed together, since both circuits are powered from a single secondary winding. 

Coil L1 is located in the common ground lead (‘O’ terminal), so the piezoelectric buzzer will sound if a short circuit is present in either of the two circuits. The (positive) trigger voltage is taken from the lighting circuit (L) via D1 and series resistor R1. Even though the current flowing through winding L1 is an AC or pulsating DC current, which causes the contact reeds to vibrate in synchronisation with the mains frequency, the buzzer will be activated because a brief positive pulse is all that is required to trigger thyristor Th1. The thyristor takes its anode voltage from the GoldCap storage capacitor (C2), which is charged via C2 and R2.  The alarm can be manually switched off using switch S1, since although the thyris-tor will return to the blocking state after C2 has been discharged if a short circuit is present the lighting circuit, this will not happen if there is a short circuit in the track circuit. C1 eliminates any noise pulses that may be generated. 

As a continuous tone does not attract as much attention as an intermittent beep, an intermittent piezoelectric generator is preferable. As almost no current flows during the intervals between beeps and the hold current through the thyristor must be kept above 3 mA, a resistor with a value of 1.5–1.8 kΩ is connected in parallel with the buzzer. This may also be necessary with certain types of continuous-tone buzzers if the operating current is less than 3 mA. The Zener diode must limit the operating voltage to 5.1 V, since the rated volt-age of the GoldCap capacitor is 5.5 V.


source by : Streampowers
Read More

Acoustic Distress Beacon

An ELT (Emergency Locator Transmitter, also known as a distress beacon) is an emergency radio transmitter that is activated either manually or automatically by a crash sensor to aid the detection and location of aircraft in distress. This acoustic ELT project is intended for radio control (RC) model aircraft, which every now and then decide to go their own way and disappear into the undergrowth.

Circuit diagram :
Acoustic Distress Beacon-Circuit Diagram
Acoustic Distress Beacon Circuit Diagram

The audio locating device described here enables model aircraft that have landed ‘off limits’ to be found again and employs its own independent power supply. The small cam-era battery shown in the circuit activates an acoustic sounder when radio contact is lost and produces a short signal tone (bleep) every ten seconds for more than 25 hours. Current consumption in standby and passive (with jumper J1 set) modes is negligible. The timing generator for the alarm tone is the Schmitt trigger AND-gate IC1.B; its asymmetric duty cycle drives a 5 V DC sounder via MOSFET transistor T1. All the time that the RC receiver output is delivering positive pulses, the oscillator is blocked by IC1.A and diode D1. Setting jumper J1 parallel to C2 also disables the oscillator and serves to ‘disarm’ the distress beacon. 


Read More

24V DC Powered Beeper with 4 Separate Inputs

24v DC is a very popular voltage used in industrial settings. This hobby circuit below was designed to accept four different 24v DC alarm input signals, which are then used to drive a single low power beeper. The beeper is a magnetic type with its own oscillator/driver. The four diodes form an “OR” gate so any one of the four inputs will cause the beeper to make noise. A CMOS version of the popular 555 timer is used to strobe the beeper on and off at about 1Hz.


24V DC Powered Beeper with 4 Separate Inputs 


Copyright: Discover Circuits
Read More

Railway Points Sequencer Circuit Diagram

Dedicated model rail enthusiasts using sophisticated train and points controllers often have the problem that as their layouts get bigger and more complex, the transformer supplying power to the points does not have enough current to switch several points at the same time. The actuators in the points are designed for ac operation so it doesn’t help by rectifying the supply and adding reservoir capacitors, the coils can overheat and burn out if they get jammed during their travel (ac operation actually helps to overcome friction in the mechanism). The circuit shown here solves this problem by using a sequencer to ensure than only one points actuator can be active at any point in time. During operation the controller will switch all the points on one line at the same time as usual, but the other connection to each coil is connected to the sequencer unit. This circuit will only allow current to flow through one coil at a time. 

Railway Points Sequencer Circuit Diagram


Railway Points Sequencer Circuit Diagram Railway Points Sequencer Circuit Diagram

The sequencer circuit consists of a 555 timer configured as an astable multivibrator clocking a 4017 Johnson counter where the ten outputs are used to switch ten triacs in sequence, enough for ten sets of points. P1 alters the oscillator frequency of the 555 timer and can be adjusted so that each time interval of the sequencer is long enough to allow the points to switch. 

The switching time varies depending on the type of points but is typically between 1 s and 1.5 s. Any points that jam during switching give out a characteristic humming noise in time to the switching frequency so it makes them easier to find. The eleventh output of the 4017 can be connected to an LED (together with a series resistor). This will flash to give a visual indication of the sequencers operation. Power for the circuit is provided by 15 V ac from the points transformer. The B80C1500 bridge rectifier (80 Vpiv, 1.5 A) and regulator IC1 produce a stabilised 12 V for the circuit. Current consumption is only a few milliamps.

Read More