Germany
Asked — Edited

Ezb Restarts And Servo Movements

This Video Show my problems

I have problems with my hexapod. The robot makes uncontrolled movements every time the ezb is restarted. (as soon as I control a motor)

Or as soon as the engines need power. With both, it always ends with the ezb restarting. Now I don't know exactly where the problem lies. I suspect servos or voltage. I'm currently using a power bank (9v 3a), but I've also tried a power supply (also 9v 3a) with the same result.

But the same problem also occurs with another robot of mine, where I use a different ezb and different servos.

Am I doing something fundamental wrong? or is the ezb just suitable for small robots with small motors?

I Used this servos:

https://www.amazon.de/dp/B07T756ZYC/ref=cm_sw_r_apan_glt_i_S26QNBSS312FF2Y1XE00?_encoding=UTF8&psc=1

all servos work individually. (Apart from the fact that they move uncontrollably for a short time when they are controlled for the first time)


Related Hardware EZ-B v4

ARC Pro

Upgrade to ARC Pro

Take control of your robot's destiny by subscribing to Synthiam ARC Pro, and watch it evolve into a versatile and responsive machine.

#1   — Edited

My hex bot is using mostly the older Original Ez robot HD servos and it can be a power hog but I find that if I use a bigger Lipo 7.4 battery (5000 ma) and not let servos go to maximum speed, just walking around .It will explore a fairly long amount of time, with 1 sonar,camera or RGB lit eyes. It always curls up when it starts but no big deal there.

PRO
Germany
#2   — Edited

First, thanks for the quick response. But you can see in my video at 0:45 that I have already set my servos to very slow. But if the servos start to move uncontrollably then ignore the settings. The same at the first start. As soon as the servos get power, they move at maximum speed for the first moment, no matter what I have set.

