My batteries aren't enough?

I've made a 2wd robot, it has two DC motors with the driver, one servo and one ultrassonic sensor.

I'm using 6 NiHH 1,2V 2500 mAh cells, and they are connected to the arduino.

The problem:

When the robot is being fed by the computer, it works fine, but when it is on the battery, the DC motors just get crazy, and so does the servo, is my battery pack enough? Should i feed my DC motors separetely from the rest? How do i do that?

Thanks :smiley:

Need some diagrams to show how youโ€™re connecting everything. Which arduino board and did you purchase it very recently?

I have an arduino uno, i have it for almost one year, and i think i don't need the entire diagram, but i'm just wondering if that's the right solution

My concern is the. Arduino 5v regulator gives up when you require more current. Are you powering motors with 5v or the whole pack of batteries?

i think i don't need the entire diagram, but i'm just wondering if that's the right solution

Forum members need the entire diagram, to know whether it is the right solution.
A schematic diagram, even hand drawn, is much preferred over a Fritzing diagram.

Smug:
is my battery pack enough?
I'm using 6 NiHH 1,2V 2500 mAh cells, and they are connected to the arduino.

Probably not

6 x 1.2 = 7.2 the recommended minimum input is 7v, so clearly you are sailing a bit close to the wind, and, since motors are involved, the likelihood of the battery pack dropping below 7v is pretty good. Since the motors are controlled by an Arduino with a suss power supply, "going crazy" sounds a very likely result.

One more AA may suffice, but two would seal the deal.

Another faint option is to stick with the 7.2 battery but provide a more efficient 5v regulator, thereby enabling you to bypass the on-board regulators, which aren't that flash.,

Recent arduino official boards use ldo but very crappy one that gives up easily.