Re: [ecasound] play midi file to midi port?

From: Joel Roth <joelz@email-addr-hidden>
Date: Mon Dec 28 2020 - 05:04:12 EET

Hi Leon,

Nama author here. You hooked me when you said 'nama is crazy slow' :-)

On Sun, Dec 27, 2020 at 05:39:26PM +0000, Bellan, Leon Marcel wrote:
> I'm trying to use ecasound for an animatronic project, and
> have motion sensor events appropriately turning on/off
> audio (wav) tracks via the ecasound server interface
> (selectively muting/unmuting channels upon motion sensor
> events). The wav data is going to an ALSA output. I'd
> like to also have ecasound play .MID files to a MIDI port
> I have set up that controls DMX fixtures over ArtNet
> (midimonster is converting MIDI to ArtNet and displays the
> MIDI events to the terminal for debugging)To get
> everything synced correctly, it'd be great if the wav and
> midi data is read by the same program (i.e. a multitrack
> audio program playing wav and midi at the same time).
> Ecasound does just what I want when I only use wav files
> (I can load multiple files and selectively mute/unmute
> them via the server interface), and I can get the midi
> files to control fixtures correctly using aplaymidi to the
> port I've set up, but I can't seem to get ecasound to send
> MIDI data from a MIDI file to the MIDI port. I'm not sure
> whether ecasound is capable of doing this, but it'd be
> great if it could. Is there a way to play a MIDI file in
> ecasound and route not to Timidity but to a MIDI port
> (e.g. 129:0)? I'm using "ecasound -a:1 -i miditest1.mid
> -o:alsa -Md:alsaseq,129:0", which seems to send a START
> and a STOP to the port, but nothing from the MIDI file
> itself. "aplaymidi -p 128:0 miditest1.mid" sends the data
> correctly (MIDI CC data that midimonster reads), but I
> can't get it to sync well with the wav data played by
> ecasound (i.e. running "ecasound XXXX & aplaymidi YYYY "
> doesn't start playback of both files at the same time due
> to longer and slightly variable startup time for ecasound)
>
> I've thought about trying to use nama, but it is crazy
> slow on the system I'm hoping to use for this project (Pi
> Zero W) whereas ecasound, aplaymidi, etc seem to run at a
> reasonable speed, and I'm not sure if nama is designed to
> be used for only playback purposes like what I'm doing
> here.

Midish is a MIDI editor/player that can play to any MIDI
port. Maybe it will suit your needs. Jeanette can tell
you more as she uses it a lot :-)

To be able to sync ecasound playback start with midi
playback, you have to load the ecasound chain setup (or
create it with IAM commands) and then issue 'cs-connect'.
This done, ecasound can start instaneously when you give it
the 'start' command.

Nama will start Ecasound and midish together and stop them
together. The Nama command prompt will pass through midish
commands but doesn't do any setup for you.

Nama does take time to start, especially the first run that
generates a registry of all the plugins available. After
that, on my mobile i5, it takes a second or two to load a
simple project and generate its chain setup (longer for
large projects.)

Nama could startup faster if it had an option to simply load
Ecasound with a pre-generated chain setup for a project.
Without having corresponding data structures, Nama would
lose realtime abilities, such as adjusting effects
parameters or fading on start/stop.

warm regards,

-- 
Joel Roth
_______________________________________________
Ecasound-list mailing list
Ecasound-list@email-addr-hidden
https://lists.sourceforge.net/lists/listinfo/ecasound-list
Received on Tue Dec 29 04:15:01 2020

This archive was generated by hypermail 2.1.8 : Tue Dec 29 2020 - 04:15:01 EET