Teledyne LeCroy Sierra SAS_SATA Protocol Analyzer STX API Reference Manual User Manual
Page 165
Sierra SAS/SATA Protocol Suite, STX Software API Reference Manual
Using Infusion API 165
Call UseActiveConnection function for Analyzer/Infusion Integration
The CIBApiDevice class can run Analyzer/Exerciser projects, with the “Analyzer API”, along
Jammer scenarios using the connecting mode UseActiveConnection.
If a connection has already been made by the analyzer API using the SASGeneralService
functionality, call the UseActiveConnection() method instead of the ConnectFromAPI() method.
For Jammer/Analyzer mixed mode, the API should call Analyzer methods to establish a
connection with the board and then call UseActiveConnection to inform Jammer to use the
currently active connection.
// Connecting using "SASGeneralService" functionality:
HRESULT hr =
m_pIGeneralService.CreateInstance(
__uuidof
(SASGeneralService));
if
(FAILED(hr))
{
AfxMessageBox("General Service interface creation failed.");
return
;
}
CString m_cSystemPath ="";
if
(m_cSystemPath == "")
m_cSystemPath = AfxGetAppDeliverableFolder();
if
(!m_pIGeneralService->InitializeSystem(
CComBSTR(m_cSystemPath).m_str ))
{
AfxMessageBox("In specified path does not exist system
folder.");
return
;
}
hr = m_pDataBlocks.CreateInstance(
__uuidof
(DataBlocks));
if
(FAILED(hr))
{
AfxMessageBox("DataBlocks interface creation failed");
return
;
}
POSITION pos = m_listDevices.GetFirstSelectedItemPosition();
if
(pos == NULL)
{