Basic Microcontroller based project

Thread Starter

abhimanyu143

Joined Aug 25, 2014
211
Hello experts
I am trying to make small Microcontroller based project.I am making with three module
part 1-Power supply
part2-microcontroller (rest , cap and oscillator )
part3- programmer circuit

I have purchased some components
Micro controller P89v51RD2BN
Capacitor 1000 uF
diode 1N4007
regulator Ic 7805
battery 9v DC

I am trying to make circuit step by step. so that's why I am making power supply for microcontroller
upload_2015-3-31_7-18-0.png


I measured some value with multimeter
battery voltage without load = 9.39
regulator Input voltage 7.01
regulator output voltage= 6.79
microntroller voltage =6.35

please look at my reading and tell If look like correct.I am just waiting for confirmation If Its correct than I will post my next programmer circuit .
thank you very much
 

Thread Starter

abhimanyu143

Joined Aug 25, 2014
211
You have your 7805 regulator plugged in backwards.
ok that's my mistake
I have taken another readings
battery voltage without load = 9.39
regulator Input voltage 8.16
regulator output voltage= 5.03
microntroller voltage =5.00

please tell me If circuit is correct then I will post my next part
 

absf

Joined Dec 29, 2010
1,968
1. You need a pullup resistor on the button.
2. EA (p31) should be connected to +5V
3. A 100nF cap to be connected to 5V to GND on the output of 7805.
4. Another 100nF cap to be connected to pin 40 of 89V51 and GND.
5. The resset cap (10uF) and resistor (10K) should be connected to pin 9.

89v51rd2 vead.PNG

Allen
 

takao21203

Joined Apr 28, 2012
3,702
you normally only need one capacitor if the parts are so close and you dont race the circuit with some weird waveforms.

You can use almost any small capacitor (at low frequencies).
100nF as such does very little you need another value if you drive waveforms at high frequency or draw large currents.

But dont plug it with myriads of unneeded capacitors. Pull them out, see what happens, it may take an hour or two but then you see the whole thing becoming unstable.

A battery actually is kindof a capacitor, even if doesnt directly have a capacity in Farads. you dont neccessarily need a large other capacitor for a battery.
 

absf

Joined Dec 29, 2010
1,968
One more thing... Lighting the LED using logic high might not work well with 8051 as it has weak pullup on the port pin. It is better to connect the LED and resistor pair to Vcc and light it using logic zero.

Allen
 

Thread Starter

abhimanyu143

Joined Aug 25, 2014
211
hello
I think I have to buy some component
here is my another effort. tell me which component I am missing. I will buy very soon and If you see any wrong connection please informme
1.power supply circuit
2.microcontroller
3.programmer circuit
upload_2015-4-1_9-22-19.png
 

ErnieM

Joined Apr 24, 2011
8,377
abhimanyu143: the standard way to present a circuit is thru a schematic diagram. Don't get me wrong, posting a picture of your build is also very helpful in letting others see possible errors (like that 40 pin package isn't quite inserted all the way into the breadboard) but the best way to document your work is with a schematic diagram.

Those of us in the game for a while actually thing in terms of the schematic first: when we see the parts we actually see the symbols in some weird way.

There are several free programs that will let you draw schematic diagrams. My favorite is Kicad but there are many others, right down to a pencil and a piece of paper. I strongly suggest you draw this out and learn how to do good schematics if you intend to pursure electronics either as a hobby or professionally.

Sorry I can't be of much help on your project as I don't use that brand of controller but you are getting some good advice from the others here.

Good luck with your project!
 

atferrari

Joined Jan 6, 2004
4,771
Next time do first what Allen did: show a circuit and eventually one or two pictures.

You are suposed to always follow a schematic to build something.

By the way, is this your own creation or are you trying to reproduce a circuit you found somewhere?
 

absf

Joined Dec 29, 2010
1,968
On your breadboard, your button was connected to pin 10 (P3.0) but on your schematic, it was connected to pin 9 (reset). So which one is correct?

In your circuit also, you forget to connect the 2x 33p caps to Gnd. And the you need a logic high to reset the 8051.

As for the MAX232. I usually use 1uF instead of 100nF. See what the datasheet says...

Allen
 

Thread Starter

abhimanyu143

Joined Aug 25, 2014
211
On your breadboard, your button was connected to pin 10 (P3.0) but on your schematic, it was connected to pin 9 (reset). So which one is correct?

In your circuit also, you forget to connect the 2x 33p caps to Gnd. And the you need a logic high to reset the 8051.

As for the MAX232. I usually use 1uF instead of 100nF. See what the datasheet says...

Allen
ok I am making new schematic. This is my design. tell me how many mistakes are in this design ?
upload_2015-4-2_6-9-53.png
 

ErnieM

Joined Apr 24, 2011
8,377
Neither U2 nor U3 show any pins for power. I assume your schematic program hides these pins but they need be wired. Each chip should also get a o.1uF cap between the power pins as close to the device as possible; there are for power bypass and they keep the devices from interfearing with each other via the power supply wires.
 

Papabravo

Joined Feb 24, 2006
21,228
Both C9 and C10 should be connected to GND. Pins 2 & 6 will have ±8.5 volts. See Figure 6. in datasheet. These "RS-232" levels are generated from the +5V power supply using a charge pump and an inverter.

As has already been noted Vcc(+5V) goes on pin 16, which must be bypassed to GND with a capacitor, and GND(Vss) goes on pin 15.
 

Thread Starter

abhimanyu143

Joined Aug 25, 2014
211
Both C9 and C10 should be connected to GND. Pins 2 & 6 will have ±8.5 volts. See Figure 6. in datasheet. These "RS-232" levels are generated from the +5V power supply using a charge pump and an inverter.

As has already been noted Vcc(+5V) goes on pin 16, which must be bypassed to GND with a capacitor, and GND(Vss) goes on pin 15.
I think it should be correct. now tell me If schematic look like correct. I will start to make project on breadboard
upload_2015-4-2_11-34-16.png
 
Top