
Option Star-Hub
Software Interface
(c) Spectrum Instrumentation GmbH
171
In our example we synchronize all four cards. The star-hub is located on card #2 and is therefor the clock master
Limits of Clock for synchronized cards
Using the M2p Star-Hub, it is possible to have synchronized cards run with different sample rates, as long as
both
of the following conditions
are met for all cards connected to the Star-Hub and enabled for synchronization:
1) The sample rate of each card can be derived by integer division (1/N
i
) from the card with the fastest programmed sample rate.
2) The sample rate of each card can be derived by integer multiplication (* M
i
) of the card with the slowest programmed sample rate.
Both N and M must be an integer of 1 or greater, keeping the resulting sample rates within their allowed limits.
Example 1: Valid setup
• Samplerate(card0) = 100 MSps
• Samplerate(card1) = 25 MSps
• Samplerate(card2) = 5 MSps
This is setup is perfectly valid, as 100 MSps/25 MSps = 4 and 100MSps/5 MSps = 20 and also 5 * 5 MSps = 25 MSps
Example 2: Invalid setup:
• Samplerate(card0) = 100 MSps
• Samplerate(card1) = 25 MSps
• Samplerate(card2) = 10 MSps
This is setup is not valid, although the first condition of 100 MSps/25 MSps = 4 and 100MSps/10 MSps = 20 is met. But the second con
-
dition is violated, as a non-integer would be required: 2.5 * 10 MSps = 25 MSps.
Example 3: Invalid setup:
• Samplerate(card0) = 100 MSps
• Samplerate(card1) = 30 MSps
• Samplerate(card2) = 10 MSps
This is setup is not valid, although now the second condition is met, since a integer works: 3 * 10 MSps = 30 MSps but the first requirement
is now violated, since 100MSps/30 MSps = 3.33, which is not an integer.
Example 4: Valid setup
• Samplerate(card0) = 100 MSps
• Samplerate(card1) = 20 MSps
• Samplerate(card2) = 10 MSps
This is setup is perfectly valid again , as 100 MSps/20 MSps = 5 and 100MSps/10 MSps = 10 and also 2 * 10 MSps = 20 MSps
Setup of Trigger
Setting up the trigger does not need any further steps of synchronization setup. Simply all trigger settings of all cards that have been enabled
for synchronization are connected together. All trigger sources and all trigger modes can be used on synchronization as well.
Having positive edge of external trigger on card 0 to be the trigger source for the complete system needs the following setup:
spcm_dwSetParam_i32 (hSync, SPC_SYNC_ENABLEMASK, 0x000F); // all 4 cards are masked
// set the clock master to 100 MS/s internal clock
spcm_dwSetParam_i32 (hCard[2], SPC_CLOCKMODE, SPC_CM_INTPLL);
spcm_dwSetParam_i32 (hCard[2], SPC_SAMPLEATE, MEGA(100));
// set all the slaves to run synchronously with 100 MS/s
spcm_dwSetParam_i32 (hCard[0], SPC_SAMPLEATE, MEGA(100));
spcm_dwSetParam_i32 (hCard[1], SPC_SAMPLEATE, MEGA(100));
spcm_dwSetParam_i32 (hCard[3], SPC_SAMPLEATE, MEGA(100));
spcm_dwSetParam_i32 (hCard[0], SPC_TRIG_ORMASK, SPC_TMASK_EXT0);
spcm_dwSetParam_i32 (hCard[0], SPC_TRIG_EXT0_MODE, SPC_TM_POS);
spcm_dwSetParam_i32 (hCard[1], SPC_TRIG_ORMASK, SPC_TM_NONE);
spcm_dwSetParam_i32 (hCard[2], SPC_TRIG_ORMASK, SPC_TM_NONE);
spcm_dwSetParam_i32 (hCard[3], SPC_TRIG_ORMASK, SPC_TM_NONE);
Summary of Contents for M2p.59 Series
Page 190: ......