«  …11 12 13 14 15 16 17 »

redShift Excerpt

2012-05-11 09:20 supercollider

A short excerpt from a rehearsal. It is made with the patch I played at the SuperCollider Symposium 2012 club night (Corsica studios, London).

It's controlled with my custom controller redThermoKontroll


One Reason Why I Love SC

2012-05-08 14:37 supercollider

140 characters...

play{Splay.ar(SinOsc.ar(9,SinOsc.ar(midicps((Sweep.ar(0,(33..3))%128&(Sweep.ar(0,(3..9))%(LFSaw.ar(3)*9+99)))+33),0,pi)))/3}//#SuperCollider

If we run this line in SuperCollider we hear this...

and using Rohan Drape's great sc3-dot quark and swap play{} with draw{} in the line above, this mess gets revealed...

637231982.png
(click image for hi-res version)

So with a single line of code - short enough to fit in a twitter tweet - we've built this amazingly complex sound synthesis patch. I can not imagine a system with greater code-to-noise ratio than SuperCollider.

And this one is pretty fun to .draw as well...

play{f={|o,i|if(i>0,{SinOsc.ar([i,i+1e-4]**2*f.(o,i-1),f.(o,i-1)*1e-4,f.(o,i-1))},o)};f.(60,6)/60}//#SuperCollider

A heavily recursive patch that looks almost fractal. The PDF file generated from this line of code is 300kB! The number 6 in the code means recursion depth and 60 is the base frequency.

How to install sc3-dot

To use the sc3-dot quark in SuperCollider on a mac you'll need Graphviz (I use 2.28 on my OSX 10.6.8). You also need to make sure the resulting .dot files open automatically in Graphviz and not Photoshop, Word or something. (Get info on a .dot file in Finder and change all filetypes to open with graphiviz. You'll find the .dot files from sc3-dot in your hidden /tmp directory)

Updates: 240129: (thanks Carlo)

To use the sc3-dot quark in SuperCollider on a mac you'll need to install graphviz, preferably via macports (sudo port install graphviz) or via homebrew (brew install graphviz).

Then install the quark from within SuperCollider...

Quarks.install("sc3-dot");

add the following lines to your startup.scd file...

Dot.renderMode= 'pdf';
Dot.pdfViewer= "open -a Preview.app";
Dot.dotCmd= "/opt/local/bin/dot";  //macports
//Dot.dotCmd= "/usr/local/bin/dot";  //homebrew

and finally recompile SuperCollider. Now a command like...

{SinOsc.ar}.draw;

should automatically create a .dot file, convert to .pdf and open using Preview.app.

By default you will find the resulting .dot and .pdf files in the ~/Library/Application Support/SuperCollider/tmp directory.

Attachments:
637231982.pdf
1909609728.pdf

Analogue Video In/Out on a Recent MacBook Pro

2012-04-22 11:35 other

For a project, I needed to take in and send out realtime analogue (composite) video. Analogue video input has always been a problem, but on recent laptops, Apple even removed the video output via DVI adapter option (i.e. there is no DisplayPort to video/s-video adapter).

So after experimenting and going through some old hardware I had laying around, I found a solution using two devices that I last used around 10 years ago.

analogvideoinout

Broderi

2011-10-03 14:02 electronics

Wireless sensor for embroidery.

The sensor is a tilt-compensated compass i.e. a 3D accelerometer in combo with a 3D magnetometer. Compared to my other wireless boxes, this one runs on 3.0V (two AAA batteries) and not 3.6V. This due to the LSM303DLH sensor's lack of onboard voltage regulators and 1.8V I2C data lines.

The ATmega168 has an Arduino sketch loaded as firmware and is using the internal 8 MHz oscillator. So the circuit is pretty minimal.

As part of the project knyppel with Ann Rosén. Also, see this post.

broderi photo1 broderi photo2

Schematics, Arduino firmware, parts list, MaxMSPJitter patches, SuperCollider class attached.

Attachments:
broderi.zip

Soft Modem

2011-09-29 16:42 electronics, supercollider

This summer I build 8 small circuits that can control a bunch of LEDs (6 channels PWM) from basically any iDevice or Android phone. The circuit connects to the audio jack of the phone and uses the right channel to send data commands (in the form of a modem signal).

We use rjdj (and Pdlib, SuperCollider, etc) to generate the data signal on the phone in realtime. And it's relatively easy to connect for example the built-in accelerometer in the phone to control some LEDs, or to run amplitude/pitch tracking on the microphone and let that flash some LEDs.

The circuits will be used in the rhyme research project as well as in the upcoming e-textile workshop in Oslo (Oct 2011).

softModem photo1 softModem photo2 softModem photo3 softModem photo4

The design is based on SoftModem by arms22. Attached below are my schematics, Pd FSK abstraction and Arduino firmware.

The modem signal is generated using Frequency-shift keying and here's how to do that in SuperCollider...

(
c= "how are you?";
{var t= 1/1225; var m= Duty.ar(Dseq([t*100]++t.dup(11*c.size)), 0, Dseq([1]++c.ascii.collect{|cc| [0]++(cc.asBinaryString.ascii-48).reverse++[1, 1]}.flat), 2); SinOsc.ar(m*(7350-4900)+4900)!2}.play(fadeTime:0);
)

This will send the characters "how are you?" at a baud rate of 1225. This is of course not a valid command for the circuit above, just something to demonstrate how it sounds. Below is an MP3...

Attachments:
softModem.zip

More MaxPat Pictures

2011-08-04 01:02 supercollider

With my SuperCollider class MaxPat that can manipulate and create MaxMSPJitter patches, I generated the following fully functional Max5 patches. These are just simple tests but I plan to do more advanced ones someday.

MaxPat 6 MaxPat 7 MaxPat 8 MaxPat 9 MaxPat 15+1 MaxPat 15+2

See the class help file for SuperCollider code and there is more info in the post /f0blog/maxpat-max-patch-parser-converter-manipulator-generator/.


Knyppel

2011-06-29 23:11 electronics

Wireless lace pillows. In collaboration with Ann Rosén.

See knyppel.se.

knyppel photo1 knyppel photo2

Schematics, firmware, parts list, MaxMSPJitter patches, SuperCollider class attached.

Updates:

Attachments:
knyppel.zip

monijonsyn3

2011-04-25 11:33 electronics

Things to do with an iPod case... Instead of throwing it away, I took some spare parts and built a new synth based on my monijonsyn2. The new synth has a push-button and one can now step through a few different programs. And the 2-way switch set different 'modes'. In this 1.0 version, there is only 3 programs and 2 modes.

The programs basically just map the 3 analogue inputs differently, and the modes switches left/right output channels.

It's very cheap and easy to build. 2 AA-batteries provide power, the inputs are 3 touchpoints, 2 potentiometers, 1 button and a combined on/off/mode switch. All the sound generation (2 PWM pins) and program logic happen inside the 8bit AVR ATmega8 chip and the code is easy to hack (see main.c in the zip below).

Todo: add more fun programs to the firmware

monijonsyn3 photo1 monijonsyn3 photo2 monijonsyn3 photo3 monijonsyn3 photo4
monijonsyn3 schematics

Simple one-bit synthesizer based on the ATmega8 chip. On the top are 3 touchpoints that influence the sound.

Updates:

Attachments:
monijonsyn3.zip

«  …11 12 13 14 15 16 17 »