[PD] how to pd2stepper motor?

Hans-Christoph Steiner hans at eds.org
Thu Nov 2 05:25:58 CET 2006


On Oct 6, 2006, at 12:14 AM, Martin Peach wrote:

> Hans-Christoph Steiner wrote:
>>
>> Sounds like the [comport] probably didn't create properly.  If you  
>> have a recent auto-build or the most recent test release, then you  
>> can send a [info( message to [comport] and get a list of the  
>> available serial ports and their corresponding numbers.  Then you  
>> would do [comport 4] if /dev/ttyUSB0 is #4.
>>
> I changed [comport] a bit recently in CVS so that the [info 
> ( message outputs the current state of the comport, and a [devices 
> ( message gives the list of devices. This is because the operating  
> system can take a few seconds to get the device list, which only  
> needs to be loaded once, and interferes with real-time updates of  
> the input pin status.

Very nice. I just added open status to the [info( report too.

> As far as steppers go it would be nice to have arduino commands for  
> steppers. It looks like the existing pduino firmware code can only  
> change one pin at a time, it would be nice to have a parallel  
> digital pin command with a mask like set_digital_outs(int  
> output_pattern, int mask) so the set bits in mask would be changed,  
> at the same time, according to output_pattern and the zero bits  
> would be unaffected.

Couldn't the stepper commands be written as Pd objects or is the  
serial port too slow?  Do you know the maximum speed you can send the  
stepper control pulses?

Also, are there standardized patterns for steppers?

.hc

> Martin
>
>
>> .hc
>>
>> On Oct 1, 2006, at 7:45 PM, ad wrote:
>>
>>> hi, tonite i've been trying to control a stepper motor via pd's  
>>> firmata, formerly known as pduino.
>>>
>>> im using the arduino-test.pd patch included with in the  
>>> Pduino-0.1 release, me under linux (gentoo:)
>>>
>>> as soon as i choose the devicename port /dev/ttyUSB0 i get a full  
>>> pd window with:
>>>
>>> error: inlet: expected '' but got 'float'
>>> error: inlet: expected '' but got 'list'
>>> error: inlet: expected '' but got 'float'
>>> error: inlet: expected '' but got 'list'
>>>
>>> this doesn't happen when i open Gerda's and Georg Arduino-help.pd  
>>> and since it doesn't crash the process i can continue to check I/ 
>>> O's, passing data from a potentiometer to pd via analog inputs on  
>>> the arduino works like charm.
>>>
>>> but i got lost when trying to send control data to a step motor  
>>> connected in this way:  http://img.photobucket.com/albums/v20/ 
>>> igortme/Arduino/Ejemplos/ESQUEMA_MOTOR_PASO_A_PASO.jpg
>>>
>>> I wonder how should one send the messages to make the motor move  
>>> in one direction or the other any precise amount of steps? has  
>>> anyone done this (surely yes). could you tell me how will this  
>>> pd2stepper sintax goes?
>>>
>>> thanks,
>>> /alejo
>>>
>>>
>>> p.s: im sending also to the newly opened arduino mailing list :P
>>>
>>> _______________________________________________
>>> PD-list at iem.at mailing list
>>> UNSUBSCRIBE and account-management -> http://lists.puredata.info/ 
>>> listinfo/pd-list
>>
>>
>> --------------------------------------------------------------------- 
>> ---
>>
>> The arc of history bends towards justice.     - Dr. Martin Luther  
>> King, Jr.
>>
>>
>>
>> _______________________________________________
>> PD-list at iem.at mailing list
>> UNSUBSCRIBE and account-management -> http://lists.puredata.info/ 
>> listinfo/pd-list
>>


------------------------------------------------------------------------

I have the audacity to believe that peoples everywhere can have three  
meals a day for their bodies, education and culture for their minds,  
and dignity, equality and freedom for their spirits.      - Martin  
Luther King, Jr.






More information about the Pd-list mailing list