And I guess because all the servos are "jumping" at the same time, it takes too much power at once and the ECB shuts down... but what can I do about it (if that's the problem)?

#3  

Okay I saw the video, that is a much bigger Hex bot compared to my EZ robot Hex, There is someone else in the Forum that built a large one like that . IF You research this forum and look for a thread about Gargantua , I believe it was called, you may get some good fix ideas.

PRO
Synthiam
#4   — Edited

Hi there - that's an easy one. The EZB is rebooting because it isn't getting enough amperage for all the servos to move simultaneously. There's a good read with more detail here: https://synthiam.com/Support/Get-Started/how-to-make-a-robot/power

Check out the recommended options for power supply. There's also a real good (albeit more extended read) tutorial on that page about how power works with the robot.

The "slowness" of the servos moving isn't going to prevent the current spike from causing the EZ-B to brownout. As you can see by how quickly the servos "jump" to their position, it is because that has to happen before the servos can begin moving.

I know there's a lot of reading, but here's how servos work: https://synthiam.com/Support/Advanced-Fundamentals/servo-motor

Your Script I had to pause the video to see your script, but the reason only the first servo runs is that the port increment syntax is incorrect.

User-inserted image

It can read one of these two ways to do it...


$port++

or


$port = $port + 1

PRO
Synthiam
#6  

Oh, one more thing... When the EZ-B is first connected, it will not know the servos' positions. That means if the servos are resting at a position 120, and you specify to move to position 90, they will JUMP to 90 no matter what speed is set. This is because these types of servos are not "Smart" and therefore do not report their position on power-up.

That's okay because there is a workaround. The most simplest workaround is to initialize each servo into a position when the EZB starts up. You can do this by creating a script, calling it INIT, and running it when the EZ-B starts. It can do something like this.

I use JavaScript

In this example, servos ports are not linear, or the init positions are different per servo/joint. Also, tweak the sleep() time to give each servo enough time to move into position. It may require one full second (1000 ms) per servo.


// Initialize every servo into their startup position

Servo.setPosition(d0, 90);
sleep(500)
Servo.setPosition(d1, 10);
sleep(500)
Servo.setPosition(d3, 90);
sleep(500)
Servo.setPosition(d4, 110);
sleep(500)
Servo.setPosition(d6, 90);
sleep(500)
Servo.setPosition(d7, 50);
sleep(500)
Servo.setPosition(d9, 75);
sleep(500)
Servo.setPosition(d10, 90);

In this example, the servos are all the same degrees, and ports are linear


// Initialize every servo into their startup position

for (var port = 0; port < 10; port++) {

  Servo.setPosition(port, 90);
  
  sleep(500);
}

#7  

Wow great info DJ! I will do this too for all my bots!

#9  

Bookmarked that page for reference!

PRO
Belgium
#10  

hi all

looks like the servo's are not calibrated and the init script is not in the start up connection window.  seems the servo's is trying to go further then possible . is there a servo profile ?

User-inserted image

PRO
Germany
#11  

Quote:

There's a good read with more detail here: https://synthiam.com/Support/Get-Started/how-to-make-a-robot/power
I read that, didn't solve the problem but explained some things well. For example, I didn't realize that a servo could have a switch-on voltage of 3A.

Quote:

Your Script I had to pause the video to see your script, but the reason only the first servo runs is that the port increment syntax is incorrect.
actually it worked with the other arms as well. But always only when I have manually controlled the servos once, or when I have executed the script a second time. You can also see that the variable that is output in line 11 counts up. And I use the same variable for the servo... But of course I'll change the syntax if that's not the usual way of writing it.

User-inserted image

Quote:

The most simplest workaround is to initialize each servo into a position when the EZB starts up. You can do this by creating a script, calling it INIT, and running it when the EZ-B starts. It can do something like this.
That's what I actually wanted to do with the script first. But I had the same problem: Only servos that I had already moved manually moved. But I will test it again and report back here.

But I'm not getting my hopes up any more, I think I completely underestimated the power consumption.

But where can I get Lipos or batteries or power supplies with more like 3A at 9V? I can't find anything there.

I'm currently using this: https://www.amazon.de/gp/product/B089SQFCBW/ref=ppx_yo_dt_b_asin_title_o03_s00?ie=UTF8&th=1

But as I said, I've already tested it with a power supply.

Quote:

is there a servo profile ?
no, there is no servo profile, unfortunately I have not yet fully understood what it is used for. I thought it was just for fine tuning?

I am happy to accept links for information on the subject ;-)

But the main question is probably where can I get a (mobile) power source with more than 3A

Thank you for all replies. I'm actually a bit disappointed, because of course it wasn't cheap and now the project seems to fail due to too few amps...

PRO
Belgium
#12  

what servo's are you using and what voltage does they recomend ?

PRO
Synthiam
#13   — Edited

The servos you are using are rated best for 6.8v, so you'd want a 7.4v lipo.

The thing about amperage with batteries is different than a power supply. Here is why - a power supply has a limit of current it can produce (i.e., 3amps). However, a battery has an additional rating called a C rating. That rating is the capacity of energy the battery can safely discharge, represented as a multiple of its overall capacity. A battery with a higher C rating delivers more energy, which means higher performance.

Batteries are rated in milliamp per hour. So they can provide X amount of milliamps in an hour. If your battery was 5,000 mAh and you were drawing 1,000mAh continuously, your battery would theoretically last 5 hours. Also, if your robot were drawing 5,000 mAh, then your battery would last 1 hour.

However, the C rating means that your battery can discharge more current than the mAh rating. You see, the battery has a 5,000 mAh capacity, but if you were to draw 10,000 mAh, then the battery would last 30 minutes. So a 5,000 mAh battery does not mean that is the maximum output - it means that is the current per hour.

So a higher C rating means that a 7.4v 5200 mAh lipo battery can deliver 10 continuous amps for 30 minutes. However, the servos will light on fire if they draw 10 amps of current. The current when the servos are not moving is minimal.

