[PD] autobuild wrong architecture

2013-10-04 Thread martin.peach
I get this on a dual P4 running debian squeeze:
$ sudo dpkg -i Pd-0.44.0-extended-20131003-debian-squeeze-i386.deb
dpkg: error processing Pd-0.44.0-extended-20131003-debian-squeeze-i386.deb 
(--install):
 package architecture (amd64) does not match system (i386)
Errors were encountered while processing:
 Pd-0.44.0-extended-20131003-debian-squeeze-i386.deb

Martin
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] More Sensor Questions inc libfreenect on the Rpi

2013-03-15 Thread martin.peach

Maybe check out these things:

http://www.digikey.ca/product-detail/en/D6T44L06/Z3637-ND/3671589

It gives you a 4X4 pixel temperature image, and unlike the PIR sensor, it can 
detect motionless warm objects.

Martin

Date: Fri, 15 Mar 2013 20:20:33 +
From: jbee...@gmail.com
To: ron@gmail.com
CC: pd-list@iem.at
Subject: Re: [PD] More Sensor Questions inc libfreenect on the Rpi

Hey Ryuta,

Yes, we'd thought about PIR's.  My understanding, and I'd be happy to be proved 
wrong, is that they are either 'on' or 'off', motion or no-motion.  

And this case what we'd really like is to be able to detect motion but also 
depth (3d) so we can measure whether something is moving towards and away from 
the chimes with a proportional representation of force.  Then ideally lateral 
movement too so, say, someone waves their arm from side to side that that could 
also be measured.


Tricky  challenging on such a lightweight machine, particularly with no GEM, 
but I guess that's also part of the fun:)

Many thanks for your suggestion though.

All the best,

Julian





___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list 
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] bi-directional OSC over TCP from liblo

2012-11-09 Thread martin.peach

If you look inside [unpackOSCstream] you'll see that it uses [slipdec]. So the 
other end must be using [slipenc] or they won't match up.
Unless you are doing this over a serial connection there is no need to use SLIP 
at all. [unpackOSC] should work properly with [tcpclient] or [tcpserver].

Martin

 From: ja...@jamiebullock.com
 Date: Fri, 9 Nov 2012 15:19:07 +
 To: pedro.lo...@ist.utl.pt
 CC: pd-list@iem.at; martin.pe...@sympatico.ca
 Subject: Re: [PD] bi-directional OSC over TCP from liblo
 
 
 Hi Pedro,
 
 Thanks for the reply. To clarify I can OSC over *UDP* from liblo to/from Pd 
 just fine using the mrpeach externals. It's using TCP, where I run into 
 trouble. I think it's due to the streamed nature of TCP, and message 
 boundaries, but I am not an expert on this.
 
 On 9 Nov 2012, at 14:00, Pedro Lopes pedro.lo...@ist.utl.pt wrote:
 
  hey jamie, 
  
  Yep, in this project (https://vimeo.com/24818342) it was going back and 
  forth from the core app (cpp) to pd. Using OSC. Cannot recall if TCP or 
  not, but can probably track it down. (that should not make much of a 
  difference at least outside the network layer).
  
  So you send from liblo and pd receives, but no data unpacks? Did I get it 
  write? If you open a ./oscdump on command line you get the data? (meaning 
  it would be a pd-side issue...)
 
 Yes that's correct. There is an example echo server that comes with liblo. 
 I can get bidirectional communication liblo - using this example. If I 
 replace one end of the communication with [tcpserver], liblo can connect, 
 [tcpserver] receives data, but [unpackOSCstream] can't seem to unpack the 
 data. Likewise [packOSCstream] doesn't seem to generate a data format that 
 liblo can understand.
 
 best,
 
 Jamie
 
 
 
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] bi-directional OSC over TCP from liblo

2012-11-09 Thread martin.peach



 Date: Fri, 9 Nov 2012 17:25:41 +0100
 From: zmoel...@iem.at
 To: pd-list@iem.at
 Subject: Re: [PD] bi-directional OSC over TCP from liblo
 
 On 11/09/2012 05:14 PM, martin.pe...@sympatico.ca wrote:
  If you look inside [unpackOSCstream] you'll see that it uses [slipdec].
  So the other end must be using [slipenc] or they won't match up.
  Unless you are doing this over a serial connection there is no need to
  use SLIP at all. [unpackOSC] should work properly with [tcpclient] or
  [tcpserver].
 
 
 but TCP/IP *is* a serial connection (that is: stream-based rather than 
 packet-based).
 if you are sending OSC-data over TCP/IP without using SLIP, you are 
 violating the OSC1.1 standard.
 

Ah yes. I was mixed up with the original use of slip: to pack entire tcp/ip 
packets, not just the payload, for transmission over a byte-oriented serial 
link.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] cheapest production-scale pd-anywhere platform?

2012-05-16 Thread martin.peach

I've used the beaglebone to play sound files (stereo 44.1kHz) through USB 
speakers, with python calling aplay.
Possibly csound would be easier to compile and use for beaglebone than pd, it's 
possible to have a completely command-line version.

Martin



  

  
  
I'm also interested in such a machine, even if the latency is
awfully big (read  100 ms). All i need is on-the-fly (read
kind-of-real-time) synthesized sound.



Le 16/05/2012 17:37, i go bananas a écrit :
i have also been interested in this for a while, but i
  am willing to spend more if it means lower latency,

  

  what's the latency like on these machines?

  

  
  

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list




  


___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list 
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Retrieving data directly into PD from HC-SR04 sensors connected to Arduino

2012-04-24 Thread martin.peach

It would be easier if you sent only the integer value:

#include Ultrasonic.h

{  Ultrasonic ultrasonic(10, 11 );  long microsec = ultrasonic.timing();
  Serial.write(microsec, sizeof(long));

  delay(400);
}


And in Pd collect groups of four characters from [comport] and reassemble them 
into long integers...
Easiest is to send only a single byte per sensor. But you'll also need a way to 
determine which is  the first character in the packet.

Martin

From: e10du...@gmail.com
Date: Tue, 24 Apr 2012 17:00:16 +0200
To: pimas...@gmail.com
CC: pd-list@iem.at
Subject: Re: [PD] Retrieving data directly into PD from HC-SR04 sensors 
connected to Arduino

Nop! Another sensor - HC-SR04 which uses 2 pins: Echo and Trigger - input and 
output. I use this code at Arduino to get it working. For each pin, I rewrite 
the same code only changing the (10, 11) at the third line. It gives me inch as 
distance:

#include Ultrasonic.h

{  Ultrasonic ultrasonic(10, 11 );

  float inMsec;  long microsec = ultrasonic.timing();

  inMsec = ultrasonic.convert(microsec, Ultrasonic::IN);  
Serial.println(inMsec);

  delay(400);}


What do you think? Maybe we just try with one sensor and try to change the 
frequency of a song played at PD with it??






On Tue, Apr 24, 2012 at 4:49 PM, Pierre Massat pimas...@gmail.com wrote:


Are you using this code :
http://www.arduino.cc/en/Tutorial/UltrasoundSensor


? 

Apparently Ultrasound sensors need to use a single pin as both input and output 
(to send a pulse and to receive the echo). Unfortunately i don't think Firmata 
can do that (it should be possible but I suspect there would be some latency 
when switching from input to ouput back and forth - somebody confirm this??).




If you only need these 4 sensors, you can adapt the example code for ultrasound 
sensors to output the data, and read it using [comport] in Pd. This object is 
at the core of Pduino. 

(You shouldn't see anything in Pd console when using Pduino, except information 
about the current connection and the device.)




2012/4/24 Emin Durak e10du...@gmail.com



Hej Pierre, thanks again.
It works perfectly at Arduino Serial Monitor; all 4 sensors that are connected 
to.





Should I only upload the firmata library and not write any code besides for the 
sensors you mean? I have uploaded the whole StandardFirmata.ino example file. 
But you mean only firmata library + sensors library (there is one) + sensors 
code will be sufficient?





I would say let's simplify it. Let's have 4 different channels of music (sound 
files) w're playing. We wanna change the frequency of them by the data gathered 
from 4 sensors. Will need to put +5000 to the number we get for us to actually 
hear the frequency, but let's say. Or I'm fine to just see the analog data on 
PD as well. How would we do that? I send you the screenshots of how I adjusted 
PD... Ah, should I be seeing the numbers from sensors at the main PD window?? I 
get here this:





 






On Tue, Apr 24, 2012 at 4:12 PM, Pierre Massat pimas...@gmail.com wrote:





