-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Python API v1.6.8 ready for final testing
- Loading branch information
1 parent
8d16676
commit 2353263
Showing
5 changed files
with
218 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
################################################## | ||
## Combined Absolute Move | ||
################################################## | ||
## Author: Francois Giguere | ||
## Version: 1.6.8 | ||
## Email: info@vention.cc | ||
## Status: ready to test | ||
################################################## | ||
|
||
from _MachineMotion_1_6_8 import * | ||
|
||
# Define a callback to process controller gCode responses if desired. This is mostly used for debugging purposes. | ||
def debug(data): | ||
pass | ||
|
||
print ("Application Message: MachineMotion Program Starting \n") | ||
|
||
mm = MachineMotion(debug, DEFAULT_IP_ADDRESS.usb_windows) | ||
print ("Application Message: MachineMotion Controller Connected \n") | ||
|
||
# Configure the axis number 1, 8 uSteps and 150 mm / turn for a timing belt | ||
mm.configAxis(1, MICRO_STEPS.ustep_8, MECH_GAIN.timing_belt_150mm_turn) | ||
print ("Application Message: MachineMotion Axis 1 Configured \n") | ||
|
||
# Configuring the travel speed to 10000 mm / min | ||
mm.emitSpeed(10000) | ||
print ("Application Message: Speed configured \n") | ||
|
||
# Configuring the travel speed to 1000 mm / second^2 | ||
mm.emitAcceleration(1000) | ||
print ("Application Message: Acceleration configured \n") | ||
|
||
# Homing axis 1 | ||
mm.emitHome(1) | ||
print ("Application Message: Axis 1 is at home \n") | ||
|
||
# Move the axis 1 to position 100 mm | ||
mm.emitCombinedAbsoluteMove([1, 2, 3], [100, 200, 100]) | ||
print ("Application Message: Motion on-going ... \n") | ||
|
||
mm.waitForMotionCompletion() | ||
print ("Application Message: Motion completed \n") | ||
|
||
print ("Application Message: Program terminating ... \n") | ||
time.sleep(1) | ||
sys.exit(0) | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
################################################## | ||
## Combined Relative Move | ||
################################################## | ||
## Author: Francois Giguere | ||
## Version: 1.6.8 | ||
## Email: info@vention.cc | ||
## Status: ready to test | ||
################################################## | ||
|
||
from _MachineMotion_1_6_8 import * | ||
|
||
# Define a callback to process controller gCode responses if desired. This is mostly used for debugging purposes. | ||
def debug(data): | ||
pass | ||
|
||
print ("Application Message: MachineMotion Program Starting \n") | ||
|
||
mm = MachineMotion(debug, DEFAULT_IP_ADDRESS.usb_windows) | ||
print ("Application Message: MachineMotion Controller Connected \n") | ||
|
||
# Configure the axis number 1, 8 uSteps and 150 mm / turn for a timing belt | ||
mm.configAxis(1, MICRO_STEPS.ustep_8, MECH_GAIN.timing_belt_150mm_turn) | ||
print ("Application Message: MachineMotion Axis 1 Configured \n") | ||
|
||
# Configuring the travel speed to 10000 mm / min | ||
mm.emitSpeed(10000) | ||
print ("Application Message: Speed configured \n") | ||
|
||
# Configuring the travel speed to 1000 mm / second^2 | ||
mm.emitAcceleration(1000) | ||
print ("Application Message: Acceleration configured \n") | ||
|
||
# Homing axis 1 | ||
mm.emitHome(1) | ||
print ("Application Message: Axis 1 at home \n") | ||
|
||
# Move the axis one to position 100 mm | ||
mm.emitCombinedRelativeMove([1,2,3], ["positive","positive","positive"], [100, 200, 300]) | ||
print ("Application Message: Multi-axis move on-going ... \n") | ||
|
||
mm.waitForMotionCompletion() | ||
print ("Application Message: Motion completed \n") | ||
|
||
print ("Application Message: Program terminating ... \n") | ||
time.sleep(1) | ||
sys.exit(0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters