Vuo  2.0.0
Functions | Variables
VuoSerialDevices.cc File Reference

Description

VuoSerial implementation.

Definition in file VuoSerialDevices.cc.

Go to the source code of this file.

Functions

static VuoText VuoSerial_getPropertyFromObjectOrAncestry (io_object_t o, CFStringRef property)
 Searches o and its parents recursively for property, assumed to be a string. More...
 
VuoList_VuoSerialDevice VuoSerial_getDeviceList (void)
 Returns a list of the currently-avaialble serial devices. More...
 
static void VuoSerial_servicesChanged (void *refcon, io_iterator_t it)
 Invoked by the IONotification system when a serial port is added or removed. More...
 
void VuoSerial_use (void)
 Indicates that the caller needs to get notifications about serial devices. More...
 
void VuoSerial_disuse (void)
 Indicates that the caller no longer needs notifications about serial devices. More...
 
void VuoSerial_addDevicesChangedTriggers (VuoOutputTrigger(devices, VuoList_VuoSerialDevice))
 Adds a trigger callback, to be invoked whenever the list of known serial devices changes. More...
 
void VuoSerial_removeDevicesChangedTriggers (VuoOutputTrigger(devices, VuoList_VuoSerialDevice))
 Removes a trigger callback previously added by VuoSerial_addDevicesChangedTriggers. More...
 

Variables

static VuoTriggerSet< VuoList_VuoSerialDeviceVuoSerial_deviceCallbacks
 Trigger functions to call when the list of devices changes. More...
 
unsigned int VuoSerial_useCount = 0
 Process-wide count of callers (typically node instances) interested in notifications about serial devices. More...
 
IONotificationPortRef VuoSerial_notificationPort
 Manages notifications about seiral devices. More...
 

Function Documentation

◆ VuoSerial_addDevicesChangedTriggers()

void VuoSerial_addDevicesChangedTriggers ( VuoOutputTrigger(devices, VuoList_VuoSerialDevice )

Adds a trigger callback, to be invoked whenever the list of known serial devices changes.

Call VuoSerial_use() before calling this.

This function may be called from any thread.

Definition at line 262 of file VuoSerialDevices.cc.

◆ VuoSerial_disuse()

void VuoSerial_disuse ( void  )

Indicates that the caller no longer needs notifications about serial devices.

This function may be called from any thread.

Definition at line 243 of file VuoSerialDevices.cc.

◆ VuoSerial_getDeviceList()

VuoList_VuoSerialDevice VuoSerial_getDeviceList ( void  )

Returns a list of the currently-avaialble serial devices.

Definition at line 80 of file VuoSerialDevices.cc.

◆ VuoSerial_getPropertyFromObjectOrAncestry()

static VuoText VuoSerial_getPropertyFromObjectOrAncestry ( io_object_t  o,
CFStringRef  property 
)
static

Searches o and its parents recursively for property, assumed to be a string.

Definition at line 42 of file VuoSerialDevices.cc.

◆ VuoSerial_removeDevicesChangedTriggers()

void VuoSerial_removeDevicesChangedTriggers ( VuoOutputTrigger(devices, VuoList_VuoSerialDevice )

Removes a trigger callback previously added by VuoSerial_addDevicesChangedTriggers.

This function may be called from any thread.

Definition at line 273 of file VuoSerialDevices.cc.

◆ VuoSerial_servicesChanged()

static void VuoSerial_servicesChanged ( void *  refcon,
io_iterator_t  it 
)
static

Invoked by the IONotification system when a serial port is added or removed.

Definition at line 168 of file VuoSerialDevices.cc.

◆ VuoSerial_use()

void VuoSerial_use ( void  )

Indicates that the caller needs to get notifications about serial devices.

This function may be called from any thread.

Definition at line 183 of file VuoSerialDevices.cc.

Variable Documentation

◆ VuoSerial_deviceCallbacks

VuoTriggerSet<VuoList_VuoSerialDevice> VuoSerial_deviceCallbacks
static

Trigger functions to call when the list of devices changes.

Definition at line 37 of file VuoSerialDevices.cc.

◆ VuoSerial_notificationPort

IONotificationPortRef VuoSerial_notificationPort

Manages notifications about seiral devices.

Definition at line 163 of file VuoSerialDevices.cc.

◆ VuoSerial_useCount

unsigned int VuoSerial_useCount = 0

Process-wide count of callers (typically node instances) interested in notifications about serial devices.

Definition at line 162 of file VuoSerialDevices.cc.