First you need to make sure the electronic part is working fine (using Arduino 
IDE's serial monitor). 
Then upload Firmata. If your sensors need no special library you should upload 
Firmata only.






Then open arduino-test.pd with your board plugged in. The first thing you want 
to check in Pd is whether the right port is open. Choose a port, and click on 
the Version or Firmware messages to see if Pd recognizes the Arduino. If it 
does you should see a Firmata something below [pd device info]. If nothing 
appears, change the port and try again.






Once you've made sure that the right port is open, use the pink matrix in the 
upper right corner to open the pins your sensors are connected to. The digital 
pins are from 2 to 13 if i'm not mistaken, the rest is analog. Check input to 
open a digital pin for input, and analog to open an analog pin for input. 







Pierre

2012/4/24 Emin Durak e10du...@gmail.com






Hi Pierre,
Thank you very much for your tips. Yes I have been trying but how would I 
configure the analog pins as analog inputs at Pduino? I'm trying with 
ultrasonic sensors to read data (which is not on/off). And have uploaded the 
StandardFirmata code besides my sensors reading code to Arduino. And testing on 
the arduino-test.pd sketch on PD. Ain't working :(









Cheers...


On Tue, Apr 24, 2012 at 9:22 AM, Pierre Massat pimas...@gmail.com wrote:








Do you use a special library in Arduino to get data from your sensors? If not 
Firmata + Pduino should work just fine. Are you sure you opened the right port 
in Pduino? Did you configure the analog pins your sensors are connected to as 
analog inputs in Pduino? 









If you're not familiar at all with Pduino I suggest you try it with more simple 
stuff (like push buttons and pots). 

Cheers,

Pierre.

2012/4/24 Emin Durak e10du...@gmail.com









Hello!
I'm sorry this email will be probably too amateur but I 

Re: [PD] Retrieving data directly into PD from HC-SR04 sensors connected to Arduino

2012-04-24 Thread martin.peach

Send a [baud 9600( message to the [comport] object.

Martin

From: e10du...@gmail.com
Date: Tue, 24 Apr 2012 21:38:57 +0200
Subject: Re: [PD] Retrieving data directly into PD from HC-SR04 sensors 
connected to Arduino
To: martin.pe...@sympatico.ca
CC: pimas...@gmail.com; pd-list@iem.at

Thanks Martin. Hmm, do you think it really matters Martin? I already only get 
numbers from Arduino each sensor separately, which should just work fine, 
right? I mean so long as I get them in a number box each at PD. 


You have any idea how to change the byte rate to 9600 at PD?





On Tue, Apr 24, 2012 at 6:08 PM,  martin.pe...@sympatico.ca wrote:






It would be easier if you sent only the integer value:

#include Ultrasonic.h

{  Ultrasonic ultrasonic(10, 11 );  long microsec = ultrasonic.timing();


  Serial.write(microsec, sizeof(long));

  delay(400);
}


And in Pd collect groups of four characters from [comport] and reassemble them 
into long integers...
Easiest is to send only a single byte per sensor. But you'll also need a way to 
determine which is  the first character in the packet.



Martin

From: e10du...@gmail.com
Date: Tue, 24 Apr 2012 17:00:16 +0200
To: pimas...@gmail.com


CC: pd-list@iem.at
Subject: Re: [PD] Retrieving data directly into PD from HC-SR04 sensors 
connected to Arduino

Nop! Another sensor - HC-SR04 which uses 2 pins: Echo and Trigger - input and 
output. I use this code at Arduino to get it working. For each pin, I rewrite 
the same code only changing the (10, 11) at the third line. It gives me inch as 
distance:



#include Ultrasonic.h

{  Ultrasonic ultrasonic(10, 11 );

  float inMsec;  long microsec = ultrasonic.timing();

  inMsec = ultrasonic.convert(microsec, Ultrasonic::IN);  
Serial.println(inMsec);

  delay(400);}


What do you think? Maybe we just try with one sensor and try to change the 
frequency of a song played at PD with it??






On Tue, Apr 24, 2012 at 4:49 PM, Pierre Massat pimas...@gmail.com wrote:


Are you using this code :
http://www.arduino.cc/en/Tutorial/UltrasoundSensor




? 

Apparently Ultrasound sensors need to use a single pin as both input and output 
(to send a pulse and to receive the echo). Unfortunately i don't think Firmata 
can do that (it should be possible but I suspect there would be some latency 
when switching from input to ouput back and forth - somebody confirm this??).






If you only need these 4 sensors, you can adapt the example code for ultrasound 
sensors to output the data, and read it using [comport] in Pd. This object is 
at the core of Pduino. 

(You shouldn't see anything in Pd console when using Pduino, except information 
about the current connection and the device.)






2012/4/24 Emin Durak e10du...@gmail.com



Hej Pierre, thanks again.
It works perfectly at Arduino Serial Monitor; all 4 sensors that are connected 
to.





Should I only upload the firmata library and not write any code besides for the 
sensors you mean? I have uploaded the whole StandardFirmata.ino example file. 
But you mean only firmata library + sensors library (there is one) + sensors 
code will be sufficient?







I would say let's simplify it. Let's have 4 different channels of music (sound 
files) w're playing. We wanna change the frequency of them by the data gathered 
from 4 sensors. Will need to put +5000 to the number we get for us to actually 
hear the frequency, but let's say. Or I'm fine to just see the analog data on 
PD as well. How would we do that? I send you the screenshots of how I adjusted 
PD... Ah, should I be seeing the numbers from sensors at the main PD window?? I 
get here this:







 






On Tue, Apr 24, 2012 at 4:12 PM, Pierre Massat pimas...@gmail.com wrote:







First you need to make sure the electronic part is working fine (using Arduino 
IDE's serial monitor). 
Then upload Firmata. If your sensors need no special library you should upload 
Firmata only.






Then open arduino-test.pd with your board plugged in. The first thing you want 
to check in Pd is whether the right port is open. Choose a port, and click on 
the Version or Firmware messages to see if Pd recognizes the Arduino. If it 
does you should see a Firmata something below [pd device info]. If nothing 
appears, change the port and try again.








Once you've made sure that the right port is open, use the pink matrix in the 
upper right corner to open the pins your sensors are connected to. The digital 
pins are from 2 to 13 if i'm not mistaken, the rest is analog. Check input to 
open a digital pin for input, and analog to open an analog pin for input. 









Pierre

2012/4/24 Emin Durak e10du...@gmail.com








Hi Pierre,
Thank you very much for your tips. Yes I have been trying but how would I 
configure the analog pins as analog inputs at Pduino? I'm trying with 
ultrasonic sensors to read data (which is not on/off). And have uploaded the 
StandardFirmata code besides my sensors reading code to Arduino. And testing on 
the 

Re: [PD] no pd?? WTF ????

2012-01-13 Thread martin.peach


I think Pd uses %g which probably means %.6g by default, but it looks more like 
%.5g.

You're right, the precision is only lost when the patcher is written out 
somewhere.

In the attached patcher clicking on [1( calculates pi, which gets printed to a 
number box and the screen in 5 digit precision as 3.14159, but the subsequent 
[sin] object gives a value much closer to zero than when you click on 
[3.14159(, so the numbber box is hiding some extra precision.

Martin 
 But whatever the theoretical precision of a float, I think the thing that 
 makes Pd floats less precise than Max floats lies in the use of the %g format 
 specifier to print them out, which can result in a lower precision than the 
 float is capable of.
 
The %g specifier is able to print at full precision, if you instruct it 
to, but pd only uses something like %.6g, whereas you'd need %.8g to 
conserve all the binary precision (%.7g is slightly not enough, %.8g is 
too much, but there's not a %.7½g).
 
To conserve the decimal precision, however, you flip it around : in a 
32-bit float, you can only load a %.7g without loss, and a %.8g won't fit. 
But this only applies if the data really has %.8g precision to start with, 
which is not the case with %.8g numbers that came from float32, which 
really have only 7.2247 decimals of precision, which fits exactly in 
float32.
 
 This makes it possible to use maximum precision float calculations 
 inside of objects but not between them.
 
Between two objects communicating by float messages from outlet to inlet, 
things happen only in binary, and you already know that. This means that 
you can have 24-bit float32 precision between objects. The drop to 19.93 
bits of precision (%.6g) occurs only when converting to decimal ascii text 
and back.
 
Right ?
 
  __
| Mathieu BOUCHARD - téléphone : +1.514.383.3801 - Montréal, QC

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list 
#N canvas 364 685 450 300 10;
#X msg 32 18 1;
#X obj 32 44 atan;
#X obj 32 68 * 4;
#X floatatom 61 104 15 0 0 0 - - -;
#X obj 111 138 sin;
#X floatatom 141 160 15 0 0 0 - - -;
#X obj 112 188 print sin;
#X obj 32 132 print atan;
#X connect 0 0 1 0;
#X connect 1 0 2 0;
#X connect 2 0 3 0;
#X connect 2 0 4 0;
#X connect 2 0 7 0;
#X connect 4 0 5 0;
#X connect 4 0 6 0;
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] no pd?? WTF ????

2012-01-13 Thread martin.peach


Here's a more complete example of the precision thing.

Martin
  #N canvas 364 685 450 300 10;
#X msg 32 18 1;
#X obj 32 44 atan;
#X obj 32 68 * 4;
#X floatatom 92 85 15 0 0 0 - - -;
#X obj 111 164 sin;
#X floatatom 160 181 15 0 0 0 - - -;
#X obj 111 214 print sin;
#X obj 32 158 print atan;
#X obj 267 145 sin;
#X floatatom 316 162 15 0 0 0 - - -;
#X obj 267 195 print sin;
#X msg 267 105 3.14159;
#X connect 0 0 1 0;
#X connect 1 0 2 0;
#X connect 2 0 3 0;
#X connect 2 0 4 0;
#X connect 2 0 7 0;
#X connect 3 0 8 0;
#X connect 4 0 5 0;
#X connect 4 0 6 0;
#X connect 8 0 9 0;
#X connect 8 0 10 0;
#X connect 11 0 8 0;
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] 0.43 preferences flatspace

2011-12-16 Thread martin.peach

I have 29 paths in the dialog that comes up when I click Edit-Preferences, one 
of which is TrueType font and the rest are seemingly arbitrary libs from extra.
Where do they come from? (This is Pd 0.43.1-extended 20111213 on Debian)
What's the use of adding to it if they are not saved on exit?

Martin

 
 
 I've dropped support for flatspace since it was a kludge that has been 
 replaced by other things.  There is a better popen in the library 'moonlib'.  
  I've had good luck with [motex/system].
 
 As for preferences, I recommend setting the Audio and MIDI settings in the 
 patch using the 'mediasettings' library or [hcs/get-audio-dialog].  For 
 Startup prefs, those have been removed from Pd-extended, load libraries using 
 [import] in the patch.  And for the Path prefs, add paths using the new 
 [path] object.
 
 .hc
 
 On Dec 16, 2011, at 8:50 AM, rolf meesters wrote:
 
  
  hello list,
  
  in the latest 0.43 nightly-build for XP
  i can add something to the preferences but it doesn;t keep.
  
  and i'm missing flatspace (especially popen).
  is that on purpose?
  
  gr,rolf
  ___
  Pd-list@iem.at mailing list
  UNSUBSCRIBE and account-management - 
  http://lists.puredata.info/listinfo/pd-list
 
 
 
 
 
 If nature has made any one thing less susceptible than all others of 
 exclusive property, it is the action of the thinking power called an idea, 
 which an individual may exclusively possess as long as he keeps it to 
 himself; but the moment it is divulged, it forces itself into the possession 
 of everyone, and the receiver cannot dispossess himself of it.- 
 Thomas Jefferson
 
 
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] (breaking symbols) was Re: find a list of numbers in a text file

2011-09-06 Thread martin.peach



 Date: Tue, 6 Sep 2011 08:12:15 +0200
 From: f...@footils.org
 To: h...@at.or.at
 CC: pd-list@iem.at
 Subject: Re: [PD] (breaking symbols) was Re: find a list of numbers in a text 
 file
 
 Hi,
 
 On Mon, Sep 05, 2011 at 02:34:30PM -0400, Hans-Christoph Steiner wrote:
  
  Then having the patch rely on the error: float: no method for
  'symbol' error that is normally generated in that case. 
 
 Well, it prints an error because there *is* an error in the patch. The
 author should never have converted a float to a symbol and expect to
 still do float calculations with it. 
 

Yes, I think it ought to be up to the external to implement its own 
symbol-to-float converter since there is no universally valid way of doing it.
The same pattern will have different meanings in different context and Pd can't 
be expected to know what is expected in a specific case.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] (breaking symbols) was Re: find a list of numbers in a text file

2011-09-06 Thread martin.peach



From: h...@at.or.at
To: martin.pe...@sympatico.ca
Date: Tue, 6 Sep 2011 15:57:32 -0400
CC: pd-list@iem.at
Subject: Re: [PD] (breaking symbols) was Re: find a list of numbers in a
text file


On Sep 6, 2011, at 1:16 PM, martin.pe...@sympatico.ca 
martin.pe...@sympatico.ca wrote:

 Date: Tue, 6 Sep 2011 08:12:15 +0200
 From: f...@footils.org
 To: h...@at.or.at
 CC: pd-list@iem.at
 Subject: Re: [PD] (breaking symbols) was Re: find a list of numbers in a text 
 file
 
 Hi,
 
 On Mon, Sep 05, 2011 at 02:34:30PM -0400, Hans-Christoph Steiner wrote:
  
  Then having the patch rely on the error: float: no method for
  'symbol' error that is normally generated in that case. 
 
 Well, it prints an error because there *is* an error in the patch. The
 author should never have converted a float to a symbol and expect to
 still do float calculations with it. 
 

Yes, I think it ought to be up to the external to implement its own 
symbol-to-float converter since there is no universally valid way of doing it.
The same pattern will have different meanings in different context and Pd can't 
be expected to know what is expected in a specific case.

Martin

That sounds like a recipe for disaster, then we end up with multiple, 
incompatible ways of doing this.  I don't think anyone is proposing that 
symbols like four get converted to 4, but only symbols like 43, 5.22, -234, 
etc.  Things that can be directly converted from a char* to a float with a 
standard function.


I think someone might well want to make an external that can take 'four' as 4. 
Or a symbol '4+2' that would become a float 6.0.
And obviously Pd should not be doing that all the time because most of the time 
that is not the right thing to do.
The disaster would be if Pd tried to guess what the user intends based on some 
general idea of what Pd is 'for'.
For instance I've been working on an xbee external where I need to specify 
numbers like 0x0a060123 for the remote address.
I do that by interpreting the symbol as a 64-bit integer internally but I would 
not expect any other external to do this unless it needs to.
Otherwise the user would have to manually convert the number (which is 
conventionally given in hexadecimal form) into a bunch of decimal numbers small 
enough to be represented as float and then the external would combine them 
internally.

Martin


Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] netsend/netreceive + GUI bug

2011-08-03 Thread martin.peach

 
  hmm, i don't know where you get this idea from, but to me, the code of
  Pd's networking infrastructure looks, as if
  a) all incoming traffic was polled for in the main thread
  b) all output of this traffic  (to the Pd-patch) was propery protected
  by sys_lock()
 
 I am honestly not that familiar with this low-level aspect of pd. What I am 
 however aware of is that the poll function responsible for receiving message 
 (meaning when it arrives at the socket) inside netreceive immediately 
 dispatches it to pd and its polling is linked not to pd's main loop but to 
 the moment when the socket has received a packet which appears to be a part 
 of any basic network socket example code available online and as far as I can 
 see, I did not notice any relationship between its polling intervals and Pd's 
 main loop. 
 

If you are indeed talking about vanilla netsend and netreceive, the poll 
function is called during pd's main loop, not when something arrives at the 
socket.
In x_net.c :
sys_addpollfn(sockfd, (t_fdpollfn)socketreceiver_read, y);
socketreceiver_read is in s_inter.c:
void socketreceiver_read(t_socketreceiver *x, int fd)
sys_addpollfunction schedules the function to be called each pass through Pd's 
main loop.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Comport under Linux - baudbits question

2011-04-13 Thread martin.peach

 Hi all,

 Just transferring a patch into Linux from W7 and I get this message in
 the console which I didn't previously:
 get_baud_ratebits: 115200
 set_baudrate baudbits: 4098

 Now I want the baudrate to be 115200, which is good but what does the
 baudbits info mean - for example is it telling me that data is only
 coming in at 4098? Which I don't want, or, seems a waste if the overall
 patch is expecting a much faster rate.


I think the baud rate will be correct, the baudbits message is wrong.

Martin
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Comport under Linux - baudbits question

2011-04-13 Thread martin.peach

  Hi all,
 
  Just transferring a patch into Linux from W7 and I get this message in
  the console which I didn't previously:
  get_baud_ratebits: 115200
  set_baudrate baudbits: 4098
 
  Now I want the baudrate to be 115200, which is good but what does the
  baudbits info mean - for example is it telling me that data is only
  coming in at 4098? Which I don't want, or, seems a waste if the overall
  patch is expecting a much faster rate.
 

 I think the baud rate will be correct, the baudbits message is wrong.


Actually it's not wrong, it's just reporting the bits for the baud rate 
register, so it's not useful except for debugging. I will remove it.

Martin

  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] building pd-extended from svn trunk

2011-02-16 Thread martin.peach

I'm trying to build pd-extended from svn trunk.

I'm following the text here:
http://puredata.info/docs/developer/BuildingPdExtended

So I do this:
cd pure-data/packages/linux_make
make install

...and the build ends in pd/src:

dbtopow~.c:5:20: error: e_sqrt.h: No such file or directory.

It's true there is no e_sqrt.h in trunk/pd/src.

Which repository should I be using here?


Martin


  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] PD or MAX/MSP -- Arguments fpr PD needet!!

2011-02-08 Thread martin.peach

 So we´ve to compare PD with Max and then will decide for the better one...

 I prefer PD, so i need some Arguments for PD... Why PD and non Max?

 My Arguments are:


 * In PD you can easily write own Objects in PD (With C/C++ -- Is
 that in Max as possible like in PD ???

Yes, see:
http://cycling74.com/products/sdk/

Apart from that, Pd is free and also runs on linux.

Martin

  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] hardware implementation of [*~]

2011-02-03 Thread martin.peach

You're looking for a balanced modulator. The MC1496 is one.
The original ring modulator used a ring of 4 diodes between two transformers.
Running two pulse waves into an AND gate will give a binary version.

Martin



 Hello all,

 So I'm getting my feet wet in digital circuitry this quarter at my
 university and I've got numerous projects I want to waste my time on,
 one of them being a simple ring mod effect in the same vein as the ring
 mod found here: http://en.flossmanuals.net/PureData/AmplitudeModulation

 My question is what would be the hardware equivalent of the [*~]
 object. I guess it don't have to be digital... even an analog
 equivalent would help me understand it better.

 Hope this question makes sense, I don't have a good grasp on the
 terminology in this field one bit.

 Tyler

 ___ Pd-list@iem.at mailing
 list UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] [pool] build fails on linux

2011-01-27 Thread martin.peach

You get an error:
 /usr/bin/ld: cannot find -lpd
On linux you don't need lpd, it looks like you're compiling a windows version.

Martin



 Date: Thu, 27 Jan 2011 19:27:26 +0100
 From: yvan...@gmail.com
 To: pd-list@iem.at
 Subject: Re: [PD] [pool] build fails on linux

 bump ?
 sorry but this is quite boring, I hope I don't miss the obvious :/
 forgot to say that this error appears on lucid.

 ps: also sorry because it looks like my 1st message was a reply to a
 thread although it was not... (and this only on
 lists.puredata.info, weird..)

 cheers,
 _y


 On Tue, Jan 25, 2011 at 2:15 AM, Yvan Volochine
  wrote:
 hi,
 trying to build pool from latest svn (and latest pd git) I get this error:

 make[1]: Entering directory `/home/delf/dev/pool/source'
 /bin/bash ../libtool --tag=CXX --mode=link g++ -O2
 -I/usr/local/include/flext -I/home/delf/dev/pure-data/src
 -no-undefined -module -shrext .pd_linux -avoid-version -L/usr/local/lib
 -lpd -lflext-pd_s -o pool.la -rpath /usr/local/lib
 pool_la-main.lo pool_la-pool.lo pool_la-data.lo
 libtool: link: g++ -shared -nostdlib
 /usr/lib/gcc/i486-linux-gnu/4.4.3/../../../../lib/crti.o
 /usr/lib/gcc/i486-linux-gnu/4.4.3/crtbeginS.o .libs/pool_la-main.o
 .libs/pool_la-pool.o .libs/pool_la-data.o -L/usr/local/lib -lpd
 -lflext-pd_s -L/usr/lib/gcc/i486-linux-gnu/4.4.3
 -L/usr/lib/gcc/i486-linux-gnu/4.4.3/../../../../lib -L/lib/../lib
 -L/usr/lib/../lib -L/usr/lib/gcc/i486-linux-gnu/4.4.3/../../..
 -L/usr/lib/i486-linux-gnu -lstdc++ -lm -lc -lgcc_s
 /usr/lib/gcc/i486-linux-gnu/4.4.3/crtendS.o
 /usr/lib/gcc/i486-linux-gnu/4.4.3/../../../../lib/crtn.o -Wl,-soname
 -Wl,pool.pd_linux -o .libs/pool.pd_linux
 /usr/bin/ld: cannot find -lpd
 collect2: ld returned 1 exit status
 make[1]: *** [pool.la] Error 1
 make[1]: Leaving directory `/home/delf/dev/pool/source'
 make: *** [all-recursive] Error 1
 zsh: exit 2 make

 am I missing a path or something ?
 ./configure --with-sysdir=/PATH/TO/PD/SRC did find pd headers and all,
 now I have no idea about what is going wrong...

 any hint is much appreciated,

 cheers,
 _y


 ___ Pd-list@iem.at mailing
 list UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Most simple interfacing of 1 or 3 hardware switches (with [comport]?)

