User manual

Table Of Contents
Host Interface
45
is accessed by reading any of the numerous
cFM2Device.<parameter> properties. It implements the
IFM2Device interface. The cFM2Listener object creates
a cFM2Device object with every meter USB connect
event.
cFM2Devices class—An object class that manages a
collection of cFM2Device objects for application code
indexing. The collection is managed internally within the
cFM2Listener object. cFM2Device objects are added to
the collection with every meter USB connect event.
Items in the collection are searchable using the device
index key. cFM2Device objects are removed from the
collection with every meter USB disconnect event. The
collection is passed to the cFM2Notify object with every
meter USB connect or disconnect event.
Coding
Essentials
Setup First, supply the callback object by writing code for the
cFM2Notify class that implements IFM2DeviceEvents
interface.
In the application code:
1. Create a cFM2Listener object and obtain an
IFM2Listener interface to it.
2. Create the cFM2ScanUSBForChange and
cFM2ScanForData objects.
3. Create the cFM2Notify callback object.