<p>Unless you know the structure of the Marlin firmware pretty well, are good at coding (in C/C++), and are familiar with programming microcontrollers, then I wouldn't attempt to do this, IMHO. Adding new features can cause a number of issues elsewhere in the code and need rigourous planning and testing as well as discussion with the Marlin community.</p>

<p>You <em>could</em> however make a request (i.e. raise an issue) to the <a href="https://github.com/MarlinFirmware/Marlin" rel="nofollow noreferrer">Marlin community on Github</a>, however, I would seriously suggest posting to the <a href="https://reprap.org/forum/list.php?415" rel="nofollow noreferrer">Marlin forum</a>, on RepRap, first, as random suggestions and issues raised on Github aren't really appreciated, without checking on the forum first...</p>

<p>If you really want to get into coding, then I would suggest buying an Arduino Uno and some components and messing about with those first, as well as visiting our excellent <a href="https://arduino.stackexchange.com">Arduino Q&amp;A site on StackExchange</a> as well as the <a href="https://forum.arduino.cc" rel="nofollow noreferrer">Arduino forums</a>.</p>

CC BY-SA 4.0
2019-05-09T08:05:55.047Z
2019-05-09T08:30:50.303Z
2019-05-09T08:30:50.303Z
Greenonline
<p>Don't go modifying Marlin to do this unless you're using a 32 bit µC.</p>

<p>You're better off controlling Marlin with <a href="https://community.octoprint.org" rel="nofollow noreferrer">OctoPrint</a> and writing/finding a module that allows you to kick off a print when a key is pressed on a connected keyboard or pendant.</p>

CC BY-SA 4.0
2019-05-09T13:37:48.287Z
2019-05-10T12:05:57.413Z
2019-05-10T12:05:57.413Z
user77232
<p>Can any one help me out that how to start a cycle by just using a push button.</p>

<p>Note: Using Marlin firmware, Arduino Mega, Ramps 1.4</p>

<p>I haven't tried altering the Marlin code (as I am new to coding), I was just thinking of adopting this feature as it will be very easy for CNC DIY maker using Marlin code to run a cycle in a loop.</p>

CC BY-SA 4.0
2019-05-09T07:46:42.117Z
Way more information required. What have you tired so far and what didn't work? Schematic, code? This is way to broad currently.
Greenonline
CC BY-SA 4.0
2019-05-09T08:08:10.723Z
HI and welcome to SE.3DP btw! :-)
Greenonline
CC BY-SA 4.0
2019-05-09T09:11:34.217Z
What is a "cycle"? I have no clue what you mean, please explain so we can help you out! Cheers, and welcome!
0scar
CC BY-SA 4.0
2019-05-09T09:30:23.327Z
Yes, @0scar raises a good point, what *cycle*, or rather a cycle of what? A print cycle, a batch cycle? I seems like you have a good idea in mind, but it's not all that clear or well explained. Please edit and update your answer. Thanks... :-)
Greenonline
CC BY-SA 4.0
2019-05-09T13:34:51.593Z
@Greenonline, actually in terms of CNC cycle start is very descriptive.
user77232
CC BY-SA 4.0
2019-05-09T13:48:29.740Z
@user77232 - OK, but for the non-CNC initiated crowd, I think a brief explanation *might* be useful.
Greenonline
CC BY-SA 4.0
2019-05-10T12:16:26.693Z
Possible duplicate https://3dprinting.stackexchange.com/questions/7713/how-to-make-physical-buttons-send-gcode
Perplexed Dipole
<marlin>
How to start cycle by using push button
varun waikar
# How to start cycle by using push button

(Asked by: username_0 on 2019-05-09)

Can any one help me out that how to start a cycle by just using a push button.

Note: Using Marlin firmware, Arduino Mega, Ramps 1.4

I haven't tried altering the Marlin code (as I am new to coding), I was just thinking of adopting this feature as it will be very easy for CNC DIY maker using Marlin code to run a cycle in a loop.

**Tags:** marlin
> **Comments:**
> **username_1**: Way more information required. What have you tired so far and what didn't work? Schematic, code? This is way to broad currently.  
> **username_1**: HI and welcome to SE.3DP btw! :-)  
> **username_2**: What is a "cycle"? I have no clue what you mean, please explain so we can help you out! Cheers, and welcome!  
> **username_1**: Yes, @0scar raises a good point, what *cycle*, or rather a cycle of what? A print cycle, a batch cycle? I seems like you have a good idea in mind, but it's not all that clear or well explained. Please edit and update your answer. Thanks... :-)  
> **username_3**: @Greenonline, actually in terms of CNC cycle start is very descriptive.  
> **username_1**: @user77232 - OK, but for the non-CNC initiated crowd, I think a brief explanation *might* be useful.  
> **username_4**: Possible duplicate https://3dprinting.stackexchange.com/questions/7713/how-to-make-physical-buttons-send-gcode  

---

## 2 answers

### Answer by username_1 on 2019-05-09. Score: 1

Unless you know the structure of the Marlin firmware pretty well, are good at coding (in C/C++), and are familiar with programming microcontrollers, then I wouldn't attempt to do this, IMHO. Adding new features can cause a number of issues elsewhere in the code and need rigourous planning and testing as well as discussion with the Marlin community.

You *could* however make a request (i.e. raise an issue) to the [Marlin community on Github](https://github.com/MarlinFirmware/Marlin), however, I would seriously suggest posting to the [Marlin forum](https://reprap.org/forum/list.php?415), on RepRap, first, as random suggestions and issues raised on Github aren't really appreciated, without checking on the forum first...

If you really want to get into coding, then I would suggest buying an Arduino Uno and some components and messing about with those first, as well as visiting our excellent [Arduino Q&A site on StackExchange](https://arduino.stackexchange.com) as well as the [Arduino forums](https://forum.arduino.cc).


---

### Answer by username_3 on 2019-05-09. Score: 1

Don't go modifying Marlin to do this unless you're using a 32 bit µC.

You're better off controlling Marlin with [OctoPrint](https://community.octoprint.org) and writing/finding a module that allows you to kick off a print when a key is pressed on a connected keyboard or pendant.


---