2010-11-26 Thread martin.peach



Andras wrote:
 If, however, anyone knows how to recieve an 5v undefined-length impulse
 with [comport], with little hardware fuss, i'm still interested.


You should be able to read both the DTR and CTS lines by repeatedly banging the 
[info( message into [comport] and routing the dsr and cts messages that 
come out the right outlet. Also if you set the baud rate really low and send 5V 
through about 1kohm into the Rx pin with the switch connecting it to ground, 
you should get some random data out of it.

Martin

  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Deep thinking ... Problem with ADSR

2010-11-23 Thread martin.peach

You need to put a bang before the delay, otherwise the [1 10( message sets the 
delay to 1ms.

Martin



 Date: Tue, 23 Nov 2010 21:37:35 +0100
 From: pimas...@gmail.com
 To: pd-list@iem.at
 Subject: [PD] Deep thinking ... Problem with ADSR

 Dear List,

 I was trying to build a simple (very simple) metronome using [metro] to
 see if i could change the speed without having to reset the metro
 object (has this changed in 0.42 by the way?). In order to test it i
 need an equally simple ADSR upon an oscillator to hear the bangs.

 Now please look at the attached patch because i don't understand why it
 won't work. I'm very confused...

 Pierre

 ___ Pd-list@iem.at mailing
 list UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Deep thinking ... Problem with ADSR

2010-11-23 Thread martin.peach

Maybe you need to re-instantiate the delay; it works fine here (Pd version 
0.42.5-extended-rc6 on WinXp), all your examples work.

Martin


 Date: Tue, 23 Nov 2010 21:59:51 +0100
 From: pimas...@gmail.com
 To: martin.pe...@sympatico.ca
 CC: pd-list@iem.at
 Subject: Re: [PD] Deep thinking ... Problem with ADSR

 Oh, I didn't know that. Still, putting a bang between [1 10( and the
 delay doesn't make any difference. I'd tried that, and was very
 confused.

 2010/11/23 

 You need to put a bang before the delay, otherwise the [1 10( message
 sets the delay to 1ms.

 Martin


 
  Date: Tue, 23 Nov 2010 21:37:35 +0100
  From: pimas...@gmail.com
  To: pd-list@iem.at
  Subject: [PD] Deep thinking ... Problem with ADSR
 
  Dear List,
 
  I was trying to build a simple (very simple) metronome using [metro] to
  see if i could change the speed without having to reset the metro
  object (has this changed in 0.42 by the way?). In order to test it i
  need an equally simple ADSR upon an oscillator to hear the bangs.
 
  Now please look at the attached patch because i don't understand why it
  won't work. I'm very confused...
 
  Pierre
 
  ___
 Pd-list@iem.at mailing
  list UNSUBSCRIBE and account-management -
  http://lists.puredata.info/listinfo/pd-list



 ___ Pd-list@iem.at mailing
 list UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Shuffling arrays

2010-10-04 Thread martin.peach

That's a bad way to shuffle, as it can swap things back again and generally 
reduce the randomness, the way someone who is good at shufflng cards can put 
them all back the way they started while appearing to mix them up.

A better way is to start at the beginning of the array, swap the first item 
with one of the remaining items, then swap the second item, up to the end.

Martin

Claude wrote:
 On 03/10/10 23:21, Andrew Faraday wrote:

 Hey Guys
 I've recently come across the .shuffle method in Ruby which randomly 
 re-orders the content of an array. Does anyone know of a way to do this in 
 Pd, that is, either change the order of notes within an array or output them 
 in a random order (without repeating any part of it)?
 Help would be appreciated
 Andrew

 You can pick pairs of indices at random and swap them with
 tabread/tabwrite; repeat to shuffle more.

 I used a similar technique to gradually sort an array (swap random
 elements only if they are out of order):

 https://code.goto10.org/svn/maximus/2007/clouds-are-made-of-water/
 http://www.archive.org/details/ClaudiusMaximus_-_Clouds_Are_Made_Of_Water
 (track 5)


 Claude
 --
 http://claudiusmaximus.goto10.org

 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] [PD-dev] odd key object behavior under Linux

2010-09-27 Thread martin.peach

It probably happens when you get two keydowns in the space of one Pd event 
loop. The second is output at the same time. The same thing happens with 
[metro] banging serial data into [comport] or [midiout]. The metro rate is 
quantized to the event loop rate, so individual bangs are irregularly spaced 
but the mean time over many bangs is perfect. The only way to get perfect 
timing is to use signals, messages are always handled after the sound has been 
computed.
So if you don't like it you could slow down your keyboard repeat rate to slower 
than Pd, or use a microphone to detect the keypresses ;)

Martin




Ico wrote:

 It all started when I noticed that my threaded version of coll object
 tended to freeze Pd at apparently random points. As it turns out, I was
 testing its robustness simply by passing a key into a read/write message
 and holding the key down to generate a large number of requests per
 second and the [key] object at times seemed to spit out (while
 autorepeat of the pressed key was taking place) two outputs at the same
 time which in turn crashed Pd as threaded coll object did not handle
 this gracefully. I've since fixed the coll object but the key behavior
 baffles me.

 The double redundant output is apparent in both rt and non-rt Pd (on
 Ubuntu 9.10 using rt kernel on the MSI Wind atom netbook) and below is
 the simplest patch to invoke this.

 Basically, I am measuring the aforesaid time delta between broadcast
 strokes using timer object and printing it out to console.

 #N canvas 549 345 383 297 10;
 #X obj 162 83 key;
 #X obj 162 107 sel 32;
 #X text 208 108 space;
 #X obj 162 145 timer;
 #X obj 162 182 print;
 #X connect 0 0 1 0;
 #X connect 1 0 3 1;
 #X connect 1 0 3 0;
 #X connect 3 0 4 0;

 So, while certainly the fact that threaded version of coll wasn't
 handling gracefully multiple redundant requests at the same time was a
 bug (which I am hoping has been fixed now), I am wondering whether the
 aforesaid [key] behavior might be a bug as it seems to me that
 keystrokes of the same key, even if the key is autorepeating should
 never have a time delta of zero. Naturally, one can always put a
 speedlim after the [key] object but that might result in a truncated
 output of fast typing.

 I would greatly appreciate it if others can test this to see if they are
 getting the same results.

 FWIW, allowing this kind of key behavior in more complex patches did
 result in the pd-gui communication tearing with the stderr reporting
 several truncated messages before crashing. Due to their complexity and
 unpredictability of a point where tearing would occur I am not sure
 where the problem might be stemming from but it is undoubtedly at least
 in part instigated by double redundant output from the key object
 possibly in conjunction with objects that may have not provided graceful
 handling of such requests.

 NB: I only tested the same patch on Win platform and there it does not
 exhibit this problem.

 Any thoughts would be most appreciated.

 Best wishes,

 Ico


 ___
 Pd-dev mailing list
 pd-...@iem.at
 http://lists.puredata.info/listinfo/pd-dev
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] [PD-dev] odd key object behavior under Linux

2010-09-27 Thread martin.peach

Yes, the OS also has its own event loop, which might be more responsible for 
that kind of timing, as it isn't running at a fixed rate and keyboard is 
probably a lower priority than mouse or network events.

Martin

Ico wrote:

 Many thanks for the explanation! What seems weird, however, is how divergent 
 time delta between repeats is. On Windows it is always around 30ms (at least 
 on my hardware) whereas on Linux it goes between 0, including 1.4ms and up to 
 50+. Even when accounting for jitter between two events I cannot imagine that 
 they oscillate that much (unless my flavor of kernel/hardware treats keypress 
 timing like a dirt :-).

 Best wishes,

 Ico

 martin.pe...@sympatico.ca wrote:


It probably happens when you get two keydowns in the space of one Pd event 
loop. The second is output at the same time. The same thing happens with 
[metro] banging serial data into [comport] or [midiout]. The metro rate is 
quantized to the event loop rate, so individual bangs are irregularly spaced 
but the mean time over many bangs is perfect. The only way to get perfect 
timing is to use signals, messages are always handled after the sound has 
been computed.
So if you don't like it you could slow down your keyboard repeat rate to 
slower than Pd, or use a microphone to detect the keypresses ;)

Martin




Ico wrote:

 It all started when I noticed that my threaded version of coll object
 tended to freeze Pd at apparently random points. As it turns out, I was
 testing its robustness simply by passing a key into a read/write message
 and holding the key down to generate a large number of requests per
 second and the [key] object at times seemed to spit out (while
 autorepeat of the pressed key was taking place) two outputs at the same
 time which in turn crashed Pd as threaded coll object did not handle
 this gracefully. I've since fixed the coll object but the key behavior
 baffles me.

 The double redundant output is apparent in both rt and non-rt Pd (on
 Ubuntu 9.10 using rt kernel on the MSI Wind atom netbook) and below is
 the simplest patch to invoke this.

 Basically, I am measuring the aforesaid time delta between broadcast
 strokes using timer object and printing it out to console.

 #N canvas 549 345 383 297 10;
 #X obj 162 83 key;
 #X obj 162 107 sel 32;
 #X text 208 108 space;
 #X obj 162 145 timer;
 #X obj 162 182 print;
 #X connect 0 0 1 0;
 #X connect 1 0 3 1;
 #X connect 1 0 3 0;
 #X connect 3 0 4 0;

 So, while certainly the fact that threaded version of coll wasn't
 handling gracefully multiple redundant requests at the same time was a
 bug (which I am hoping has been fixed now), I am wondering whether the
 aforesaid [key] behavior might be a bug as it seems to me that
 keystrokes of the same key, even if the key is autorepeating should
 never have a time delta of zero. Naturally, one can always put a
 speedlim after the [key] object but that might result in a truncated
 output of fast typing.

 I would greatly appreciate it if others can test this to see if they are
 getting the same results.

 FWIW, allowing this kind of key behavior in more complex patches did
 result in the pd-gui communication tearing with the stderr reporting
 several truncated messages before crashing. Due to their complexity and
 unpredictability of a point where tearing would occur I am not sure
 where the problem might be stemming from but it is undoubtedly at least
 in part instigated by double redundant output from the key object
 possibly in conjunction with objects that may have not provided graceful
 handling of such requests.

 NB: I only tested the same patch on Win platform and there it does not
 exhibit this problem.

 Any thoughts would be most appreciated.

 Best wishes,

 Ico


 ___
 Pd-dev mailing list
 pd-...@iem.at
 http://lists.puredata.info/listinfo/pd-dev

 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] return a list of externals

2010-09-10 Thread martin.peach

Not sure if it's what you want but the attached patch will list all the objects 
in a patch.

Martin

kim wrote:
 is there a way to get a list of all the externals used in a patch?
 other than by hand of course...
 I see nothing in pd --help

  #N canvas 625 239 616 367 10;
#X obj 51 16 openpanel;
#X obj 51 42 t b b a;
#X msg 51 72 1000;
#X obj 51 102 until;
#X msg 90 70 read \$1;
#X msg 70 145 rewind;
#X obj 51 -18 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 90 182 msgfile;
#X msg 51 126 find #X obj;
#X obj 90 215 list split 4;
#X obj 124 243 list split 1;
#X obj 243 85 route bang;
#X obj 300 128 + 1;
#X msg 300 165 goto \$1;
#X text 74 -21 choose a Pd patch;
#X obj 124 272 print object;
#X text 51 -47 list_objects will print all the objects in a patch;
#X connect 0 0 1 0;
#X connect 1 0 2 0;
#X connect 1 1 5 0;
#X connect 1 2 4 0;
#X connect 2 0 3 0;
#X connect 3 0 8 0;
#X connect 4 0 7 0;
#X connect 5 0 7 0;
#X connect 6 0 0 0;
#X connect 7 0 9 0;
#X connect 7 1 11 0;
#X connect 8 0 7 0;
#X connect 9 1 10 0;
#X connect 10 0 15 0;
#X connect 11 0 3 1;
#X connect 11 1 12 0;
#X connect 12 0 13 0;
#X connect 13 0 7 0;
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] problem using [udpsend] from iemnet (or mrpeach) in a sub-process (with [pd~])

2010-08-20 Thread martin.peach

There's [udpsend~] and [udpreceive]~ for sending multichannel signals.

Martin

bernardo wrote:
 maybe as audio signal through JACK? That is the fastest way I'm aware.
 That would be 441000 values per second per channel -1.0/+1.0, then you
 had to rescale again.
 
 2010/8/20 Jack j...@rybn.org:
  Hello Mathieu,
 
  I have already do that with [packOSC]/[unpackOSC] and
  [udpsend]/[udpreceive], it is slow too.
  I need to send 2 lists of 3 floats (id, pos x, pos y) each frame (50
  fps) from one process to other.
  Thanx.
  ++
 
  Jack
 
 
  Le vendredi 20 août 2010 à 10:20 -0400, Mathieu Bouchard a écrit :
  On Fri, 20 Aug 2010, Jack wrote:
 
   Is there another method to accelerate this transfert between GEM and MSD
   using [pd~] and [stdout] ?
 
  Can you try communicating with OSC instead, and see whether it's faster ?
  It does lesser amounts of encoding and decoding for floats, than what
  [netsend]/[netreceive]/[stdout]/[pd~] need. How many floats do you need to
  send from one process to the other, per second ?
 
_ _ __ ___ _  _ _ ...
  | Mathieu Bouchard, Montréal, Québec. téléphone: +1.514.383.3801
 
 
 
  ___
  Pd-list@iem.at mailing list
  UNSUBSCRIBE and account-management - 
  http://lists.puredata.info/listinfo/pd-list
 
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] exact meaning of netsend outlet

