How to specify the MIDI channel?
hi,
i do have 2 devices setup under "midi settings".
As input device 1 i have the device A, no device as input device 2.
As output device 1 i have the device B, as output device 2 i have the device A.
i red in this forum that device 1 sends on the channels 0-16 and device 2 sends on the channels 17-32.
when i first tried it worked pefectly. after a restart it was totally different. like device 1 and 2 sended on the channels 17-32 (of course then it makes no sense to specify the midi channel 2 on the "noteout" object).
i found out that a different order in input devices and output devices gives different midi channel depandancies.
it feels a little bit random. Is there a way to make sure or to specify which device uses which midi channel?
thanx,
slx
Serious problem with poly object!!
I have used the poly object to route the midi notes to voices in order to have polyphony. I am constructing a patch like piano so I use pedals also. I've program the right pedal to cut the velocity 0 message, when it is pressed, in order to have a sustain sound. The problem is that when I repeat a note in the keyboard the route object gives to the same midi note other voice numbers so the same note goes to different voices. I want the same note to remain in the same voice number (note in-note off, or note on-note on without note off). Is there a way for poly object to do such a thing or I have to program every note correspond to a voice sub-patch? Thanx anyone who will help in advance!
Tarmtott - ep by swamps up nostrils
This lil' thing just got released on the great netlabel Control Valve, it is 6 tracks of whacky looping made with PD. Download @:
inforz:
"ctrlvlv#007 IS NOW READY FOR DOWNLOADING!!!!!!!!!!!!!!!!‏ ctrlvlv#007 IS NOW READY FOR DOWNLOADING!!!!!!!!!!!!!!!!‏ ctrlvlv#007 IS NOW READY FOR DOWNLOADING!!!!!!!!!!!!!!!!‏
artist: swamps up nostrils title: tarmtott
artist statement: "Swamps Up Nostrils is a spatiotemporal mishap again and again focusing on both experimental wrongdoings and ancient traditional musical structures like beats and harmonies. What you hear is not what you get but it will however seem pretty close anyway, so why bother? Swirling the eternal wormholes between the familiar and the unknown, we hope to entertain but admit that to most people it must seem like meaningless idiocy, but then again most people seem like meaningless idiots too, including ourselves, so I guess it balances out. Only by admitting to being an idiot yourself will you understand what it means to be one, and understand just how many idiots there are around here. We, the failed abhorritions of monkey-like beings of ancient times, will not let us be controlled by our biological shortcomings, although we admit to them causing us both irritation and confusion. This irritation and confusion is not the source of this music. This music was made by utilizing magick and computers, if you believe in such stuff. If you do not, this music was made by utilizing science and computers, if you believe in such stuff. If you do not, this music was made by utilizing faith and computers, if you believe in such stuff. If you do not, this music was made by utilizing computers and computers, if you believe in such stuff. If you do not, this music was made by utilizing music and music, if you believe in such stuff. If you do not, this mucus was made by utilizing mucus and mucus, if you believe in such stuff. If you do not, this made not was believe and unbelief is by whom was finalized as not more. If you do not, please ignore all above statements as they are irrelevant to the audial experience anyway. There appears not more than what vibrates in your ear, and how your brain interprets that on the basis of your own very personal framework of reference. Anyone telling you otherwise is either trying to highjack your brain or may be lying, or may be convinced of otherwise and acts on a compulsion of good faith, although faith can never exist as something good outside someone's subjective defenition of the matter so the statement is meaningless. Now stop reading this nonsense and listen to the music instead, because, as implied in this body of textual represented idiocies, the point is not to read about this music it is to listen to it. Get it?"
swamps up nostrils is arnfinn killingtveit from trodheim, norway. no one can ever be sure what will come out of the speakers when playing a swamps up nostrils release. the first time i heard one it was some sort of drum and bass mixed with circuit bent electronics, with just a tad of field recordings. you might be getting some sort of techno, drone, noise, minimalism, analog, digital, ect...... whatever it might be, it is always top notch sound work, great composition, and a highly enjoyable listen. killingtveit also runs the superb cd-r label Krakilsk
6 tracks of looping-layered sound composition 320kbps. mp3 cover image"
\[key\] stops working when PD is not the active window
Thanks ... it is indeed. What does it do? The help file just has a patch which lists devices without explaining what it does ... How can it help me route keystrokes to PD when its not the active window ?
if it helps this is what I get when I run the patch
hidin: ** found 9 devices on your system
DEVICES: -1 None
DEVICES: 1
DEVICES: 2
DEVICES: 3
DEVICES: 4
hidin: -- could not get device #5: Access is denied.
hidin: -- can not read from mouse and keyboard
DEVICES: 5 Unsupported Device
hidin: -- could not get device #6: Access is denied.
hidin: -- can not read from mouse and keyboard
DEVICES: 6 Unsupported Device
hidin: -- could not get device #7: Access is denied.
hidin: -- can not read from mouse and keyboard
DEVICES: 7 Unsupported Device
hidin: -- could not get device #8: Access is denied.
hidin: -- can not read from mouse and keyboard
DEVICES: 8 Unsupported Device
hidin: -- could not get device #9: Access is denied.
hidin: -- can not read from mouse and keyboard
DEVICES: 9 Unsupported Device
Thanks again.
W
Arduino and pure data
Hello. I'm trying to use Arduino with Puredata using the Firmata Library. I downloaded Firmata and installed the library as instructed in the readme, and then loaded 'AnalogFirmata' from the library examples. When I try to compile this example (or any of the others) I receive a string of error statements. Code and errors listed below. Any suggestions?
Code:
/* This firmware supports as many analog ports as possible, all analog inputs,
* four PWM outputs, and two with servo support.
*
* This example code is in the public domain.
*/
#include <Firmata.h>
#include <Servo.h>
/*==============================================================================
* GLOBAL VARIABLES
*============================================================================*/
/* servos */
Servo servo9, servo10; // one instance per pin
/* analog inputs */
int analogInputsToReport = 0; // bitwise array to store pin reporting
int analogPin = 0; // counter for reading analog pins
/* timer variables */
extern volatile unsigned long timer0_overflow_count; // timer0 from wiring.c
unsigned long nextExecuteTime; // for comparison with timer0_overflow_count
/*==============================================================================
* FUNCTIONS
*============================================================================*/
void analogWriteCallback(byte pin, int value)
{
switch(pin) {
case 9: servo9.write(value); break;
case 10: servo10.write(value); break;
case 3:
case 5:
case 6:
case 11: // PWM pins
analogWrite(pin, value);
break;
}
}
// -----------------------------------------------------------------------------
// sets bits in a bit array (int) to toggle the reporting of the analogIns
void reportAnalogCallback(byte pin, int value)
{
if(value == 0) {
analogInputsToReport = analogInputsToReport &~ (1 << pin);
}
else { // everything but 0 enables reporting of that pin
analogInputsToReport = analogInputsToReport | (1 << pin);
}
// TODO: save status to EEPROM here, if changed
}
/*==============================================================================
* SETUP()
*============================================================================*/
void setup()
{
Firmata.setFirmwareVersion(0, 2);
Firmata.attach(ANALOG_MESSAGE, analogWriteCallback);
Firmata.attach(REPORT_ANALOG, reportAnalogCallback);
servo9.attach(9);
servo10.attach(10);
Firmata.begin();
}
/*==============================================================================
* LOOP()
*============================================================================*/
void loop()
{
while(Firmata.available())
Firmata.processInput();
if(timer0_overflow_count > nextExecuteTime) {
nextExecuteTime = timer0_overflow_count + 19; // run this every 20ms
for(analogPin=0;analogPin<TOTAL_ANALOG_PINS;analogPin++) {
if( analogInputsToReport & (1 << analogPin) )
Firmata.sendAnalog(analogPin, analogRead(analogPin));
}
}
}
Error Statements:
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: typedef 'callbackFunction' is initialized (use __typeof__ instead)
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: expected primary-expression before 'int'
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: typedef 'sysexCallbackFunction' is initialized (use __typeof__ instead)
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'argv' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:81: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:81: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:86: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:87: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:88: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:90: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: 'callbackFunction' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:96: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:97: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'sysexCallbackFunction' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'void FirmataClass::attach(int, int)' cannot be overloaded
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: with 'void FirmataClass::attach(int, int)'
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:99: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:104: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:105: error: ISO C++ forbids declaration of 'byte' with no type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:105: error: expected ';' before '*' token
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:107: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:108: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:109: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:110: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:112: error: 'boolean' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:115: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:116: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:117: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:118: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:119: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:122: error: 'sysexCallbackFunction' does not name a type
In function 'void setup()':
Interfacing PD with the Arduino ... how?
i got a problem in uploading the file to the board. ( I have press play, same error found. When I press upload to I/O, below error found)
anyone can help?
thx
////////////////////////////
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: typedef 'callbackFunction' is initialized (use __typeof__ instead)
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:61: error: expected primary-expression before 'int'
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: typedef 'sysexCallbackFunction' is initialized (use __typeof__ instead)
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'byte' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:64: error: 'argv' was not declared in this scope
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:81: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:81: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:86: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:87: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:88: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:90: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:91: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: 'callbackFunction' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:96: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:97: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'sysexCallbackFunction' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:98: error: 'void FirmataClass::attach(int, int)' cannot be overloaded
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:95: error: with 'void FirmataClass::attach(int, int)'
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:99: error: 'byte' has not been declared
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:104: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:105: error: ISO C++ forbids declaration of 'byte' with no type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:105: error: expected ';' before '*' token
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:107: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:108: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:109: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:110: error: 'byte' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:112: error: 'boolean' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:115: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:116: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:117: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:118: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:119: error: 'callbackFunction' does not name a type
/Applications/arduino-0012/hardware/libraries/Firmata/Firmata.h:122: error: 'sysexCallbackFunction' does not name a type
In function 'void setup()':
Random Note Value?
Thanks for the reply boonier. I tried your suggestion but not really the thing I was looking for.
I'll see if I can explain my case better.
For example I have a steady rhythm beat going on @120bpm. I would like to throw in there a pre-define notes(C=48, D=50, E=52, G=55, Bb=58 or 8ve) in whole (1 note per 1000ms), half(2 note per 1000ms or 1 note per 500ms), quarter(4 note per 1000ms or 1 note per 250), eighth(125) etc...
So I would like to be able to play a random notes with a random note value.
And Im not sure if my patch above will do that.
In other words its kinda playing it in a 16-note sequencer but not playing the same note & the same note value over & over again. Then maybe later with added random velocity & other random parameters...
ciao
UBUNTU Pd install libjack0.100.0-0 error
Thanks but all this did'nt slove the problem. When I try to install Pd with in a terminal with the command:
sudo dpkg -i Pd-0.39.2-extended-rc4-debian-stable-i386.deb
I get the following messages:
Selecting previously deselected package pd-extended.
(Reading database ... 90801 files and directories currently installed.)
Unpacking pd-extended (from Pd-0.39.2-extended-rc4-debian-stable-i386.deb) ...
dpkg: dependency problems prevent configuration of pd-extended:
pd-extended depends on libjack0.100.0-0; however:
Package libjack0.100.0-0 is not installed.
pd-extended depends on tcl8.4; however:
Package tcl8.4 is not installed.
pd-extended depends on tk8.4; however:
Package tk8.4 is not installed.
pd-extended depends on libflac7; however:
Package libflac7 is not installed.
pd-extended depends on imagemagick; however:
Package imagemagick is not installed.
pd-extended depends on libpng3; however:
Package libpng3 is not installed.
pd-extended depends on libmpeg1; however:
Package libmpeg1 is not installed.
pd-extended depends on libmpeg2-4; however:
Package libmpeg2-4 is not installed.
pd-extended depends on libmpeg3-1; however:
Package libmpeg3-1 is not installed.
pd-extended depends on libquicktime0; however:
Package libquicktime0 is not installed.
pd-extended depends on libimlib2; however:
Package libimlib2 is not installed.
pd-extended depends on libmagick++9c2a; however:
Package libmagick++9c2a is not installed.
dpkg: error processing pd-extended (--install):
dependency problems - leaving unconfigured
Errors were encountered while processing:
pd-extended
martin@martin-desktop:~/PD_extended$
Best way to do this tree...
Thanks obiwannabe. Before you posted, I had just found a way to get things working. It's messy and probably not the most efficient way of doing things though, but again it works how I need it. Right now, I'm using routeing, moses, and some send/receives. I'll take a look at lists since they seem like that may have been a better route to go.
I'm sorry, I probably didn't explain well what I am trying to achieve. Every 8 notes, I wanted a pattern (algorithmic) to go back to Note 1 and find a new pattern (which may be the same as the previous one). Looking at the diagram, each box is the option(s) that can be chosen by the random generator. A 1/2 = 500ms, 1 = 1000ms, 2 = 2000ms, and 4 = 4000ms. At note 1, if a 2 is chosen, the next one can only be a 2, and the next only a 1, next a 3, next a 4, 3, or 1. If a 1 is chosen for note 5, then the next note must be a 4, next a 1/2, and last a 1/2, then back to note 1 again ( 4 or 2). There is no direct link between step and note length other then the fact that the order of note lengths reach an even point at the end of every 4 and 8 notes.
Basically, I originally had an algorithmic note generator, where the notes were picked from moses divide/split points. The problem is, with 4 instruments playing simultaneously, the rhythms were too random. So, I wanted to line them up every 4 and 8 notes. With the diagram setup, every 4 notes and 8 notes, the notes start together, while in between they can deviate randomly in their rhythm (note length).
I hope that makes more sense. I'm a student, and learning PD for the first time. So I'm sure my way isn't the most efficient, but it's all I could think of. =) The patch is almost completed, and I can upload it once finished if interested.
Best way to do this tree...
I'm making an algorithmic based program and I just thought of a new way that I'd like to generate length of notes. I'm still new to pd and programming in general, so I was wondering what the best and easiest way would be to go about making something like my chart below:
4 = note lengths of 4000ms (4 seconds), 2 = 2 seconds, 1 = 1 second, 1/2 = half second. So similar to whole, half, quarter, and eight notes. If the first note (when banged from a random 50/50 chance) is a 4, then the second note can be a 1 or a 2. If the second note is a 1, the third note must be a 2 and so on. I hope the diagram explains what I am trying to accomplish. The goal in doing this is so that on every 4 and 8 notes, the notes line up again (since I have 4 parts to this music generation).
I originally was doing something else to get note lengths, using a route 8 and a random note was triggered by a metronome, and then the metronome (received this length and) didn't choose another until the length of the first note finished. I'm having a hard time switching over to this new concept.
This notelength, is passed to a random note chooser using route 8.
Any help would be great! =)