PxIntInstallService()

Install a PXROS service call as an interrupt handler.

APPLIES TO

8.2.0

SYNOPSIS
PxError_t PxIntInstallService (PxUInt_t intno, PxIntSvEnum_t service, PxArg_t arg, PxEvents_t events);
ARGUMENTS
intno

The number of the interrupt for which the PXROS service is installed

service

The PXROS service

arg

Argument for PXROS service

events

Events sent to installing task

RETURN VALUES
  • PXROS error code

ERROR CODES

PXERR_REQUEST_INVALID_PARAMETER

intno out of specification

PXERR_ACCESS_RIGHT

The calling task has not the right to install handlers

PXERR_INTR_ILL

The handler already installed from another task

PXERR_INTERRUPT_ILLINTERRUPT

intObj not valid interrupt object

PXERR_ILLEGAL_SERVICE_CALLED

Service invalid

DESCRIPTION

Installs a PXROS handler service directly as an interrupt handler.

IMPLEMENTATION GUIDELINES
Before call
  • The parameter intno must be a valid interrupt id. (V)

  • The parameter service must be a valid PXROS-HR service id. (V)

After call
  • The function returns PXERR_NOERROR if the service could be installed. Any other return value describes an error, which has to be interpreted (C).

Best Practice
  • The calling task must have the right to install services as interrupt handlers (PXACCESS_INSTALL_SERVICES). (V)

SEE ALSO
USAGE
#include "pxdef.h"

PxError_t Err = PxIntInstallService(intno, serviceNo, (PxArg_t)0, 0);

if (Err != PXERR_NOERROR) {
    // Report error
}