Hello,
A few weeks ago I was reminded of my promise to share [soundtouch~], a
SoundTouch port for Pure Data. I use this class since quite some time now,
and had the code available on my website earlier on, but when I found that
it could not work for Linux 64 bit I withdrew the project for a while.
Reportedly, Olli Parviainen's newest version of SoundTouch is ready for 64
bit. I can not check this as I have no access to a 64 bit machine at the
moment. Anyway, I have built [soundtouch~] binaries for OSX(fat), Linux32
and Windows32, and uploaded it together with source and help patch:
http://www.katjaas.nl/pitchshift/soundtouch~.html
SoundTouch is a time domain pitch shift / time stretch library, and I've
built it into [soundtouch~] as a real time pitch shifter. It is suitable for
the transposition of material with simple harmonic content, like voice,
flute etc. The SoundTouch library is not perfectly adapted to real time
processing, because you have to choose (at compile time!) between a build
which produces dropouts during pitch factor change, and a build which has
increased latency. I opted for the clicks instead of the increased latency
(which is by necessity already considerable) in my binaries distribution,
but if you want you can recompile according to your preference. To solve
this clicks-vs-latency issue, if possible at all, would require a
modification of the SoundTouch library itself.
Apart from this issue, I'm fairly content with [soundtouch~]. Let me know
what you think about it. If [soundtouch~] is considered a useful addition to
existing Pd methods for pitch shifting, it may be worth the effort to try
and solve the clicks-vs-latency issue. It is not a trivial task though.This
time I'm not promising anything.
Katja.
Hi Ingo
Thanks for testing!
On Thu, 2011-09-15 at 05:23 +0200, Ingo wrote:
> Hi Roman,
>
> the new version works great!
I'm glad to hear that.
> I made myself some testing objects around it.
> Maybe that could be useful if you guys ever get around fixing the help
> patch.
I'll have a look. Thanks.
> I still think the version using individual debyte masks is far more
> efficient than this one. But as you pointed out this one is more scalable
> and might take care of boards coming in the future (I have just seen a mega
> clone with 70 or 72 digital inputs).
>
> Most people don't use incremental wheels timed to 1-2 ms - like I do -
> anyway. So efficiency shouldn't matter in 99.9% of the cases.
I generally think it does matter. However, i don't have any concerns
that the additional table look up causes an efficiency problem. Table
lookups are usually very fast.
It's probably a matter of taste, but I often find myself looking for an
'algorithmic' solution instead of copying very similar code several
times around, even if the former is a bit less efficient than the
latter.
In this case, if using several [pd debytemask], it'd be nice to use an
abstraction instead. However, if the original [mapping/debytemask] would
be used, every (-1) instance would require a row of 8 [+ 8] objects, [+
16], [+ 24], etc. respectively. So it would either end up with a lot of
additional objects below all [debytemask] instances or multiple manually
crafted [pd debytemask] with each containing slightly different code (as
you implemented it) would be required.
The additional [pd polychange] with table lookup is made of just a
handful of objects.
However, if it ever turns out, that in your setup the [arduino]
abstraction eats a significant amount of CPU power (what I really
doubt), I'll happily replace it by your version of [pd digital messages]
if it helps.
And yes, the goal should be to cover also 'edge' cases like your
incremental wheel. The more use cases work well with Firmata / [arduino]
the better.
Roman
>
> > -----Ursprüngliche Nachricht-----
> > Von: pd-list-bounces(a)iem.at [mailto:pd-list-bounces@iem.at] Im Auftrag von
> > Hans-Christoph Steiner
> > Gesendet: Mittwoch, 14. September 2011 22:33
> > An: Roman Haefeli
> > Cc: pd-list(a)iem.at
> > Betreff: Re: [PD] pduino rewrite
> >
> >
> > As Ingo pointed out, one bug is that [mapping/debytemask] has the
> > [change] object for each outlet. So probably the way to fix this is to
> > make a bunch of [mapping/debytemask] objects for all the possible
> > digital ports.
> >
> > [arduino] should only output on change of digital input, and it receives
> > the digital information one byte/port at a time, i.e. 8 pins. Another
> > approach would be to have an array of all of the previous values which
> > are then compared to the current before outputting.
> >
> > .hc
> >
> >
> > On Wed, 2011-09-14 at 11:24 +0200, Roman Haefeli wrote:
> > > Hi Ingo
> > >
> > > Thanks for all your reports.
> > >
> > > Sorry that my replies sometimes only come a few days later. I'm still
> > > willing to fix any outstanding issues, but not very often I find time to
> > > get an arduino into my hands. Since sometimes I have troubles following
> > > you and keeping your several bug reports apart from each other, I'd
> > > suggest to stick with [arduino] bugs and let the documentation aspect
> > > aside for a while.
> > >
> > > I _think_ I finally understand your problem with the digital ins. I
> > > can't currently test or reproduce the problem, since I don't have an
> > > arduino at hand, but from reading the code, I think I see what could go
> > > wrong.
> > >
> > > On certain incoming commands of [pd digital messages], the [pd
> > > debytemask] *) subpatch generates more than one message, but only the
> > > last one is finally sent to the outlet, because it only fires, when the
> > > left inlet of [+ ] is triggered, which is under all circumstances only
> > > triggered once after all the [pd debytemask] messages have fired.
> > > Actually, the order should be inversed, so that all messages from [pd
> > > debytemask] go the _left_ inlet of [+ ], and the summand is sent the
> > > _right_ inlet before. This is what I did in the patch you find
> > > attached.
> > >
> > > I rather have my version going into [arduino], since it is much less
> > > code than yours. From what I can tell, they both produce similar output,
> > > but as I said, I haven't had the chance to test it in real-world
> > > circumstances with a real arduino. So, please test and report back.
> > >
> > > I guess the main reason nobody (including me) has noticed this bug yet,
> > > is that you won't trigger it, if you only test one digital in at once.
> > > Changing the state of only one input at a time makes it seem, that all
> > > inputs work correctly. Only when changing states of several inputs at
> > > the same time, you will receive only a single digital messages, which is
> > > obviously wrong.
> > >
> > > I'm happy now that you kept bugging about this. It took me a while to
> > > (hopefully) understand the problem. Thanks for your persistence.
> > >
> > > *) There is no [debytemask] abstraction anymore in the git version of
> > > [arduino]. I replaced it by a subpatch.
> > >
> > > Roman
> > >
> > >
> > > On Sun, 2011-09-11 at 06:20 +0200, Ingo wrote:
> > > > There is another thing that I just noticed about the pduino test-
> > patch.
> > > >
> > > > The mode buttons are suggesting that you can turn of all functions by
> > > > selecting "NONE". This is not true! These buttons have absolutely NO
> > > > function and should be replaced with the correct commands.
> > > > While doing this the option "Input-PullUp" should be added.
> > > >
> > > > The Arduino generally defaults to input. Selecting "NONE" at the
> > current
> > > > state leaves it at the last selected option.
> > > >
> > > > The analogue ins can actually be turned off by the command "analogIns
> > X 0"
> > > > (where the X stands for the pin number 0-5). The digital input pins
> > need the
> > > > command "digitalIns X 0" (where the X stands for the pin number 0-11).
> > > >
> > > > I also think that there should be a separate block for digital an
> > analogue
> > > > (with the available options only) as beginners might think you could
> > select
> > > > "analog" as an option for digital pins, and so on...
> > > >
> > > > Ingo
> > > >
> > > >
> > > > BTW with the fix I just submitted in my last email all digital ins now
> > work
> > > > flawlessly after testing for several hours. I am amazed that hardly
> > anybody
> > > > noticed is bug for over two years!
> > > >
> > >
> > >
> > > _______________________________________________
> > > Pd-list(a)iem.at mailing list
> > > UNSUBSCRIBE and account-management ->
> > http://lists.puredata.info/listinfo/pd-list
> >
> >
> >
> > _______________________________________________
> > Pd-list(a)iem.at mailing list
> > UNSUBSCRIBE and account-management ->
> > http://lists.puredata.info/listinfo/pd-list
I've tried getting into around with pd a couple of times before, this is my
first concerted time. I've worked with a bunch of flow-charty programming
environments in the past (Unreal Engine's kismet is the slickest I've come
across - http://odedge.com/forums/ut3_kismet_04.jpg ) - pure data is taking
a bit of getting used to (most of this is due to the fact that it does
special things, some things feel a bit more avoidable, other things feel
frivolously subjective :P ). Here're some of the things that stuck out for
me (some might be due to ignorance on my part, I'd love to have things
cleared up :) ):
1 - Inlets/outlets too small for me to accurately click on (touchpad) -
checking on pd-dev, they can be visually reskinned, but their actual
clickable size can't be changed. [ so I guess this one has been responded
to, but might as well repeat it ]
2 - If I have an object selected (that's to say pressing buttons to edit
text in it) I can't find any key-combination that will delete it - I have to
deselect it, then press the mouse down on it, then, while holding the mouse
button down, press backspace? (this is an uncomfortable manipulation on a
laptop w/ touchpad) - on OSX at least, a shortcut like cmd+backspace would
be quite idiomatic for this.
3 - I can drag lines from outlets to inlets, but not from inlets to outlets.
4 - is there a shortcut for deleting connections? something like ctrl+click
would save me a lot of time.
5 - is there a way to type numbers directly into a number box?
clicking+dragging, or pumping them in via a message, doesn't feel good to
me.
6 - shortcut for opening help of selected item would be...convenient for me
I'm still working through the tutorials, and am enjoying the experience
overall :)
Hi,
A new report of my researchs about audio dynamic patching techniques.
The continuation of my previous reviews :
http://abel.jerome.free.fr/pd/dynamic-patching/reviews/DynamicPatching_revi…http://abel.jerome.free.fr/pd/dynamic-patching/reviews/DynamicPatching_revi…
===================================================
Pd-list archives
===================================================
"The issue has been discussed several times" (IOhannes m zmoelnig)
That's right. I've just seen that the "pd dsp O/1" method was described in 2005 !
It's quite difficult to find those threads without the terms "dsp tree" or "dsp graph" or "dsp chain". Indeed, I don't know anything about it.
A list of the best search terms could help us (see below) and avoid those "noise" requests.
We are trying here to make a review of all dynamic patching techniques to make it easier to understand and find the "best" solution for any project. It could be a page on the community website instead of the disheartening "do not use dynamic patching" (http://puredata.info/docs/tutorials/TipsAndTricks#how-to-avoid-audio-drop-o…).
- Search engine usage
----------------------------------------
When I search in the pd-list, the score show some posts where the search term are in the next or previous message links, not in the message body. How limit the search term to the body and not the links ?
Futhermore, if I'm interested in one thread, it seems that if I choose to sort by thread, it's only the threads of a month. How group one thread on all months ?
- Search terms
----------------------------------------
"audio drop-outs with pd dsp O; pd dsp 1"
"activate audio abstraction"
"dynamic audio abstraction"
"dynamic patching"
"dynamic patching techniques"
"update dsp-tree"
"update dsp-graph"ofxPd
- Threads about audio dynamic abstraction in pd-list
----------------------------------------
- [PD] strange behavior upon loading dsp abstraction....
http://lists.puredata.info/pipermail/pd-list/2004-12/thread.html#24337
- [PD] no dsp-chain update after dynamic abstraction-creation
http://lists.puredata.info/pipermail/pd-list/2005-06/028923.html
- [PD] slowly load a pd-patches/abs without dropouts
http://lists.puredata.info/pipermail/pd-list/2007-01/046243.html
- [PD] this is crazy
http://lists.puredata.info/pipermail/pd-list/2008-01/059244.html
- [PD] API for manipulating a patch in real time
http://lists.puredata.info/pipermail/pd-list/2008-12/066723.html
- [PD] Dynamically created signal object bug
http://lists.puredata.info/pipermail/pd-list/2009-02/068246.html
- [PD] abstraction creation audio engine start
http://lists.puredata.info/pipermail/pd-list/2009-04/069849.html
===================================================
Dynamic creation of audio abstractions
===================================================
- Methods
----------------------------------------
1 - DSP 0/1
2 - Add/clear an audio object (subpatch)
3 - Add/cut any object (subpatch)
See :
http://abel.jerome.free.fr/pd/dynamicPatching/patchs/dyn-audio-abstraction/
This methods work with any abstraction.
- DSP 0/1 method - explanations
----------------------------------------
>From IOhannes m zmoelnig :
"You shouldn't dynamically create abstractions while dsp is running, as it slows down significantly."
"If dsp is on, and you dynamically create 10 objects in one go (in zero
logical time), then the dsp graph will be re-calculated 10 times.
If you turn dsp off, then dynamically create 10 objects as before, then
no dsp graph will be evaluated until you turn dsp on again, summing up
to exactly 1 time.
Furthermore, it guarantees that the entire DSP graph is calculated and
not only parts of it (because of buggy implementations)"
Thanks a lot for those explanations. It's clear enough to see why choose these method even if internal processes in the DSP graph are still incomprehensibles.
- DSP 0/1 method - Some questions
----------------------------------------
--- With one audio abstraction.
If we create just one audio abstraction at one time. Is it still the best solution or is it the same than other methods ?
--- Audio clics.
>From me:
But audio clics may occur for all sounds, not just for the new one, right ?
>From IOhannes:
"no, this is wrong. (at least not, if you computer is fast enough to calculate the DSP-graph within the buffertime)."
I don't understand how you can not heard clics with it.
With my system, audio clics occur... Wrong settings ? Do I need a recent computer ?
In fact, a clic is heard the first time with Jack/Alsa and always with Alsa and Asio4all.
But in a dynamic patching case, what's this first time ? In the dynamic patch example, clics occurs even if I use Jack/Alsa.
See :
http://abel.jerome.free.fr/pd/dynamic-patching/patchs/cpu-on-off/screenshot…http://abel.jerome.free.fr/pd/dynamic-patching/patchs/dyn-audio-abstraction…
--- Time response depends on audio system
If I want a cross-platform system, it couldn't be the best solution.
With my computer : WinXP (~ 90 ms), Xubuntu10.04.LTS(~ 20 ms with ALSA, ~0.09 ms with Jack/Alsa), PureDyne9.11+(~ 0.09 ms with Jack/Alsa)
See :
http://abel.jerome.free.fr/pd/dynamic-patching/patchs/cpu-on-off/screenshot…
- Methods without clics [line~]
----------------------------------------
If I can't use audio on/off because of the clics, we need to make prepared abstractions with a [line~] method.
The idea is to split methods in two parts:
- create/destroy objects
- connect/disconnect audio paths (in our case : audio activation)
Audio processing methods:
- [line~]
- [switch~] and [line~]
- all audio paths in a [mtx_*~] object which receive audio signals from abstraction and a [send~ $1] in abstrations, where $1 is the unique ID of the abstraction.
Communication methods:
- global messages
- unique message for abstractions : an unique Id in the first argument and a [r $1] in the abstraction
===================================================
Dynamic patching : other techniques
===================================================
Any feedbacks or projects with those techniques ?
- ofxPd
---------------------------------------------------
https://github.com/danomatika/ofxPd
"Announcing ofxPd, an Open Frameworks addon for running an instance of the Pure Data audio environment within an OpenFrameworks application. Audio, messages, and MIDI events can be passed to and from pure data patches and the library is thread safe.
Note: This is not the ofxPd originally released by Damian (see http://forum.openframeworks.cc/index.php/topic,4444.0.html). This is a new addon using the official libpd library.
- libpd, Purity, Dyn~, Pdsheefa, Ext13 lib
---------------------------------------------------
I wrote some feedbacks about those techniques here :
http://abel.jerome.free.fr/pd/dynamic-patching/reviews/DynamicPatching_revi…
===================================================
Dynamic patching : some quality specifications
===================================================
We could synthesize specifications for a good audio dynamic system in Pd
- How many objects must be created in one time
- Constraints about the quantity of audio objects
- Activate audio (for abstractions)
- System with any or prepared abstractions
- Avoid audio clics (dsp on/off or line~): delete/create without clics, make connection/disconnect without clics
- Dsp chain (update dsp-graph one time)
- Best CPU (avoid compute dsp on unused abstractions)
- Best time response (dsp 0/1 latency)
- Easiest way (less is often better)
- Internal messages or Pd exteranls or C/C++ API
Jerome
Hi, how can i select a random wavefile from a folder withouth knowing the
names of the files in my folder?
how can i read all the files names in a folder and then select one? which
would be the best way of doing this?
thanks
A.
buenas tutti
roman & me did some rewrite on the pduino - citing the README:
Pduino - improved
-----------------
All Pd patches are based on the official Pduino (version 0.5beta8)
maintained by Hans-Christoph Steiner.
The goals of the improvements are:
* Get rid of avoidable dependencies on other external/abstraction
libraries
* Update help- and test-patches in accordance to current Firmata
* Create 'intuitive' and easy-to-understand GOP abstraction
Dependencies:
* comport
* pdstring library from moocow
you'll find the patches here:
https://github.com/reduzent/pduino
the GOP-abstraction is still in tango alpha state aka not useable at all.
so basically arduino.pd & arduino-help.pd should be of interest. as they went thru some changes - most important the
dependencies are reduce to the minimum.
check it out & report
ø
--
ETs DNA will not be televised
http://hasa-labs.org
Hi pd peoples,
I looked around the pd ecosystem and didn't find much in terms of testing
facilities (please correct me if I'm wrong)
and so I made an external with special functional testing purposes.
Test suites are written in the very simple and easy to learn Lua programming
language, a test case resemble:
Suite("Example suite").case("Foobar").test("FOO").should:equal("BAR")
where the pdtest external will outputs "symbol FOO" and test will pass if it
receives back "symbol BAR"
documentation and source code can be found:
https://github.com/lp/pdtest#readme
I would appreciate feedback on the usability of its design. It work perfect
for the external I need to test but I may not grasp what the collective need
for testing is, if one exist at all in the pd world anyway.
regards,
Louis-Philippe