ApModuleFunction()

Specify the setup function for a PhAB internal link callback

Synopsis:

#include <Ap.h>

void ApModuleFunction( ApEventLink_t *link_callback,
                       int (* function)(),
                       int realize_flags );

Arguments:

link_callback
The ABM_ link callback that you want to specify a setup function.
function
The setup function that you want to register for the link callback.
realize_flags
A flag that indicates when the setup function should be called; one of:

Library:

Ap

Description:

ApModuleFunction() is used to specify the setup function for a PhAB internal link callback.

When you create an internal link callback, PhAB lets you specify the setup function. ApModuleFunction() lets you change that setup function. The new function is retained until changed again.

Examples:

ApModuleFunction( ABM_mydialog, setup_module, AB_FUNC_BOTH );
ApCreateModule( ABM_mydialog, NULL, NULL );

setup_module( PtWidget_t *widget, ... ) {
    /* setup processing for module */
}

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

ApCreateModule(), ApModuleLocation()

Accessing PhAB Modules from Code chapter of the Photon Programmer's Guide