Welcome! Log In Create A New Profile

Advanced

Help Driving Stepper with Raw GCode

Posted by dlamet 
Help Driving Stepper with Raw GCode
November 02, 2022 02:48AM
I'm attempting to get my Z-motor to run using raw Gcode commands in Pronterface. I'm using RAMPS 1.4 & Marlin v1. I've disabled thermistors and verified that endstops are happy. I have a test script I've downloaded to my board that runs the motor, so I know there's no hardware problem.

With Smoothie I was able to enable motors with one command and move with another like this:

M17
G0 Z50 F1000


But no sign of life. I hear no power. Do things work differently in RAMPS-world? Anyone know what I'm missing?

Thanks in advance.

Dan
Re: Help Driving Stepper with Raw GCode
November 02, 2022 04:45AM
What firmware is on the mega.ramps?

Same g-code should work on Marlin
Re: Help Driving Stepper with Raw GCode
November 02, 2022 12:43PM
Wouldn't the firmware on the Mega be the Marlin v1? Or are you referring to something else?
Re: Help Driving Stepper with Raw GCode
November 03, 2022 10:44PM
Looking at the code, my RAMPS gets to planner.cpp at line 712 (or therebouts). Looks like this.

int moves_queued=(block_buffer_head-block_buffer_tail + BLOCK_BUFFER_SIZE) & (BLOCK_BUFFER_SIZE - 1);

I'm getting moves_queued=0, but I suspect it should be >0. Does anyone know this code? I can't figure out how block_buffer_tail gets set.

Any help is appreciated.
Re: Help Driving Stepper with Raw GCode
November 08, 2022 10:57AM
The answer is that I had not set the motherboard type in the Configuration.h. This was not part of any of the tutorials that I went through.

// 33 = RAMPS 1.3 / 1.4 (Power outputs: Extruder, Fan, Bed)

#ifndef MOTHERBOARD
#define MOTHERBOARD 33
#endif
Sorry, only registered users may post in this forum.

Click here to login