Master/Slave Relationship
A master/slave relationship is a specification of a chain of command for
controlling a synchronized event. The relationship is 1:N, where one object
(the synchronization master) controls the behavior of one or more
subordinate objects (the slaves). The relationship is established
using the SpiEnableSync function, where one data stream is designated the
master and one or more data streams are designated as slaves. Real-time
information, transmitted from the master to all slaves by the Sync/Stream
Manager, gives each of the slaves the current time in the time base of the
MMTIME standard (1/3 msec units). This time information (sync pulse)
allows each slave stream handler to adjust the activity of that stream so
that synchronization can be maintained.
Certain rules govern master/slave synchronization relationships:
- A data stream can be a slave in only one synchronization
relationship.
- Stream handlers must be able to enslave multiple data
streams (if multiple data streams are supported) according to different
sync masters. For example, each active stream under that handler's control
might have a different master.
- A stream cannot become the master of two separate
groups of slaves (any additional streams become slaves in the existing master/slave
group).
- The sync group (master and all slaves) can be started,
stopped, and seeked as a group by using the "slaves" flag on each of the
following SPI functions:
- SpiStartStream
- SpiStopStream
- SpiSeekStream
Any
slave in a sync relationship may be arbitrarily started or stopped without
affecting the activity of the master or any other slave. The master can
be stopped independently of any slave streams in the same sync group and
the option is available for all of the slave to be stopped at the same time
that the master stream is stopped.
Group
synchronized stream time will always be the master stream time. This includes
slave streams that have been stopped and re-started.
Stream
seeking is done on a per stream basis. For example, a seek in a master stream
does not seek in any slave streams that may be in the same sync group.
It is possible for a slave to fail to maintain synchronization. This condition,
called sync overrun, happens when a stream handler has not processed
the last sync pulse received from the Sync/Stream Manager and another sync
pulse is received. The application can optionally request (by way of the
SpiEnableEvent function) to be notified of any sync overruns. The stream
is not stopped but the application could request a stop once it receives
a sync overrun event.
[Back: Synchronization Features]
[Next: Sync Pulse Generation]