![]() I also tried the 2 nd mode in which PWM is given in both the ENABLE pins and the dedicated PWM pins are in DIGITAL pins for directions control, the direction control works fine but still PWM the problem persists.Ģ PWMs for Clock and Anti Clockwise rotationsĮNABLE pins are given PWM and the PWM pins are in DIGITAL for DIRECTION control.ĪDMUX |= 1 << REFS0 // Ref.Voltage same as VccĬhannel &= 0x07 //Select ADC Channel between 0-7 This doesn’t make any sense because all the Arduino libraries are based on AVR so why would a normal AVR code not work. I also checked my code in a different motor driver by Cytron technologies 30 A model, my AVR code works perfectly fine. The project I am working on requires PWM manipulation using PID algorithms so I need the full range of PWM. The mode is 8 bit fast PWM, also tried in 16 bit PWM channel but the problem persists. The Problem is in normal Arduino code it works fine but in AVR code PWM below 130, the motor doesn’t rotate and also in 130 PWM the motor rotates like it is rotating at 30 PWM (meaning False PWM), but when I give 255 PWM it works fine. I have a DC motor driver BTS7960 Motor driver 24V 43A specs.
0 Comments
Leave a Reply. |