2010-08-13 Thread martin.peach

 wondering what the exact meaning of the outlet of [netreceive] in TCP
 mode is:
 
 Does it indicate whether Pd through the OS was able to open a port

The right outlet  indicates that the port is open and the other end is 
listening.

 or
 does it indicate if a TCP packet arrived at the destination?
 
 And: Am I correct assuming that netsend only outputs a message when it
 got a (send ...) message into its inlet? So there is no way to indicate
 whether the receiving machine is online unless I keep sending
 heartbeat/ping messages?
 

If the other end drops the connection, then the right outlet will output zero, 
but it might not happen right away.
Especially with wireless it's better to have some kind of heartbeat ping-pong 
going at a higher level than the OS.

Martin
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Beagleboard-xM

2010-07-29 Thread martin.peach

I have one of these:
http://www.globalscaletechnologies.com/p-22-sheevaplug-dev-kit-us.aspx
still running since this spring. It has no display except a couple of LEDs 
though, not sure what Pd can do with it. Two USB ports for external sound card 
or an Arduino maybe? Is it possible to build a no-gui version of Pd?

Martin 

From: h...@at.or.at
To: jeffreyconcepc...@gmail.com
Date: Thu, 29 Jul 2010 15:36:02 -0400
CC: djk_1...@hotmail.com; pd-list@iem.at
Subject: Re: [PD] Beagleboard-xM


I just heard of this box, it sounds like it could be very nice for embedded Pd. 
 It runs Debian, so it should be easy to get Pd going on it.
http://www.globalscaletechnologies.com/t-guruplugdetails.aspx
.hc
On Jul 29, 2010, at 2:36 PM, Jeffrey Concepcion wrote:That device is out of 
production, as far as i know.
Jeff

On Tue, Jul 20, 2010 at 12:17 PM, Jose Luis Santorcuato 
santorcuat...@gmail.com wrote:
 Hi, check this:

http://www.bluemelon.org/index.php/Products/BM7505_BluePD_programmable_Pure_Data_router
 
Best regards
 
José

2010/7/20 David Kirkpatrick djk_1...@hotmail.com
   Hi,

The Beagleboard-xM will be coming out shortly and I'd like to use it in a 
stand-alone instrument i'm building. Does anyone know from looking at the specs 
if it'll run Pure Data? I'm fairly sure it'll run PDa but i'd prefer to use 
standard Pure Data if possible.
 
Thanks,

David Kirkpatrick
Sound and Multimedia Artist
www.davidk.com.au
  
Looking for a hot date? View photos of singles in your area! 
___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list
 


-- 

http://arselectronicachile.blogspot.com
http://www.myspace.com/santorcuato
 

 
___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list
 


-- 
www.avmachinists.org Puerto Rico based Art Collective/ Non-Profit Org
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list

 

News is what people want to keep hidden and everything else is publicity.   
   - Bill Moyers 

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list 
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] OSCSerial for windows

2010-05-13 Thread martin.peach

  Hi Ricardo,
  Well I didn't have chance to try it with [comport], but I suspect you need
  to make the output of [comport] into lists using the slip packet delimiter
  192 and [list append] and [list prepend] as in the [list] examples.
  It should not crash Pd though, that's bad...
  Martin
 
 Hi Martin, I used [list preped] and [list append] as you said and now
 it works, thanks.
 

Yes, but I think it should work with individual input bytes, I noticed that 
it's not checking the buffer for overflow in that case, so I will fix that 
today. I was getting crashes by feeding [slipdec] with random bytes.


 However, I am still getting crashes with the stream from comport (if I
 program the microcontroller to send messages every ~200ms, it works
 fine), I read a recent mail about unpackOSC, then I tested using just
 slipdec (still crashes)
 
 Crashes occur if I send messages too fast, just putting a [metro 50]
 to a valid message in slipenc-help.pd or sending microcontroller
 messages every 10 - 50 ms, freezes pd, and eventually make it crash.
 

Maybe it's a [print] object overloading? Trying to print thousands of numbers 
usually hangs Pd.

 I don't know what should be the minimun time that slipdec needs to
 process a packet, I use the same settings that I use in Linux with
 serialIO, OpenSoundControl and OSCruote [1], in Linux it works pretty
 well even with shortes times.
 

It should be able to hold on to a partial message indefinitely, but at the 
moment if the message list isn't a complete SLIP packet it might not work 
properly.

Martin
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] OSCSerial for windows

2010-05-12 Thread martin.peach

Hi Ricardo,
Well I didn't have chance to try it with [comport], but I suspect you need to 
make the output of [comport] into lists using the slip packet delimiter 192 and 
[list append] and [list prepend] as in the [list] examples.
It should not crash Pd though, that's bad...
Martin


 From: rduen...@gmail.com
 Date: Wed, 12 May 2010 16:05:36 -0500
 Subject: Re: [PD] OSCSerial for windows
 To: martin.pe...@sympatico.ca
 CC: pd-list@iem.at
 
 Hi Martin, that´s what I´m looking for, but I am getting an error when
 I connect the comport output to the slipdec input, pd crashes
 inmediately and closes.
 
 Comport receives data fine, and slipdec makes his job too, but
 together pd crashes, is it a stable version?
 
 
 Thanks,
 
 Ricardo
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Max Smoother Audio than Pd?

2010-03-25 Thread martin.peach

matteosistisette wrote:
 colet.patr...@free.fr escribió:

 in despite a lot of efforts to have tools for making music with pd,
 there's no way to make something smooth enough to be commercial,
 unless cheating with some steinberg or direct x stuff,

 That doesn't seem strange to me: I guess all the sound processing
 involved in creating _fullu_ commercial-sounding stuff would be quite
 complicated to implement natively in Pd and probably too cpu-expensive -
 anybody correct me if I am wrong.

 But I wonder how this can be different in Max (note that I don't know
 Max at all (almost))


I think the main difference is that Max uses doubles (64-bit floating point) 
and Pd uses floats (32-bit floating point) to calculate the audio.
There are two varieties of csound, one use floats and the other uses doubles: 
files rendered with the doubles version usually sound better.

Martin


  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Max Smoother Audio than Pd?

2010-03-25 Thread martin.peach

vboehm wrote:point)

 oha, myth-alarm! max (still) uses 32-bits.

Yeah I guess you're right. In the Max sdk docs they sometimes refer to 32-bit 
floats as 'doubles'.
e.g. The other options are A_FLOAT for doubles, A_SYM for symbols, and 
A_GIMME,...
but the Max atom is essentially identical to the Pd atom, so it must be a float.

Max has an integer atom type (A_LONG) while Pd doesn't, although Pd declares 
some integer methods in m_pd.h, but that won't affect the audio.

So csound doubles version should sound best of all...

Martin

  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Max Smoother Audio than Pd?

2010-03-25 Thread martin.peach

mnb wrote:
 colet.patr...@free.fr wrote:

 didn't like the sonority of netpd for example, because rendered
 texture are poor, only one sytnh sound good

 the reason might be that netpd is 'pd-vanilla', and there are
 not so much techniques used for getting smooth(er) sound (afair),
 like bandlimited oscs and custom filters. without any further effort (or
 using externals), pd sounds pretty rough and 'digital'. (not so much
 like 'ice-cold fm-pads', more like '8-bit lofi with aliasing'.)

If a basic [osc~] sounds like 8 bits I think maybe you need a better sound 
card. ;)

Martin
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] question about netclient and netserver

2010-03-24 Thread martin.peach

 use mrpeach's [tcpserver]/[tcpclient].

 I guess they suffer from the very same problem that I wrote about in my
 last post. However, it would be still interesting to see, whether they
 make any difference for Ivica's setup.

I just committed a possible fix: tcpserver stops sending when it can't create 
any more threads, until it receives an [unblock( message.

I seriously think that you should be using UDP if you want to broadcast. Make 
your own handshake mechanism in UDP. Don't expect TCP to do things it wasn't 
made for.

Martin
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] question about netclient and netserver

2010-03-24 Thread martin.peach

reduzierer wrote:
From what I know, there is an internal buffer of ~4kB for the sending
 sockets in both netclient and netserver (I can't recall whether this
 buffer is built into the externals or is part of the network subsystem
 of the OS). If that limit is hit, the Pd process is blocked until that
 buffer is emptied again (which leads obviously to audio drop-outs).

 IMHO, this is a design flaw, which all sending net-externals suffer
 from. There is no way to check the state of this buffer, which would be
 required in order to avoid a buffer overrun. It would be sufficient to
 get notified only, when the buffer is completely emptied, so that you
 could design your patch in a way that it would only send the next
 message when the previous one is through.


IMHO it's not a design flaw, but part of TCP's design philosophy that tries to 
send packets until they are received. In the original concept, bombs would be 
dropping all over the countryside, destroying cables and data centres 
willy-nilly, while messages could still get through to the missile silos and AA 
gunners.

UDP was designed to send and forget.

If you are broadcasting in TCP you are actually sending separate messages to 
each recipient, with the OS providing overhead for each one until it has been 
acknowledged by the recipient. Obviously it's easy to do a DOS attack this way 
even on your own machine simply by sending faster than the receiver can process 
the packets.

Broadcasting in UDP sends a single packet to a single address that the router 
sends to every machine on the subnet. The OS discards the buffer as soon as it 
is sent, so you can't overload the stack, although you can always peg the CPU 
trying.

Martin





  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] question about netclient and netserver

2010-03-24 Thread martin.peach

zmoelnig wrote:

 PS:
 for what it is worth: i have forked mrpeach/net yesterday, with the aim
 to provide a simple (simpler than mrpeach's objects) high-performance
 (on my loopback device i was able to do about 600MBit/s read and write
 with Pd) without all the legacy encumberments of the original objects.
 (the plan is to simplify the api a little bit)

 currently it is still crashy when it comes to disconnecting servers.
 find it at iem/iemnet


If you're going to do that, I think you should change their names, otherwise 
confusion will reign.

Martin
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] midiout / sysex on windows

2010-03-04 Thread martin.peach



L. Willkomm wrote:

 martin.pe...@sympatico.ca wrote:

 Shouldn't [midiout] be renamed to [sysexout]? It only does sysex, you can't 
 send any other kind of MIDI message with [midiout].

 Martin


 Hello list,
 I think [midiout] should just send the midi byte we want. As far as I
 see, it is the only way to send data bytes with Running Status.

Yes, sorry, I was confused by the sysex stuff, [midiout] does indeed output the 
realtime status bytes, on ALSA and Windows as well. Sysex via [midiout] on 
Windows doesn't work: the start and end bytes are there but the message is 
missing.

Martin


 L. Willkomm

 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Re : GEM units

2010-03-03 Thread martin.peach

So GEM units are QuarterWindowSides, then?

Martin

t wrote:


 In fact, if you don't change the gemwin's view parameters , z = 4.

 So if you create a 512 * 512 dimensions window for example, and if you want
 to build a square with te same dimensions, your square's size will be 4.

 Il you create a 600 * 400 dimensions window, the size of corresponding
 rectangle will be 6 * 4.

 Is this what you wanted to know?

 t


 Le 3/03/10 0:54, « Jon »  a écrit :

 this must be documented somewhere, but i can't locate it.
 is there some logic to the size units for GEM objects? like: what
 exactly is 2 in [cube 2]?
 thankyou
 jon

 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list





 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] http client native in pd?

2010-03-01 Thread martin.peach

If you change the [list append 13 10] to [list append 13 10 13 10], adding a 
blank line to the request, it works. 

Martin

hc wrote:


 Here's a sketch to start with. It works sometimes, but seems to be a
 bit flaky:
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] http client native in pd?

2010-03-01 Thread martin.peach

And here's a version that gets the latest solar wind speed from the ACE 
satellite...

Martin

hc wrote:

 Ah, right, here's an updated version, that will also disconnect if
 there's no response within 5000ms.

 .hc

  

httpget-ace.pd
Description: application/puredata
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] midiout / sysex on windows

2010-02-08 Thread martin.peach

