On 1/10/2014 12:33 PM, Charles Steinkuehler wrote:
On 1/10/2014 9:33 AM, Charles Steinkuehler wrote:
On 1/10/2014 7:42 AM, Thomas Studwell wrote:
I can easily modify the PRU assembly and create a version that does
falling-edge step pulses for all step/dir generators.  To use it, you
would simply point to the modified PRU binary in the HAL command that
loads the hal_pru_generic module.  The longest part will be actually
testing the code to make sure it works as expected.
OK, here's the quick and dirty version of the PRU code that just inverts
the step signal.  I've verified it moves motors on my 3D printer and the
default step state is high (the step pulse is a falling edge, followed
very briefly by a return to the default high state).

Just drop it in the linuxcnc/xenomai directory and adjust your ini/hal
file to load the new file (pru_generic_fall.bin).  The debugging files
are included just in case you feel _really_ adventurous!  :)

cc'd directly to the two interested parties in case the list strips the
attachment.  If it does, and someone else is interested in a copy of
this as well, just e-mail me directly.

WARNING:  This is for short-term use ONLY!  I expect to have updated
code that will support setting the step polarity via HAL within a week
or two, along with many other changes that will require significant
modification to any existing configurations (but will make pin numbering
a whole lot more consistent and understandable!).

Charles, sorry it took so long to get back to you on this, apparently others found 'better' uses of my time ;-)

The driver works as advertised! I've attached two scope traces, one taken with the original driver (Y_Step_Pos.png) and the second (Y_Step_Neg.png) taken with the new driver. The only oddity, which doesn't affect the motion but does affect power consumption, is that the signals are not initialized to high (AKA inactive state) on program startup. The signals do go high and remain there after the first step, however. The motors are energized at high level when the signal is left low.

Thank you for building this! I'll use this until your new, improved, version is available.

Tom

<<attachment: Y_Step_Neg.png>>

<<attachment: Y_Step_Pos.png>>

------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today.
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to