Arduino Forum

Using Arduino => General Electronics => Topic started by: Ginza on Aug 31, 2015, 09:24 pm

Title: Servo movement resets ATMEGA328
Post by: Ginza on Aug 31, 2015, 09:24 pm
Hi everybody, I have a 9v battery connected to a 7805IC to get 5v to ATMega328 and a TowerPro 9g servo.

Im using all in a protoboard, the problem is that when the servo moves, the ATMega328 restarts.

I have read in the web that it could work with a 7805 for the servo and other 7805 for the ATMega328.

What do you think ?


Best regards, GInza.
Title: Re: Servo movement resets ATMEGA328
Post by: CrossRoads on Aug 31, 2015, 09:50 pm
The servo could draw an amp while moving. The 9V battery is only good for a coupele hundred mA. So the voltage drops when the servo moves, and the Arduino restarts.
Battery/7805 for each unit is what you really need. Go with 6xAA battery pack for the servo.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Aug 31, 2015, 10:01 pm
Hi CrossRoads, thanks for your reply.

Sorry if that I will tell you is wrong, Im starting with Arduino few month ago.

I was thinking in use the same battery with two 7805.

What do you think ?


Best regards, GInza
Title: Re: Servo movement resets ATMEGA328
Post by: CrossRoads on Aug 31, 2015, 10:05 pm
As I said: The servo could draw an amp while moving. The 9V battery is only good for a couple hundred mA. So the voltage drops when the servo moves, and the Arduino restarts."
If one regulator draws an amp, the battery voltage will drop, the 2nd regulator will be starved for voltage, and the microcontroller will reset.
Use 2 batteries.
Title: Re: Servo movement resets ATMEGA328
Post by: Paul__B on Sep 01, 2015, 12:02 am
As was explained.

