Skip to content

Instantly share code, notes, and snippets.

View logxen's full-sized avatar

Logxen logxen

View GitHub Profile
switch.fan1.enable true # this tells Smoothie to create a new switch named "fan1"
switch.fan1.startup_state false # this sets the initial state of the switch
switch.fan1.input_pin 2.11 # watch for changes on this pin
switch.fan1.input_pin_behavior toggle # valid options are "toggle" and "momentary"
switch.fan1.input_on_command M106 # any command that starts with this exact string turns this switch on
switch.fan1.input_off_command M107 # any command starting with this exact string turns off the switch
switch.fan1.output_pin 2.12! # this pin will follow the state of the switch
#switch.fan1.output_on_command M106 # this command is sent whenever the switch turns on
#switch.fan1.output_off_command M107 # this command is sent whenever the switch turns off
@logxen
logxen / gist:8792351
Last active August 29, 2015 13:56
Smoothiepanel - Proposed simple comms
Command Description
# system functions
0x00 nop
0x01 read vid
0x02 read pid
0x03 read revision
0x04 read version
# lcd
@logxen
logxen / gist:9335769
Created March 3, 2014 22:13
tool change
// Compute extrusion speed based on parameters and gcode distance of travel
void ToolsManager::on_gcode_execute(void* argument){
Gcode* gcode = static_cast<Gcode*>(argument);
if( gcode->has_letter('T') ){
int new_tool = gcode->get_value('T');
bool make_move = false;
if ( gcode->has_letter('F') ){
make_move = true;
}
logxen@Eneiou-Mint ~/git/Smoothie $ make
make[1]: Entering directory `/home/logxen/git/Smoothie/mbed'
Building src
make[2]: Entering directory `/home/logxen/git/Smoothie/mbed/src'
Building mbed-lpc1768.mk
make[3]: Entering directory `/home/logxen/git/Smoothie/mbed/src'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/logxen/git/Smoothie/mbed/src'
Building mbed-lpc11u24.mk
make[3]: Entering directory `/home/logxen/git/Smoothie/mbed/src'
@logxen
logxen / gist:6a4f00bfd2a2268692d3
Created May 4, 2014 23:15
How to wire an 8-lead stepper
I. Find coils
-with the stepper unplugged, spin the motor by hand
-touch two leads together and see if it is harder to spin
-if it is harder to spin you found a coil
-keep testing the rest and find all 4 coils
II. Find pairs
-name coils 1 through 4 and make a note of their colors for later reference
-plug in coils 1 and 2 then plug in and run the motor to see if it spins
-change coil 2 for 3 then plug in and run the motor see if it spins
switch.freeze.enable true
switch.freeze.input_on_command M112
switch.freeze.output_on_command reset
@logxen
logxen / gist:ad195ccd31914bab8869
Last active May 10, 2018 04:22
Edison Quickstart Guide for Octoprint and Smoothie
# *** Documentation Links
Documentation list: https://communities.intel.com/community/makers/edison/documentation/content
Edison Guide: https://communities.intel.com/docs/DOC-23158
Mini Breakout Guide: https://communities.intel.com/docs/DOC-23252
Mini Breakout Schematic: https://communities.intel.com/docs/DOC-23323
Mini Breakout BoM: https://communities.intel.com/docs/DOC-23322
Arduino Breakout Guide: https://communities.intel.com/docs/DOC-23161
Arduino Breakout Schematic: https://communities.intel.com/docs/DOC-23309
Arduino Breakout BoM: https://communities.intel.com/docs/DOC-23308
BSP Guide (yocto build environment): https://communities.intel.com/docs/DOC-23159
@logxen
logxen / gist:10d8433bce103c28200d
Created December 21, 2014 06:14
thermocouple config block sample
# Hotend temperature control configuration
temperature_control.hotend.enable true # Whether to activate this ( "hotend" ) module at all.
# All configuration is ignored if false.
temperature_control.hotend.sensor max31855
temperature_control.hotend.spi_channel 0
temperature_control.hotend.chip_select_pin 0.16
temperature_control.hotend.set_m_code 104 #
temperature_control.hotend.set_and_wait_m_code 109 #
temperature_control.hotend.designator T #
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at processing.app.Editor$15.actionPerformed(Editor.java:696)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.AbstractButton.doClick(Unknown Source)
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.menuDragMouseReleased(Unknown Source)
at javax.swing.JMenuItem.fireMenuDragMouseReleased(Unknown Source)
@logxen
logxen / ft232h.cfg
Created June 22, 2017 18:11
Smoothie 2 Debug Toolchain for FT232H
interface ftdi
ftdi_vid_pid 0x0403 0x6014
ftdi_layout_init 0x0c08 0x0f1b
ftdi_layout_signal nTRST -data 0x0100 -noe 0x0400
ftdi_layout_signal nSRST -data 0x0200 -noe 0x0800
adapter_khz 1000
transport select jtag