beautypg.com

Teledyne LeCroy Sierra SAS_SATA Protocol Analyzer STX API Reference Manual User Manual

Page 167

background image


Sierra SAS/SATA Protocol Suite, STX Software API Reference Manual

Using Infusion API 167

//Add Device ID string in StringArray.

astrDeviceId.Add(strDeviceID);

//Convert StringArray to Variant.

AfxConvertStringArrayToVariant(&vDeviceId, astrDeviceId);

//Attach to Board with Added ID.

ProductTypeEnum eProductType =
(ProductTypeEnum)PROJECT_TYPE_SAS;

m_pIGeneralService->Attach(m_yPortType, vDeviceId,
eProductType);

eRC = pDevice->UseActiveConnection();

if

(INFRC_FAILED(eRC))

{

AfxMessageBox("Using Active connection failed.\n");

return

;

}

}

NOTE: Ensure that the “analyzer project” has the same port configuration as Jammer. Jammer

projects call the SetupTahoe() method to set the port configuration. Use the following

code to compare that both Analyzer and Jammer use the same port configuration:

m_eConfigType = INI_DEVICE_CONFIG_J_0_A_A;

pDevice->SetupTahoe(strDeviceID, m_eConfigType);

if

(m_pICaptureProject->GetDeviceType(0) != m_eConfigType)

{

AfxMessageBox("Jammer current selected config is different

from analyzer capture project config!");

return

;

}