# EAM and NCC service call control

When applications receive calls using NCC service call control with the EAM protocol, they can receive digits in the following ways:

- All at once

- One at a time

## Receiving digits all at once

For EAM, after NCCEVN_INCOMING_CALL is received, the following fields contain the received digits in the NCC_CALL_STATUS structure:

Field | Description
--- | ---
calledaddr | Called number. Also referred to as the direct inward dial (DID) number.
callingaddr | Calling number (if available). Also referred to as the automatic number identification (ANI) number.

For EAM, after NCCEVN_INCOMING_CALL is received, the following fields contain the received digits in the NCC_CAS_EXT_CALL_STATUS structure:

Field | Description
--- | ---
usercategory | Calling party category (Group I), for example, normal subscriber, operator, maintenance equipment.
ANIpresentation | ANIs may not be available because the application is using protocols where call path, or ANI presentation are restricted. Possible values include: 0 = calling number presentation allowed (default) 1 = calling number presentation restricted 2 = calling number not available
tollcategory | Category associated with the calling party in register signaling Group II. Usually this is the same as the user category, but in some countries it carries the toll category of the call.

Several entries in the TCP parameter file affect the way pulsed E and M TCPs accept and process digits.

Note: When you call nccAnswerCall with EAM TCPs, the upper five bits of the number_of_rings argument are reserved and should be set to zero. This means that EAM TCPs support a maximum of 0x7FF (2047) rings.

EAM parameter | Description
--- | ---
NCC.X.ADI_EAM.DIDnumber | Number of direct inward dial (DID) digits the TCP should expect from the calling party. Default is 7.
NCC.X.ADI_EAM.ANInumber | Number of automatic number identification (ANI) digits the TCP should expect. Set this number to one more than the number of ANI digits to expect, to include the category digit. For example, if the TCP expects 7 digits, set this parameter to 8 (the default). If this parameter is set to 0, no ANI digits are collected. However, the TCP always tries to collect the user category of the calling party and present it to the application.
NCC.X.ADI_EAM.DIDBeforeANI | Number of DID digits the TCP should receive before signaling the calling party to send ANI digits. Default is 1.

Refer to Configuring TCPs for information about loading parameter files.

## Receiving digits one at a time

For pulsed E and M, the digits appear in the following format:

d 1 # c 1 a 1...a m # d 2 d 3...d n # c 2

where:

Value | Description
d 1...d n | DID digits received. n is determined by the NCC.X.ADI_EAM.DIDnumber parameter.
c 1 | Group I category of the calling party (user category).
a 1 ...a m | ANI digits received. m is determined by the NCC.X.ADI_EAM.ANInumber parameter.
c 2 | Group II category of the calling party (toll category).
# | NMS separator symbol.

Note: The number of DID digits received before the # separator depends on the NCC.X.ADI_EAM.DIDbeforeANI parameter.