Here's a good lipo battery for your application: https://www.amazon.ca/RoaringTop-5200mAh-Battery-Connector-Truggy/dp/B08G1H8HMB

PRO
Synthiam
#14   — Edited

BTW, that hexapod is going to be super cool. I made a large one that I named Super Six.

I used the servo mapping and Auto Position GAITs from the Six project here: https://synthiam.com/Community/Apps/Six-Bare-10964

Not sure if that Auto Position GAIT will be helpful to your robot configuration or not. You'd have to make sure the servos are connected in the same orientation, but other than that, maybe it'll be helpful.

PRO
Belgium
#15  

hi dj / knusel

here (s the link for calibrating your servo's . after that you can use servo profile . calibrate the servo's whit no bracket attached  so the horn can move to 90 , then ad the bracket and do fine tunning . you can find all info on ez robots.com .

lessons robot 

PRO
Synthiam
#16  

Nomad, knusel won't have a reason to calibrate the servos if he's programming the gait from scratch. However, if he does use the project I referenced in my previous post, he may need to tweak the servo positions with a calibration. Or he can modify the Auto Position gait frames.

PRO
Belgium
#17  

hi dj

i always though it was a perfect to beginning a project .  thanks for the update .

PRO
Germany
#18  

Quote:

Batteries are rated in milliamp per hour. So they can provide X amount of milliamps in an hour. If your battery was 5,000 mAh and you were drawing 1,000mAh continuously, your battery would theoretically last 5 hours. Also, if your robot were drawing 5,000 mAh, then your battery would last 1 hour.
Ok I think I got that part. And I can operate the EZB with 7.4 volts? I always assumed 9V.

Quote:

BTW, that hexapod is going to be super cool. I made a large one that I named Super Six.
Many Thanks. I also designed a torso with space for leds, camera and ultrasonic sensors. They're already lying around here. But before I invest any more time and money in 3D printing, I want to see if I can get the robot to run at all

User-inserted image

Quote:

Not sure if that Auto Position GAIT will be helpful to your robot configuration or not. You'd have to make sure the servos are connected in the same orientation, but other than that, maybe it'll be helpful.

I'll definitely have a look at it. THX

#19   — Edited

Yes that will be an awesome bot there!  Also great vid on DJ's super 6! These types of hex bot always scare the smiles out of visitors, I find!xD

PRO
Synthiam
#20  

The ezrobot ezb v4 will run on as low as 4v from my tests. I’ve actually seen it run off 3.5v about, but that’s just crazy:)

your 3d render is wild. The lipo battery link I gave you will work wonderful.

once you get the battery trouble out of the way, it’ll be smooth sailing and the robot will be running in no time.

PRO
Canada
#21   — Edited

Hello @Knusel,

Quote:

Ok I think I got that part. And I can operate the EZB with 7.4 volts? I always assumed 9V.
I'm curious where you found the 9V information, all the EZ-Robot kits run on 7.4V LiPo batteries and I personally recommend high amperage 7.5V or 5V power supplies for wall power.

Quote:

Also, tweak the sleep() time to give each servo enough time to move into position. It may require one full second (1000 ms) per servo.
In order to really address this whole scenario, I need to get a bit deeper into all this and build off of what @DJ already shared.

There are two things at play here. One is the nature of wall power supplies. Two is the nature of RC servo motors.

Wall Power supplies

Aka power bricks, wall adapters, or wall warts. These power supplies can deliver a constant current of what they are rated for (example 7.5V 3A). They cannot deliver more current than they are rated for. When more current is demanded by the load (for example motors on a robot) the voltage dips to compensate. If the voltage gets too low, the connected robot controller will reset, due to brownout protection.

This is the reason most Robots use batteries. Batteries can deliver the needed current demands from the load. For example, a 5000mAh 25C Lipo battery can supply 125A momentarily if needed (ignoring wire impedance and other physical limitations). The ability to deliver this kind of current burst allows the battery to keep the robot controller from resetting.

