Can very high step rates destroy Arduino digital I/O pins?
August 18, 2017 04:31AM
It occurred to me a couple of times that I destroyed most/all of the digital I/O pins of the Arduino Mega board after running for a few seconds the Extruder motor at very high speed.
Is it something we can expect/explain, or were them just coincidences?

Step rate was around 50,000 step/second (STEPS_PER_UNIT=1000 steps/mm, Feedrate=50 mm/sec).
Just after the incident I notices Ramps LED1 blinking fast, if this can help in troubleshooting.
Arduino processor still works, serial communication and Temperature control are OK, but all 4 motor controls do not work anymore.
Replacing the Arduino board solves the issue, i.e. Ramps and motor drivers are still working perfectly.

Configuration:
Arduino Mega (Taurino and RobotDyn) + Ramps 1.4
DRV8825 Stepper Motor Driver
Nema 17 17HS4401 or 42BYGHW811
Marlin firmware:
#define DEFAULT_AXIS_STEPS_PER_UNIT {80.25,80.25,4000,1000} steps/mm
#define DEFAULT_MAX_FEEDRATE {300, 300, 2, 60} mm/sec
Re: Can very high step rates destroy Arduino digital I/O pins?
August 18, 2017 10:37AM
You probably destroyed the stepper drivers, not Arduino pins. I have blown the tops off motor driver chips by PWM'ing them at too high frequencies. If you have a Ramps board, replace the stepper drivers and I'll bet your unit will come back to life.

DLC
Re: Can very high step rates destroy Arduino digital I/O pins?
August 18, 2017 11:08AM
Unfortunately not. As I wrote above, "Replacing the Arduino board solves the issue, i.e. Ramps and stepper drivers are still working perfectly"

Edited 1 time(s). Last edit at 08/18/2017 11:08AM by paolo1968.
Re: Can very high step rates destroy Arduino digital I/O pins?
August 18, 2017 01:37PM
My Teensy 3.2 has no problem running 60,000 steps per second. Changing to a 32bit processor will allow you to run faster.
Re: Can very high step rates destroy Arduino digital I/O pins?
August 18, 2017 06:04PM
Quote
paolo1968
Unfortunately not. As I wrote above, "Replacing the Arduino board solves the issue, i.e. Ramps and stepper drivers are still working perfectly"

I have clocked AVRmega pins in the MHZ range, so something else has gone awry, clocking the I/O pins at any rate will not damage anything on the chip.
Something else occurred that caused the failure, your step mistake is a coincidence, IMO.

DLC
Re: Can very high step rates destroy Arduino digital I/O pins?
August 20, 2017 08:34AM
Problem finally solved!
No damage to the hardware, just EEPROM parameters messed up.

Problem was that somehow (a bug in Marlin or an HW issue?) most of the EEPROM parameters (including the axis_steps_per_unit) got completely overwritten, most of them with 0 values.
After that the printer was not able to make any moves on XYZ and E, making me to believe that digital I/Os were damaged.

M502 + M500 ("Revert to the default "factory settings" + "Store parameters in EEPROM") solved the problem.
BTW, reloading the firmware was not enough, as EEPROM parameters are persistent.
Re: Can very high step rates destroy Arduino digital I/O pins?
August 21, 2017 03:10PM
That are the most important Codes - M502 + M500.

If anything goes wrong theese are the first I do. - But beware! You have to have your correct settings hard coded, to be able to print afterwards without reconfiguring everything!
Sorry, only registered users may post in this forum.

Click here to login