Welcome! Log In Create A New Profile

Advanced

G-code

Posted by TheBikeRaider 
G-code
October 05, 2017 04:55AM
Hey people, I have been using the Prusa i3 for a while now, and I wanted to start to dig into its code, I have downloaded and installed the merlin code and when I opened it I haven't understood much of it, but my main question is, where is the section that refers to reading the x y and z positions that are being read by the processor from the sd card... I am basically starting a new project and I wanted to use the p89c51rd2 microcontroller and I need to translate all the Arduino C++ code into #C.... if anyone has some answers I would appreciate that.
Thank you very much.
Re: G-code
October 05, 2017 05:43AM
Do you mean Marlin?

get_available_commands() is the main get gcodes routine, either from serial or spooled from SD

get_sdcard_commands() fills the command buffer with commands

gcode_get_destination() decodes the position from the gcode command (ie Set XYZE destination and feedrate from the current GCode command)

Im somewhat worried though... this is the easy stuff from the firmware...

I would skim read threw Marlin_main.cpp, get an idea of how it works. Start at void setup() and void loop() the standard arduino main program.

Edited 2 time(s). Last edit at 10/05/2017 05:57AM by Dust.
Sorry, only registered users may post in this forum.

Click here to login