Servo Motors

Aka Hobby servos or RC Servos. These servos have 3 conditions that hugely affect the power supply. The conditions are:

Inrush current - Aka starting current. This is the current needed to move the servo from rest to moving. Operating current - Aka running or steady-state current. This is the current consumed by the servo when moving. Current Spikes - Aka current surge. This happens when you switch the directions of a servo without stopping.

Inrush current is stated to be 4 to 6 times the operating current. With EZ-Robot HDD servos I found it to be around 3 times the operating current. EZ-Robot HDD servos have an operating current of ~250mA (+/- 50mA). Let's do some example calculations:

So the inrush current of an EZ-Robot HDD servo is approximately 3 x 250mA = 750mA, 4 servos starting at the exact same time is an inrush of 3000mA (3A).

This demonstrates that if you start moving 4 x HDD servos at the same time a 3A wall power supply can handle it, but once you add a fifth, the power supply voltage will dip and you'll get an EZ-B reset.

If you stager the starting (inrush current) of the servos a 3A supply can operate up to 12 HDD servos simultaneously (250mA x 12 = 3A).

DJ mentioned using a delay of 500mS or 1S between moving servos, but I've found with my testing that you can even go as low as a 1mS delay between the servos as the inrush current doesn't last that long (under 1mS).

Ok, here's the last and likely most important part of this. If you don't allow a servo to reach its intended position before switching directions you will create a huge current spike. I found that I could get an EZ-B to reset with only 2 HDD servos (using a 3A supply) when moving them quickly back and forth.

This type of current spike is over 6 times the operating current and will quickly cause an EZ-B reset (when powered by a 3A supply), not to mention severely diminishing the life of the motor brushes inside your servo. Try not to move your servos in the opposite direction until they have come to rest, this will greatly promote the longevity of your servos, not to mention all brushed DC motors in general.

I hope this helps and increases everyone's knowledge here.

Maybe I should make my own tutorial about this:D I did all the tests yesterday to make sure everything I was saying was accurate.

#22  

Awesome facts there Jer, great job!:D

PRO
Germany
#23   — Edited

some good news and some bad news.

The lipos arrived yesterday, (long live amazon) I did the first tests, wrote an init script... it's not perfect yet, but it works now, the EZB doesn't restart and the motors have a lot of power! (see video) VIDEO

That was the good news. The bad ones are that the EZB looks like he is burned out. It just switched itself off, at first I thought the batteries were empty... but it doesn't work with the other power sources either. He also smells a bit burnt. Anyone an idea why this happened? I didn't do anything other than what is shown in the video...

I used this lipos:Link

(the lipos that dj recommended are not available on German Amazon)

and connected them in parallel with this cable, which shouldn't be the problem if I understood it correctly: Link

Quote:

I'm curious where you found the 9V information, 
I'm probably just assumed because the dev. The kit included a cable to connect a 9V block battery. Like I said, electronics isn't my specialty... That's why I have no idea why the EZB is broken now.

I still have two EZB's here in my Johnny 5 robot, but of course I don't want to blow them all up now...

PRO
Synthiam
#24  

The EZ-Robot EZ-B v4 probably has a blown fuse. It is in the base.

You can see the EZ-Robot EZ-B v4 datasheet specifications here: https://www.ez-robot.com/learn-robotics-ezb-smart-robot-controller-and-iotiny-datasheet.html

Even if you connected the two batteries in series, accidentally, it should still be fine because they're only 7.4v each.

There's also an option that one of the traces burned on the EZ-Robot EZ-B v4 if the servo were drawing too much current. I'd check the fuse first, that's the easiest.

However, if you connected the power backward, that will be easily recognizable by examining the inside of the EZ-Robot EZ-B v4.

PRO
Germany
#25  

i swapped the fuse with one of the fuses from my other ezb, unfortunately without success. (but good to know there is one)