I just tried this with vanilla pd-0.42.5 on WinXP. [midiout] and [sysexin] both 
work despite the warnings. You need to send a multiple message like [240, 1, 2, 
3, 247( although sometimes just sending the individual characters works too.

On pd-extended-0.42.5 [midiout] only sends the start and end sysex status, no 
message.
Maybe because extended isn't using portmidi?

Shouldn't [midiout] be renamed to [sysexout]? It only does sysex, you can't 
send any other kind of MIDI message with [midiout].

Martin

alex wrote:


 I just tried this myself on a friend's windows machine running a
 relatively recent version of pd extended, though I'm not exactly sure
 which one..
 it gave me an error
 MidiOut Error 1
 whenever I tried to send a sysex message out.
 And there was an error about [sysexin] not being implemented on
 windows and [midiout] being dangerous.. I'm not sure if midiin worked
 with sysex or not because i couldn't get the sysex out..

 Anyone know if this has changed or if there are plans to make sysex
 i/o work for windows?

 Thanks,
 Alex

 On Wed, Nov 11, 2009 at 7:23 AM, kristof lauwers
  wrote:
 hello,

 I was wondering what the current state of midiout is on windows (i'm working
 on Xp, but should make something that works under any recent windows
 version) I see some discussion about it in the list archives and forum, but
 it's not clear if it should be working or not right now..

 I tried it on vanilla PD 0.42.5 and in extended 0.4.3. It seems in vanilla
 it does nothing at all. In extended it's sending out something, but not what
 i expect.. (sometimes the 3 bytes i try to send each padded by 2 or 3 0's,
 sometimes nothing at all..)

 Also, it's not very clear what kind of input midiout expects - the
 documentation doesn't say anything about that.. i'd guess a list with first
 status byte and then the data bytes?

 if it's not working (yet), are there any alternatives to send sysexes from
 Pd?

 thanks,

 Kristof




 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management -
 http://lists.puredata.info/listinfo/pd-list


 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] midiout / sysex on windows

2010-02-03 Thread martin.peach

I don't think sysex works on linux either; at least I'm trying to send using 
[midiout] using alsa midi and nothing is going through the interface, whereas 
[noteout] works fine. On Pd 0.42.5-extended2010105 debian lenny.
I think I should be able to send a list like:

[240 88 123 247(
|
[midiout]

...but it won't.

Martin


 Date: Wed, 3 Feb 2010 09:38:16 -0800
 From: x37v.a...@gmail.com
 To: pd-list@iem.at; pd-...@iem.at
 Subject: Re: [PD] midiout / sysex on windows
 
 BTW, he is using pd 0.41.4-extended
 
 -Alex
 
 
 On Tue, Feb 2, 2010 at 7:46 PM, Alex x37v.a...@gmail.com wrote:
  I just tried this myself on a friend's windows machine running a
  relatively recent version of pd extended, though I'm not exactly sure
  which one..
  it gave me an error
  MidiOut Error 1
  whenever I tried to send a sysex message out.
  And there was an error about [sysexin] not being implemented on
  windows and [midiout] being dangerous.. I'm not sure if midiin worked
  with sysex or not because i couldn't get the sysex out..
 
  Anyone know if this has changed or if there are plans to make sysex
  i/o work for windows?
 
  Thanks,
  Alex
 
  On Wed, Nov 11, 2009 at 7:23 AM, kristof lauwers
  p...@kristoflauwers.domainepublic.net wrote:
  hello,
 
  I was wondering what the current state of midiout is on windows (i'm 
  working
  on Xp, but should make something that works under any recent windows
  version) I see some discussion about it in the list archives and forum, but
  it's not clear if it should be working or not right now..
 
  I tried it on vanilla PD 0.42.5 and in extended 0.4.3. It seems in vanilla
  it does nothing at all. In extended it's sending out something, but not 
  what
  i expect.. (sometimes the 3 bytes i try to send each padded by 2 or 3 0's,
  sometimes nothing at all..)
 
  Also, it's not very clear what kind of input midiout expects - the
  documentation doesn't say anything about that.. i'd guess a list with first
  status byte and then the data bytes?
 
  if it's not working (yet), are there any alternatives to send sysexes from
  Pd?
 
  thanks,
 
  Kristof
 
 
 
 
  ___
  Pd-list@iem.at mailing list
  UNSUBSCRIBE and account-management -
  http://lists.puredata.info/listinfo/pd-list
 
 
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] [dirpanel] inconsistency in Windows?

2010-01-14 Thread martin.peach


Matteo Sisti Sette wrote:
 If you bang a [dirpanel] and browse for a directory in Windows, if you 
 select any folder that is not the root of a disk, you get:
 
 symbol X:/path/to/the/folder
 
 NOT ending with slash.
 
 However, if you select the root of drive X, you get:
 
 X:/
 
 WITH the ending slash.
 
 Isn't this inconsistent? Shouldn't the output either always or never 
 include the ending slash? (I don't know which of the two would be better).
 

The pathname of the root directory is / so it is actually a beginning slash, 
so it's consistent.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] jack - [udpreceive] - audio engine on

2009-12-14 Thread martin.peach

Does it still do that if you run the [metro] a lot slower than 1000/sec?

Martin


wolfgang.jaeger wrote:
 Hello,
 
 I'm having some troubles using the object [udpreceive] with jack. I
 reduced my patch to make it traceable.
 
 1. start jack
 
 2. start pd working with jack as audio engine
 
 3. source patch:
   [toggle] - [metro 1] - [1( - [udpsend]
connect [udpsend] to localhost (127.0.0.1) on a highport (12350)
 
 4. destination patch:
   [udpreceive 12350]
 
 5. turn on the audio engine
 
 After turning on the audio engine the GUI of the destination patch
 isn't updated any more (it still responds to the mouse but doesn't show
 the result of my clicking or patching).
 
 
 I'm not having the troubles working with ALSA and the load of my system
 is quite low (and I reproduced the problem on another machine):
 --
 top - load average: 0.18, 0.12, 0.09
 Cpu(s):  1.1%us,  1.3%sy,  0.0%ni, 97.1%id,  0.0%wa,  0.0%hi,  0.5%si,
 0.0%st
 Mem:   2050720k total,   862196k used,  1188524k free,63984k buffers
 Swap:  4915880k total,0k used,  4915880k free,   506104k cached
 
   PID USER  PR  NI  VIRT  RES  SHR S %CPU %MEMTIME+  COMMAND
 
 14xxx xxx 20   0 19924 3864 2284 S2  0.2   0:05.67 pd
 14xxx xxx 20   0 32080 4976 4664 S0  0.2   0:01.43 jackd
 --
 
 Thanks for any help.
 
 Wolfgang
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Comport issue: two digits problem

2009-12-10 Thread martin.peach

lineacurva wrote:

 Hi guys,
 
 I'm working on my first RFID project, involving Arduino and Pure  
 Data. I use Innovation Id-20 reader and Arduino 2009. I'm stuck in a  
 problem with comport.
 
 As I put a transponder near the reader, in Arduino serial monitor I  
 can see a number like: 495211712056
 
 But in the little patch I attach here, comport reads: 53
 
 This is a problem since more than one transponder give me a 53  
 feedback (but a different 12 digits number in Arduino monitor).
 

53 is the ASCII value of the character '5'. Probably if you add a [print] to 
the [comport] output you would get a list of 12 ASCII values for each sample.

In Pd you need to accumulate the list of incoming ASCII codes, subtract 48 
(ASCII '0') from each, and route them accordingly. A 12-digit number won't 
display correctly as a float. Probably it's easier in Arduino to make your 
numbers ints on [0..255] and send them as BYTE. Then you get one number per 
sample and don't need to handle lists.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Very large patches unstable?

2009-12-02 Thread martin.peach



matju wrote:

 On Wed, 2 Dec 2009, Martin Peach wrote:
 
  Before that I would try the very large patch on a faster computer with 
  more RAM.
 
 Good idea. Now with four CPUs, you can now load Pd in the same amount of 
 time as before, but as a bonus, your system is 75% CPU idle in the 
 meanwhile.
 

Oh no of course not! You must then make your patch even bigger until it's again 
using 110% and crashes because of 'bugs'.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Inconsistent creation in some objects

2009-11-18 Thread martin.peach

 Personally, I think it should instantiate, and throw a pd_error()  
 saying that it can't function without a port number.  Another option  
 for netreceive is to pick a default port number.
 

So maybe Pd needs a default port number that could be inscribed in 
/etc/services and /etc/inetd.conf, or at least m_pd.h.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] arduino problem with analog sensors

2009-11-12 Thread martin.peach

The microcontroller in the Arduino has a single sampling capacitor that can be 
connected to any one of the analog pins.
It will charge up to the voltage on the pin if enough charged particles are 
available on the pin (or a path less than about 10kohm exists to a source of 
current).
The cap is not discharged by the analog-to-digital conversion process or 
between samples except through leakage.
If no charge is available on the pin the capacitor will continue to slowly 
drain its charge from the previous sample.
It's normal and harmless unless you are in a high-voltage environment like a 
thunderstorm or a nylon carpet, where much more than 5V could accumulate on an 
open pin. Then it's best to ground unused inputs.

Martin


 Date: Thu, 12 Nov 2009 18:02:05 +0100
 From: alte...@gmail.com
 To: pd-list@iem.at
 Subject: [PD] arduino problem with analog sensors
 
 hi
 
 not a PD question I guess...  i dont know much of electrical stuff. i am 
 connecting two analog sensors to the arduino. One is a pressure sensor 
 and the second a potentiometer, they are both from an old icube.
 
 i noticed that when i raise the potentiometer (analog pin 5) the 
 pressure sensor (analog pin 2) reports values ranging 0 to ~0.16 
 increasing together as the potenciometer goes up. It is like some kind 
 of residual noise comming from pin 5 that goes into pin 0.
 
 the power cables of both sensors go together to 5v inlet of the arduino 
 and the ground cables go to ground pin, each of the data cable goes to 
 its separate analog pin.
 
 I am using arduino from Pure Data extended using latest Firmata, so i am 
 just filtering out any value smaller than 0.16 coming from analog pin 0.
 
 is there anything I am doing wrong? or is this normal?
 
 thanks
 
 enrike
 
 ___
 Pd-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] lib.pd on pd-extended

2009-09-30 Thread martin.peach

The latest autobuild for windows 
http://autobuild.puredata.info/auto-build/latest/Pd-0.42.5-extended-windowsxp-i386.exe
now installs pd.a as pd.lib and that seems to work OK to link against with 
MSVisualC++2008ExpressEdition, so the .def file that is also installed is 
probably redundant.

I notice in the log that moocow stuff fails when -lpd is used, although -lpd 
works OK for pd.dll and others:

gcc  -DPD -I/home/pd/auto-build/pd-extended/pd/src -Wall -W -ggdb 
-I/home/pd/auto-build/pd-extended/Gem/src -mms-bitfields -DMSW -DNT 
-D'O_NONBLOCK=1' -D'srand48(n)=srand((n))' 
-D'drand48()=((double)rand()/RAND_MAX)' -D'bzero(p,n)=memset(p,0,n)'  
-L/home/pd/auto-build/pd-extended/pd/bin 
-L/home/pd/auto-build/pd-extended/pd/obj -L/sw/lib -shared 
-L/home/pd/auto-build/pd-extended/externals/moocow/extended/build.moo/bin 
-L/home/pd/auto-build/pd-extended/externals/moocow/extended/build.moo/obj -o 
locale.dll  locale.o  -lpd -lwsock32 -lpthreadGC2 -lkernel32 -luser32 -lgdi32 
-lregex
c:\MinGW\bin\..\lib\gcc\mingw32\3.4.5\..\..\..\..\mingw32\bin\ld.exe: cannot 
find -lpd

Maybe the path is wrong? I don't think it wants to find libpd.a instead of 
pd.a, since
in makefile.mingw, pd.dll is built with --out-implib=pd.a, then pd.exe uses 
-lpd without any errors.

Martin

  ___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] pd.lib

2009-09-24 Thread martin.peach







zmoelnig wrote:
 Damien Henry wrote:
  Hello !
  
  Where can I find documentation about pd.lib ?
  Does anyone on the list turn pd into a library ? for creating a DSP
  engine for instance ?
 
 
 no.
 this is how Pd has always been built by miller on w32.
 pd.exe/pd.com is just a tiny wrapper that calls the main-loop within pd.lib
 nothing like a libpd
 

Well pd.lib is actually a kind of list of function entry points in pd.dll, 
which is the real shared library.

pd.exe and pd.com jump to a function sys_main() in pd.dll.

sys_main then starts up the whole gui, unless it was called with the -nogui 
argument. 

pd.lib only exists for the linker to find the code and isn't required at 
run-time. With the M$ linker it's needed to associate the symbols (function 
names in Pd) with entry points (pointers to Pd code), when building externals.

Nothing stops you using code within pd.dll as library code. It's just like a 
libpd except for the requirement to know ahead of time where the functions are 
located, which is why pd.lib is there. Practically it's nearly useless as a lib 
because everything is interrelated, but you could probably fake a call to the 
perform routine of osc~ without otherwise using the dsp graph; or use some 
utility function.

Martin

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Recieving OSC / Wiimote

2009-07-15 Thread martin.peach


___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] preventing comport freezes

2009-05-08 Thread martin.peach

Roman wrote:
 On Fri, 2009-05-08 at 08:14 -0400, Martin Peach wrote:
  Hans-Christoph Steiner wrote:
   
   So right now, when [comport] is open and that device gets disconnected, 
   comport freezes and Pd crashes.  My guess is that comport is waiting and 
   therefore blocking.  It seems like the select() call should prevent 
   that, any other guesses on how to prevent comport from locking like 
   this?  Many arduino users would be very happy.
   
  
  Is this on linux? It should be non-blocking on Windows.
  I suppose it crashes only when you try to send something, not if you 
  just pull the cable out. I would have thought that if hardware 
  handshaking was off, the port will send anyway. I seem to remember 
  sending into an oscilloscope probe with no cable present.
 
  Select is problematic, as we have seen with recent [tcpserver], checking 
  if each byte can be sent before it goes out slows the whole thing down a 
  lot.
  
 
 i am still in the process of understanding things, that you have to deal
 with, so forgive any obvious question from my side, but why is it
 necessary to call select() for each single byte? wouldn't it be
 sufficient to call it 'from time to time' (whatever that means)?
 

I guess if you pull the cable out at the exact moment that [tcpserver] is 
sending a message, every once in a while it might hang because select said it 
was clear to send, but right after that the connection broke...

 just out of curiosity: if there is a solution, that works well for
 [tcpserver], couldn't it be applied also to [comport]?
 


Maybe. But I think you should be able to use [comport] with no hardware 
handshaking enabled and send data even if no cable is attached. Sometimes the 
absence of one of the two input handshake signals prevents the serial hardware 
from sending. Also if an error occurred in the reception of serial data it may 
not be handled properly in [comport]. So I'm not sure what is causing this 
particular crash, since HC said that it happened when the remote device was 
disconnected but gave no further detail.

Martin

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] DIY GSoC: getting those projects done

2009-03-23 Thread martin.peach

padawan12 wrote:
 Chris McCormick wrote:
 
  Also, I hate to be cynical, but
  I can't see any way even remotely in which Google could use Pd to make a
  profit. ;) 
 
 
 Profit aside, you can make a fundamental partition in computing 
 between forward looking systems (predictive, generative, 
 hypothetical, AI, imaginative type systems) and backward 
 looking (retrospective, analytical, indexing, organising, 
 sort, search, existing value based systems). A bit like left 
 and right brain faculties. Most problems involve elements of 
 both, but Google's domain (search) really falls more into the 
 latter, while applications of Pd are constructive and fall 
 better into the former. 
 

Hmmm, maybe a project to find and install any Pd external missing from a 
patch...

Martin

___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Midi in with arduino

2009-03-16 Thread martin.peach

 Does anybody know how to wire a midi in on to the arduino.
 

See the attached schematic. The Rx pin is whichever digital input on the 
Arduino you are using. The two MIDI wires are pins 4 and 5 of a DIN-5 
connector. You must not connect the ground (shield or pin 2) from the MIDI 
cable. R2 and D1 are there to let you see the data as it arrives by flashing 
the LED, so they're not essential.

Martin

attachment: MIDI_IN.PNG___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] import and pduino

2007-09-24 Thread martin.peach
I've finally got a breadboarded atmega168 running the arduino bootloader and 
the pduino firmware 0.31. Running Pd version 0.40.3-extended-20070905 on WinXP, 
I get this in the pd main window:

[import] $Revision: 1.2 $
written by Hans-Christoph Steiner [EMAIL PROTECTED]
compiled on Sep  5 2007 at 06:05:46 
compiled against Pd version 0.40.3
libdir_loader: added hardware to the canvas-local path
[import] loaded library: hardware
libdir_loader: added flatspace to the canvas-local path
[import] loaded library: flatspace
libdir_loader: added iemlib to the canvas-local path
[import] loaded library: iemlib
libdir_loader: added mapping to the canvas-local path
[import] loaded library: mapping
 bytemask -
... couldn't create
 bytemask -
... couldn't create
 comport $1 57600
... couldn't create
[arduino]: version_0.3


