OSCHID Deals with OSC-based Human Interface Devices


Inherits from: Object


Treat your touchOSC or OSCeleteon or other OSC-based HID  as you would any other HID


See also: OscSlot


Other Issues




Creation / Class Methods


*new (netAddr)

Creates a new OSCHID. There should be one of these per device.

netAddr - An optional argument for the address of the device.. Default value is nil.

// Example

k = OSCHID.new.spec_((

ax: OscSlot(\realtive, '/hand/x'),

ay: OscSlot(\realtive, '/hand/y'),

az: OscSlot(\realtive, '/hand/z')

));

k.callibrate = false;


Accessing Instance and Class Variables

spec

spec_

A dictionary mapping keys to OscSlots





setAction (key, keyAction)

Set the action for a particular slot by key

key - The key for the slot.. Default value is nil.

keyAction - The Action, which takes the slot as an argument.. Default value is nil.

// Example

k = OSCHID.new.spec_((

ax: OscSlot(\realtive, '/hand/x')));

k.setAction(ax, {|val|

val.value.postln;

});


calibrate_ (bool)

Turn callibration on or off

bool - true for on, false for off. Default value is nil.

When callibration is true, relative slots do not call their actions


// Example

k.calibrate = true;

k.setAction(ax, {|val|

val.value.postln;

});


k.callibrate = false;