Home › Evil Mad Scientist Forums › AxiDraw › Walk Home ?
- This topic has 8 replies, 2 voices, and was last updated 2 years ago by CliffStoll.
-
AuthorPosts
-
January 4, 2023 at 4:29 pm #30562CliffStollParticipant
Simple script, does not work. Stepper motors chomp.
Axidraw SE/A3, firmware 3.7.0Start with Axidraw at home.
I run this python script:
from pyaxidraw import axidraw # Import the Axidraw module
#…
x_step_length_mm = 124
y_step_length_mm = 44ad = axidraw.AxiDraw()
ad.plot_setup()
ad.options.mode = “manual”ad.options.manual_cmd = “walk_mmy”
ad.options.walk_dist = y_step_length_mm
ad.plot_run() # moves properlyad.options.manual_cmd = “walk_mmx”
ad.options.walk_dist = x_step_length_mm
ad.plot_run() # moves properlyad.options.manual_cmd = “walk_home”
ad.plot_run() # Stepper motor goes nuts.
quit()January 4, 2023 at 4:57 pm #30563Windell OskayKeymasterHmm.
Testing with the current release version ( AxiDraw Command Line Interface 3.7.2; AxiDraw Software 3.7.1), I’m not currently able to reproduce the issue with this script. I downgraded to 3.7.0, and I’m still not able to reproduce it.
Check to make sure that you have EBB firmware 2.6.2 or newer; the current version is 2.8.1.
One subtle thing about the walk_home command is that it tries to move the carriage to the position where the motors were enabled (or, last time the resolution was set), by querying the total sum of motor steps since then. This isn’t necessarily the same as where the “software” origin is located; a temporary origin is created each time that you call ad.plot_setup, for example.
If there has been a position-loss event — grinding motor noises etc. — then you may want to try resetting the AxiDraw (unplug power and USB) or disabling then re-enabling the motors to be sure that it’s position is reset. Otherwise, it may not know the correct direction and distance from its current position to that power-on position.
January 4, 2023 at 5:35 pm #30564CliffStollParticipantHow do I check the EBB firmware?
Inkscape options are:
This is AxiDraw Control version 3.7.0.
Your AxiDraw Control software is up to date.Your AxiDraw has firmware version 2.8.1.
Your firmware is up to date; no updates are available.Additional system information:
3.10.4 (main, Apr 10 2022, 21:38:20) [Clang 13.0.0 (clang-1300.0.29.30)]
Voltage readout: 7 (~ 0.51 V).
Current setpoint: 542 (~ 0.99 A).January 4, 2023 at 5:54 pm #30565CliffStollParticipantFound the problem — you’re right.
I had reset the system by just removing 9V power from the Axidraw. But I left the machine connected to the USB cable. *sigh*
So:
1) Before running the program, I pull the 9 volt power supply
2) Remove the USB connection.
3) Plug in both of these connectors.
4) Now run the program. It works!January 4, 2023 at 6:05 pm #30566Windell OskayKeymasterLooks like your firmware is up to date; that all looks just fine.
Instead of physically unplugging, I do expect that either rebooting the EBB or disengaging the motors first would work just as well. (There’s no CLI command to reboot the EBB, but I can write you a very short python script to do so if that’s helpful.)
January 4, 2023 at 6:07 pm #30567CliffStollParticipantRelated question:
In /manual/ mode, is there any way to speed up the motion?
ad.options.mode = “manual”
ad.options.speed_penup = 110 # nope, not for manual mode`
ad.options.speed_penpendown = 110 # nope, not for manual mode`THANX!
January 4, 2023 at 6:30 pm #30568Windell OskayKeymasterAt first glance, I agree that something looks wrong there; probably a bug. I’ll look into it and report back.
January 4, 2023 at 7:04 pm #30569Windell OskayKeymasterThis too is subtle: you have
ad.options.speed_penpendown
there, notad.options.speed_pendown
— which does work.After fixing *that*, this seems to be more responsive.
A separate question is why does it assume that the pen is down? And, that may be a bug proper. (The pen state is somewhat undefined until it is asserted, and that’s part of the problem.)
Add this above your move commands to ensure that the pen state is well defined:
ad.options.manual_cmd = "raise_pen" ad.plot_run()
- This reply was modified 2 years ago by Windell Oskay.
- This reply was modified 2 years ago by Windell Oskay.
January 4, 2023 at 8:50 pm #30572CliffStollParticipantYep, you caught me again! How’d I make that goof?
Thanks from your all-too-error-prone axidraw addict!
- This reply was modified 2 years ago by CliffStoll.
-
AuthorPosts
- The topic ‘Walk Home ?’ is closed to new replies.