Mainly the problem is one I always get with [import]: it doesn't work. 
[comport] is in flatspace but pd can't find it unless I rename it 
[flatspace/comport]. Am I doing something wrong here?

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] [; pd init(

2007-09-20 Thread martin.peach
 Steffen wrote:
 On 18/09/2007, at 19.34, Frank Barknecht wrote:
 
  [; pd init( crashes Pd here (Linux),
 
 Thanks for testing.
 
  so it's clearly a bug somewhere.
  Or rather here, according to gdb:
 
  #38 0xb7d0b161 in vsnprintf () from /lib/tls/libc.so.6
 
 Woo. That's all double dutch to me - or rather an argot i don't know.

It means basically that pd crashed in the function vsnprintf, which is in libc. 
libc probably isn't buggy though, it's more likely that the parameters passed 
by pd were not good. Looking in the pd source code shows that vsnprintf is 
called in the function sys_vgui in the file s_inter.c (and also in s_print.c, 
but that's probably not relevant here). Now someone needs to check the calling 
parameters... 

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] inconsistencies with lib names (was: representning classes

2007-09-18 Thread martin.peach
Frank Barknecht wrote:
 Hallo,
 [EMAIL PROTECTED] hat gesagt: // [EMAIL PROTECTED] wrote:
 
  I think it would be more useful right now if pd would search in
  subdirectories. For instance there are about 70 directories in
  pd/extra (Pd version 0.40.3-extended-20070905), and only 10 lines in
  the path dialog...not to mention the time wasted typing in every
  single path. At the moment most of the help files are not found and
  the objects don't work unless they are prefixed with their path,
  like [mrpeach/oscsend].  It looks like the function do_open_via_path
  in s_path.c is the one to fix...
 
 This might break some stuff. For example I often use private
 subdirectories whose objects should *not* be available globally.

What if pd searched deeply only in the extra directory, then you could put 
private files elsewhere and they would not be found? The do_open_via_path 
function already treats 'extra' as a special case, only searching it after all 
else fails.

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] inconsistencies with lib names (was: representning classes

2007-09-18 Thread martin.peach
Frank Barknecht wrote:
 Hallo,
 Georg Holzmann hat gesagt: // Georg Holzmann wrote:
 
  As far as I undestood it the code of e.g. comport would go in this 
  standard lib (e.g. to hardware/comport) but should not duplicate the 
  code - instead the iem/comport code should be obsolete and now 
  maintained in hardware/comport.
 
 Yes, that would be the idea for binaries in the std-lib.
 
  But as the others convinced me at the pd conv I don't think that this 
  will happen soon (and soon in pd time means maybe 8-10 years ... ;)
 
 Depends on how you define this: I don't think that every external
 has to move over to stdlib immediately, if at all. comport would be a
 good example for an external that could stay outside the stdlib for
 the next 8-10 years without any bigger problems, as it is an object
 with a rather specific purpose. [drip] OTOH would be a candidate to
 take immediately. The old build-system by Guenther (flatspace in
 pd-extended) already showed the how the whole stdlib could be built as
 far as externals are concerned, and abstractions are dead easy to
 handle (as long as they are core-Pd-abstractions).

I think it would be more useful right now if pd would search in subdirectories. 
For instance there are about 70 directories in pd/extra (Pd version 
0.40.3-extended-20070905), and only 10 lines in the path dialog...not to 
mention the time wasted typing in every single path. At the moment most of the 
help files are not found and the objects don't work unless they are prefixed 
with their path, like [mrpeach/oscsend].
It looks like the function do_open_via_path in s_path.c is the one to fix...

Martin


Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] inconsistencies with lib names (was: representning classes

2007-09-18 Thread martin.peach
Frank Barknecht wrote:
 Date: 2007/09/18 Tue PM 04:51:57 EDT
 To: pd-list@iem.at
 Subject: Re: [PD] inconsistencies with lib names (was: representning classes
 
 Hallo,
 Thomas O Fredericks hat gesagt: // Thomas O Fredericks wrote:
 
  It looks like the function do_open_via_path in s_path.c is the one to
  fix...
  
  Wow, talk about solving a big problem with the most simple solution!
  If this were implemented (and that could be done in one day instead of
  years), 
 
 If it was implemented, which one would become [once]: 
 
 extra/purepd/once.pd
 extra/iemabs/once.pd
 extra/pdmtl/flow/once.pd
 
 or maybe:
 
 extra/iem/spatialization/VARESE/app/iemabs/once.pd
 extra/CUBEmixer/lib/libs/iemabs/once.pd
 

The first one found would be the right one. It's not pd's problem if there 
exist more than one file with the same name. Surely that's up to the creators 
of the files to sort out. The alternative of using paths for each and every 
object is a massive kludge that's going to fall on your head and crush you 
sooner or later, at least I can already feel it pushing me into the mud :(
[possibly/the/worst/idea/ever/invented/once]


Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] object or class in pdpedia

2007-09-12 Thread martin.peach
Class is what pd calls objects internally.
For example here is the setup routine for the unpackOSC object:

void unpackOSC_setup(void)
{
unpackOSC_class = class_new(gensym(unpackOSC),
(t_newmethod)unpackOSC_new, (t_method)unpackOSC_free,
sizeof(t_unpackOSC), 0, 0);
class_addlist(unpackOSC_class, (t_method)unpackOSC_list);
}

I think of the ideal thing as a 'class' and its instances in a patch as 
'objects'. The object receives 'messages' that the class handles using 
'methods'.

Martin

 marius schebella wrote:
 as hans already knew, I disagree. I have not heard the term class 
 before. I think the term class is really not in use by pd users.
 what you (hans) call a class is called an object by everybody else...
 [class]  -- that is not a class, it is an object.
 [message( -- and that is a message.
 when we are talking about dac~, then we are talking about the object 
 dac~, even if it is not the technically correct term (I learned now: it 
 is a class, until you make an instance of the class, that is called 
 object) but that is confusing. please use object!
 
 marius.
 
 Hans-Christoph Steiner wrote:
  
  Marius and I are sitting here arguing over whether we should use the 
  term class or object in the pdpedia as the standard term for 
  differentiation, e.g. bang (class) vs. bang (selector).
  
  I think the current usage of the term object in Pd has two meanings: 
  an instance of a class, and the class itself.  I think we should 
  distinguish between these two in the pd wiki, and the word class is 
  quite well established for that.
  
  Yes, that means some education for some users, but that's a big part of 
  the pdpedia mission.
  
  That's my take, Marius will now disagree.  :D
  
  .hc
  
  
  
   
  
  
  Man has survived hitherto because he was too ignorant to know how to 
  realize his wishes.  Now that he can realize them, he must either change 
  them, or perish.-William Carlos Williams
  
  
  
 
 
 ___
 PD-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] writing soundfiles (was Re: (no subject))

2007-09-11 Thread martin.peach
Batuhan Bozkurt wrote:
  David Schaffer wrote:
  Hello,
Does anyone know the size limit of a 44.1k stereo wav file that 
  soundfiler can handle? So far, I haven't been able to write more than 
  36562276 samples to a table (which represents 829 seconds of sound if I 
  get it right). What can I do in order to be able to read larger files? 

 You should be able to load fairly large files to tables with the -resize 
 option combined with -maxsize option. But there is obviously a limit. I 
 remember being able to load more than 1 hours of 441.k mono files 
 through soundfiler.
 
 So sending
 [read -resize -maxsize  soundfile.wav(
 
 to soundfiler object should work. obviously there is a limit to that 
 maxsize sample length, and I'm not really sure about the number(and what 
 limits it), but this limit may have something to do with your memory 
 limits set in /etc/security/limits.conf if you are on linux but its just 
 a guess.

16777215 ,aka (2^24) - 1, is the last sequential integer that can be accurately 
represented by a 32-bit float, the kind used in pd, so the  in the 
message, which pd processes as a 32-bit float, would probably end up as another 
value. (Some larger integers can be accurately represented but they are 
separated by increasingly large runs of unrepresentable integers).
Perhaps you could split the file into several smaller tables?

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] compiling iemmatrix for mactel

2007-09-11 Thread martin.peach
punchik punchik wrote:
 hi, i got the iemmatrix sources from cvs
 
 im following iohanes advice for compiling using cd
 iemmatrix/src/  autoconf  ./configure  make
 
 but when i do make i get this:
 
 chikuns-computer:~/externals/iem/iemmatrix/src root#
 make
 In file included from iemmatrix.c:14:
 iemmatrix.h:54:18: error: m_pd.h: No such file or
 directory
 make: *** [iemmatrix.d] Error 1
 
 
 do anybody have whats is going wrong here?

Well yes, the compiler can't find m_pd.h. Normally it would be in pd/src next 
to externals/. If not you need to edit the makefile to match the actual path 
(look for -I../pd/src or something like that).

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] my first external

2007-09-04 Thread martin.peach
Atte André Jensen wrote:
 I took the code found here
http://iem.kug.ac.at/pd/externals-HOWTO/node3.html#SECTION00036000
 placed it in a file helloworld.c, but got:
 
 [EMAIL PROTECTED]:~/music/synth/pd/externals/atte$ gcc helloworld.c
 /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/crt1.o: In function 
 `_start':
 ../sysdeps/i386/elf/start.S:115: undefined reference to `main'

Because you need to tell gcc to build a dynamic library instead of a standalone:
Add -export_dynamic and -shared to the command line
Also add -ohelloworld.pd_linux to get the correct output file name.
 
 /tmp/ccuN3zCm.o: In function `helloworld_bang':
 helloworld.c:(.text+0xe): undefined reference to `post'

You need to #include m_pd.h in the source file.
If you have #include m_pd.h then m_pd.h has to be in the same directory as 
the source file.

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] OSC bundles with time tag

2007-08-30 Thread martin.peach
Stephen Sinclair wrote:
 I suggest you have a look at the OSC objects in the mrpeach
 folder, as I think they have better support for timetags among other
 things.

Yes, look at routeOSC-help and packOSC-help to see how it's done. You'll need a 
recent version, it's only 6 weeks old...

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] counter question

2007-07-26 Thread martin.peach
Derek Holzer wrote:
 If I use a simple counter structure that continues to generate a number 
 from [f]  [+1] at every bang, and use [mod] to keep that number within 
 certain bounds, then eventually it will require more and more memory to 
 hold the number coming from [f], right? Is this a potential memory leak, 
 or is there a cap to how much memory it will hold?

A float always uses 4 bytes. When the number gets too big, mod won't work 
properly because the number it's working on won't be accurate. It won't ever 
use any more memory.
But if you use the output of [mod] to reset the float, it will never be a 
problem because the float will never get larger than the output of [mod].


Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] netsendnetreceive from Pd to Max

2007-07-26 Thread martin.peach
I just tried netsend-help.pd on linux: it disconnects after you send exactly 
two messages to foo if there is no receiver, on localhost or anywhere else. 
Something is wrong here, using UDP it should not care if its messages are 
received or not.

Martin

  but if I try to send data from pd to max I always get the following message:
  
  connecting to port 1
   
  error : netsend : not connected
  



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Sending Data form Max/Msp to PD via upd

2007-07-04 Thread martin.peach
It should be spelled udpreceive, udp for User Datagram Protocol and i 
before e except after c, the rule for strange english spellings.

Martin

alexandre r. decoupigny wrote:
 
 thanks martin .. tried it ...little joy ..i have to fix it first..
 one more question though.. are you sure the [mrpeach/updrecieve] is included
 in the mac osx version.. or does it need the GEM library ? apart from the
 gem library, pd loads all the included
 libraries on this machine. But it wont create a [mrpeach/updrecieve]
 object.. any clue to what
 is wrong here would be magnificient..



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] OSC between win and mac

2007-06-18 Thread martin.peach
 Frank Barknecht wrote:
 
 Hallo,
 Johannes Krause hat gesagt: // Johannes Krause wrote:
 
  i send OSC messages from a windows computer
  (running eyecon) to a mac (running pd). 
  
  
  when i am using:
  
  
  dumpOSC 7000
   I
   I
  OSCroute /Poly1 /Poly2 /Poly3
   I
  
  there is no output in the atomboxes.
  
   
  how to receive OSC messages in pd?
  
  where i have to specify the ip?
 
 You have to specify it in the connect message you give [sendOSC].
 It's the same as with [netsend].
 

If you're receiving you don't specify the ip, only the port. The sender 
specifies both the ip and port. 
Be sure that both machines are set up to pass udp packets on port 7000.

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Opencv pd

2007-05-30 Thread martin.peach
IOhannes m zmoelnig wrote:

 i thought that you should integrate your openCV objects into Gem and not
 brew your own objects.

I too would like to make some objects in Gem. I have already done some  openGL 
externals for max/msp (see lifeGL and lifeTorus at 
http://www.billvorn.concordia.ca/menuall.html)
and would like to port them to pd. It seems the alternatives are to set a 
tcl/tk drawable as openGL, or Gem. Is there any documentation about the Gem API 
or is it all in the Gem source?

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] opencv motion tracker external HELP!

2007-05-30 Thread martin.peach
Alain wrote:
  void window_getframe(t_window *x, t_symbol *sym)
 {
   char* decode;
   char symstr;
   x-sym-s_name = decode;
   symstr = atol(decode);
   frame = symstr;
 }
Is this the receiving function? I would write it more like:

void window_getframe(t_window *x, t_symbol *sym)
{
IplImage * frame;

frame = (IplImage *)atol(sym-s_name);
}

Martin 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] opencv motion tracker external HELP!

2007-05-29 Thread martin.peach
 I dont think I quite understood.  I tried:
 
 #define FRAMEOUT frame
 
 IplImage *frame = 0;
 
 x-x_outlet = outlet_new(x-x_obj, s_anything);
 outlet_anything(x-x_outlet, FRAMEOUT);
 
 with the same results.  Maybe someone can dumb it down for me?

You can only work with atoms in pd's message system, and each atom usually 
contains a bang, a float or a symbol. You could convert the pointer to a float 
but it probably won't work because the pointer is a large integer that won't be 
accurately represented as a float. You could convert the pointer to a symbol 
using something like: 
char symstr[10];
t_symbol sym;
sprintf(symstr, %p, frame);
sym = gensym(symstr);
...then send sym through the outlet and convert it back to a pointer at the 
receiving end by extracting the string from the s_name field of the symbol and 
passing it to atol().

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] opencv motion tracker external HELP!

2007-05-29 Thread martin.peach
Alain wrote:
 I am getting a weird error when I try sym = gensym(symstr);  I get
 no match for 'operator=' in 'sym = gensym(((char*)( symstr)))'
 I dont know what thats all about.  I have seen this used before with no 
 problems.

That looks like a c++ error to me, maybe you should be compiling it as c?

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] accuracy of signal/message-objects

2007-05-07 Thread martin.peach
 
 marius schebella wrote:
 2) Is it possible to get microsecond accuracy in metro?
 the difference between metro 200 and 200.5 would be one beat per minute. 
 for synchronizing a big difference.
 marius.

