Re: [PD] gpio on the raspberry pi from within pd ?

2013-04-11 Thread J Oliver
Hi Julian, All,I think I've figured out the [gpio] external. It works fine, but there there is no documentation, however, the .c file is not very complicated.The test-gpio.pd file is not very good as documentation, so I am attaching a draft help file. The argument of [gpio] is the pin number. The first thing to do is [enable 1( and not [open 1(, which is equivalent to the:sudo echo "17" > /sys/class/gpio/exportcommand.Then [open 1(, then [output 1/0( to choose direction and then write (float) to or read (bang) from the pin...There are still a few more things I need to discover, but more tomorrow when I have some jumper cables and feel more awake.best,J

gpio-help.pd
Description: Binary data
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] flip image in glsl

2013-04-11 Thread Patrice Colet
Hello Jack, 

 I didn't realized how using gemframebuffer is really an interesting approach, 
in fact there is no need to move textures with glsl because it's possible move 
objects rendered into the framebuffer, also the flipping problem isn't occuring 
anymore...
 The solution you are proposing here gives results I haven't expected, and 
might fit some other purposes that might come later,
since the texture processed by glsl (tex0) isn't anymore mapped with mixed 
textures (tex1 and tex2)...
 In all cases thank you for the contribution that gave me all the solutions I 
need in the project I'm working on.

Colet Patrice

