GithubHelp home page GithubHelp logo

node-midi's Introduction

♪ ♫ ♩ ♬

node-midi

A node.js wrapper for the RtMidi C++ library that provides realtime MIDI I/O. RtMidi supports Linux (ALSA & Jack), Macintosh OS X (CoreMidi), and Windows (Multimedia).

Build Status

Prerequisites

OSX

  • Some version of Xcode (or Command Line Tools)
  • Python (for node-gyp)

Windows

  • Microsoft Visual C++ (the Express edition works fine)
  • Python (for node-gyp)

Linux

  • A C++ compiler
  • You must have installed and configured ALSA. Without it this module will NOT build.
  • Install the libasound2-dev package.
  • Python (for node-gyp)

Installation

Installation uses node-gyp and requires Python 2.7.2 or higher.

From npm:

$ npm install midi

From source:

$ git clone https://github.com/justinlatimer/node-midi.git
$ cd node-midi/
$ npm install

Usage

MIDI Messages

This library deals with MIDI messages as JS Arrays for both input and output. For example, [144,69,127] is MIDI message with status code 144 which means "Note on" on "Channel 1".

For list of midi status codes, see http://www.midi.org/techspecs/midimessages.php

Input

const midi = require('midi');

// Set up a new input.
const input = new midi.Input();

// Count the available input ports.
input.getPortCount();

// Get the name of a specified input port.
input.getPortName(0);

// Configure a callback.
input.on('message', (deltaTime, message) => {
  // The message is an array of numbers corresponding to the MIDI bytes:
  //   [status, data1, data2]
  // https://www.cs.cf.ac.uk/Dave/Multimedia/node158.html has some helpful
  // information interpreting the messages.
  console.log(`m: ${message} d: ${deltaTime}`);
});

// Open the first available input port.
input.openPort(0);

// Sysex, timing, and active sensing messages are ignored
// by default. To enable these message types, pass false for
// the appropriate type in the function below.
// Order: (Sysex, Timing, Active Sensing)
// For example if you want to receive only MIDI Clock beats
// you should use
// input.ignoreTypes(true, false, true)
input.ignoreTypes(false, false, false);

// ... receive MIDI messages ...

// Close the port when done.
setTimeout(function() {
  input.closePort();
}, 100000);

Output

const midi = require('midi');

// Set up a new output.
const output = new midi.Output();

// Count the available output ports.
output.getPortCount();

// Get the name of a specified output port.
output.getPortName(0);

// Open the first available output port.
output.openPort(0);

// Send a MIDI message.
output.sendMessage([176,22,1]);

// Close the port when done.
output.closePort();

Virtual Ports

Instead of opening a connection to an existing MIDI device, on Mac OS X and Linux with ALSA you can create a virtual device that other software may connect to. This can be done simply by calling openVirtualPort(portName) instead of openPort(portNumber).

const midi = require('midi');

// Set up a new input.
const input = new midi.Input();

// Configure a callback.
input.on('message', (deltaTime, message) => {
    console.log(`m: ${message} d: ${deltaTime}`);
});

// Create a virtual input port.
input.openVirtualPort("Test Input");

// A midi device "Test Input" is now available for other
// software to send messages to.

// ... receive MIDI messages ...

// Close the port when done.
input.closePort();

The same can be done with output ports.

Streams

You can also use this library with streams! Here are the interfaces

Readable Stream

// create a readable stream
const stream1 = midi.createReadStream();

// createReadStream also accepts an optional `input` param
const input = new midi.Input();
input.openVirtualPort('hello world');

const stream2 = midi.createReadStream(input)

stream2.pipe(require('fs').createWriteStream('something.bin'));

Writable Stream

// create a writable stream
const stream1 = midi.createWriteStream();

// createWriteStream also accepts an optional `output` param
const output = new midi.Output();
output.openVirtualPort('hello again');

const stream2 = midi.createWriteStream(output);

require('fs').createReadStream('something.bin').pipe(stream2);

References

Maintainers

Contributors

License

Copyright (C) 2011-2021 by Justin Latimer.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

A different license may apply to other software included in this package, including RtMidi. Please consult their respective license files for the terms of their individual licenses.

node-midi's People

Contributors

a-rodin avatar amilajack avatar dependabot-preview[bot] avatar dependabot[bot] avatar drewish avatar dzoba avatar hhromic avatar imyller avatar jeremybernstein avatar jhorology avatar jjgonecrypto avatar julianduque avatar justinlatimer avatar luxigo avatar malvineous avatar malyn avatar michael-lawrence avatar nroadley avatar simeg avatar szymonkaliski avatar timsusa avatar tmpvar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

node-midi's Issues

input.on('message') doesn't receive MIDI clock signals

Hi!
I have following code

var midi = require("midi");

var input = new midi.input();
console.log(input.getPortCount());
console.log(input.getPortName(3));
input.on('message', function(deltaTime, message) {
  console.log('m:' + message + ' d:' + deltaTime);
});
input.openPort(3);
setTimeout(function() {
  input.closePort();
}, 1000000000);