[metro] is very accurate over time, it just has a jitter as the bangs have to 
happen in between sample blocks, but if you measure over say one hour the 
timing is very accurate. I can run a hydrogen drum pattern with a pd midi patch 
both running at the same tempo and they stay in sync all day long, (or until 
hydrogen crashes because of its outrageously photorealist gui...I generally run 
with all windows minimized.)

Martin
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] accuracy of signal/message-objects

2007-05-07 Thread martin.peach
 Frank Barknecht wrote:
 I think, it's comport's fault: [metro] generates clock-delayed
 messages. These are like messages tagged with a time-stamp referring
 to Pd's internal clock. However an object needs to actually use the
 time-stamps and look at the clock to see what time it is. Objects
 like [vline~] or [delay] do this, but comport doesn't.

Well that's interesting! How does one access these timestamps? I thought a bang 
has no associated info. Or are you referring to a [metro~]?

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Arduino stuff

2007-04-16 Thread martin.peach
marius schebella wrote:
 Tim Boykett wrote:
- is there a Max version of the Pduino interface stuff? 
 
 yes, have a look at
 http://www.parasitaere-kapazitaeten.net/max_msp/pduino_for_max
 it is still beta (serial object is not working properly under windows.)

There's an interim update of serial here, it's much faster:

http://www.cycling74.com/twiki/pub/IncrementalDownloads/WebHome/serial061002W.zip

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] apt get for abstractions

2007-04-04 Thread martin.peach
Alexandre Quessy said:
 
 Hi,
 
 2007/4/1, Hans-Christoph Steiner [EMAIL PROTECTED]:
  Maybe the curl thing would be possible using Martin Peach's tcp objects?
 
  .hc
 
 Does it allow one to dowload binary data and save it as files ?

In combination with the [str] objects, yes.
They can send files as-is up to BYTE_BUF_LEN, which you could try changing if 
the files are longer than 64kB.
What does the curl thing do?

Martin


 If
 not, it wouldn't be that hard to make it possible. A system package
 ala netpd would be great.
 
 The http://wiki.dataflow.ws/PdMtlAbstractions is a proposal of a
 http://pear.php.net/ -like packages structure for pd.
 
 
 a
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] boids2d, boids3d

2007-03-31 Thread martin.peach
 I suppose the code was taken from a max object. the problem I saw was, 
 that when you send a message like maxspeed 10 and then dumped the 
 current values, it showed up as maxspeed 1.#inf.
 so that's what I meant with messages get screwed somehow. and I thought 
 that could be a float/int conversion/not conversion problem...

Oh yes, I see what you mean. All the message functions are expecting doubles 
and pd is sending them floats, because pd, unlike max, doesn't use doubles in 
messages. I guess I (or someone) will have to change all the doubles to floats 
in the code.

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] boids2d, boids3d

2007-03-31 Thread martin.peach
 Do the points have an orientation? Some things
 sound different depending on the direction they're
 facing.
 

Each boid has a velocity in 2 or 3 dimensions, so yes.
I just compiled the 2d version on WinXP, compiler complained about the line 
endings being Macintosh. I reformatted the file according to the pd guidlines 
using Unix line endings and spaces for tabs and c-style comments. I could 
commit my changes if nobody complains...I don't see in the source code that the 
messages aren't working. It may be the way they are implemented in the help 
file, they seem to be prefixed with semicolons there?

Martin

 
 
 
 On Fri, 30 Mar 2007 10:19:25 -0400
 marius schebella [EMAIL PROTECTED] wrote:
 
  short answer: you send position messages of an attraction point in space 
  and then your boids object prints out positions of x flocks everytime 
  you bang it. the positions are affected by the attraction point and 
  neighboring flocks. (there is a bunch of settings for all that)
  marius.
  
  padawan12 wrote:
   I'm interested in these. How do they work?
   
   
   On Fri, 30 Mar 2007 02:00:52 -0400
   marius schebella [EMAIL PROTECTED] wrote:
   
   hi,
   accidentally I found two objects (boids2d and boids3d) which could be 
   very nice tools, if only they were working.
   I have no idea who ported them to pd, but message input seems to be 
   broken. Is someone working on them?
   (the objects simulate animal/birds and could be useful for grain 
   synthesis or multi voice synthesis stuff)
   marius.
  
   ___
   PD-list@iem.at mailing list
   UNSUBSCRIBE and account-management - 
   http://lists.puredata.info/listinfo/pd-list
   
   ___
   PD-list@iem.at mailing list
   UNSUBSCRIBE and account-management - 
   http://lists.puredata.info/listinfo/pd-list
   
  
 
 


killerbees.pd
Description: Binary data
___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list

___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Getting (not pure) data over the internet

2007-03-22 Thread martin.peach
You could try [tcpclient]. You would need to convert the request into a series 
of ASCII numbers and similarly with the replies.
It's in cvs at /externals/mrpeach/net.

Martin


 
 De: Stuart Jones [EMAIL PROTECTED]
 Date: 2007/03/22 jeu. PM 03:00:25 EDT
 À: pd-list@iem.at
 Objet: [PD] Getting (not pure) data over the internet
 
 Hi
 
 Sorry to have sent this in HTML earlier, new to this and hit the send button
 to soon...
 
 I need to get data from a wireless sensor network to control Pd patches. The
 WSN feeds to a database on a server and I need to send queries over the
 internet to the data server in the form http://ip
 address/data/location/device/now (or when on a LAN: ip
 address/data/.../.../now). How do I send the query out of the Pd patch, and
 how do I get the resulting data back in? (The data comes in this form:
 2007-03-22 18:00:01,17,1,0, which is timestamp, device ID, data). I would
 automate the querying with [metro].
 [netsend] [comport] [netserver] don¹t seem to apply.
 
 BTW got good results using [comport] on site, picking up from arduinos
 sending via bluetooth. However, must be done via the server, as data is
 coming from arduinos, crossbow motes, and proprietary systems and anyway the
 arduino bluetooth is paired to the server.
 
 Thanks
 
 Stuart
 
 
 
 
 ___
 PD-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Binary - integer conversion

2007-03-16 Thread martin.peach
I'm working on coding all the useful CMOS 4000 series chips as pd objects. They 
all use 0 and 1 as inputs and outputs. They were used in some sequencers and 
synths in the 70s and 80s. I could add objects to convert from float(integer) 
to binary as a kind of interface to them.
I'll put them in cvs soon.

Martin

 
 From: David Powers [EMAIL PROTECTED]
 Date: 2007/03/16 Fri PM 01:44:54 EDT
 To: PD List pd-list@iem.at
 Subject: [PD] Binary - integer conversion
 
 Hello,
 
 Is it possible to somehow convert back and forth between integer and
 binary in PD?
 
 My idea, is to represent simple drum machine style rhythms as binary
 numbers. [101010001011]. Ok, so if this were a float, it would be
 trivial to do a common task and shift the rhythm left or right. I
 think, that other rhythmic variations would also be quite fast to
 implement using this system, you can do binary math instead of list
 operations which should be much faster, I assume.
 
 ~David
 
 ___
 PD-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] rfcomm and comport device list

2007-03-07 Thread martin.peach
gordo said
 
 hi all,
 
 i´m running pd 0.39-1 on 2.6.17-gentoo-r8 and reading data from an
 incoming bluetooth device via bluez´s rfcomm.
 
 after connecting:
 
 # rfcomm connect 1
 Connected /dev/rfcomm1 to 10:00:E8:52:32:CE on channel 1
 
 i can do:
 
 # cat /dev/rfcomm1
 
 which cats all my incoming data correctly, but if i´m printing
 device-list with comport-object, it pathetically outputs:
 [comport]: available serial ports:
 0 /dev/ttyS0

That's because it looks for anything like /dev/tty[SU]*.
Possibly if you open by name [open /dev/rfcomm1( it will work, if rfcomm1 is a 
serial port. Otherwise, it might not...

Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] hid compatibility

2007-02-13 Thread martin.peach
 [hid] and [hidio] get the data straight from the device, so you can  
 get data from multiple devices separately with no problem.  But the  
 OS also gets the data and uses it to move the mouse pointer.  I know  
 of no way to stop Windows from using a mouse's data from moving the  
 mouse.  In GNU/Linux/XWindows, it's pretty straightforward.

One way is to use a serial mouse and plug it in after Windows boots. Then the 
data can be captured by pd.

Martin
#N canvas 397 1 754 904 10;
#X msg 290 63 open 1;
#X text 333 63 Open serial port by number;
#X msg 331 125 verbose \$1;
#X obj 331 104 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0
1;
#X msg 79 223 info;
#X floatatom 275 308 7 0 0 1 baud - -;
#X floatatom 381 323 4 0 0 3 parity - -;
#X floatatom 417 312 4 0 0 2 stop - -;
#X floatatom 452 325 4 0 0 3 data - -;
#X obj 630 308 print;
#X floatatom 559 304 4 0 0 0 port - -;
#X obj 489 345 tgl 15 0 empty empty rts/cts -10 20 1 11 -262144 -1
-1 0 1;
#X obj 523 325 tgl 15 0 empty empty xon/xoff -14 20 1 11 -262144 -1
-1 0 1;
#X text 251 355 serial packet format:;
#X obj 310 331 tgl 15 0 empty empty dsr 0 20 1 11 -262144 -1 -1 0 1
;
#X obj 346 331 tgl 15 0 empty empty cts 0 20 1 11 -262144 -1 -1 0 1
;
#X obj 275 279 route baud dsr cts parity stop data rtscts xonxoff port
open;
#X obj 594 319 tgl 15 0 empty empty open -6 20 1 11 -262144 -1 -1 1
1;
#X obj 196 251 comport 1 1200;
#X msg 128 148 bits 7;
#X msg 111 181 dtr 1;
#X msg 95 205 rts 1;
#X obj 232 461 float;
#X obj 232 484 + 1;
#X msg 214 379 0;
#X obj 178 517 pack 1 2;
#X obj 214 329 = 64;
#X obj 214 353 sel 1;
#X obj 196 277 t f f;
#X obj 196 424 t b f;
#X text 237 518 index each byte in the 3- or 4-byte packet;
#X obj 178 551 route 0 1 2 3;
#X obj 82 606  32;
#X obj 81 873 tgl 15 0 empty empty left -34 7 0 10 -44926 -355 -355
0 32;
#X obj 111 606  32;
#X obj 110 873 tgl 15 0 empty empty middle -14 -10 0 10 -44926 -355
-355 0 32;
#X obj 140 606  16;
#X obj 139 873 tgl 15 0 empty empty right 17 7 0 10 -44926 -355 -355
0 16;
#X obj 169 606  12;
#X obj 209 606  3;
#X obj 169 629  4;
#X obj 209 628  6;
#X obj 196 673 +;
#X obj 283 674 +;
#X obj 221 727 = 128;
#X obj 221 748 sel 1;
#X msg 221 769 -256;
#X obj 196 793 +;
#X msg 252 769 0;
#X obj 196 706 t f f;
#X obj 308 728 = 128;
#X obj 308 749 sel 1;
#X msg 308 770 -256;
#X obj 283 795 +;
#X msg 339 770 0;
#X obj 283 707 t f f;
#X text 15 23 serial mouse interface;
#X obj 62 67 loadbang;
#X obj 79 109 t b b b b;
#X obj 236 832 float;
#X obj 196 832 +;
#X obj 236 805 t b f;
#X obj 323 832 float;
#X obj 283 832 +;
#X obj 323 805 t b f;
#X obj 236 874 nbx 5 14 -1e+037 1e+037 0 0 empty empty x 0 -8 0 10
-44926 -355 -355 0 256;
#X obj 323 874 nbx 5 14 -1e+037 1e+037 0 0 empty empty y 0 -8 0 10
-44926 -355 -355 0 256;
#X connect 0 0 18 0;
#X connect 2 0 18 0;
#X connect 3 0 2 0;
#X connect 4 0 18 0;
#X connect 16 0 5 0;
#X connect 16 1 14 0;
#X connect 16 2 15 0;
#X connect 16 3 6 0;
#X connect 16 4 7 0;
#X connect 16 5 8 0;
#X connect 16 6 11 0;
#X connect 16 7 12 0;
#X connect 16 8 10 0;
#X connect 16 9 17 0;
#X connect 16 10 9 0;
#X connect 18 0 28 0;
#X connect 18 1 16 0;
#X connect 19 0 18 0;
#X connect 20 0 18 0;
#X connect 21 0 18 0;
#X connect 22 0 23 0;
#X connect 22 0 25 0;
#X connect 23 0 22 1;
#X connect 24 0 22 1;
#X connect 25 0 31 0;
#X connect 26 0 27 0;
#X connect 27 0 24 0;
#X connect 28 0 29 0;
#X connect 28 1 26 0;
#X connect 29 0 22 0;
#X connect 29 1 25 1;
#X connect 31 0 32 0;
#X connect 31 0 36 0;
#X connect 31 0 38 0;
#X connect 31 0 39 0;
#X connect 31 1 42 0;
#X connect 31 2 43 0;
#X connect 31 3 34 0;
#X connect 32 0 33 0;
#X connect 34 0 35 0;
#X connect 36 0 37 0;
#X connect 38 0 40 0;
#X connect 39 0 41 0;
#X connect 40 0 43 1;
#X connect 41 0 42 1;
#X connect 42 0 49 0;
#X connect 43 0 55 0;
#X connect 44 0 45 0;
#X connect 45 0 46 0;
#X connect 45 1 48 0;
#X connect 46 0 47 1;
#X connect 47 0 60 0;
#X connect 48 0 47 1;
#X connect 49 0 47 0;
#X connect 49 1 44 0;
#X connect 50 0 51 0;
#X connect 51 0 52 0;
#X connect 51 1 54 0;
#X connect 52 0 53 1;
#X connect 53 0 63 0;
#X connect 54 0 53 1;
#X connect 55 0 53 0;
#X connect 55 1 50 0;
#X connect 57 0 58 0;
#X connect 58 0 4 0;
#X connect 58 1 21 0;
#X connect 58 2 20 0;
#X connect 58 3 19 0;
#X connect 59 0 60 1;
#X connect 59 0 65 0;
#X connect 60 0 61 0;
#X connect 61 0 59 0;
#X connect 61 1 59 1;
#X connect 62 0 63 1;
#X connect 62 0 66 0;
#X connect 63 0 64 0;
#X connect 64 0 62 0;
#X connect 64 1 62 1;

___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] general libdir question

