Echelon Mini FX User Manual

Page 109

Advertising
background image

96 Developing

Device

Applications

ISI_DEFAULT_GROUP, isiDirectionVarious, 1, 0xFF, 95u, 0,
{
0, 0, isiScopeStandard, {0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, 1
}
};

void IsiCreateCsmo(unsigned Assembly, IsiCsmoData* pCsmoData)
{
memcpy(pCsmoData, &myCsmo, sizeof(IsiCsmoData));
#pragma ignore_notused Assembly
}


//
// When ISI receives an open enrollment, it inquires with the
// application whether this is an eligible enrollment. The
// application returns an application-specific assembly number
// if this is the case, or returns ISI_NO_ASSEMBLY.
// This simple example accepts all enrollments that consist of
// the same enrollment description than its own, but more advanced
// applications can accept a larger variety of enrollments, or be
// more specific which enrollment to accept.
//
unsigned IsiGetAssembly(const IsiCsmoData* pCsmo, boolean automatic)
{

return memcmp(pCsmo, &myCsmo, sizeof(IsiCsmoData)) == 0 ?

0 : ISI_NO_INDEX;

#pragma ignore_notused automatic
}

//
// The ISI application groups network variables that apply to the
// same enrollment in logical assemblies, using application-defined
// assembly numbers 0..254. Then ISI processes an assembly, the engine
// inquires with the application about the mapping of locally
// implemented network variables to the members of that assembly.
//
// This simple example supports only one assembly, which consists of
// only one network variable:
//
unsigned IsiGetNvIndex(unsigned assembly, unsigned offset)
{
return nviSwitch::global_index;
#pragma ignore_notused assembly
#pragma ignore_notused offset
}

Advertising