I run it on OS X 10.9. There is a Traktor output sending MIDI clock messages on the 3rd port (I could monitor it with MIDI Monitor http://www.snoize.com/MIDIMonitor/). But the node.js code doesn't receive MIDI clock messages.
What to do with it?

Node crashes on socket.io connection.

I'm trying to use this in conjunction with socket.io. However, when socket.io connects, node crashes with a Segmentation Fault: 11. I'm running node v.0.10.3 on a macbook pro, I've tried using socket io library versions 1.0.3 and 1.0.6.

MIDI output produces no audio

(I suspect this is not a bug in node-midi, but there doesn't seem to be a better place to ask this, so...)

I'm trying to play MIDI sound on Ubuntu. node-midi shows five available ports, one Midi Through:0 and four TiMidity:[0-3]. However, if I try opening any of them and sending a noteon event, it doesn't do anything.

I haven't seen any errors from node-midi during this whole process, so I'm confused what could be going wrong. Running timidity or mplayer from the command line plays MIDI and MP3 files fine, so I don't think there's anything wrong with my system audio. And I can get MIDI input through node-midi, so some part of it is working okay.

I don't know if there's some sort of configuration for midi or alsa or something that I've missed? Any help would be appreciated.

I can only send CC messages, no note-ons?

I'm using this syntax, and following your example pretty explicitly. I tried looking at the RtMidi docs but still couldn't figure it out.

output.sendMessage([176,36,90]);

Support for JACK Audio Connection Kit

It seems that replacing __LINUX_ALSA__ with __UNIX_JACK__ and -lasound with -ljack in binding.gyp allows RtMidi to use JACK instead of ALSA for MIDI. However, adding both side-by-side seems to compile the library with just ALSA support. Is it possible to have both enabled, or to be able to choose which one to use?

closing a port twice crashes node

> input.closePort(0)
undefined
> input.closePort(0)
node: ../src/node_object_wrap.h:104: virtual void node::ObjectWrap::Unref(): Assertion `!handle_.IsWeak()' failed.
Aborted

node version v0.10.9

npm install fails when VS2015 RC is installed

It seems that the midi module can't be installed when Visual Studio 2015 RC is installed.
I can't recall the exact error but it was on node-midi.cpp I think.
I uninstalled VS2015 and reinstalled VS2013 and it worked fine after that

Build script appears to use hard-coded path name in /Users/justin

Any way I can work around this? I forked the project and searched it, but haven't tracked down the problem yet. I'm a bit of an npm newb.

The crucial line:

OSError: [Errno 2] No such file or directory: '/Users/justin/Documents/Projects/node-midi/build'

The full stack trace:

<airbook:giles> [01-17 17:10] ~/dev/fuck_yeah_hacking/coffeescript_arx_port master   
 ↪  npm install midi
npm http GET https://registry.npmjs.org/midi
npm http 304 https://registry.npmjs.org/midi

> [email protected] preinstall /Users/giles/dev/fuck_yeah_hacking/coffeescript_arx_port/node_modules/midi
> make

node-waf clean || true; node-waf configure build
Nothing to clean (project not configured)
Setting srcdir to                        : /Users/giles/dev/fuck_yeah_hacking/coffeescript_arx_port/node_modules/midi 
Setting blddir to                        : /Users/giles/dev/fuck_yeah_hacking/coffeescript_arx_port/node_modules/midi/build 
Checking for program g++ or c++          : /usr/bin/g++ 
Checking for program cpp                 : /usr/bin/cpp 
Checking for program ar                  : /usr/bin/ar 
Checking for program ranlib              : /usr/bin/ranlib 
Checking for g++                         : ok  
Checking for node path                   : ok /Users/giles/.node_libraries 
Checking for node prefix                 : ok /usr/local/n/versions/0.6.7 
'configure' finished successfully (0.079s)
Waf: Entering directory `/Users/justin/Documents/Projects/node-midi/build'
Waf: Leaving directory `/Users/justin/Documents/Projects/node-midi/build'
Traceback (most recent call last):
  File "/usr/local/n/versions/0.6.7/bin/node-waf", line 16, in <module>
    Scripting.prepare(t, os.getcwd(), VERSION, wafdir)
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Scripting.py", line 145, in prepare
    prepare_impl(t, cwd, ver, wafdir)
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Scripting.py", line 135, in prepare_impl
    main()
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Scripting.py", line 188, in main
    fun(ctx)
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Scripting.py", line 386, in build
    return build_impl(bld)
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Scripting.py", line 405, in build_impl
    bld.compile()
  File "/usr/local/n/versions/0.6.7/bin/../lib/node/wafadmin/Build.py", line 268, in compile
    os.chdir(self.bldnode.abspath())
OSError: [Errno 2] No such file or directory: '/Users/justin/Documents/Projects/node-midi/build'
make: *** [all] Error 1
npm ERR! error installing [email protected]
npm ERR! [email protected] preinstall: `make`
npm ERR! `sh "-c" "make"` failed with 2
npm ERR! 
npm ERR! Failed at the [email protected] preinstall script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     make
npm ERR! You can get their info via:
npm ERR!     npm owner ls midi
npm ERR! There is likely additional logging output above.
npm ERR! 
npm ERR! System Darwin 10.8.0
npm ERR! command "node" "/usr/local/n/versions/0.6.7/bin/npm" "install" "midi"
npm ERR! cwd /Users/giles/dev/fuck_yeah_hacking/coffeescript_arx_port
npm ERR! node -v v0.6.7
npm ERR! npm -v 1.1.0-beta-10
npm ERR! code ELIFECYCLE
npm ERR! message [email protected] preinstall: `make`
npm ERR! message `sh "-c" "make"` failed with 2
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/giles/dev/fuck_yeah_hacking/coffeescript_arx_port/npm-debug.log
npm not ok

problem installing module

(previously added to issue #16 moved to here)
Failure installing the module on the following environment:

OSX10.7.5, latest xcode
node & npm installed via mac ports (node: v0.10.12/npm: 1.2.30)

i.e. this is a new environment, macports just grabbed the latest versions avail

npm is fetching midi 0.7.0 from the repo

When I do 'npm install midi' - this is what I get, immediately after the node-gyp rebuild:

CXX(target) Release/obj.target/midi/src/node-midi.o
In file included from ../src/node-midi.cpp:8:
../src/lib/RtMidi/RtMidi.cpp:473:26: warning: implicit conversion of NULL
constant to 'MIDIEntityRef' (aka 'unsigned int') [-Wnull-conversion]
MIDIEntityRef entity = NULL;
~~~~~~ ^~~~
0

& the module is not built, so 'require('midi')' fails.

update: checking on a macbook with known working midi 0.7.0: same config (Lion 10.7.5, node/npm via macPorts).
With node = 0.10.10 & npm = 1.2.28. node midi seems to work fine.

In order to preserve your working version when updating packages via MacPorts you can exclude node & npm by using something like:

'sudo port upgrade outdated and not nodejs or npm'

A

Error: Could not load the bindings file

Hi. I'm a node newbie (sorry!) wanting to try out this module. I tried installing it and testing it (on OSX 10.7.4) and this is the result. Any ideas?

Williams-iMac:~ william$ npm install midi
npm http GET https://registry.npmjs.org/midi
npm http 304 https://registry.npmjs.org/midi
npm http GET https://registry.npmjs.org/bindings
npm http 304 https://registry.npmjs.org/bindings
[email protected] ./node_modules/midi
└── [email protected]
Williams-iMac:~ william$ npm test midi

[email protected] test /Users/william/node_modules/midi
node test/virtual-loopback-test-automated.js

/Users/william/node_modules/midi/node_modules/bindings/bindings.js:87
throw err
^
Error: Could not load the bindings file. Tried:
→ /Users/william/node_modules/midi/build/midi.node
→ /Users/william/node_modules/midi/build/Debug/midi.node
→ /Users/william/node_modules/midi/build/Release/midi.node
→ /Users/william/node_modules/midi/out/Debug/midi.node
→ /Users/william/node_modules/midi/Debug/midi.node
→ /Users/william/node_modules/midi/out/Release/midi.node
→ /Users/william/node_modules/midi/Release/midi.node
→ /Users/william/node_modules/midi/build/default/midi.node
→ /Users/william/node_modules/midi/compiled/0.8.2/darwin/x64/midi.node
at bindings (/Users/william/node_modules/midi/node_modules/bindings/bindings.js:84:13)
at Object. (/Users/william/node_modules/midi/midi.js:1:93)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:362:17)
at require (module.js:378:17)
at Object. (/Users/william/node_modules/midi/test/virtual-loopback-test-automated.js:1:74)
at Module._compile (module.js:449:26)
npm ERR! [email protected] test: node test/virtual-loopback-test-automated.js
npm ERR! sh "-c" "node test/virtual-loopback-test-automated.js" failed with 1
npm ERR!
npm ERR! Failed at the [email protected] test script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node test/virtual-loopback-test-automated.js
npm ERR! You can get their info via:
npm ERR! npm owner ls midi
npm ERR! There is likely additional logging output above.
npm ERR!
npm ERR! System Darwin 11.4.0
npm ERR! command "node" "/usr/local/bin/npm" "test" "midi"
npm ERR! cwd /Users/william
npm ERR! node -v v0.8.2
npm ERR! npm -v 1.1.0-beta-4
npm ERR! code ELIFECYCLE
npm ERR! message [email protected] test: node test/virtual-loopback-test-automated.js
npm ERR! message sh "-c" "node test/virtual-loopback-test-automated.js" failed with 1
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /Users/william/npm-debug.log
npm not ok

Can not build or run with node v0.12.0 on OS X

Hello,
i can not build or run the node module with node.js v0.12.0 on OS X Mavericks. It seems to be a problem with the new v8 version, node v0.12.0 uses.
When i'm trying to install it with

npm install midi

i get lots of errors and

Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild

Whe i use a prebuild module, i get

Error: Module did not self-register.

Greets and thanks in advance,
Christian

Error: Module version mismatch

I get this after entering node and calling the module:

$ node
require('midi');

Full error :

Error: Module version mismatch. Expected 11, got 1.
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object. (/home/user/node_modules/canvas/lib/bindings.js:2:18)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)

Windows Error MSB8007 When Installing

Hello --

I tried to install a module (launchpadder) that relies on node-midi and I encountered the error 'MSB8007' when it got to the node-midi stage of the build.

I have Python v2.7.5 and just installed Microsoft Visual Studios C++ 2010 Express edition. I'm not too savvy on C++ so I'm not really sure where to go next. Googling the issue had results of other projects dealing with x64, but it's not really clear what I have to do to resolve the issue. The output from the install command is below:

D:\_WORK\SPECTRUMBRANCH\github\launchpad-tests>npm install launchpadder --save
npm WARN package.json [email protected] No description
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No README data
npm http GET https://registry.npmjs.org/launchpadder
npm http 304 https://registry.npmjs.org/launchpadder
npm http GET https://registry.npmjs.org/midi
npm http 304 https://registry.npmjs.org/midi
npm http GET https://registry.npmjs.org/bindings
npm http 304 https://registry.npmjs.org/bindings

> [email protected] install D:\_WORK\SPECTRUMBRANCH\github\launchpad-tests\node_modules\launchpad
der\node_modules\midi
> node-gyp rebuild


D:\_WORK\SPECTRUMBRANCH\github\launchpad-tests\node_modules\launchpadder\node_modules\midi
>node "D:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-
gyp\bin\node-gyp.js" rebuild
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.Cpp.InvalidPlatform.Targets(2
3,7): error MSB8007: The Platform for project 'midi.vcxproj' is invalid.  Platform='x64'.
 You may be seeing this message because you are trying to build a project without a solut
ion file, and have specified a non-default Platform that doesn't exist for this project.
[D:\_WORK\SPECTRUMBRANCH\github\launchpad-tests\node_modules\launchpadder\node_modules\mi
di\build\midi.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe` failed w
ith exit code: 1
gyp ERR! stack     at ChildProcess.onExit (D:\Program Files\nodejs\node_modules\npm\node_m
odules\node-gyp\lib\build.js:267:23)
gyp ERR! stack     at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:789:12)
gyp ERR! System Windows_NT 6.1.7600
gyp ERR! command "node" "D:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-
gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd D:\_WORK\SPECTRUMBRANCH\github\launchpad-tests\node_modules\launchpadder\node
_modules\midi
gyp ERR! node -v v0.10.21
gyp ERR! node-gyp -v v0.10.10
gyp ERR! not ok
npm ERR! weird error 1
npm ERR! not ok code 0


Thanks for your time.

Packages in README

Would be useful if the packages required to build the module were in the readme

Example: sudo apt-get install libasound2-dev

Can't find CoreMIDI/CoreMIDI.h or CoreAudio/HostTime.h

I apologise in advance for the length of this stack trace. I'm a node.js / npm n00b, (following Giles Bowkett's new screencast series), and can't get node-midi compiled/installed. My environment is a 13" Macbook Air (Mid 2011), Mac OSX Lion, 10.7.3 with node installed via the official OSX package and npm via the shell script. I'm not even sure if it's a node issue / npm issue / or system architecture issue. I wonder if anyone else is coming across this?

