Yesterday I did a quick and dirty assembly of the right wheel with shaft, bearings, motor and motor bracket. The motor bracket is a 3D printed prototype before doing the acutal CNC milling manufacturing. The bracket today is printed with PETG from PrimaSelect. PETG is a great filament, very solid and hard, but yet flexible. BUT, for an motor bracket flexibilty is not very good, beacuse the brackets can move when forces are applied and this causes disturbance in some cases (noises).
When I get my brackets in aluminum, some noise will disappear and it will be a very silent drive (It is very silent now as well).
My setup includes two VECS´s that will control one motor each. Today the motors are equipped 120 degrees internal PCB hall sensors. To get an absolute rotor position for each motor I am thinking of adding encoders to each motor. The VECS have integrated support for the AS5047P from FW2.17.
To be able to get the encoders working, one need to remove the hall sensor filter on the VESC. Looking at the Schematic of the hall sensor the filter is located at R11-13.
R11-R13 must be removed. No jumper, just remove.
R8-R10 must be jumpered. You can do that with a “solder Jumper” or a 0 Ohm resistor.
You can then hookup the AS5047p with the following connection:
SCK -> HALL 1 MISO -> HALL 2 MOSI -> VCC CS -> HALL 3
My VECS´s looked a bit different because they are the flier-model. The flier-model is a modified Chinese producer that moved the mosfets layout so they are all on 1 side at an extra pcb. Making it a bit harder to locate the hall sensor filter. They also added a large heatsink over the them.
After some hours investigating the cables and the pcb I came up with the following solution for removing the filter in on my flier-model (not yet tested). I will do the modifications on the VECS´s this weekend when I have a bit more time.
So I actually bought a bunch of different encoders to try out. That will work with the VESC after reading around different forums.
The AS5047P is a high-resolution rotary position sensor for high speed (up to 28krpm) angle measurement over a full 360-degree range. This new position sensor is equipped with revolutionary integrated dynamic angle error compensation (DAEC™) with almost 0 latency and offers a robust design that suppresses the influence of any homogenous external stray magnetic field. A standard 4-wire SPI serial interface allows a host microcontroller to read 14-bit absolute angle position data from the AS5047P and to program non-volatile settings without a dedicated programmer. Incremental movements are indicated on a set of ABI signals with a maximum resolution of 4000 steps / 1000 pulses per revolution in decimal mode and 4096 steps / 1024 pulses per revolution in binary mode. The resolution of the ABI signal is programmable and can be reduced to 100 steps per revolution, or 25 pulses per revolution.
The AS5047D is a high-resolution rotary position sensor for fast absolute angle measurement over a full 360-degree range. This new position sensor is equipped with revolutionary integrated dynamic angle error compensation (DAEC™) with almost 0 latency and offers a robust design that suppresses the influence of any homogenous external stray magnetic field. A standard 4-wire SPI serial interface allows a host microcontroller to read 14-bit absolute angle position data from the AS5047D and to program non-volatile settings without a dedicated programmer. The resolution of the incremental ABI interface is programmable with a maximum resolution of 2000 steps / 500 pulses per revolution in decimal mode and 2048 steps / 512 pules per revolution in binary mode.
The AS5048A is a 14-bit rotary position sensor (previously known as encoder) for absolute angular measurement and with a PWM (=pulse width modulation) output over a full turn of 360° based on contactless magnetic sensor technology. This device fits perfectly for on-axis applications where a simple 2-pole magnet rotates above or below the sensor IC and the zero position can be programmed into the device simply with a SPI command. The absolute magnet angular position is measured with a resolution of 14 bit = 16384 positions per revolution and it is provided as a digital value on the serial interface (SPI).
In order to mount the encoders on the motors I designed a new mount for them that fits on the current drive system. I had no space left in the robot to mount them on the motor shaft, therefor I will mount them on the reverse side of the motor (I have 4x screw holes there that would be perfect for a 3D printed magnet holder). The 6×2.5mm diametric magnet must be placed over or under the sensor, and should be centered on the middle of the package with a tolerance of 0.5mm. The airgap between the magnet surface and the package should be maintained in the range 0.5mm to 3mm.
So we have some quite precise tolerance to work with, lets see if my Raise3D and my PETG filament settings can achieve that. Here is a visualization of the Encoder mount
So once I modified the VECS´s and received the different encoders lets give them all a try to see which one performs best in my use case.
Here is a small test drive with one wheel mounted on the robot. Running FOC mode and the temporary motor bracket (causing some noise).