[PD] pduino test patch: "old analog/digital controls"

olsen sesselastronaut at googlemail.com
Thu Nov 3 11:57:40 CET 2011


yo bonitos

due to the pduino rewrite I've to reanimate this threat ;)
I would like to remove the ambiguity and confusion about this old and new way of enabling the analog pins.

old way of enabling the analog 0 pin is sending the following to the arduino object:
[analogIns 0 1(

enabling the same pin(analog 0) the new school way:
[pinMode 14 analog(

is this correct? if so what's a bit byte confusing for people is that in the new way pin 14 equals the analog 0 pin - 
guess this is a peculiarity of firmata? isn't there a possability to use f.e. A0-A5 for adressing the analog pins?

thanks for info & salutis
ø





On 06/17/2011 10:52 AM, olsen wrote:
>
>
> On 06/17/2011 12:24 AM, Matteo Sisti Sette wrote:
>> On 06/16/2011 05:44 PM, olsen wrote:
>>> it's all in the
>>> arduino-help.pd by Gerda Strobl and Georg Holzmann!
>>
>> Which one???
>>
>> Not the one that is distributed together with [arduino] and [arduino-test] at http://at.or.at/hans/pd/objects.html,
>> right?
> yo it's in Pduino-0.5beta8 linked on this page
>>
>>> in the last subpatch [pd SWITCHING-INPUTS] you'll find the apropriate
>>> messages.
>>
>> There I find the same analogIns messages that are supposed to be the old ones (but are the only ones I've found that
>> work for analog pins with the latest version of Firmata)
> jep i agree they're the same - i think it's a matter of wrong denotation so due to my knowledge there's nothing like old
> and newer messages -> the current 'contemporary' message for enabling the analog inputs is:
> [analogIns pinumber 1=on; 0=off(
> f.e. to enable analog pin 1:
> [analogIns 1 1(
> correct me if i'm wrong!
>>
>>
>> > i don't know why this is commented with (optional)
>>
>> I must have another version of the help patch, as I don't see such a comment
> right behind the [pd SWITCHING-INPUTS] is a comment "<- example of switching inputs on and off (optional)"
>>
>>
>> How are the messages you're talking about?
>>
>>
>>> i guess it's a firmata peculiarity that you've explicit have to enable
>>> the analog pins as in arduino they are enabled by default - but correct
>>> me if i'm wrong.
>>
>> Yes, I guess what you have to explicitly enable is to have the firmware _send_ the values to the computer. It would be
>> undesirable to have a constant flood of values of all pins whether you use them or not.
> jep right so with firmata the analogIns have to be enabled explicitly to use them. i think the (optional) comment
> somehow makes it ambiguous. as told i'll try to consider this in the improvements we're working on!
>
> salutis
> ø
>>
>>
>

-- 
ETs DNA will not be televised
http://hasa-labs.org




More information about the Pd-list mailing list