$ node -v
v0.6.11
$ npm -v
1.1.2
$ npm install midi
npm http GET https://registry.npmjs.org/midi
npm http 200 https://registry.npmjs.org/midi
npm http GET https://registry.npmjs.org/midi/-/midi-0.5.0.tgz
npm http 200 https://registry.npmjs.org/midi/-/midi-0.5.0.tgz

> [email protected] preinstall /Users/pootsbook/node_modules/midi
> make

node-waf clean || true; node-waf configure build
Nothing to clean (project not configured)
Setting srcdir to                        : /Users/pootsbook/node_modules/midi 
Setting blddir to                        : /Users/pootsbook/node_modules/midi/build 
Checking for program g++ or c++          : /usr/bin/g++ 
Checking for program cpp                 : /usr/bin/cpp 
Checking for program ar                  : /usr/bin/ar 
Checking for program ranlib              : /usr/bin/ranlib 
Checking for g++                         : ok  
Checking for node path                   : not found 
Checking for node prefix                 : ok /usr/local 
'configure' finished successfully (0.046s)
Waf: Entering directory `/Users/pootsbook/node_modules/midi/build'
[1/2] cxx: src/node-midi.cpp -> build/Release/src/node-midi_1.o
In file included from ../src/node-midi.cpp:8:
../src/lib/RtMidi/RtMidi.cpp:170:31: error: CoreMIDI/CoreMIDI.h: No such file or directory
../src/lib/RtMidi/RtMidi.cpp:171:32: error: CoreAudio/HostTime.h: No such file or directory
In file included from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:21:19: error: AE/AE.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:25:35: error: CarbonCore/CarbonCore.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:29:35: error: OSServices/OSServices.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:33:43: error: CoreFoundation/CoreFoundation.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:37:33: error: CFNetwork/CFNetwork.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:41:43: error: LaunchServices/LaunchServices.h: No such file or directory
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:30,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:20:35: error: CoreFoundation/CFBase.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:24:34: error: CoreFoundation/CFURL.h: No such file or directory
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:34,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:20:37: error: CoreFoundation/CFString.h: No such file or directory
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:38,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:28:41: error: CoreFoundation/CFDictionary.h: No such file or directory
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:42,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:32:35: error: CoreFoundation/CFDate.h: No such file or directory
In file included from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:48:31: error: Metadata/Metadata.h: No such file or directory
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:49:51: error: DictionaryServices/DictionaryServices.h: No such file or directory
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:30,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:51: error: ‘CFTypeRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:66: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:97: error: ‘SKDocumentRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:115: error: ‘CFURLRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:156: error: ‘SKDocumentRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:182: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:205: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKDocument.h:229: error: ‘SKDocumentRef’ does not name a type
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:34,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:54: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:71: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:88: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:107: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:127: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:146: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:165: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:184: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKAnalysis.h:207: error: ‘CFStringRef’ does not name a type
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:38,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:74: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:98: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:215: error: ‘CFURLRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:216: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:217: error: expected primary-expression before ‘inIndexType’
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:218: error: ‘CFDictionaryRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:218: error: initializer expression list treated as compound expression
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:256: error: ‘CFURLRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:257: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:258: error: ‘Boolean’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:258: error: initializer expression list treated as compound expression
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:295: error: ‘CFMutableDataRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:296: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:297: error: expected primary-expression before ‘inIndexType’
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:298: error: ‘CFDictionaryRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:298: error: initializer expression list treated as compound expression
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:332: error: ‘CFDataRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:333: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:333: error: initializer expression list treated as compound expression
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:368: error: ‘CFMutableDataRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:369: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:369: error: initializer expression list treated as compound expression
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:393: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:411: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:429: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:455: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:497: error: ‘CFDictionaryRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:521: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:543: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:574: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:623: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:655: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:676: error: ‘CFDictionaryRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:698: error: ‘SKDocumentRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:699: error: ‘CFDictionaryRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:723: error: ‘SKDocumentRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:741: error: ‘SKDocumentID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:758: error: ‘SKDocumentRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:775: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:793: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:815: error: ‘SKDocumentRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:834: error: ‘SKDocumentRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:852: error: ‘SKDocumentID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:867: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:887: error: ‘CFArrayRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:904: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:927: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:942: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:962: error: ‘CFArrayRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:979: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKIndex.h:999: error: ‘CFIndex’ does not name a type
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:42,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:78: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:90: error: ‘UInt32’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:131: error: ‘CFStringRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:132: error: ‘SKSearchOptions’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:194: error: ‘Boolean’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:238: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:239: error: ‘SKDocumentID’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:240: error: ‘CFStringRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:241: error: ‘SKDocumentID’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:272: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:273: error: ‘SKDocumentID’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:274: error: ‘SKDocumentRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:305: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:306: error: ‘SKDocumentID’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:307: error: ‘CFURLRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:335: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:358: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:411: error: typedef ‘CALLBACK_API_C’ is initialized (use __typeof__ instead)
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:411: error: ‘Boolean’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:411: error: ‘SKSearchResultsFilterCallBack’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:435: error: ‘CFArrayRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:452: error: ‘CFArrayRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:501: error: ‘CFStringRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:503: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:505: error: ‘SKSearchResultsFilterCallBack’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:551: error: ‘CFArrayRef’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:552: error: ‘CFIndex’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:554: error: ‘SKSearchResultsFilterCallBack’ has not been declared
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:568: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:617: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSearch.h:649: error: ‘CFArrayRef’ does not name a type
In file included from /System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SearchKit.h:46,
                 from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:45,
                 from ../src/lib/RtMidi/RtMidi.cpp:172,
                 from ../src/node-midi.cpp:8:
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:68: error: ‘CFTypeID’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:97: error: ‘CFStringRef’ was not declared in this scope
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:116: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:136: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:159: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:184: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:210: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:236: error: ‘CFStringRef’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:277: error: ‘CFIndex’ does not name a type
/System/Library/Frameworks/CoreServices.framework/Frameworks/SearchKit.framework/Headers/SKSummary.h:317: error: ‘CFIndex’ does not name a type
In file included from ../src/node-midi.cpp:8:
../src/lib/RtMidi/RtMidi.cpp:177: error: ‘MIDIClientRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:178: error: ‘MIDIPortRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:179: error: ‘MIDIEndpointRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:180: error: ‘MIDIEndpointRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:182: error: ‘MIDISysexSendRequest’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:190: error: expected ‘,’ or ‘...’ before ‘*’ token
../src/lib/RtMidi/RtMidi.cpp:190: error: ISO C++ forbids declaration of ‘MIDIPacketList’ with no type
../src/lib/RtMidi/RtMidi.cpp: In function ‘void midiInputCallback(int)’:
../src/lib/RtMidi/RtMidi.cpp:192: error: ‘procRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:202: error: expected initializer before ‘*’ token
../src/lib/RtMidi/RtMidi.cpp:203: error: ‘list’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:214: error: ‘packet’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:224: error: ‘AudioGetCurrentHostTime’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:227: error: ‘AudioConvertHostTimeToNanos’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:232: error: ‘AudioGetCurrentHostTime’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:333: error: ‘MIDIPacketNext’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘void RtMidiIn::initialize(const std::string&)’:
../src/lib/RtMidi/RtMidi.cpp:340: error: ‘MIDIClientRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:340: error: expected `;' before ‘client’
../src/lib/RtMidi/RtMidi.cpp:341: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:341: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:342: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:342: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:349: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:349: error: ‘client’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:350: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiIn::openPort(unsigned int, std::string)’:
../src/lib/RtMidi/RtMidi.cpp:363: error: ‘MIDIGetNumberOfSources’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:376: error: ‘MIDIPortRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:376: error: expected `;' before ‘port’
../src/lib/RtMidi/RtMidi.cpp:378: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:378: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:381: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:381: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:382: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:382: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:388: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:388: error: expected `;' before ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:389: error: ‘endpoint’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:390: error: ‘port’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:390: error: ‘MIDIPortDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:391: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:391: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:397: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:397: error: ‘port’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:397: error: ‘endpoint’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:397: error: ‘MIDIPortConnectSource’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:398: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:399: error: ‘MIDIPortDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:400: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:400: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:406: error: ‘struct CoreMidiData’ has no member named ‘port’
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiIn::openVirtualPort(std::string)’:
../src/lib/RtMidi/RtMidi.cpp:416: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:416: error: expected `;' before ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:417: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:417: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:420: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:420: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:426: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:426: error: ‘endpoint’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiIn::closePort()’:
../src/lib/RtMidi/RtMidi.cpp:433: error: ‘struct CoreMidiData’ has no member named ‘port’
../src/lib/RtMidi/RtMidi.cpp:433: error: ‘MIDIPortDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In destructor ‘virtual RtMidiIn::~RtMidiIn()’:
../src/lib/RtMidi/RtMidi.cpp:445: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:445: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:446: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:446: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:446: error: ‘MIDIEndpointDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual unsigned int RtMidiIn::getPortCount()’:
../src/lib/RtMidi/RtMidi.cpp:455: error: ‘MIDIGetNumberOfSources’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: At global scope:
../src/lib/RtMidi/RtMidi.cpp:460: error: ‘CFStringRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp:530: error: ‘CFStringRef’ does not name a type
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual std::string RtMidiIn::getPortName(unsigned int)’:
../src/lib/RtMidi/RtMidi.cpp:584: error: ‘CFStringRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:584: error: expected `;' before ‘nameRef’
../src/lib/RtMidi/RtMidi.cpp:585: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:585: error: expected `;' before ‘portRef’
../src/lib/RtMidi/RtMidi.cpp:590: error: ‘MIDIGetNumberOfSources’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:598: error: ‘portRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:598: error: ‘MIDIGetSource’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:599: error: ‘nameRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:599: error: ‘ConnectedEndpointName’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:600: error: ‘CFStringGetCString’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:601: error: ‘CFRelease’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual unsigned int RtMidiOut::getPortCount()’:
../src/lib/RtMidi/RtMidi.cpp:613: error: ‘MIDIGetNumberOfDestinations’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual std::string RtMidiOut::getPortName(unsigned int)’:
../src/lib/RtMidi/RtMidi.cpp:618: error: ‘CFStringRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:618: error: expected `;' before ‘nameRef’
../src/lib/RtMidi/RtMidi.cpp:619: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:619: error: expected `;' before ‘portRef’
../src/lib/RtMidi/RtMidi.cpp:624: error: ‘MIDIGetNumberOfDestinations’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:632: error: ‘portRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:632: error: ‘MIDIGetDestination’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:633: error: ‘nameRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:633: error: ‘ConnectedEndpointName’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:634: error: ‘CFStringGetCString’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:635: error: ‘CFRelease’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘void RtMidiOut::initialize(const std::string&)’:
../src/lib/RtMidi/RtMidi.cpp:643: error: ‘MIDIClientRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:643: error: expected `;' before ‘client’
../src/lib/RtMidi/RtMidi.cpp:644: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:644: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:645: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:645: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:652: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:652: error: ‘client’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:653: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiOut::openPort(unsigned int, std::string)’:
../src/lib/RtMidi/RtMidi.cpp:665: error: ‘MIDIGetNumberOfDestinations’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:678: error: ‘MIDIPortRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:678: error: expected `;' before ‘port’
../src/lib/RtMidi/RtMidi.cpp:680: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:680: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:683: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:683: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:684: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:684: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:690: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:690: error: expected `;' before ‘destination’
../src/lib/RtMidi/RtMidi.cpp:691: error: ‘destination’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:692: error: ‘port’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:692: error: ‘MIDIPortDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:693: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:693: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:699: error: ‘struct CoreMidiData’ has no member named ‘port’
../src/lib/RtMidi/RtMidi.cpp:699: error: ‘port’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:700: error: ‘struct CoreMidiData’ has no member named ‘destinationId’
../src/lib/RtMidi/RtMidi.cpp:700: error: ‘destination’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiOut::closePort()’:
../src/lib/RtMidi/RtMidi.cpp:708: error: ‘struct CoreMidiData’ has no member named ‘port’
../src/lib/RtMidi/RtMidi.cpp:708: error: ‘MIDIPortDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘virtual void RtMidiOut::openVirtualPort(std::string)’:
../src/lib/RtMidi/RtMidi.cpp:717: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:724: error: ‘MIDIEndpointRef’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:724: error: expected `;' before ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:725: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:725: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:728: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:728: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:734: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:734: error: ‘endpoint’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In destructor ‘virtual RtMidiOut::~RtMidiOut()’:
../src/lib/RtMidi/RtMidi.cpp:744: error: ‘struct CoreMidiData’ has no member named ‘client’
../src/lib/RtMidi/RtMidi.cpp:744: error: ‘MIDIClientDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:745: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:745: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:745: error: ‘MIDIEndpointDispose’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: At global scope:
../src/lib/RtMidi/RtMidi.cpp:751: error: variable or field ‘sysexCompletionProc’ declared void
../src/lib/RtMidi/RtMidi.cpp:751: error: ‘MIDISysexSendRequest’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:751: error: ‘sreq’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp: In member function ‘void RtMidiOut::sendMessage(std::vector<unsigned char, std::allocator<unsigned char> >*)’:
../src/lib/RtMidi/RtMidi.cpp:771: error: ‘MIDITimeStamp’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:771: error: expected `;' before ‘timeStamp’
../src/lib/RtMidi/RtMidi.cpp:773: error: ‘OSStatus’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:773: error: expected `;' before ‘result’
../src/lib/RtMidi/RtMidi.cpp:788: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:788: error: ‘struct CoreMidiData’ has no member named ‘destinationId’
../src/lib/RtMidi/RtMidi.cpp:789: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:789: error: ‘Byte’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:789: error: expected primary-expression before ‘)’ token
../src/lib/RtMidi/RtMidi.cpp:789: error: expected `;' before ‘sysexBuffer’
../src/lib/RtMidi/RtMidi.cpp:790: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:791: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:792: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:792: error: ‘sysexCompletionProc’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:793: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:793: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:795: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:795: error: ‘struct CoreMidiData’ has no member named ‘sysexreq’
../src/lib/RtMidi/RtMidi.cpp:795: error: ‘MIDISendSysex’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:796: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:808: error: ‘MIDIPacketList’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:808: error: expected `;' before ‘packetList’
../src/lib/RtMidi/RtMidi.cpp:809: error: ‘MIDIPacket’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:809: error: ‘packet’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:809: error: ‘packetList’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:809: error: ‘MIDIPacketListInit’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:810: error: ‘timeStamp’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:810: error: ISO C++ forbids declaration of ‘type name’ with no type
../src/lib/RtMidi/RtMidi.cpp:810: error: ISO C++ forbids declaration of ‘type name’ with no type
../src/lib/RtMidi/RtMidi.cpp:810: error: expected primary-expression before ‘const’
../src/lib/RtMidi/RtMidi.cpp:810: error: expected `)' before ‘const’
../src/lib/RtMidi/RtMidi.cpp:817: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:818: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:818: error: ‘struct CoreMidiData’ has no member named ‘endpoint’
../src/lib/RtMidi/RtMidi.cpp:818: error: ‘MIDIReceived’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:819: error: ‘noErr’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:827: error: ‘result’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:827: error: ‘struct CoreMidiData’ has no member named ‘port’
../src/lib/RtMidi/RtMidi.cpp:827: error: ‘struct CoreMidiData’ has no member named ‘destinationId’
../src/lib/RtMidi/RtMidi.cpp:827: error: ‘MIDISend’ was not declared in this scope
../src/lib/RtMidi/RtMidi.cpp:828: error: ‘noErr’ was not declared in this scope
Waf: Leaving directory `/Users/pootsbook/node_modules/midi/build'
Build failed:  -> task failed (err #1): 
    {task: cxx node-midi.cpp -> node-midi_1.o}
make: *** [all] Error 1
npm ERR! error installing [email protected]

npm ERR! [email protected] preinstall: `make`
npm ERR! `sh "-c" "make"` failed with 2
npm ERR! 
npm ERR! Failed at the [email protected] preinstall script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     make
npm ERR! You can get their info via:
npm ERR!     npm owner ls midi
npm ERR! There is likely additional logging output above.
npm ERR! 
npm ERR! System Darwin 11.3.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "midi"
npm ERR! cwd /Users/pootsbook
npm ERR! node -v v0.6.11
npm ERR! npm -v 1.1.2
npm ERR! code ELIFECYCLE
npm ERR! message [email protected] preinstall: `make`
npm ERR! message `sh "-c" "make"` failed with 2
npm ERR! errno {}
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/pootsbook/npm-debug.log
npm not ok

"pointer being freed was not allocated"

becojo:dimidi benoitcote-jodoin$ node start.js
node(12219,0x7fff73c16960) malloc: *** error for object 0x7feaa2400480: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort trap: 6

I never encounter this error before. I thought it was because I upgraded to node v0.8.2 but I just removed everything and installed node v0.6.9 and I still get this error.

node version and midi_addon.node location problem

22:38:40 isaacs: my problem is that binary module .node file location changed since node 0.5.4, so it could be nice if we could upload many versions of the same package and let npm install the right one depending on the package.json engine:node version ... or maybe it would be sufficient to use fs.stat in a script loading the module instead.. dunno..
22:41:24 luxigo: if you're installing from a dependency in a package.json file, it does filter based on node version.
22:41:55 luxigo: if you have a dep that moved things around, and you need to be aware of that, and it's not setting a "main" module to abstract this out, sorry, you're just gonna have to deal with it.
22:45:24 isaacs: waf since node 0.5.4 place the binary modules (.node) it builds in another directory
22:46:40 luxigo: publish two versions with different "engines" settings, and appropriate "main" modules. or, have a "main" module that's js and does an fs.statSync to find the right one.
22:47:08 luxigo: i'd just abandon support for 0.5.0 - 0.5.4
22:47:16 luxigo: and then assume that the 0.5-compatible one is latest 0.5

Unable to find ports on Debian Linux

Currently I am trying to use a MPK Midi Keyboard with a BeagleBone Black. The BeagleBone runs Debian 7.5.

I'm able to find the Midi Device by entering $ amidi -l

Dir Device    Name
IO  hw:1,0,0  MPK mini MIDI 1

and $ cat /proc/asound/cards

 0 [Black          ]: TI_BeagleBone_B - TI BeagleBone Black
                      TI BeagleBone Black
 1 [mini           ]: USB-Audio - MPK mini
                      AKAI PROFESSIONAL,LP MPK mini at usb-musb-hdrc.1.auto-1.2, full speed

I am even able to get some midi input with $ cat /dev/midi1. But I'm not able to connect to the keyboard via node-midi. The number of devices is always zero.

$ sudo node index.js 
INFO   midi              "Number of Ports: 0"

Does anyone knows a solution to this problem or can point me in the right direction? Currently I'm clueless.

Thanks

Implementing in node-webkit

I wanted to implement node-midi into a node-webkit application but I run into the following error:

Uncaught Error:
dlopen(/Users/yoeran/GruntProjects/tapsequencer/dist/TapSequencer.app/Contents/Resources/app.nw/node_modules/midi/build/Release/midi.node, 1):
no suitable image found.
Did find:
/Users/yoeran/GruntProjects/tapsequencer/dist/TapSequencer.app/Contents/Resources/app.nw/node_modules/midi/build/Release/midi.node: mach-o, but wrong architecture",
source: 
/Users/yoeran/GruntProjects/tapsequencer/dist/TapSequencer.app/Contents/Resources/app.nw/node_modules/midi/node_modules/bindings/bindings.js (83)

node-midi is running fine on my macbook when I use it in a single script and run it with node.
The packaging on behalf of node-webkit might confuse the routing for node-midi.
Any thoughts, hints or tips on how I can fix this?

Specs:
OS: OSX 10.9.3, Darwin 13.2.0 x86_64
Node: v0.10.28 (via NVM)
Node-midi: ^0.9.0

Node-webkit by Roger Wang: https://github.com/rogerwang/node-webkit

io.js 3.0 and raspberry pi using debian fails

Seems to completely crash and burn, mostly in the nan sub-package. Anyone else got this running or is this stable on some other version of io.js?

Using straight from git, Alsa has been installed (asoundlib2-dev), python 2.7 exists, and node-gyp is installed. Alsa utils and alsa-oss are installed and working.

kernel: Linux marjipoor 3.18.11+ #781 PREEMPT Tue Apr 21 18:02:18 BST 2015 armv6l GNU/Linux
gcc version: gcc (Debian 4.6.3-14+rpi1) 4.6.3
g++ version: g++ (Debian 4.6.3-14+rpi1) 4.6.3

Here's the error: http://pastebin.com/g8sL5qcw

ALESIS Guitar Link Plus

when I call input.getPortCount() it returns 0 despite that cable is connected. does node-midi support alesis guitar link cable?

Windows install of midi 0.5.0

Just tried to install with npm on Windows 7 but the install failed. Any plans to support Windows?

C:\Users\home>npm install midi
npm http GET https://registry.npmjs.org/midi
npm http 304 https://registry.npmjs.org/midi

[email protected] preinstall C:\Users\home\node_modules\midi
make

'make' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! error installing [email protected]

npm ERR! [email protected] preinstall: make
npm ERR! cmd "/c" "make" failed with 1
npm ERR!
npm ERR! Failed at the [email protected] preinstall script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! make
npm ERR! You can get their info via:
npm ERR! npm owner ls midi
npm ERR! There is likely additional logging output above.
npm ERR!
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\Program Files (x86)\nodejs\node.exe" "C:\Program File
s (x86)\nodejs\node_modules\npm\bin\npm-cli.js" "install" "midi"
npm ERR! cwd C:\Users\home
npm ERR! node -v v0.6.12
npm ERR! npm -v 1.1.4
npm ERR! code ELIFECYCLE
npm ERR! message [email protected] preinstall: make
npm ERR! message cmd "/c" "make" failed with 1
npm ERR! errno {}
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\home\npm-debug.log
npm not ok

Problem receiving SysEx on Windows

Is anyone using Windows and receiving SysEx messages? I am not receiving them - have set the ignoreTypes to false, and other messages work fine. I tried putting some debug messages in the RtMidi code and saw open/close/etc. messages but not any sysex data ones. I also built a small cpp wrapper around the RtMidi code and it does see them (identity reply). Anything else I can try?

Can not install on win 8.1

I am trying to install the node-midi package on Windows 8.
Python and Visual Studio Express 2013 have been installed beforehand but I keep getting this error:

C:\Program Files (x86)\Windows Kits\8.1\Include\um\winsock2.h(882): fatal error C1083: Datei (Include) kann nicht geöffnet werden: "qos.h": No such file or directory [C:\Users\Marco\AppData\Roaming\npm\node_modules\midi\build\midi.vcxproj]

I can't find any information about the "gos.h" file that is missing and can't check the midi.vcxproj file because the installer removes it immediately as it seems.

Any hints on what I could try?

Thansk in advance.

Crash when instantiating multiple midi input instances

To start, thank you for this amazing software. It's been incredibly useful.

We've been experiencing crashes using this package on OSX (may not be OSX specific). This occurs when we instantiate two midi.input objects and then only use one of them. I'm not sure if this is expected functionality but since it's not documented, I assume it's not.

We put together a small test to demonstrate the crashes here (steps to reproduce are at the bottom):
https://github.com/OSCModulator/midi-test/blob/master/midi-test.coffee

Test 2 seems to crash somewhere around 382 messages.

We'd love your thoughts on this. For the moment we plan to work around the issue.

Thanks again for this great tool!

closed virtual ports still "hang around"

If I do this:

var output;

function newOutput(name) {
  if (output) { output.closePort(); }

  output = new midi.output();
  output.openVirtualPort(name);
}

newOutput("test-1");
newOutput("test-2");
newOutput("test-3");

I would like to see only "test-3" in Max/MSP, Ableton, etc... but I get all of the outputs (with test-1 and test-2) even thought I closed them. Is there something I can do to "clean" those up?

node/win32 crash when creating a NodeMidiInput instance

Since binary external modules are not supported on win32 yet,
node-midi must be compiled as an internal module on win32 (https://gist.github.com/1247101)

It works great on linux, but on windows node crash when you create a NodeMidiInput instance. The problem seems to be libev or pthread.

In MSVC I had to include ev.h and link with libev (that was compiled as a separate project). Maybe that's the problem.

:7üC:

Publish to npm

Support for Node.js 4.0.0 has been added but module isn't on npm yet

Set tempo

Hi all,

Great piece of software!

Quick question, I don't understand how to send a tempo.

For example?
output.sendMessage([ ??? ])
How to send the tempo?

No MIDI input devices ?

Hi!

I tried to use Your component under Windows 7 Pro 64bit, node.js v 0.10.12
but I cant get any MDII input device:

tMidiIn::initialize: no MIDI input devices currently available.
tMidiIn::getPortName: the 'portNumber' argument (0) is invalid.

I am using Python 2.7.5 and have VC++ 2010 installed.

any ideas ?

Thanx,
Hans

Not working

Can't read or write using streams or messages. Device is a USB-2-MIDI thing I ordered off amazon. It shows up in the device list from the library as "USB2.0-MIDI:0" twice when it is an output stream, once when it is an input.

node-midi fails to work with nwjs or atom-shell

I'm getting the following error with nwjs and atom-shell if I install with npm install midi:

"Uncaught Error: Module did not self-register.", source: .../node_modules/midi/node_modules/bindings/bindings.js (83)

If I try to use apm install . for atom-shell, node-gyp just throws up and doesn't even build.

Upgrade to node 0.10.x segfaults

Hi,

I've just upgraded to node 0.10. from the last stable 0.8 release. Node midi now, sadly, segfaults when required.

I've done the obvious (to my mind), and rebuilt/reinstalled it; but to no avail. I tried giving it a go with this (https://github.com/ddopson/node-segfault-handler) but haven't had any luck getting any output yet. I'll be having another go as soon as I have time.

I'm no node expert, so If there is something I should have done ready for release 0.10 I'd be happy to do it if I knew what it was.

Cheers

Si

can't find CoreMIDI.h

$ npm install midi

> [email protected] preinstall /home/substack/projects/node-jammin/node_modules/midi
> node-waf configure && node-waf build

Setting srcdir to                        : /home/substack/projects/node-jammin/node_modules/midi 
Setting blddir to                        : /home/substack/projects/node-jammin/node_modules/midi/build 
Checking for program g++ or c++          : /usr/bin/g++ 
Checking for program cpp                 : /usr/bin/cpp 
Checking for program ar                  : /usr/bin/ar 
Checking for program ranlib              : /usr/bin/ranlib 
Checking for g++                         : ok  
Checking for node path                   : not found 
Checking for node prefix                 : ok /home/substack/prefix 
'configure' finished successfully (0.600s)
Waf: Entering directory `/home/substack/projects/node-jammin/node_modules/midi/build'
[1/2] cxx: src/node-midi.cpp -> build/default/src/node-midi_1.o
In file included from ../src/node-midi.cpp:6:0:
../src/lib/RtMidi/RtMidi.cpp:167:31: fatal error: CoreMIDI/CoreMIDI.h: No such file or directory
compilation terminated.
Waf: Leaving directory `/home/substack/projects/node-jammin/node_modules/midi/build'
Build failed:  -> task failed (err #1): 
    {task: cxx node-midi.cpp -> node-midi_1.o}
npm ERR! error installing [email protected] Error: [email protected] preinstall: `node-waf configure && node-waf build`
npm ERR! error installing [email protected] `sh "-c" "node-waf configure && node-waf build"` failed with 1
npm ERR! error installing [email protected]     at ChildProcess.<anonymous> (/home/substack/prefix/lib/node_modules/npm/lib/utils/exec.js:49:20)
npm ERR! error installing [email protected]     at ChildProcess.emit (events.js:67:17)
npm ERR! error installing [email protected]     at ChildProcess.onexit (child_process.js:192:12)

> [email protected] preuninstall /home/substack/projects/node-jammin/node_modules/midi
> rm -rf build/*

npm ERR! [email protected] preinstall: `node-waf configure && node-waf build`
npm ERR! `sh "-c" "node-waf configure && node-waf build"` failed with 1
npm ERR! 
npm ERR! Failed at the [email protected] preinstall script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-waf configure && node-waf build
npm ERR! You can get their info via:
npm ERR!     npm owner ls midi
npm ERR! There is likely additional logging output above.
npm ERR! 
npm ERR! System Linux 2.6.38-8-generic
npm ERR! command "node" "/home/substack/prefix/bin/npm" "install" "midi"
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /home/substack/projects/node-jammin/npm-debug.log
npm not ok

Compatible with OSS / Alsa

When running on Mac, Is this compatible with the device files that OSS / Alsa use on Linux.

In other words, I use Mac / Gimp which has "Midi input" which really expecting OSS or Alsa. Will this program allow creating a special file / FIFO which works with that?

Not creating virtual device on OSX Lion

I installed RTmidi and node-midi as per directions, and the server starts up with no errors. However, no virtual device is created. Is this a bug or am I doing something wrong?

'Error: %1 is not a valid Win32 application' under Node-Webkit/Windows 7

Dear all,

I have tried to use node-midi under node-webkit, but when I try to execute this simple script:

var midi = require('midi');
var input = new midi.input();

window.onload = function() {
    console.log(input.getPortCount());
}

I get the following error:

Error: %1 is not a valid Win32 application. 
c:\Users\ttaluy\AppData\Local\Temp\nw2524_20403\node_modules\midi\build\Release\midi.node
    at Module.load (module.js:352:32)
    at Function.Module._load (module.js:308:12)
    at Module.require (module.js:360:17)
    at require (module.js:376:17)
    at bindings (C:\Users\ttaluy\AppData\Local\Temp\nw2524_20403\node_modules\midi\node_modules\bindings\bindings.js:76:44)
    at Object.eval (C:\Users\ttaluy\AppData\Local\Temp\nw2524_20403\node_modules\midi\midi.js:1:93)
    at Module._compile (module.js:452:26)
    at Object.Module._extensions..js (module.js:470:10)
    at Module.load (module.js:352:32)
    at Function.Module._load (module.js:308:12)

It looks like this is a path-related issue, maybe a path having empty spaces or something not being interpreted correctly under Microsoft Windows? I am using Windows 7 Ultimate SP1 64-bit with node-webkit-v0.9.2, Python 2.7.7 and Visual C++. I had a couple of warnings during the installation through npm, I did not note these down, but they can be easily reproduced in case you need them.

Thank you!

node-midi segfaults on OS X

Hey, for some reason I've found that node-midi has been segfaulting pretty badly on OS X (I'm running 10.9.1 Mavericks). I've replicated the issue through my library, launchpadder and through the node-midi tests:

$ git clone https://github.com/justinlatimer/node-midi.git
...
$ cd node-midi
$ npm install
...
$ npm test

> [email protected] test /Users/steve/Code/node-midi
> node test/virtual-loopback-test-automated.js

zsh: segmentation fault  npm test
$

Looks like it's not getting too far before segfaulting either. Any ideas as to what's going wrong here?

Unable to install on Ubuntu 12.04 LTS via NPM

I have been able to install midi on this system before, but now it doesn't work. I haven't worked with it for a few months, so I must have hit some update that messed it up. I already checked the libasound2-dev package, and it is installed up to the current release.

matt@matt-Inspiron-N5040:~/Programming/NodeProjects/MIDI/browserify_midi/ext require method$ sudo npm install midi
npm http GET https://registry.npmjs.org/midi
npm http 304 https://registry.npmjs.org/midi
npm http GET https://registry.npmjs.org/bindings
npm http 304 https://registry.npmjs.org/bindings

[email protected] install /home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/node_modules/midi
node-gyp rebuild

gyp WARN EACCES user "root" does not have permission to access the dev dir "/home/matt/.node-gyp/0.10.26"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/node_modules/midi/.node-gyp"
gyp http GET http://nodejs.org/dist/v0.10.26/node-v0.10.26.tar.gz
gyp http 200 http://nodejs.org/dist/v0.10.26/node-v0.10.26.tar.gz
make: Entering directory /home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/node_modules/midi/build' CXX(target) Release/obj.target/midi/src/node-midi.o g++: error: require: No such file or directory g++: error: method/node_modules/midi/.node-gyp/0.10.26/src: No such file or directory g++: error: require: No such file or directory g++: error: method/node_modules/midi/.node-gyp/0.10.26/deps/uv/include: No such file or directory g++: error: require: No such file or directory g++: error: method/node_modules/midi/.node-gyp/0.10.26/deps/v8/include: No such file or directory make: *** [Release/obj.target/midi/src/node-midi.o] Error 1 make: Leaving directory/home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/node_modules/midi/build'
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:797:12)
gyp ERR! System Linux 3.8.0-37-generic
gyp ERR! command "node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/node_modules/midi
gyp ERR! node -v v0.10.26
gyp ERR! node-gyp -v v0.12.2
gyp ERR! not ok
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the midi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls midi
npm ERR! There is likely additional logging output above.

npm ERR! System Linux 3.8.0-37-generic
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install" "midi"
npm ERR! cwd /home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.3
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/matt/Programming/NodeProjects/MIDI/browserify_midi/ext require method/npm-debug.log
npm ERR! not ok code 0

Input/Output opening order affects Input.

Hi,
I just discovered that the order you open input/output (and keep them open) affects MIDI input reception (at least on LINUX!). In particular, it works fine if you open first MIDI input and then output, but not the other way around. For example the following doesn't receive any MIDI input message:

var midi = require('midi');
var midiInput = new midi.input();
var midiOutput = new midi.output();
midiInput.on('message', function (deltaTime, message) {
    console.log('%j', message);
});
midiOutput.openPort(1);
midiInput.openPort(0);

But if you invert the last two lines, it works properly. I inspected carefully the indexing and it seems the MIDI input gets non operational if you open first for output. It doesn't matter if you open the same or different physical devices.

I will try to debug this myself but if anyone has a clue, I would like some pointers to fix this. I don't know yet if this is because of node-midi or RtMidi, I'll figure it out.

Cheers!
Hugo.

Issues installing with Visual Studio Express 2013

I'm trying to install this module but getting an error when its trying to build. I should mention on I'm on Windows 8 x64, I have Visual Sudio Express 2013 install. I can not find an install for 2012. Its complaining because the build platform is set to v110. Its saying I can change it in Visual Studio but that build folder does not exist after the build fails.

image

Stream sample doesn't work

In the README it has

require('fs').createReadStream('something.mid').pipe(stream2);

That actually doesn't work :( The whole file is read at once and the writeStream implementation is only expecting a Buffer with 3 bytes in it

/cc @tmpvar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.