Changing Dynamixel to RC Servos (electronics)

The goal of this part of the project [short presentation] is to use cheaper motors but not loose the accuracy the dynamixel ones, provide. Since we are using an arduino to control everything about the motor (driving, controller, feedback, diagnostics) we thought it would be very convenient, apart from updating the gains of the PID, also to be able to upload new sketches (code) to arduino.

Starting from the sensor, we are using the Austria Microsystems magnetic encoder, AS5145 [link] with 12-bit resolution, which means 0.088 degrees of accuracy. The reading of the sensor is through SSI (similar to SPI but with 3 pins). The serial word contains the position data plus some flags about the validity of the reading. The other option is to read the position through a pwm output (of the sensor) but that way we donā€™t have any flags and thatā€™s why we discarded this option.

With being able to read the position, we created input/output data in order to estimate the parameters of the motor. These parameters were used for the design of the PID controller.

About the driver of the motor, we recently changed to the VNH5180A-E [link]. With power supply up to 41V and output current of 8A we believe is suitable for the most RC-servos in the market. It also have the advantage of overvotage clamp, thermal shutdown, PWM up to 20Khzā€¦ well I am just reading the datasheet hereā€¦ :). Big advantage, the current sensor. The only drawback is itā€™s size (kind of big for the little space we have) but we are working on that.

The communication between the motors it will be through I2C. Therefore in total we will have two cables (or pins) for the supply, two for the I2C, and four for the ISP (Vcc and gnd already on board). The access to this pins and the position on the case of the motor is still on discussion.

We will share it with an implemented PID, tuned for a configuration without a load. The user will have the option to just update the gains, or implement itā€™s own controller (by uploading his code). In the future, if we find some time, we would like to also create a simple application to update the gains and also visualize the input and the output, to make the process of tuning a bit more easy.

Right now we are testing the driver, then will finish the design of the prototype of the pcb and after a test of the whole system, we will share everything. Till then we will share very soon the parts that we are confident of, to get any feedback or ideas for improvements and of course to compare it with ongoing projects.

Dimitris.

2 Likes

Ok time for some update! :slight_smile: We have ā€œsomeā€ delay because we wanted to make a prototype, before order the pcb from a manufacturer, in order to test everything. Well, we still didnā€™t solve this problem but at least we are able now to test the bridge and everything seems to work smoothly. I attached the images of the two boards (main and the sensor):

The main board:

Where the yellow shows where the sensor board will be.

And the sensor board:

Where the yellow circle represents the magnet.

These are the designs for the prototype (a guy in the uni that has a machine to make pcbā€™s) and it is required to have minimum vias of 0.8mm diameter (!!). It also doesnā€™t have any thermal pads, but the final design will be much moreā€¦ elegant :slight_smile: .

Now, as we said, the user will be able to flash the arduino inside each motor, so it will have full access to the controller. The connection (for now) it will be with cables going out of the motor. These cables are going out of the sensor board (and so, between the main board and the sensor board). There are a lot of them (6 for isp, 2 for I2C, 2 for the power supply) but the versatility of being able to reprogram the controller we believe is a huge plus!

Even though the driver, based on our tests so far, seems reliable it has the disadvantage that is quite big for the size of the main board. In order to save some space, we will be sending to the motor two power supplies (battery voltage and 5V). So no voltage regulator. The main advantages of the driver are that has overheat protection and integrated current sensor (more space saved). We also used a mosfet for reverse battery connection protection. I think the electronics parts are quite protected from burning.

And a little bit out of topic. As far as the rest of the project (poppyā€¦ walking), we started right now some simulations of simplified models of ā€œwalkersā€ so ā€¦ soon we will open another topic related to it.

2 Likes

Thatā€™s sound really good, You will use ATMEGA328p?

Yes. I tried to flash it with an arduino board but couldnā€™t manage it so I used the cheap USBasp programmer and everything was fine!

And one picture with the board mounted (not soldered in this one)

As we said, there are a lot of cables, but only because we have the ISP (grey ones) for re-programming the controller.

2 Likes

really cool!
Your grey cables are soldered on your pcb? You will keep it like this or itā€™s removable ?

Unfortunately there is no space to solder some pins on the board to make the cables removable. Itā€™s the very first assembled board so not the final version. I am looking for moreā€¦ ā€˜properā€™ cables.