I unscrewed the top... and that's where the burnt smell comes from. Nothing can be seen visually, but I guess I have to put up with it.

The question is, what can I do to make sure this doesn't happen to me again?

Am I on the safe side if I use the lipos individually?

PRO
Synthiam
#26   — Edited

It’s always safer to use lipo individually. The ezrobot ezb v4 was designed with lipos. And lipos are just batteries anyway, so it doesn’t matter what kind of battery.

You’d have to figure out what went wrong, so it doesn’t happen again.

I have seen low-cost/quality servos break the wires inside the servo and short. Or, the power could have been applied in reverse accidentally.

You can always try reaching out to ezrobot support and see if they can help you. It’s rare that a circuit would break entirely without any partial function. That might mean the power supply is damaged if that’s the case. You could try applying 3.3v to the ADC ports and see if it comes to life.

Do you have power in the power pins when connected to a battery? Or is there continuity between the power supply and power pins?

Otherwise, there are other ezb options, such as Arduino, and it’s more cost-effective. The esp32 could be used with an SSC-32 servo controller.

The only trouble is piecing parts together can end up as costly as an ezrobot ezb.

#27   — Edited

Wonderful information from all here. Thanks for the guidance and tips. I'd like to add a few practical and personal thoughts;

I've struggled in the past with the same issues you have @Knusel. Power brown outs, burnouts, quirky script writing.  I've also burnt up my share of components and devices. It sucks but happens. Sometimes I didn't even know what I did. It only takes a quick touch of the wrong wire (a short) to do a lot of damage or to try to draw to many amps (current) through a device. It's been my way of learning I guess but I learned quickly.

What did I learn?

*Disconnect all power before working.  *Double check my connections and wiring before I start up. And then check again. LOL.  *If I smell burnt, it's broke.  *Voltage and amps (current) are two different things. *You can feed variable amounts of voltage to a dc motor but servos are sensitive to voltage needs. Don't over volt either one.  *Keep DC voltage within all the specs of all devices and servos in the circuit. I include a servo as a device in my understanding. A servo is actually a DC motor that has a control board inside of it. *Devices "draw current (amps) from the power supply (or battery). The power supply does not feed the current. A device or motor will continue to draw amps until it gets what it wants or until the power supply burns up or dies.  *Add up all the peek amps (current) needed by all the devices and motors connected to your power supply. Then get a power supply (or battery) that can deliver at least 25% or more of the current of what is needed at peak draw. *I stopped running power for my motors and servos through the EZB. These things are current hungry as mentioned by others in this thread. When they move or simply run they can quickly rob the EZB of the power it needs to run and cause it to reset. I run all my power around the EZB (unless it's a small device that does not draw too much current). I keep my EZB on it's own independent circuit to the power supply (If you are not using the base then that circuit needs to be fused).    *The WIFI connection needs to be strong and on a channel little used by other's.

I hope this helps a little. Good luck and don't quit.

PRO
Belgium
#28  

hi all

i think its best to use all ez robot parts original . can you post a picture of the bad print controller?

PRO
Canada
#29   — Edited

I would have a look to see if the reverse polarity protection diode got toasted on the EZ-Bv4 mainboard. It's a small SMD diode near where the voltage comes into the board at the Micro deans connector. I find that if you are really running the EZ-Bv4 hard with tons of current in a DIY scenario this will be the first component to go. If the diode is toast it will have a visible small hole in it. It will usually fail "open circuit". You can either replace the diode or short the diode connections if you aren't worried about reverse voltage hook up. It's an SB540 and can be replaced very easily if you know your way around electronics. If you don't then a local hackerspace or makerspace might have a hot air rework station or soldering iron and the expertise to help you out.

If it was the SWPS chip, those are very hard to come by these days. You could try injecting 3.3V on the ADC power pins as @DJ mentioned, a clever solution since only ~200mA is needed to run the EZ-Bv4 and camera.