Published
Edited
Feb 14, 2020
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
midiDeviceName = "OP-1 Midi Device"
Insert cell
Insert cell
// svg.dispatchEvent(new CustomEvent("input", { bubbles: true }));
webmidi.enable(function(err){
if(err){ console.log(err) }
else { console.log('Enabled!') }
console.log(webmidi.inputs);
console.log(webmidi.outputs);
const input = webmidi.getInputByName(midiDeviceName)
input.addListener('noteon', 'all', function(e) {
console.log(e.note.name + e.note.octave)
//svg.dispatchEvent(new CustomEvent("input", { bubbles: true }));
svg.value[1] = 1

})
})

Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
amplitude = 40
Insert cell
frequency = 13
Insert cell
Insert cell
Insert cell
Insert cell
height = 500
Insert cell
fontSize = 250
Insert cell
radius = 3;
Insert cell
spacing = 14
Insert cell
collisionStrength = 0.1;
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
webmidi = require('webmidi')
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more