2007-01-29 Thread martin.peach
 From: Georg Holzmann [EMAIL PROTECTED]
 Date: 2007/01/29 Mon PM 02:21:59 EST
 To: Hans-Christoph Steiner [EMAIL PROTECTED]
 CC: pd-list@iem.at
 Subject: Re: [PD] general libdir question
 The problem is, that canvas-local search path really tread each path as 
 local to the canvas-path ( see line 1561 in g_canvas.c).
 So if you add e.g. /usr/local/lib/pd/extra/iemmatrix, it will search for 
 this path, but local to the canvas path - so if I started Pd from 
 /home/me it will search in /home/me//usr/local/lib/pd/extra/iemmatrix !
 
 Is this a feature or a bug of Pd ?

I would say it's a bug: I would expect that if the first character of the path 
is a slash, it's an absolute address, otherwise it's relative to the canvas 
path. So /usr/local is absolute but usr/local is relative to the canvas 
path. In Windows there's also the problem of specifying drives as in C:/pd, 
so it's necessary to look for a letter followed by a colon followed by a slash 
in the first three characters of the path. And then there's double slashes for 
networked drives...

Martin


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] mr peach language...xmlsocket

2006-12-12 Thread martin.peach
Notice that [any2string] outputs a zero as the last element of a list of 
floats. The attached patch shows a way to replace the zero with the more usual 
carriage-return/line-feed combination.

Martin

 
 De: IOhannes m zmoelnig [EMAIL PROTECTED]
 Date: 2006/12/12 mar. AM 10:28:39 GMT-05:00
 À: Miguel Cardoso [EMAIL PROTECTED]
 Cc: pd-liste pd-list@iem.at,   [EMAIL PROTECTED]
 Objet: Re: [PD] mr peach language...xmlsocket
 
 Miguel Cardoso wrote:
  Hello!
  
  Im using mrpeach to send messages to flash, but all I can send is files...
  so comunication is working and just need to understand the language...
  
  [ send 21 /test.xml 0 ]
  I send to socket 21 the content of test.xml
  0 end the message (for flash) / the 0 byte flash needs
  
  How can I convert into bytes a message composed in pd, instead of
  loading a file?
 
 with [any2string].
 
 mfgasdr
 IOhannes
 


text_to_tcpclient.pd
Description: Binary data
___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] error compiling any2string

2006-12-12 Thread martin.peach
The errors are probably because you are not linking against pd.lib, which is 
where the undefined symbols are hiding.
Martin

 
 De: Miguel Cardoso [EMAIL PROTECTED]
 Date: 2006/12/12 mar. PM 03:36:28 GMT-05:00
 À: pd-liste pd-list@iem.at
 Objet: [PD] error compiling any2string
 
 I get this error compiling any2string.c
 
 does anyone have these moocow externals compiled for mac intel?
 
 thks list
 
 cc any2string.c   -o any2string
 /usr/bin/ld: Undefined symbols:
 _main
 _binbuf_add
 _binbuf_clear
 _binbuf_free
 _binbuf_gettext
 _binbuf_new
 _class_addanything
 _class_new
 _class_sethelpsymbol
 _freebytes
 _gensym
 _getbytes
 _outlet_free
 _outlet_list
 _outlet_new
 _pd_new
 _s_
 _s_float
 _s_list
 collect2: ld returned 1 exit status
 make: *** [any2string] Error 1
 
 
 ___
 PD-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] mr peach externals

2006-12-11 Thread martin.peach
You can get the latest source here:

http://pure-data.cvs.sourceforge.net/pure-data/externals/mrpeach/net/

It will probably be easier for you to compile your own than to wait for one to 
show up. 

Martin


 
 De: Miguel Cardoso [EMAIL PROTECTED]
 Date: 2006/12/11 lun. PM 02:07:57 GMT-05:00
 À: [EMAIL PROTECTED] [EMAIL PROTECTED]
 Cc: pd-liste pd-list@iem.at
 Objet: Re: [PD] mr peach externals
 
 Thanks Martin
 
 Sorry but I only found c and dll files...
 http://pure-data.iem.at/Members/martinrp/
 
 is there anywhere else where i can get the compiled files?
 I tried copying them from a recent pd autobuild... but pd wouldn't  
 recognize them...
 
 
 best
 miguel
 
 On Dec 11, 2006, at 6:32 PM, [EMAIL PROTECTED]  
 [EMAIL PROTECTED] wrote:
 
  I always just add them individually to the extra folder and call  
  them by name, e.g. [tcpclient]. I don't know if there is such a  
  thing as a mrpeach lib. They should all work on intel macs if they  
  were compiled for that platform. I've only tried them on WinXP and  
  linux.
 
  Martin
 
 
 
  De: Miguel Cardoso [EMAIL PROTECTED]
  Date: 2006/12/11 lun. AM 11:57:30 GMT-05:00
  À: pd-liste pd-list@iem.at
  Objet: [PD] mr peach externals
 
  hi list
 
  how can I install mrpeach externals in pure data?
 
  Im currently using the version Steffen linked for  MacIntel:
  http://puredata.info/Members/stffn/Pd-0.39.2-extended-2006-10-31-
  macosx104-i386.dmg
 
  the latest autobuild versions have mr peach but It appears they
  aren't running on some intel machines owned by newbies :)
 
  thanks
  m
 
  ___
  PD-list@iem.at mailing list
  UNSUBSCRIBE and account-management - http://lists.puredata.info/ 
  listinfo/pd-list
 
 
 
 


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] DOS prompt

2006-11-27 Thread martin.peach

 
 From: derek holzer [EMAIL PROTECTED]
 Date: 2006/11/27 Mon PM 05:17:41 EST
 To: Hans-Christoph Steiner [EMAIL PROTECTED]
 CC: pd-list@iem.at
 Subject: Re: [PD] DOS prompt
 
 Hi HC,
 
 Thanks for this:
 
 Hans-Christoph Steiner wrote:
 
  Pd-extended and Pd vanilla are installed into %PROGRAMFILES%\pd\bin\pd.exe.
  
  %PROGRAMFILES is a environment variable that varies depending on the 
  language of the install.  Some possibilties:
  
  C:\Program Files
 
 Is there an escape character possible here?
 
 As in C:\Program/ Files\pd\bin\pd.exe? I remember this space was a 
 problem when I was trying this on Windows long ago.

It shouldn't be a problem on recent Windows. You can always put the whole path 
in quotes, like C:\Program Files, to make sure. If I type:
echo %PROGRAMFILES%
 in a command prompt it gives me this:
C:\Program Files


Martin



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] Pure coherent noise (Perlin noise)

2006-11-14 Thread martin.peach
I attached the patch this time for sure...

Martin

 
 From: Steffen [EMAIL PROTECTED]
 Date: 2006/11/14 Tue PM 01:05:01 EST
 To: [EMAIL PROTECTED] [EMAIL PROTECTED]
 Subject: Re: [PD] Pure coherent noise (Perlin noise)
 
 Hey Martin
 
 On 14/11/2006, at 18.16, [EMAIL PROTECTED]  
 [EMAIL PROTECTED] wrote:
 
  See the attached patch
 
 I think you forgot to attache it. Hope you'll post it. Thanks,
 
 Steffen
 
#N canvas 511 103 718 809 12;
#X obj 65 81 noise~;
#X obj 64 156 *~ 1;
#X obj 140 -9 vsl 15 128 0.01 100 1 1 empty empty empty 0 -9 0 10 -258699
-1 -1 11900 0;
#X obj 65 116 lop~ 1;
#X obj 165 81 noise~;
#X obj 164 156 *~ 1;
#X obj 240 -9 vsl 15 128 0.01 10 1 1 empty empty empty 0 -9 0 10 -260818
-1 -1 0 0;
#X obj 262 81 noise~;
#X obj 261 156 *~ 1;
#X obj 337 -9 vsl 15 128 0.01 10 1 1 empty empty empty 0 -9 0 10 -241291
-1 -1 0 0;
#X obj 165 116 lop~ 10;
#X obj 262 116 lop~ 100;
#X obj 146 346 dac~;
#X obj 144 192 +~;
#X obj 144 224 +~;
#X obj 15 372 table snd;
#X obj 181 346 tabwrite~ snd;
#X obj 211 320 metro 100;
#X obj 211 297 tgl 15 1 empty empty graph 17 7 0 10 -250685 -262144
-250685 1 1;
#X obj 378 81 noise~;
#X obj 377 156 *~ 1;
#X obj 453 -9 vsl 15 128 0.01 10 1 1 empty empty empty 0 -9 0 10 -24198
-1 -1 0 0;
#X obj 378 116 lop~ 1000;
#X obj 144 259 +~;
#X obj 496 81 noise~;
#X obj 495 156 *~ 1;
#X obj 580 -9 vsl 15 128 0.01 1 1 1 empty empty empty 0 -9 0 10 -44926
-1 -1 0 0;
#X obj 496 116 lop~ 1;
#X obj 145 298 +~;
#X connect 0 0 3 0;
#X connect 1 0 13 0;
#X connect 2 0 1 1;
#X connect 3 0 1 0;
#X connect 4 0 10 0;
#X connect 5 0 13 1;
#X connect 6 0 5 1;
#X connect 7 0 11 0;
#X connect 8 0 14 1;
#X connect 9 0 8 1;
#X connect 10 0 5 0;
#X connect 11 0 8 0;
#X connect 13 0 14 0;
#X connect 14 0 23 0;
#X connect 17 0 16 0;
#X connect 18 0 17 0;
#X connect 19 0 22 0;
#X connect 20 0 23 1;
#X connect 21 0 20 1;
#X connect 22 0 20 0;
#X connect 23 0 28 0;
#X connect 24 0 27 0;
#X connect 25 0 28 1;
#X connect 26 0 25 1;
#X connect 27 0 25 0;
#X connect 28 0 12 0;
#X connect 28 0 12 1;
#X connect 28 0 16 0;

___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] arduino-test port under linux

2006-11-09 Thread martin.peach
Where can I get the last [comport] source?

From 
http://pure-data.cvs.sourceforge.net/pure-data/externals/iem/comport/comport/

Martin

___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list

___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: Re: [PD] Per sampleblock manipulation question

2006-11-06 Thread martin.peach
I attach a version of lrshift~.c and the new help file. It now accepts floats 
to change the shift amount. Maybe you could check to see if it works well. I 
guess I could commit it to cvs if approved.
Martin


 
 From: Charles Henry [EMAIL PROTECTED]
 Date: 2006/11/06 Mon AM 11:24:26 EST
 To: pd-list@iem.at
 Subject: Re: [PD] Per sampleblock manipulation question
 
 lrshift~ needs to have a second inlet, or a float method to change the 
 argument
 (grumblegripemoan) :P
 
 I'd volunteer to add it, but what would the procedure be like for that?
 Chuck
 
 On 11/6/06, Mathieu Bouchard [EMAIL PROTECTED] wrote:
  On Sun, 5 Nov 2006, thewade wrote:
   Quoting Mathieu Bouchard [EMAIL PROTECTED]:
   I will poke around in the help files to see if I can find the
   incorrectly-named help for this object, to see what the related objects 
   are.
 
  It's just named rlshift~ instead. Else it should work fine (unless you
  have additional -path -helppath required, which may happen on some setups)
 
   no, convolution is a bunch of sample-wise shifts and [*~] and [+~]
   together (as many as there are values in the convolution kernel).
 
   Yes, but conceptually convolution is converting time domain sounds into
   frequency domain, storing the values in a sample block, and multiplying
   the two blocks together (and normalizing of course).
 
  Convolution can be defined in two completely equivalent ways: one as
  polynomial product in the time domain (using a z-series representation)
  and one as the complex multiplication of two frequency spectra using an
  infinite blocksize.
 
  Almost all of the time, the time-domain representation is taught first.
  This might be especially important as the frequency-domain only becomes
  tangible once some kind of Fourier transform is in place, and the
  polynomial product is certainly easier to explain than the Fourier
  transform. (and that's even more true for realtime)
 
  But if you want to apply convolutions with large kernels and/or large
  pieces of data, you really have to use [fft~] (for sound) or [#fft] (for
  spatial-frequencies of images).
 
   So if one block has no sound at 300Hz and the other block does, the
   resulting block does NOT have sound at 300Hz, right?
 
  Right.
 
   So if your block size was four and you had one FFT block that was:
   0,1,0,1 And another that was: 0,0,0,1 The convolved real sound block
   (before going to ifft~) would be 0,0,0,1 Right?
 
  Yes, supposing each of those values is a complex number. But that's
  because AND is a special case of multiplication, because:
 
  0*0 = 0
  0*1 = 0
  1*0 = 0
  1*1 = 1
 
  so * over {0,1} is exactly AND.
 
_ _ __ ___ _  _ _ ...
  | Mathieu Bouchard - tél:+1.514.383.3801 - http://artengine.ca/matju
  | Freelance Digital Arts Engineer, Montréal QC Canada
 
  ___
  PD-list@iem.at mailing list
  UNSUBSCRIBE and account-management - 
  http://lists.puredata.info/listinfo/pd-list
 
 
 
 
 ___
 PD-list@iem.at mailing list
 UNSUBSCRIBE and account-management - 
 http://lists.puredata.info/listinfo/pd-list
 
#include m_pd.h

/*  lrshift~ - */

static t_class *lrshift_tilde_class;

typedef struct _lrshift_tilde
{
t_object x_obj;
int x_n;
} t_lrshift_tilde;

static t_int *leftshift_perform(t_int *w)
{
t_float *in = (t_float *)(w[1]);
t_float *out= (t_float *)(w[2]);
int n = (int)(w[3]);
int shift = (int)(w[4]);
in += shift;
n -= shift;
while (n--)
*out++ = *in++;
while (shift--)
*out++ = 0;
return (w+5);
}

static t_int *rightshift_perform(t_int *w)
{
t_float *in = (t_float *)(w[1]);
t_float *out= (t_float *)(w[2]);
int n = (int)(w[3]);
int shift = (int)(w[4]);
n -= shift;
in -= shift;
while (n--)
*--out = *--in;
while (shift--)
*--out = 0;
return (w+5);
}

static t_int *lrshift_perform(t_int *w)
{
t_float *in = (t_float *)(w[1]);
t_float *out= (t_float *)(w[2]);
int n = (int)(w[3]);
t_lrshift_tilde *x = (t_lrshift_tilde *)w[4];
int shift = x-x_n;

if (shift  n)
shift = n;
if (shift  -n)
shift = -n;
if (shift  0)
{
shift = -shift;
out += n;
in += n;
n -= shift;
in -= shift;
while (n--)
*--out = *--in;
while (shift--)
*--out = 0;
}
else
{
in += shift;
n -= shift;
while (n--)
*out++ = *in++;
while (shift--)
*out++ = 0;
}
return (w+5);
}

static void lrshift_tilde_dsp(t_lrshift_tilde *x, t_signal **sp)
{
int n = sp[0]-s_n;
dsp_add(lrshift_perform, 4, sp[0]-s_vec, sp[1]-s_vec, n,