If this is what you are using as a battery:
(https://upload.wikimedia.org/wikipedia/commons/thumb/8/8d/Duracell_9_Volt_0849.jpg/403px-Duracell_9_Volt_0849.jpg) (https://en.wikipedia.org/wiki/Nine-volt_battery)

then give up now!


Get a proper battery.  Start with a pack of six "AA" (not "AAA") alkaline cells.
(http://www.batteryspace.com/images/products/detail/2122.png)
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 01, 2015, 11:14 pm
Do you have a DMM ?

Do you know what current is ?
Do you know the mAh rating of your battery ?
Do you know the current draw of your circuit (static and dynamic ) ?
Do you know the voltage of your battery (at this moment ) ?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 01, 2015, 11:22 pm
Hi everybody, thanks for your replies.

Yes, im using a 9v battery like the picture, but im using a rechargable 9v battery, because I want to save money with the circuit.

Two 9v batteries is more expensive that I was thinking CrossRoads, may be another option ?


Do you mean a pack of six "AA" for ATMega and the servo Paul__B  ?


I dont know what is aDMM raschemmel...


Best regards, GInza.
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 01, 2015, 11:29 pm
You want answers. How about giving us some:
Quote
Do you know what current is ?
Do you know the mAh rating of your battery ?
Do you know the current draw of your circuit (static and dynamic ) ?
Do you know the voltage of your battery (at this moment ) ?
Title: Re: Servo movement resets ATMEGA328
Post by: Paul__B on Sep 02, 2015, 12:03 am
I don't know what is a DMM raschemmel...
Ever tried Google (https://en.wikipedia.org/wiki/DMM)?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 12:29 am
Hi raschemmel, look I have started with Arduino few month ago. Im a software developer, but one day I wanted to do that my code start to do things with the real world, so I started with Ardunio Uno.

Im learning in the road, while Im connecting things Im learning, Im getting all the information from youtube, google, etc.

Please got me patience :)


My goal now is to find a good power supply to connect the circuit, If I can save money better. I have the ATMega328 on a protoboard with the basics elements to work it without the Arduino uno board. I have connected a 7805 to limit voltage to 5v.

Im using a VIPOW 9v Battery 250mA.

I dont know the current draw of the circuit (static and dynamic ) , i will try to get information in the web.

Please guide me. Thanks

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 01:03 am
The Arduino UNO is about 50 to 75mA. The servo can be anywhere from 100mA to 500mA depending on the load connected to the servo. If the load requires a lot of force to move it then the current would probably be more than 250mA.

By Ohm's Law,
V (voltage) = I (current(A)) x R (resistance (ohms)

If you had a DMM (Digital MultiMeter) , you could put it in current mode and measure the current or in voltage mode and measure the voltage across the battery. For most arduino hobbyists looking to control things , a DMM is to them what a tire iron (or jack) is to a traveler. You just won't get very far without one and you should never leave home without it. Either buy a cheap digital multimeter or find another hobby.
Title: Re: Servo movement resets ATMEGA328
Post by: Paul1958 on Sep 02, 2015, 02:05 am
As it has been said. You just cant really do electrical / electronic things without a DMM.I am 57 and been doing this kind of thing sense I was about 15, so that is 42 years and these gents have been trying to help and give you good info. 9v battery for uno. 6 AA batteries for the servo. Just make sure to connect the ground (-) wires together.
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 03:04 am
Quote
My goal now is to find a good power supply to connect the circuit, If I can save money better. I have the ATMega328 on a protoboard with the basics elements to work it without the Arduino uno board. I have connected a 7805 to limit voltage to 5v.
This really tells us nothing regarding where you are with the uC.

What is the SITREP ? (Milspeak for Situation Report)



1-Are you breadboarding an ATmega328 blind or do you know what you are doing ?
2-Do you know how you are going to communicate with the ATmega328 ?
3-Does the ATmega328 have a bootloader already ?
4-What are you using for a clock ?
5-Have you been able to communicate with the ATmega328 yet ?
6-Do you know what a schematic is ?
7-Can you draw a schematic of your circuit and post a photo of it?
8-WHAT EXACTLY have you actually done with this so far ? (have you powered it up? loaded a sketch ? etc etc ?

Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 04:45 pm
Hi raschemmel and Paul1958, thanks for your replies. Sorry for my english, Im spanish.

I will try to explain you the situation.

I have finished the project code, now Im testing if it is right. I dont want unexpected behavior, so I want to put the code working standalone on a protoboard.

The devices that I have connected to the Atmega are a RTC module (DS1302) and a BlueTooth module (HC-05). I have communication with the Atmega by BlueTooth with my phone and it works properly. I can get and set data in both ways.

To get the system working standalone, I must get a good power supply option, I need that it should be rechargable.

Yesterday I have connected all on the protoboard without the servo with the 9v battery full charged to see how the system works. It only was turned on 20 minutes. I think that the 9v battery doesnt work for my needs.

In your experience, please recommend me a good and cheap power supply to use. I will try the 6AA batteries like you said me.

I will try to upload some pictures, this are not very schematics, but is the faster way to show you what I have got.

About the DMM, of course I have got one and I use it. But I dont know it by the initals, I know it by multimeter.

Best regards, GInza.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 04:54 pm
Pictures
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 04:55 pm
Pictures
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 05:46 pm
You didn't answer the most important question:
How do you know there is a pot and do youbhabe the schematic and what is the voltage across the pot. That is all that matters at this stage.

Que le importa las otra cosas si no sabes que necessita de la circuita que maneja la barca ?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 05:52 pm
Hi raschemmel, what is the meaning of POT ?

I dont have schematics yet. I will try do it then.

What do you think about 6AA pack before the 7805 ?
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 06:12 pm
Quote
You didn't answer the most important question:
How do you know there is a pot and do youbhabe the schematic and what is the voltage across the pot. That is all that matters at this stage.

Que le importa las otra cosas si no sabes que necessita de la circuita que maneja la barca ?
DISREGARD ABOVE (It was intended for a different post. I got the two posts mixed up . My bad)

Do you upload sketches via bluetooth as well ?

Your original problem of reseting was because of the battery type you were using.
Use the 6 AA batteries.












Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 07:25 pm
No, I upload the sketches by USB.

I use BlueTooth to get and set data at the AtMega.

I will use the 6AA pack and test how much time it is turn on.

Can you tell me how many amps must be the AA battery ? Because they are in different amps versions.

Also, I have a 12v/4Ah. Do you think if I connect it before the 7805, the 7805 will regulate the voltage and amps to the ATMega328 and doesnt destroy it ?
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 09:03 pm
You said you're using an ATmega328. You didn't say UNO or any other arduino board. You also didn't mention if your chip has a bootloader. You're telling us you upload sketches with USB but the ATmega328 doesn't have any FTDI USB to TTL  serial capability. The only way you can load sketches is by using an FTDI adaptor (USB to TTL serial), so did you forget to mention that you have one of those and that's how you are uploading sketches ? You also didn't mention what frequency you are using and how.


We're taking our time to help you . If you are just going to ignore our questions then maybe I should go work on another post.

I posted this:
Quote
1-Are you breadboarding an ATmega328 blind or do you know what you are doing ?
2-Do you know how you are going to communicate with the ATmega328 ?
3-Does the ATmega328 have a bootloader already ?
4-What are you using for a clock ?
5-Have you been able to communicate with the ATmega328 yet ?
6-Do you know what a schematic is ?
7-Can you draw a schematic of your circuit and post a photo of it?
8-WHAT EXACTLY have you actually done with this so far ? (have you powered it up? loaded a sketch ? etc etc ?
I don't see any answers.


Quote
I have a 12v/4Ah. Do you think if I connect it before the 7805, the 7805 will regulate the voltage and amps to the ATMega328 and doesnt destroy it ?
You could but it would the 7805 will run a little hot dissipating the extra heat.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 02, 2015, 09:52 pm
Hi raschemmel, sorry. Im new in this.

Yes I have got an Arduino UNO and upload the sketches by USB. But a few days ago I have burned the sketch on the ATmega328 and put it standalone on a protoboard to test it 24/7.

Today I will try the 12v/4Ah battery with the 7805 and something with it to dissipate the heat.

When I could buy the AA batteries I will try this option too.

I really appreciate your time and your help.

I only ask here when I cant get information from the web or to get some experience of the people that has more knowledge like you.

Best regards, GInza

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 02, 2015, 10:38 pm
You don't have to do that . If you get one of these  (https://www.dipmicro.com/store/CPU-ARD328P)  all you need is this  (http://www.trossenrobotics.com/p/FTDI-Basic-Breakout-5V.aspx?feed=Froogle&gclid=Cj0KEQjwvJqvBRCL77m2-uKczsIBEiQAkx8VjJXgJOk9MEeS5c26VvHoPmTRrEGPybb-e3ljqznn4o4aAu6k8P8HAQ)
 to load the sketches and you can breadboard atmega328s. You do need the 16 Mhz crystal, 2 18 pF caps and a few other minor components.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 03, 2015, 03:22 pm
Hi raschemmel, yes I have seen that the sketch can be uploaded with a FTDI module. But in my country is very complicated found and buy arduino parts and PIC elements. And when you found a shop the prices are very high because there is not competition of sellers here.

Im fighting now to get a 28 pins DIP zocket  :(


Please tell me, about de 6AA bateries option to power the protoboard, which mAh they must be ?


Best regards, Ginza

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 03, 2015, 03:58 pm
do the math
Make a list of everything that will be powered by the batteries and how much current each one draws
Ask yourself how long do you want this system to run on a fresh set of batteries.
mAh = Totol current draw/# or hours of operation

Example:
Let desired hours of operation = 6
Let total current draw = 333mA

required mAh rating of batteries = ? mAh

required mAh = [Total current draw] * [# or hours of operation]
       
                     = 0.333A * 6 hours
                     = 2000 mAh


list the data and choices
Title: Re: Servo movement resets ATMEGA328
Post by: pegwatcher on Sep 04, 2015, 04:02 am
For rechargeable power, If it were me, I would first try a single Li-Po cell. Voltage runs between 3.7 and is 4.2 volts when fully charged. It will run the 328 just fine and puts out huge current for it's volume and weight to run the servo.  One advantage is you don't need a voltage regulator. Maybe that voltage will be too low for your servo load, Depends upon the force the servo needs to exert but if you can get or borrow one it would be worth a try.

I run 328 off of single Li-Po cells all the time. So far they always work at 16 MHz ok. If you use that cell, YOU MUST CHARGE WITH A PROPER LI-PO CHARGER, otherwise you could have an explosion or nasty fire.

HobbyKing is one good mail order source for Li-Po. This might be a more expensive solution than you need, so then you need to use 5 or 6 AA cells with regulator, or just 3 cells without a regulator; maybe NiMh so you can recharge them. Again, a special charger is needed.
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 04, 2015, 04:06 am
I would opt for a 2S lipo at 8.4V fully charged and use the 5V regulator.
Title: Re: Servo movement resets ATMEGA328
Post by: pegwatcher on Sep 04, 2015, 04:18 am
Quote
I would opt for a 2S lipo at 8.4V fully charged and use the 5V regulator.
Yes, definitely if you are using analogRead or any other thing that needs precise voltage. OP never said what all he is doing with his rig.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 04, 2015, 03:57 pm
Hi everybody, thanks a lot for all your replies. Im happy because Im learning a lot with you  :)

Look, I will tell you what a I have thinked yesterday night. I have a medium protoboard and two mini-protoboards. I will burn the sketch in three ATMega328 and prepare the three protoboards to work them standalone.

About the things that must be powered, each circuit have the ATMega328 and the necessary components that it must have to work (10k resistor, two 22pf capacitor, crystal oscillator, etc) and also I need a HC-05 Bluettoth and a RTC Module DS1302 (board that already has 3.3v round battery).

About the time that it must work, well I want that it works the greater amount of time that it can. So when I know how long it can work without a recharge or battery replace, after that I will can take other descision. Now if it can work standalone more than one day is ok.

I want ask you about this, I didnt found 6AA battery box, but I have found a cheap 4AA battery box, perhaps you can help me about the mAh of the AA batteries that I must get, so I will can buy 3 4AA battery box and buy 12AA batteries to start my testing on protoboards to improve the code of the sketch.

The RTC module works with 2.0-5.5V full operation and the Bluettoth module works 3.6-6V. Besides there is the ATMega328.

Now for testing on protoboards, I will put a led or a buzzer replacing the servo. So then, when I get the basic elements working I will add the servo and think about how to power supply it.

I have thinked that this month (September) I must have the circuit tested and finished and the code tested. And the code must be without errors or bugs working 24/7.

Like always, best regards to everybody.

 

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 04, 2015, 04:19 pm
You need to be more organized and follow instructions.
You are posting on the forum for help .
The basic concept here is that you're the NOOB and we're the experts.
You ask us what to do , we tell you and you do it or explain why you cannot.
You were asked to list all the devices 1,2,3 etc and how research how much current each draws and enter that value next to the item :
ie:
1-ATmeg328 : 50mA
2-RTC module : 30 mA
etc etc.

at the bottom there should be a total current draw .
You were also asked to list your battery mAh options
ie:
option-1: 1500 mAh
option-2: 2000 mAh
etc.

You stated you want it to run as long as possible, which  means your battery choice is simplified to the one with the highest rating.

We recommended 6 AA batteries. You state you can only find 4 AA battery box.
Come on, really ? You mean you can't figure out how to use two 4-battery boxes to obtain a 6 battery pack ?  THINK . You short the last two battery compartments with a jumper wire soldered on and you wire the two boxes in series.  If we tell you should use a 6 battery box and you can only find a 4 battery box, if you can't figure out how to make that work you are supposed to come back and ask us
"Is there a way to use two 4-battery boxes to make a 6 battery pack ?"

You state you are going to buy three 4-battery boxes  and 12 batteries. How were you planning on wiring those up ? Each box is designed for a 6V pack.  Are you implying you are now considering running your circuit on 6V  (x3) ? Are you going to be using a 5V regulator ?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 04, 2015, 04:38 pm
Hi raschemmel, I will do the testing joining 2 battery boxes to get 6AA batteries like you said and then I will upload the testing comments.

I will continue using the 7805 IC by now.

Thanks.
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 04, 2015, 06:07 pm
Are you going to use rechargable AAs or alkaline ?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 08, 2015, 03:59 pm
Rechargable batteries, because the price is very similar and then I will think about recharge the batteries with the same ATMega circuit.

Im testing the circuit with a power supply adaptor (12v 1A), yesterday the 7805 generates some heat, so I will put a sink to it.

Now Im developing the Android App to manage the ATMega by Bluetooth.

So while Im testing the sketch and the circuit Im developing the Android App to gain time. I must finish the App now in September to test the Skecth, Circuit and Android App all in October 24/7.

Best regards, GInza.

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 08, 2015, 04:08 pm
This  (http://www.radioshack.com/to-220-to-202-aluminum-heat-sink/2761368.html) is the kind of heatsink you need for a 7805 running on 12V input. Notice the difference between that heatsink and this  (https://www.sparkfun.com/products/121?gclid=Cj0KEQjwjrqvBRD6wf2fy-C61PIBEiQAUzKQTtTRqzWztbQBpjS5oxVbF-TguX6JlG5KZa0xizxNYG0aAgkH8P8HAQ) one.  The surface area is greater and the metal thickness of the mounting surface is thicker.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 09, 2015, 06:05 pm
Hi raschemmel, thanks for your suggestion. Yesterday I have unsoldered one from an old PC power supply and put on the 7805.

Im without money now, but when I'll have the circuit finished and stable, I will get one like you recommend me.

Im testing now the best power supply option for my project. I have seen that with basic power the Bluetooth communication is poor and when is turned on an output from the phone, the ATMega can be reseted.

I think that I must use a basic power supply for the ATMega328, so the system processing is always ok and running and other to power the outputs.

What do you think about it ?



Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 09, 2015, 09:21 pm
Quote
I think that I must use a basic power supply for the ATMega328, so the system processing is always ok and running and other to power the outputs.

What do you think about it ?
 
I've been working in electronics for 30 years and the term "basic power supply" could mean anything so it doesn't tell me anything.  A voltage regulator like the LM7805 is always preferred for a uP  over any unregulated power source such as batteries. The ideal input voltage for an LM7805 is between 7V and 9V, (7.5 V to 8V is the best range but these are not standard regulator values) not 12V so it doesn't need to dissipate the extra voltage. Do you have any capacitors on your  5V bus?
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 14, 2015, 03:37 pm
Hi raschemmel, reading my last question to you, I think that you are doing double work, answering me and trying to understand my poor english :)


Yes, I have a capacitor of 100uF at the 7805 output.


Yesterday I have connected the 9V/250mah only for the ATMega328 and the RTC Module and 4AA batteries/1800mAh only for the bluetooth. Because I need that the system at the ATMega works always, but the bluetooth is only to set and get system settings.

I thought that by this way I can preserve more battery time to the ATMega328, the results were:

--> The ATMega could run 10 hours with the 9v battery
--> The Bluetooth device HC-05 could run one hour.

I had to put differents power supplies, because the BlueTooth device was killing the power for the ATMega when they share the same power supply.

Im thinking that I could use an AC/DC adaptor of 9V or 7V to feed the ATMega behind the 7805 and leave the option to put a 9V battery backup, so the system works with AC/DC and if it is neccesary to move the device or there is a problem with the energy, it can continue working with the 9V battery.

Same to the other power supply to feed the BlueTooth, an AC/DC adaptor and optional 4AA batteries if it fails.

Also Im thinking that I can put a sliding switch or a simple switch, to turn on and off the BlueTooth so it will be turned on only when it is neccesary to configure the system.

I will try to upload 2 pictures of yesterday.

Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 14, 2015, 08:51 pm
You realize that if your software is written correctly, you can control a relay that switches between the ac/dc adaptor and the battery. With more than one relay you can have multiple battery banks, monitor the voltage of the battery in use and switch to a different battery when it starts to get low. Theoretically the only limit to how many battery banks you can have is the number of digital I/O and the six analog inputs can be used as digital I/O as well. (you would have do a little research . I don't know how to do that.) You can get an 8-relay module (http://www.sainsmart.com/8-channel-dc-5v-relay-module-for-arduino-pic-arm-dsp-avr-msp430-ttl-logic.html) with 5V relays.
Title: Re: Servo movement resets ATMEGA328
Post by: CrossRoads on Sep 14, 2015, 09:07 pm
Quote
monitor the voltage of the battery in use and switch to a different battery when it starts to get low
That might get tricky as the voltage will get pulled down some under heavy loads (servos moving) and rise again under light load.  I suppose one could check it only when no servos were being commanded to move, or, check only when servos were moving, and if it didn't stay at a high enough level then call it end of life and switch.

The analog pins can be assigned as digital outputs easily:
byte pin14 = 14; // A0
:
byte pin19 = 19; // A5
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 14, 2015, 09:59 pm
Hi CrossRoads, yesterday I didnt connected the servo.

I think I must use different power supplies, so with one power supply only for the atmega I will can continue running the sketch.

Yesterday night I have connected the 9v battery/250mAh only for the ATmega and the RTC and today morning the 9v battery down to 5v, so the 7805 wont continue working and the sketch stop working.

Im continue searching the best option to feed the circuit...
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 14, 2015, 11:12 pm
Quote
You realize that if your software is written correctly 
I didn't say it would be simple. Crossroad's observations/suggestions are good advice. Any software designed to monitor battery voltage should include some kind of "IF" statement code to exclude any measurements "while" any power consuming devices are running (motors, servos , etc.) This can be accomplished using boolean flags :

 if ((motor_A ==false) && (servo_A == false))
    {
      bat1 = analogRead(A0);
      }
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 15, 2015, 03:18 pm
Hi raschemmel, I will take note about this that you comment me. Yes I was thinking about measure the battery status and send the data by bluetooth to the phone.

But, look at this, I was testing with the 9v/250mAh battery (powering ATmega328 and RTC module only), the battery has a 7805 to regulate the 5v, with this schema my sketch can run until the battery will be in 6v or 7v.

When the battery is discharged to 5v or 6v the 7805 cant continue working because it needs minimum 7v to work, but the power that is in the battery (5v/6v) is perfect to continue running the skecth.

I think that I need in my final circuit connect directly to a AC/DC power supply with the option that I can get a secondary power supply with rechargable batteries. So when I can power the circuit with AC/DC I dont use the batteries and when the AC/DC power is not available I use the rechargable option. Also I should recharge the batteries with the circuit when it is connected to AC/DC.

Also I think that I need 2 power supplies, one fot the ATMega328 and RTC and other for BlueTooth module, servo, etc.

What do you think about this ?

Yesterday I was trying to upload 2 pictures of the project, but appears a message that dont let me upload pictures. I downgrade the quality of pictures, put them into a zip file, but was impossible upload the pictures, I dont know why.

Best regards.
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 15, 2015, 04:31 pm
Quote
Yesterday I was trying to upload 2 pictures of the project, but appears a message that dont let me upload pictures. I downgrade the quality of pictures, put them into a zip file, but was impossible upload the pictures, I dont know why.
The error is caused by the photo file exceeds maximum file size. Open the photo file with Windows Paint. In the upper left corner of Paint is a button called "Resize" Click this button and type in "40" where you see the "100" and hit ENTER. Click on the floppy disk symbol at the top left of Paint to SAVE the resized photo. The file should now be 40% of the original size. It is not necessary to use Winzip and it actually doesn't help anyway with picture files. The resized file should now be small enough to upload without errors.
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 15, 2015, 06:30 pm
I have tried to upload the picture one more time, the forum message says 'security check...'  I work with Debian Linux, perhaps this may be the problem, I dont know, dont worry.

Now im developing the Andriod app to communicate by bluetooth with the circuit.

Please, tell me what do you think about the power supply in my last post.

CrossRoads, if you can read my last post, please comment it. Thanks.
 
Title: Re: Servo movement resets ATMEGA328
Post by: CrossRoads on Sep 15, 2015, 06:43 pm
Yes, two power supplies, one for 5V and one tor the servo & other power hungry stuff would be good.
Could even use 3xAA battery for 5V directly and skip the 7805.
Title: Re: Servo movement resets ATMEGA328
Post by: dwightthinker on Sep 15, 2015, 10:50 pm
By 'show what you got', do you mean to show the current draw?
For a fast  pulse use a sense resistor and an oscilloscope( analog ).
Dwight
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 15, 2015, 11:06 pm
I think you replied to the wrong post. There is nothing in this thread about pulses.
Title: Re: Servo movement resets ATMEGA328
Post by: dwightthinker on Sep 16, 2015, 01:23 am
It was an earlier post. I believe he wanted to measure the current
of the servo in action. That is usually faster than a DMM response time.
Sorry, I'm so far out of sequence.
Dwight
Title: Re: Servo movement resets ATMEGA328
Post by: raschemmel on Sep 16, 2015, 02:28 am
Your response time is nothing short of horrendous.. :D
Title: Re: Servo movement resets ATMEGA328
Post by: Ginza on Sep 16, 2015, 03:09 pm
Hi everybody, yes CrossRoads, I was thinking about remove the 7805 of the ATMega328 and connect directly to a few AA batteries.

Also use a rechargable power supply for servo, but it must be behind a 7805, and feed both rechargables ways (ATMega circuit and servo circuit) with an AC/DC adaptor.

So I think that is posible feed all with and without rechargables batteries. Because without rechargables batteries it can be powered by the AC/DC adaptor.

If you have any suggestion from your experience about to make a rechargable circuit, please let me know.

Now, while Im improving circuit details with you Im developing the Android App to manage the sketch with the phone. I was using BluTerm to communicate with the AtMega on the breadboard and everything work properly, but I need a more specific software solution.

Thanks a lot to help me in the project.

Best regards.