- Mail original -
> De: "Jack" 
> À: "Patrice Colet" 
> Cc: "PD List" 
> Envoyé: Mercredi 10 Avril 2013 17:13:07
> Objet: Re: [PD] flip image in glsl
> 
> Le 10/04/2013 07:48, Patrice Colet a écrit :
> > Hi Jack,
> >
> >  the fragment code is now very short and much more elegant,
> >  certainly faster than using conditions, I guess this is due to
> >  [pix_info] that is computing dimensions of the resulting texture.
> >  This procedure seems to work for horizontal flipping then corrects
> >  strange behavior between pix_image and glsl,
> > but vertical flipping has no consequence.
> >  It's also possible to crop using the dimen parameter, but I
> >  believe there is a zoom parameter missing to do it entirely.
> > So I'm going to restart coding a fragment code from the basis you
> > propose that would allow to crop both textures, because this looks
> > fundamental for my possible use of this object, that is mainly
> > about mixing two textures which coordinates could be modulated to
> > fit a particular context, where textures would need to be placed
> > accurately without having to modify it in an image editor, maybe
> > you have an idea about how to do it simply?
> >
> >
> >> You can do operations directly on vec2 instead of two floats in
> >> your
> >> fragment shader.
> >> You can also avoid condition (could be slow).
> >> See patch and glsl vertex and fragment attached for flip.
> >> ++
> >>
> >> Jack
> >>
> >>
> >>
> >> ___
> >> Pd-list@iem.at mailing list
> >> UNSUBSCRIBE and account-management ->open
> >> http://lists.puredata.info/listinfo/pd-list
> >>
> Hello Patrice,
> 
> Not sure to understand what you mean about the problem on
> horizontal/vertical flipping.
> Here a new patch and the fragment shader. This time, all is computed
> from the Gem window size.
> You can flip, scale and move each texture. (the flip is done from the
> center position of the Gemwin).
> In this patch, i use a workaround to avoid to see the 'border' of the
> texture thanks to the message [perspec( on [gemframebuffer]. I don't
> know if there is a better solution ?
> Hope it will help.
> ++
> 
> Jack
> 
> PS : I can clean the this patch and keep only the part about position
> and scale of a texture with GLSL for Gem example if it is interesting
> ?
> 

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


Re: [PD] gpio on the raspberry pi from within pd ?

2013-04-11 Thread J Oliver
Miller Puckette wrote:
> I think either I or a grad student (we'll see) will be writing a Pd extern
> to do this efficiently -- for the moment it would be possible with a Python
> script (using netsend/netreceive in Pd) but having an extern would be more
> lightweight and probably more robust.

Hi Miller,

Did this extern and blog happen beyond the extern found in:
http://crca.ucsd.edu/~msp/syllabi/206.13w/index.htm
?

I can get this one to load, but not to open the gpio.

If I send 
[open 1( 
to 
[gpio 4]
I get the error
/sys/class/gpio/gpio4/value: No such file or directory
in the console

best,

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


Re: [PD] BUG more than 2 output/input chanells -> segfaults

2013-04-11 Thread Fero Kiraly
iohannes thanks for helping.
yes, I am running JACK.

when i ran:

pdextended -channels 4

everything is okay, but when I try to change num of channles from the pd
GUI, it segfault then.

debug:

[paum@bookes ~]$  gdb --args pdextended   -nrt -channels 4
GNU gdb (GDB) 7.5.1
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
...
Reading symbols from /usr/bin/pdextended...(no debugging symbols
found)...done.
(gdb) run
Starting program: /usr/bin/pdextended -nrt -channels 4
warning: no loadable sections found in added symbol-file system-supplied
DSO at 0x77ffa000
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[New Thread 0x77fba700 (LWP 2249)]
[New Thread 0x77f39700 (LWP 2250)]
[New Thread 0x77eb8700 (LWP 2251)]
[New Thread 0x753d6700 (LWP 2252)]
[Thread 0x77eb8700 (LWP 2251) exited]
[Thread 0x77f39700 (LWP 2250) exited]
[Thread 0x77fba700 (LWP 2249) exited]
[New Thread 0x77fba700 (LWP 2253)]
[New Thread 0x77f39700 (LWP 2254)]
[New Thread 0x77eb8700 (LWP 2255)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x77eb8700 (LWP 2255)]
0x004685f5 in ?? ()
(gdb) bt
#0  0x004685f5 in ?? ()
#1  0x76f83cac in ?? () from /usr/lib/libjack.so.0
#2  0x76f83bb4 in ?? () from /usr/lib/libjack.so.0
#3  0x76f81aab in ?? () from /usr/lib/libjack.so.0
#4  0x76fa0ebc in ?? () from /usr/lib/libjack.so.0
#5  0x778c8dd2 in start_thread () from /usr/lib/libpthread.so.0
#6  0x76ca3ced in clone () from /usr/lib/libc.so.6
(gdb)

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


Re: [PD] Gem High def out put (stills ect)

2013-04-11 Thread Alan Brooker
Thanks everyone for the suggestions [polygon_smooth] helps much.  
09.SnapshotSaveHD looks like it could be what I need but it has me a bit 
stumped. I will try to connect it into my Gem scene but any tips would be 
welcome

Thanks again for the feedback!



On 11 Apr 2013, at 14:00, Jack  wrote:

> Le 11/04/2013 14:30, Alan Brooker a écrit :
>> Hi
>> II am use Gem to create some 3d artworks I planning to have printed for 
>> framing/postcards etc.- would be grateful for any advice on way to save high 
>> quality/large images from the Gem window? Ways to achieve Anti aliasing (is 
>> this only for Nvidia graphics?), smoothing of edges and such.
>> Thanks for the advice all, much appreciated.
>> Alan
>> 
>> 
>> ___
>> Pd-list@iem.at mailing list
>> UNSUBSCRIBE and account-management -> 
>> http://lists.puredata.info/listinfo/pd-list
> 
> Hello Alan,
> 
> Have a look in examples section in Gem (from the help panel). There is 
> '02.advanced/09.SnapshotSaveHD.pd'.
> There is no Anti aliasing, but after you can reduce the size of the picture 
> with a software like Gimp to get something smooth.
> Or it is possible to use supersampling anti aliasing with two or more 
> framebuffer, but you need a good graphic card for that.
> Hope '09.SnapshotSaveHD.pd' will work for you.
> ++
> 
> Jack
> 
> 
> ___
> 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] RPI Raspian - Hard/soft floating point best for Pd?

2013-04-11 Thread Julian Brooks
Never mind.

Sorry for noise - that's the problem with the RPi in some ways, 6 month old
posts are very outdated.

Hard it is (unless someone very convincingly says otherwise:).

Cheers,

Julian


On 11 April 2013 20:31, Julian Brooks  wrote:

> Hi all,
>
> I'm about to install a fresh raspian and came across the hard/soft float
> thing.
>
> My understanding is that hard float is faster but only some software make
> use of it.
>
> Any gains to be made for Pd with hard float?
>
> Cheers,
>
> Julian
>
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Sensors GPIO Raspberry Pi Pd

2013-04-11 Thread Julian Brooks
Hey Martin,

Ok, good stuff - progress.
Will check all connections again (have to be tomorrow now).

Nice one,

Julian


On 11 April 2013 20:25, Martin Peach  wrote:

> On 2013-04-11 14:24, Julian Brooks wrote:
>
>> Hey Martin / list,
>>
>> Finally got all the stuff and ...
>>
>> It’s not working!
>>
>> We spent the day soldering cables and connecting stuff up as per the
>> Omron ‘App Note 01’ spec sheet.
>>
>> Started off super-conservative using the  I2C level converter (case 3
>> page 4) 
>> http://www.adafruit.com/**products/757#Blog/Flickr
>>
>> We tried resistors on both sides (being super paranoid!) and then we
>> took  the low (Pi) side ones off.
>>
>> We then moved on to case 2 page 3 of this same document…
>>
>> At each stage we checked with “I2Cdetect –Y 1” and nothing was visible.
>>
>> The grid shows no attached devices every time we run it.
>>
>> We re-booted at every stage following the various online
>> tutorials/methods of setting up I2C GPIO on the Pi (checked & double
>> checked).
>>
>>
>> As you can see we’re using a pi protoplate:
>>
>> https://www.adafruit.com/**products/801
>>
>> In the photo I’ve attached the cables are coded as follows:
>>
>> Orange   GND
>>
>> Yellow5v
>>
>> BlueSCL
>>
>> Green SDA
>>
>> The white is also 5v for the pull up resistors.
>>
>> The resistor values are 4.7k btw.
>>
>> We have tested the cable that terminates at the sensor and all that is OK.
>>
>> I put a multimeter on the GND and SDA solder points on the sensor itself
>> and got 3.7v…
>>
>> I put a multimeter on the GND and SCL solder points on the sensor itself
>> and got 0.0v…
>>
>>
> If you have pullup resistors you should get the same 3.7V on SCL (with it
> switched on and not running any code), so probably your pin isn't connected
> somewhere.
>
> Martin
>
>
>
___
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list


[PD] RPI Raspian - Hard/soft floating point best for Pd?

2013-04-11 Thread Julian Brooks
Hi all,

I'm about to install a fresh raspian and came across the hard/soft float
thing.

My understanding is that hard float is faster but only some software make
use of it.

Any gains to be made for Pd with hard float?

Cheers,

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


Re: [PD] Sensors GPIO Raspberry Pi Pd

2013-04-11 Thread Martin Peach

On 2013-04-11 14:24, Julian Brooks wrote:

Hey Martin / list,

Finally got all the stuff and ...

It’s not working!

We spent the day soldering cables and connecting stuff up as per the
Omron ‘App Note 01’ spec sheet.

Started off super-conservative using the  I2C level converter (case 3
page 4) http://www.adafruit.com/products/757#Blog/Flickr

We tried resistors on both sides (being super paranoid!) and then we
took  the low (Pi) side ones off.

We then moved on to case 2 page 3 of this same document…

At each stage we checked with “I2Cdetect –Y 1” and nothing was visible.

The grid shows no attached devices every time we run it.

We re-booted at every stage following the various online
tutorials/methods of setting up I2C GPIO on the Pi (checked & double
checked).


As you can see we’re using a pi protoplate:

https://www.adafruit.com/products/801

In the photo I’ve attached the cables are coded as follows:

Orange   GND

Yellow5v

BlueSCL

Green SDA

The white is also 5v for the pull up resistors.

The resistor values are 4.7k btw.

We have tested the cable that terminates at the sensor and all that is OK.

I put a multimeter on the GND and SDA solder points on the sensor itself
and got 3.7v…

I put a multimeter on the GND and SCL solder points on the sensor itself
and got 0.0v…



If you have pullup resistors you should get the same 3.7V on SCL (with 
it switched on and not running any code), so probably your pin isn't 
connected somewhere.


Martin



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


Re: [PD] BUG more than 2 output/input chanells -> segfaults

2013-04-11 Thread IOhannes m zmölnig
On 04/11/2013 17:37, Fero Kiraly wrote:
> Hi friends,
> 
> Here pd-extended 0.43.4 in archlinux. When I try to set more channels
> than 2 it segfaults.
> 


which audio backend are you using?
does it happen with all of them?
if it's jack, is jack server running?

could you provide a backtrace?

$ gdb --args pd -nrt -channels 4
...
(gdb) run
...
(gdb) bt

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


Re: [PD] Gem High def out put (stills ect)

2013-04-11 Thread Jack
Le 11/04/2013 16:06, Cyrille Henry a écrit :
> hello,
>
> rendering to a framebuffer allow 4096 or 8192 (depending on your
> hadware memory) pixel snap.
> you can render only part of the image in the framebuffer using the
> perspect message to gemwin, in order to add many of them to a bigger
> image.
>
> for antialiasing, you have many solutions depending on what you are
> rendering
> - the easiest is to insert "alpha" and "polygon_smooth" object after
> the gemhead.
> - an other one is to render 4 time every primitives translated by a
> 1/2 pixel on every direction, and using alpha to adjust transparency.
> - you can render a very big image and reduce it.
>
> cheers
> c
>
>
> Le 11/04/2013 14:30, Alan Brooker a écrit :
>> Hi
>>
>> II am use Gem to create some 3d artworks I planning to have printed
>> for framing/postcards etc.- would be grateful for any advice on way
>> to save high quality/large images from the Gem window? Ways to
>> achieve Anti aliasing (is this only for Nvidia graphics?), smoothing
>> of edges and such.
>>
>> Thanks for the advice all, much appreciated.
>>
>> Alan
>>
>>
>>
>> ___
>> 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

Hello Cyrille,

Cool ! I didn't know this method with [alpha] and [polygon_smooth].
I get good results here with this method, better than render 4 times a
primitive and translate it by 1/2 pixel with alpha.
Maybe it depends on what you need to render ?
Thanks to this info, my computer will be cooler :)
++

Jack



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


[PD] BUG more than 2 output/input chanells -> segfaults

2013-04-11 Thread Fero Kiraly
Hi friends,

Here pd-extended 0.43.4 in archlinux. When I try to set more channels than
2 it segfaults.

it is working to you ?
its problem on my side ?

thanks.

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


[PD] Fwd: Re: PD-ext fails to connect to alsa-midi on startup...

2013-04-11 Thread Ivica Bukvic
-- Forwarded message --
From: "Ivica Bukvic" 
Date: Apr 11, 2013 11:24 AM
Subject: Re: [PD] PD-ext fails to connect to alsa-midi on startup...
To: "Raphael Raccuia" 
Cc:

Not sure If this is the same problem but in pd-l2ork I need to specify both
alsa-midi flag and -mididev 0 (even If such a device does not exist).
On Apr 11, 2013 10:56 AM, "Raphael Raccuia" 
wrote:

>  Hi,
> I have to re-configure to alsa-midi every time I launch pd-ext. anybody
> has the same issue? (0.43 from repo)
> thank you
> r
>
>
> ___
> 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] PD-ext fails to connect to alsa-midi on startup...

2013-04-11 Thread Raphael Raccuia

Hi,
I have to re-configure to alsa-midi everytime I launch pd-ext. anybody 
has the same issue? (0.43from repo)

thank you
r

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


Re: [PD] Gem High def out put (stills ect)

2013-04-11 Thread Cyrille Henry

hello,

rendering to a framebuffer allow 4096 or 8192 (depending on your hadware 
memory) pixel snap.
you can render only part of the image in the framebuffer using the perspect 
message to gemwin, in order to add many of them to a bigger image.

for antialiasing, you have many solutions depending on what you are rendering
- the easiest is to insert "alpha" and "polygon_smooth" object after the 
gemhead.
- an other one is to render 4 time every primitives translated by a 1/2 pixel 
on every direction, and using alpha to adjust transparency.
- you can render a very big image and reduce it.

cheers
c


Le 11/04/2013 14:30, Alan Brooker a écrit :

Hi

II am use Gem to create some 3d artworks I planning to have printed for 
framing/postcards etc.- would be grateful for any advice on way to save high 
quality/large images from the Gem window? Ways to achieve Anti aliasing (is 
this only for Nvidia graphics?), smoothing of edges and such.

Thanks for the advice all, much appreciated.

Alan



___
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] Gem High def out put (stills ect)

2013-04-11 Thread Jack
Le 11/04/2013 14:30, Alan Brooker a écrit :
>
> Hi
>
> II am use Gem to create some 3d artworks I planning to have printed
> for framing/postcards etc.- would be grateful for any advice on way to
> save high quality/large images from the Gem window? Ways to achieve
> Anti aliasing (is this only for Nvidia graphics?), smoothing of edges
> and such.
>
> Thanks for the advice all, much appreciated.
>
> Alan
>
>
>
> ___
> Pd-list@iem.at mailing list
> UNSUBSCRIBE and account-management -> 
> http://lists.puredata.info/listinfo/pd-list

Hello Alan,

Have a look in examples section in Gem (from the help panel). There is
'02.advanced/09.SnapshotSaveHD.pd'.
There is no Anti aliasing, but after you can reduce the size of the
picture with a software like Gimp to get something smooth.
Or it is possible to use supersampling anti aliasing with two or more
framebuffer, but you need a good graphic card for that.
Hope '09.SnapshotSaveHD.pd' will work for you.
++

Jack


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


[PD] Gem High def out put (stills ect)

2013-04-11 Thread Alan Brooker
Hi

II am use Gem to create some 3d artworks I planning to have printed for
framing/postcards etc.- would be grateful for any advice on way to save
high quality/large images from the Gem window? Ways to achieve Anti
aliasing (is this only for Nvidia graphics?), smoothing of edges and such.

Thanks for the advice all, much appreciated.

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


Re: [PD] best way to play (long) 24-channel wav file in pd

2013-04-11 Thread Matthias Blau

Thanks,
readsf~ was exactly what I was looking for! Works very well with 24 
channels.


-Matthias


On 04/09/2013 04:12 PM, Charles Goyard wrote:

Hi,

Matthias Blau wrote:

I want to play a 24-channel wav file in pd. It is rather big
(several minutes), such that pre-loading the data into tables will
probably not work (have to check that though). I tried zexy/sfplay
but it seems to be limited to 8 channels.


Did you try readsf~ or readanysf~ if not in wav format ?

On 64bits machines it should be no problem to open a huge file.


___
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