home changes issues contents help options subscribe edit
From Carlo 12-11-2002:

I added in the cvs repository a program called midimuxer. It can have
many inputs and has one output. You call it as follows:

midimuxer -i in1 -i in2 -i in3 ... -o out

Currently, on sortebill, there is an experimental path with two
capturers + 2 motion detectors running together with the video patch
thing. The two motion detectors send their outputs to
/usr/share/mob/mot1 and mot2, that are named pipes. So, I ran
midimuxer as follows:

 midimuxer -i /usr/share/mob/mot1 -i /usr/share/mob/mot2 -o /tmp/tst > /tmp/mmux 2>&1 &

(will send result to temp file /tmp/mmux. Will have to be substitutes
with midi unit as soon as you have USB working)

I cannot see it working because there is no active video input to the
first two capture cards on sortebill. So I will leave it to you to
check. 

IMPORTANT: I tried the experiment of running two patches at the same
time. The system is supposed to run like this, but I have never used
it so. Here, you have two completely separate sections. So, I created
two patch files. The first, that I called scr2.1, is as follows:

<mob name="Vmux plus couple captures. Part 1" savefile="scr2.1">
  <module name="algo" instance="rithm" />
  <module name="midiio" instance="midi" unit="0" />
  <module name="matrixgen_vmux" instance="mx" algo="rithm" parallel-unit="0" midiio="midi" midi_channel="1" midi_note_offset="36" />
</mob>

The second, scr2.2 is as follows:

<mob name="Vmux plus couple captures. Part 2" savefile="scr2.2">
  <module name="capturer" instance="capto1" unit="0" xres="320" yres="240" bpp="32" input="Composite1" out="mot1" /> 
  <module name="motion" instance="mot1" pipe="/usr/share/mob/mot1" midi-channel="1" out="displo1"/>
  <module name="displayer_xw" instance="displo1" xres="320" yres="240" bpp="32" />
  <module name="capturer" instance="capto2" unit="1" xres="320" yres="240" bpp="32" input="Composite1" out="mot2" /> 
  <module name="motion" instance="mot2" pipe="/usr/share/mob/mot2" midi-channel="1" out="displo2"/>
  <module name="displayer_xw" instance="displo2" xres="320" yres="240" bpp="32" />
</mob>

I run them as follows:

master_mobber > log 2>&1 &
t1 scr2.1
t1 scr2.2

(and then start midimuxer)

and then I find the two separate module lists under peek. It seems to
work, and it should ease the burden of the main process mobber
processes (two of them are running, independently). 

Please test, eventually reboot with the fourth capture card, and
extend these patches. You must really find out if you obtain a
sufficient performance. You may want to reduce the capture rate of the
cards maybe to 2 or 3 per second... This can surely help.

I now have to leave.

Carlo

--