1.2.5.8 ADP_GetAvailableMacLayers Function

C

ADP_AVAILABLE_MAC_LAYERS ADP_GetAvailableMacLayers (
    void
);

Summary

The ADP_GetAvailableMacLayers primitive gets the available MAC layer(s).

Description

G3 projects may include PLC MAC, RF MAC, or both. This funtion allows upper layers to get which MAC layer(s) is(are) available at runtime.

Parameters

None.

Example

// ...
ADP_Open(ADP_BAND_CENELEC_A);
// ...

ADP_AVAILABLE_MAC_LAYERS availableLayers;
availableLayers = ADP_GetAvailableMacLayers();

if (availableLayers == ADP_AVAILABLE_MAC_PLC) {
    // Only PLC MAC available
}
else if (availableLayers == ADP_AVAILABLE_MAC_RF) {
    // Only RF MAC available
}
else {
    // Both MAC layers available
}

Remarks

None.