mirror of
https://git.mirrors.martin98.com/https://github.com/petaflot/pygcode
synced 2025-07-19 18:34:27 +08:00
forgot a few things..
This commit is contained in:
parent
ada8ebfa13
commit
f094d24993
@ -8,13 +8,16 @@ for python.
|
|||||||
|
|
||||||
# Installation
|
# Installation
|
||||||
|
|
||||||
|
Somthing in the order of
|
||||||
```
|
```
|
||||||
git clone git@github.com:petaflot/pygcode.git
|
git clone git@github.com:petaflot/pygcode.git --depth=1
|
||||||
cd pygcode
|
cd pygcode
|
||||||
pip install -e .
|
pip install -e .
|
||||||
```
|
```
|
||||||
|
|
||||||
Make sure you set `_DEFAULT_` to the dialect you want to use in `src/pygcode/dialects/__init__.py`
|
## Configuration
|
||||||
|
|
||||||
|
Make sure you set `_DEFAULT_` to the dialect you want to use in `src/pygcode/dialects/__init__.py` ; this is absolutely suboptimal, contributions are welcome. Also, note that `marlin2` flavor covers all versions of Marlin ; due to some functional redundances, some commands have been commented out (typically for bed leveling and delta bots, see `src/pygcode/gcodes_marlin.py`).
|
||||||
|
|
||||||
|
|
||||||
# Documentation
|
# Documentation
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
> # """G29: Probe the bed and enable leveling compensation."""
|
> # """G29: Probe the bed and enable leveling compensation."""
|
||||||
> # param_letters = "ACOQEDJV"
|
> # param_letters = "ACOQEDJV"
|
||||||
> # word_key = Word('G', 29)
|
> # word_key = Word('G', 29)
|
||||||
96,109c96,109
|
96,114c96,114
|
||||||
< class GCodeBedLevelingLinearg2(GCodeMachineRoutines):
|
< class GCodeBedLevelingLinearg2(GCodeMachineRoutines):
|
||||||
< """G29: Probe the bed and enable leveling compensation."""
|
< """G29: Probe the bed and enable leveling compensation."""
|
||||||
< param_letters = "ACOQXYPSEDTHFBLRJV"
|
< param_letters = "ACOQXYPSEDTHFBLRJV"
|
||||||
@ -23,6 +23,11 @@
|
|||||||
< """G29: Probe the bed and enable leveling compensation"""
|
< """G29: Probe the bed and enable leveling compensation"""
|
||||||
< param_letters = ""
|
< param_letters = ""
|
||||||
< word_key = Word('G', 29)
|
< word_key = Word('G', 29)
|
||||||
|
<
|
||||||
|
< class GCodeBedLevelingUnifiedm3(GCodeMachineRoutines):
|
||||||
|
< """G29: Probe the bed and enable leveling compensation."""
|
||||||
|
< param_letters = "ABCDEFHIJKLPQRSTUVWXY"
|
||||||
|
< word_key = Word('G', 29)
|
||||||
---
|
---
|
||||||
> #class GCodeBedLevelingLinearg2(GCodeMachineRoutines):
|
> #class GCodeBedLevelingLinearg2(GCodeMachineRoutines):
|
||||||
> # """G29: Probe the bed and enable leveling compensation."""
|
> # """G29: Probe the bed and enable leveling compensation."""
|
||||||
@ -38,6 +43,11 @@
|
|||||||
> # """G29: Probe the bed and enable leveling compensation"""
|
> # """G29: Probe the bed and enable leveling compensation"""
|
||||||
> # param_letters = ""
|
> # param_letters = ""
|
||||||
> # word_key = Word('G', 29)
|
> # word_key = Word('G', 29)
|
||||||
|
>
|
||||||
|
> #class GCodeBedLevelingUnifiedm3(GCodeMachineRoutines):
|
||||||
|
> # """G29: Probe the bed and enable leveling compensation."""
|
||||||
|
> # param_letters = "ABCDEFHIJKLPQRSTUVWXY"
|
||||||
|
> # word_key = Word('G', 29)
|
||||||
136,139c136,139
|
136,139c136,139
|
||||||
< class GCodeMechanicalGantryCalibrationb(GCodeMachineRoutines):
|
< class GCodeMechanicalGantryCalibrationb(GCodeMachineRoutines):
|
||||||
< """G34: Modern replacement for Průša's TMC_Z_CALIBRATION"""
|
< """G34: Modern replacement for Průša's TMC_Z_CALIBRATION"""
|
||||||
@ -48,7 +58,16 @@
|
|||||||
> # """G34: Modern replacement for Průša's TMC_Z_CALIBRATION"""
|
> # """G34: Modern replacement for Průša's TMC_Z_CALIBRATION"""
|
||||||
> # param_letters = "SZ"
|
> # param_letters = "SZ"
|
||||||
> # word_key = Word('G', 34)
|
> # word_key = Word('G', 34)
|
||||||
1045,1048c1045,1048
|
362,367c362
|
||||||
|
< param_letters = "PWETSI"
|
||||||
|
< word_key = Word('M', 43)
|
||||||
|
<
|
||||||
|
< class GCodeTogglePinsb(GCodeIO):
|
||||||
|
< """M43T: Toggle pins states"""
|
||||||
|
< param_letters = "SLIRW"
|
||||||
|
---
|
||||||
|
> param_letters = "PWETSIRL"
|
||||||
|
1045,1048c1040,1043
|
||||||
< class GCodeDeltaConfiguration(GCodeMachineConfig):
|
< class GCodeDeltaConfiguration(GCodeMachineConfig):
|
||||||
< """M665: Set delta geometry values"""
|
< """M665: Set delta geometry values"""
|
||||||
< param_letters = "HLRSXYZABC"
|
< param_letters = "HLRSXYZABC"
|
||||||
@ -58,7 +77,7 @@
|
|||||||
> # """M665: Set delta geometry values"""
|
> # """M665: Set delta geometry values"""
|
||||||
> # param_letters = "HLRSXYZABC"
|
> # param_letters = "HLRSXYZABC"
|
||||||
> # word_key = Word('M', 665)
|
> # word_key = Word('M', 665)
|
||||||
1060,1063c1060,1063
|
1060,1063c1055,1058
|
||||||
< class GCodeSetDeltaEndstopAdjustmentsa(GCodeMachineConfig):
|
< class GCodeSetDeltaEndstopAdjustmentsa(GCodeMachineConfig):
|
||||||
< """M666: Set Delta endstop adjustments"""
|
< """M666: Set Delta endstop adjustments"""
|
||||||
< param_letters = "XYZ"
|
< param_letters = "XYZ"
|
||||||
|
@ -108,10 +108,10 @@ class GCodeBedLevelingBilinearm2(GCodeMachineRoutines):
|
|||||||
# param_letters = ""
|
# param_letters = ""
|
||||||
# word_key = Word('G', 29)
|
# word_key = Word('G', 29)
|
||||||
|
|
||||||
class GCodeBedLevelingUnifiedm3(GCodeMachineRoutines):
|
#class GCodeBedLevelingUnifiedm3(GCodeMachineRoutines):
|
||||||
"""G29: Probe the bed and enable leveling compensation."""
|
# """G29: Probe the bed and enable leveling compensation."""
|
||||||
param_letters = "ABCDEFHIJKLPQRSTUVWXY"
|
# param_letters = "ABCDEFHIJKLPQRSTUVWXY"
|
||||||
word_key = Word('G', 29)
|
# word_key = Word('G', 29)
|
||||||
|
|
||||||
class GCodeSingleZProbe(GCodeMachineRoutines):
|
class GCodeSingleZProbe(GCodeMachineRoutines):
|
||||||
"""G30: Probe bed at current XY location"""
|
"""G30: Probe bed at current XY location"""
|
||||||
@ -359,12 +359,7 @@ class GCodeSetPinState(GCodeIO):
|
|||||||
|
|
||||||
class GCodeDebugPins(GCodeIO):
|
class GCodeDebugPins(GCodeIO):
|
||||||
"""M43: Get information about pins ; set/get pins states"""
|
"""M43: Get information about pins ; set/get pins states"""
|
||||||
param_letters = "PWETSI"
|
param_letters = "PWETSIRL"
|
||||||
word_key = Word('M', 43)
|
|
||||||
|
|
||||||
class GCodeTogglePinsb(GCodeIO):
|
|
||||||
"""M43T: Toggle pins states"""
|
|
||||||
param_letters = "SLIRW"
|
|
||||||
word_key = Word('M', 43)
|
word_key = Word('M', 43)
|
||||||
|
|
||||||
class GCodeProbeRepeatabilityTest(GCodeMachineRoutines):
|
class GCodeProbeRepeatabilityTest(GCodeMachineRoutines):
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# vim: number ts=4
|
# vim: number ts=4
|
||||||
"""
|
"""
|
||||||
generate src/pygcode/gcode_marlin.py based on official documentation
|
generate src/pygcode/gcode_marlin.py based on MarlinDocumentation
|
||||||
|
|
||||||
|
NOTE: because of a few silly names that are not very explicit and cause collisions,
|
||||||
|
using fork found here: https://github.com/petaflot/MarlinDocumentation
|
||||||
"""
|
"""
|
||||||
from string import ascii_letters
|
from string import ascii_letters
|
||||||
|
|
||||||
class_types = {
|
class_types = {
|
||||||
# unused: GCodeDistanceMode
|
|
||||||
# unused: GCodePathControlMode
|
|
||||||
# unused: GCodeProgramControl
|
|
||||||
'g000': 'GCodeMotion', # LinearMove
|
'g000': 'GCodeMotion', # LinearMove
|
||||||
'g002': 'GCodeArcMove', # GCodeMotion > ArcOrCircleMove
|
'g002': 'GCodeArcMove', # GCodeMotion > ArcOrCircleMove
|
||||||
'g004': 'GCode', # Dwell
|
'g004': 'GCode', # Dwell
|
||||||
|
Loading…
x
Reference in New Issue
Block a user