Questions about synchronize usrp2 via mimo cable

Hi all,
I am trying to study STBC using USRP2 and have some questions about how
to use mimo cable.

I followed the instruction on ettus but i dont understand ‘Configuring
the slave’ part
USRP Hardware Driver and USRP Manual: USRP2 and N2x0 Series

Configuring the slave
In order for the slave to synchronize to the master over MIMO cable,
the following clock configuration must be set on the slave device:

uhd::clock_config_t clock_config;
clock_config.ref_source = uhd::clock_config_t::REF_MIMO;
clock_config.pps_source = uhd::clock_config_t::PPS_MIMO;
usrp->set_clock_config(clock_config, slave_index);

I wonder where should I add these lines?

What I am trying is:
self.usrp_sink = uhd.usrp_sink(device_addr=self.addr, stream_args =
uhd.stream_args(cpu_format=“32fc”,channels=range(2),),)
self.usrp_sink.set_clock_source(“internal”, 0)
self.usrp_sink.set_time_source(“mimo”, 0)
self.usrp_sink.set_clock_source(“mimo”, 1)
self.usrp_sink.set_time_source(“mimo”, 1)

Am I right about that?
Thanks for any help~

Robee

On 07/24/2013 08:25 PM, yeran wrote:

uhd::clock_config_t clock_config;
clock_config.ref_source = uhd::clock_config_t::REF_MIMO;
clock_config.pps_source = uhd::clock_config_t::PPS_MIMO;
usrp->set_clock_config(clock_config, slave_index);

I wonder where should I add these lines?

The code you have below is correct. The code snippet in the docs using
clock_config reflects an older API. I will correct this. Thanks

-josh