Cytron Motor Driver Issue - Encoder Improper Readings

I have attached problem statement. For quality purpose, we have switched into cytron motor driver, but when we connect the motor driver with processor getting improper reading from encoder. We are thinking that is because of EMC issue, but we don’t know exactly. We are not taking 5v from cytron to processor, 2 Analog, 2 digital, one common ground connected. From battery 24v power source connected to Cytron. We have connected 20 A fuse in between motor driver’s supplyline. So, maximum load will be 15 A, Motor supply ground and logic groundare connected common with Raspberry.

Problem:
For example, quadrature encoder 400 ppr we are using, so for one rotation we will get 400 pulse per second, but with cytron without starting motor like 0 pwm generated but output 576 pulses that also not same in every time some time 467 pulse, 278 pulse, 653 pulses.
when we use Hercules motor driver everything working properly, exactly 400 pulse output displayed. Exactly we don’t know what is the problem with cytron. How to solve this problem. Kindly help me solve this issue.
I have connected Raspberry Pi - Optocoupler - MDDS10 on this combination. For your further reference, I have attached Photo copy of circuit connection and circuit diagram.Test 1 :Raspberry Pi - Optocoupler - MDDS10 connected. For testing purpose, I have connected only one motor MDDS10 input pins (DIG 1,AN 1) left motor pins are connected, Separate power source. You can see the below diagram and connection. Cytron motor driver blinking red color error light.
Test 2 : Usually when we didn’t connect common ground from processor to cytron that will blink. For right motor I have tried. Processor ground and both Optocoupler (2nd) terminal common grounded, both Optocoupler emitter terminal (4th) and cytron ground terminal common grounded, Separate power source. Error light blinking.
Test 3 : Processor ground and both Optocoupler (2nd) terminal, Optocoupler emitter terminal (4th), Cytron ground common grounded, Separate power source. Error light blinking.
Test 4 : I have provided 5v to processor from cytron (without separating power source), ground terminal common. Error light blinking.
Test 5 : Only Analog pins connected, Error light blinking.
Test 6 : 4 Units of optocoupler I have connected, I thought may be because of this issue, but still same error light blinking.
I didn’t understand what is the problem ? Power source common, separated, common ground and separated (ground, power source). Still error light blinking. Anything missed ? we have to give any input ? How to solve this problem ? or else any other possibilities are there to solve this issue ? I have attached all testing images, whatever I have done.






hi did you try it with arduino and test it with real PWM?

Hi,

To troubleshoot the issue you are encountering, you might want to :

]First, verify that you have the correct DIP switches configuration on the SmartDriveDuo Driver. We suggest you to interface the SmartDriveDuo with an Arduino UNO (with the DIP switches configuration suggested from Cytron in Serial Packetized Mode here). You can use this Arduino sample code./:m]
]If everything works as expected, you can then connect the encoder outputs to the Arduino and add the Arduino code for the encoders to your previous code. You can find a lot of Arduino code examples for encoders online./:m]
]If you don’t encounter any issue with the previous setup, this will confirm that there is no problems with the hardware (SmartDriveDuo Driver + Encoders) and you can interface it with the Raspberry Pi. /:m]

Hi Brahim Daouas,

              Thanks a lot. As per your guidance I will try with above setup. That may help me to  troubleshoot the issue.