Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Erlang Core MIDI

Erlang wrapper library for Core MIDI.

test() ->
    application:ensure_all_started(coremidi),

    {ok, Devices} = coremidi:list_devices(),

    {ok, Con} = coremidi:start_link([{device, "My MIDI Device"}, {entity, {0, 0}}]),


    % blocking recv
    Msg1 = coremidi:recv(Con),

    coremidi:send(Con, Msg1),


    % non blocking recv
    coremidi:arecv(Con),

    receive
        {Con, Msg2} ->
            coremidi:send(Con, Msg2)

    end,


    % non blocking sub
    coremidi:sub(Con),

    lists:foreach(fun(_) ->
            receive
                {Con, Msg} ->
                    coremidi:send(Con, Msg)

            end
        end,
        lists:seq(0, 9)),

    coremidi:unsub(Con),

    coremidi:stop(Con).

About

Erlang wrapper library for Core MIDI

Topics

Resources

License

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.