FipCore
API
Overview
This section presents functions, structures, and enumerations of the FipCore v2.x library that are useful for communicating with a FIP device.
To see examples of how to use the library, please go to the Tutorial section.
Device - Information
fipcore_get_deviceconf
- Prototype
- Description
- This function returns information about the target device.
- Parameters
- Input
device_type
FIP arbitrator device type.device_index
Device index comprised between 1 and 9.- Output
device_conf
Structure containing device information.- Return Value
- See Error Codes section.
fipcore_get_devices_number
- Prototype
- Description
- This function returns the number of FIP Arbitrator device on the machine.
- Parameters
- Input
NONE
- Output
nb_detected_devices
Number of FIP Arbitrator devices detected.- Return Value
- See Error Codes section.
fipcore_get_devices_list
- Prototype
- Description
- This function returns the number of FIP Arbitrator device on the machine and the information associated with it.
- Parameters
- Input
NONE
- Output
devices_conf
Table of structures containing the information of detected devices.nb_detected_devices
Number of FIP Arbitrator devices detected.- Return Value
- See Error Codes section.
fipcore_get_error_str
- Prototype
- Description
- This function returns the error string specified by its code.
- Parameters
- Input
error_code
Error code (32-bits).- Output
NONE
- Return Value
- Error string. See Error Codes section.
Device - Access
fipcore_device_open
- Prototype
- Description
- This function starts the device and allocates the objects used internally by the library.
- Parameters
- Input
device_type
FIP arbitrator device type.device_index
Device index comprised between 1 and 9.- Output
error_code
See Error Codes section.- Return Value
- Fipcore handle session for the device. This handle will be used in all the functions described below.
fipcore_device_close
- Prototype
- Description
- This function closes the device and frees the objects used internally by the library.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_get_access_mode
- Prototype
- Description
- This function gets the current access mode of the FIP device.
FIP devices have two possible access modes:
- Conventional Access: This is a communication mode through the 8-bit interface of the embedded FullFIP component (UCOM register).
- Free Access: This is a communication mode through a direct access to the RAM component containing the FullFIP database.
NOTE: The use of Free Access mode drastically increases the read/write performance of the FIP device.
If your device supports it, it is therefore strongly recommended to use this access mode.
[See: fipcore_set_access_mode function] - Parameters
- Input
hnd
Session handle.- Output
access_mode
Access mode (0 : Conventional Access, 1 : Free Access).- Return Value
- See Error Codes section.
fipcore_set_access_mode
- Prototype
- Description
- This function sets the access mode of the FIP device.
FIP devices have two possible access modes:
- Conventional Access: This is a communication mode through the 8-bit interface of the embedded FullFIP component (UCOM register).
- Free Access: This is a communication mode through a direct access to the RAM component containing the FullFIP database.
By default, all FIP boards are set to Conventional Access mode. If your card supports Free Access mode, it is possible to switch from one mode to the other by calling this function.
NOTE: The use of Free Access mode drastically increases the read/write performance of the FIP device. If your device supports it, it is therefore strongly recommended to use this access mode.WARNING 1: Some devices do not support Free Access mode (ex: MobiFIP [USB]). For the PCI/PCIe product family, check the hardware version of the board (only recent designs support it).WARNING 2: This function must be called up before the fipcode_init_network function. Once the FIP session is initialized, the FIP access mode will remain the same throughout the session. - Parameters
- Input
hnd
Session handle.access_mode
Access mode (0 : Conventional Access, 1 : Free Access).- Output
NONE
- Return Value
- See Error Codes section.
fipcore_get_rgb_led
- Prototype
- Description
- This function reads the RGB led state of the device.
- Parameters
- Input
hnd
Session handle.- Output
led_state
RGB color.- Return Value
- See Error Codes section.
fipcore_set_rgb_led
- Prototype
- Description
- This function changes the RGB led color of the device.
- Parameters
- Input
hnd
Session handle.led_state
RGB color.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_is_registered_device
- Prototype
- Description
- This function tests the authorization of the device for a particular Exoligent software.
- Parameters
- Input
hnd
Session handle.soft_type
Exoligent software to test.- Output
NONE
- Return Value
- See Error Codes section.
Network - Context Info
fipcore_get_config
- Prototype
- Description
- This function returns the entire station configuration structure.
- Parameters
- Input
hnd
Session handle.- Output
fip_conf
FIP station configuration.- Return Value
- See Error Codes section.
fipcore_get_var_config_by_id
- Prototype
- Description
- This function returns the variable configuration structure for the ID.
- Parameters
- Input
hnd
Session handle.identifier
Variable ID.- Output
var_conf
Variable configuration.- Return Value
- See Error Codes section.
fipcore_get_var_key_by_id
- Prototype
- Description
- This function returns the internal access key for the variable specified by its ID.
- Parameters
- Input
hnd
Session handle.identifier
Variable ID.direction
Direction (0 : OUT, 1 : IN).- Output
access_key
Variable Access Key.- Return Value
- See Error Codes section.
fipcore_get_var_id_by_key
- Prototype
- Description
- This function returns the variable ID specified by its internal access key.
Note : This function is useful for processing event_parameter of the fipcore_read_evt function. - Parameters
- Input
hnd
Session handle.access_key
Variable Access Key.- Output
identifier
Variable ID.direction
Direction (0 : OUT, 1 : IN).- Return Value
- See Error Codes section.
fipcore_get_msg_config_by_header
- Prototype
- Description
- This function returns the configuration structure for the message.
- Parameters
- Input
hnd
Session handle.dest_id
Destination ID.dest_seg
Destination segment.src_id
Source ID.src_seg
Source segment.- Output
msg_conf
Message configuration.- Return Value
- See Error Codes section.
fipcore_get_tag_config_by_id
- Prototype
- Description
- This function returns the tag configuration structure specified by its tag ID.
- Parameters
- Input
hnd
Session handle.tag_id
Tag ID (Mnemonic ID).- Output
tag_conf
Tag configuration.- Return Value
- See Error Codes section.
fipcore_get_tag_config_by_name
- Prototype
- Description
- This function returns the tag configuration structure specified by its tag name.
- Parameters
- Input
hnd
Session handle.tag_name
Tag name (Mnemonic name).- Output
tag_conf
Tag configuration.- Return Value
- See Error Codes section.
Network - Running / Stopping
fipcore_init_network
- Prototype
- Description
- This function downloads the FIP station configuration file to the device. The file contains the FIP network parameters, the variables and the messages.
- Parameters
- Input
hnd
Session handle.file_type
Type of FIP station configuration file.file_conf_path
Path to FIP station configuration file.user_callbacks
Structure containing user callbacks to be registered for this session.
WARNING: FipCore library only supports XML files.
To make this file, please refer to Station Configuration File section.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_start_network
- Prototype
- Description
- This function starts the communication with the FIP network.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_stop_network
- Prototype
- Description
- This function stops the communication with the FIP network. Then it unloads FIP station configuration from the device.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
Network - Medium Access
fipcore_get_medium
- Prototype
- Description
- This function retrieves the mediums status.
- Parameters
- Input
hnd
Session handle.- Output
network_status
Structure containing the information that is representative of transmission quality on the network, and on its operating status.- Return Value
- See Error Codes section.
fipcore_set_medium_cmd
- Prototype
- Description
- This function is used to send a command to the FIP channel controller.
- Parameters
- Input
hnd
Session handle.fieldual_cmd
Medium Command [see enumeration MEDIUM_CMD].- bit0 and bit1 : Channel 1 Selection
- b1b0 = 01b : Channel 1 enabled
- b1b0 = 10b : Channel 1 disabled
- bit2 and bit3 : Channel 2 Selection
- b3b2 = 01b : Channel 2 enabled
- b3b2 = 10b : Channel 2 disabled
- bit4 : Clear Errors
- b4 = 1 : Clear
- b4 = 0 : Do not clear
- bit5 : Channel 1 Reset
- b5 = 1 : Reset channel 1
- b5 = 0 : Do not reset channel 1
- bit6 : Channel 2 Reset
- b6 = 1 : Reset channel 2
- b6 = 0 : Do not reset channel 2
- bit7 to bit15 : Reserved
- bit0 and bit1 : Channel 1 Selection
- Output
NONE
- Return Value
- See Error Codes section.
Network - Variable Access
fipcore_write_var_by_id
- Prototype
- Description
- This function allows the user to write a FIP variable to the network from its identifier.
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).p_var
Structure containing data to send.
- Output
NONE
- Return Value
- See Error Codes section.
fipcore_read_var_by_id
- Prototype
- Description
- This functions allows the user to read a FIP variable on the network from its identifier.
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).- Output
c_var
Structure containing read data.is_prompt
Promptness validity.is_refreshed
Refreshment validity.
- Return Value
- See Error Codes section.
fipcore_read_var_svf_by_id
- Prototype
- Description
- This function allows the user to read a FIP variable on the network from its identifier even if its length and PDU definition is unknown into the FIP configuration file.
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).- Output
c_var
Structure containing read data.is_prompt
Promptness validity.is_refreshed
Refreshment validity.
- Return Value
- See Error Codes section.
fipcore_read_var_time_by_id
- Prototype
- Description
- This function allows the user to read a FIP variable with a dynamic refresh status on the network.
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).- Output
c_var_time
Structure containing read data.production_time
Time elapsed between the variable writing by the user and its emission on the network (in μs).transmission_time
Transfer time of the variable on the network (in μs). This time is calculated based on the variable length and the network speed.consumption_time
Time elapsed between the reception of the variable from the network and the reading by the user (in μs).reception_time
transmission_time + consumption_timeis_prompt
Promptness validity.is_refreshed
Refreshment validity.
- Return Value
- See Error Codes section.
fipcore_read_lstpresent
- Prototype
- Description
- This function reads the management variable of the SM_MPS network called Presence List. This variable, created and distributed on the network through the active BA carrier device, contains the list of all subscribers connected to each medium.
- Parameters
- Input
hnd
Session handle.- Output
present_list
Structure containing the list of all subscribers and that indicates their presence or not.- Return Value
- See Error Codes section.
fipcore_send_aper_by_id
- Prototype
- Description
- This function allows the user to send a request for an aperiodical variable transmission.
- This request has two levels of priority depending on the mode parameter value.
- The necessary condition to send the request to the bus arbitrator is to have at least one produced variable with aperiodical variable transmission request authorized in the station configuration file (See <AperiodicService> tag).
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).mode
0 - Normal request, 1 - Urgent request.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_purge_aper
- Prototype
- Description
- This function purges the aperiodic request storage FIFO. The fifo_type parameter value indicates the FIFO request to purge (normal or urgent).
- Parameters
- Input
hnd
Session handle.fifo_type
0 - Normal request FIFO, 1 - Urgent request FIFO.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_def_var_event_by_id
- Prototype
- Description
- This function allows to dynamically define an event associated with a variable in emission or reception.
- The associated event can be temporary or permanent.
- A permanent event is sent/received each time the variable is produced or consumed.
- However a temporary event is sent/received only once.
- Parameters
- Input
hnd
Session handle.identifier
Variable identifier (ID).event_code
Event type to associate with the variable.
- FIP_EVT_SEND_VAR_T (0x0100): Temporary event on sent variable.
- FIP_EVT_SEND_VAR_P (0x8100): Permanent event on sent variable.
- FIP_EVT_RECEIVE_VAR_T (0x0200): Temporary event on received variable.
- FIP_EVT_RECEIVE_VAR_P (0x8200): Permanent event on received variable.
- Output
NONE
- Return Value
- See Error Codes section.
Network - Message Access
fipcore_write_msg
- Prototype
- Description
- This function allows the user to write a FIP message in the FIFO emission channel of the device.
- Parameters
- Input
hnd
Session handle.channel_number
The channel on which the message is to be sent.
- 0: Aperiodic messaging channel.
- 1 to 8: Periodic messaging channel.
message_frame_out
Structure containing message to sent.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_read_msg
- Prototype
- Description
- This function allows the user to read a FIP message from the FIFO reception channel of the device.
Note : When a message is received, an event is signaled by the event code: FIP_EVT_RECEIVE_MSG.- See also : fipcore_read_evt, FIP_EVENT_CODE
- Parameters
- Input
hnd
Session handle.- Output
message_frame_in
Structure containing received message.- Return Value
- See Error Codes section.
fipcore_purge_msg
- Prototype
- Description
- This function allows the user to selectively purge the content of the message send queues.
- It frees up the allocated FIFO blocks corresponding to the channel selected.
- Parameters
- Input
hnd
Session handle.channel_number
The transmission channel that must be purged.
- 0: Aperiodic messaging channel.
- 1 to 8: Periodic messaging channel.
- Output
nb_blocks_freed
Number of freed message blocks.blocks_freed_tab
Table of freed block numbers. Up to 64 * uint16_t.- Return Value
- See Error Codes section.
Network - File Transfer
fipcore_set_file_reception_dir_path
- Prototype
- Description
- This function is used to set the directory path for the input files coming from the FIP network.
- Parameters
- Input
hnd
Session handle.directory_path
Folder for receiving incoming files.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_send_file
- Prototype
- Description
- This function allows you to send a file on the FIP network.
- Parameters
- Input
hnd
Session handle.channel_number
Transmission channel type.
- 0: Aperiodic messaging channel.
- 1 to 8: Periodic messaging channel.
dest_id
File destination ID.dest_seg
File destination segment.src_id
File source ID.src_seg
File source segment.file_path
Path of the file to be sent.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_abort_file_emission
- Prototype
- Description
- This function cancels the current file transmission.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
Network - Tag Access
fipcore_write_tag_by_id
- Prototype
- Description
- This function allows the user to write a tag value to the FIP network from its tag ID.
- Parameters
- Input
hnd
Session handle.tag_id
Tag identifier (Tag ID).data
Pointer to the value to be written.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_write_tag_by_name
- Prototype
- Description
- This function allows the user to write a tag value to the FIP network from its tag name.
- Parameters
- Input
hnd
Session handle.tag_name
Tag name.data
Pointer to the value to be written.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_read_tag_by_id
- Prototype
- Description
- This function allows the user to read a tag value from the FIP network from its tag ID.
- Parameters
- Input
hnd
Session handle.tag_id
Tag identifier (Tag ID).- Output
data
Pointer to the value to be read.- Return Value
- See Error Codes section.
fipcore_read_tag_by_name
- Prototype
- Description
- This function allows the user to read a tag value from the FIP network from its tag name.
- Parameters
- Input
hnd
Session handle.tag_name
Tag name.- Output
data
Pointer to the value to be read.- Return Value
- See Error Codes section.
Network - Bus Arbiter Access
fipcore_start_ba
- Prototype
- Description
- This function starts the bus arbiter. The user can select the scan table number to run.
- Parameters
- Input
hnd
Session handle.ba_number
Scan table number to run [1 or 2].- Output
NONE
- Return Value
- See Error Codes section.
fipcore_stop_ba
- Prototype
- Description
- This function stops the bus arbiter.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_continue_ba
- Prototype
- Description
- This function processes the command allowing the user to order resumption of bus arbiter program execution at a specific address.
- This function is used for processing program instruction BA_SUSPEND, which is needed for the user to run the subscriber presence test (FIELDUAL compatible mode or ZN130). This command is only acknowledged by the software if the bus arbiter is in initial BA_PENDING status.
- Parameters
- Input
hnd
Session handle.ba_continue_address
Restart address of the bus arbiter. This address is given by the BA_SUSPEND event.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_change_macrocycle
- Prototype
- Description
- This function allows the user to change the scan table to be executed by the bus arbiter whether it be active, idle or stopped.
- The macro-cycle change becomes effective on completion of execution of the current macro-cycle, on program instruction BA_NEXT_MACRO.
- Parameters
- Input
hnd
Session handle.ba_number
Scan table number to run [1 or 2].- Output
NONE
- Return Value
- See Error Codes section.
fipcore_synchro_ba
- Prototype
- Description
- This function allows to resynchronize execution of a bus arbiter program.
- This instruction is used for processing program instruction BA_WAIT_SYNC or BA_WAIT_SYNC_SILENCE.
- When the command is received, the bus arbiter resumes execution of its program at the current address.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_change_param_ba
- Prototype
- Description
- This function is used to modify some bus arbiter operating parameters on-line:
- Physical address of network subscriber (station)
- Maximum number of subscribers connectable to network
- Bus arbiter priority level
- Bus arbiter start timeout
- Bus arbiter election timeout
- Parameters
- Input
hnd
Session handle.ba_parameters
Bus arbiter parameters.- Output
NONE
- Return Value
- See Error Codes section.
Network - Event Access
fipcore_read_evt
- Prototype
- Description
- This function allows the user to read a memorized event in a single storage queue (up to 32 items).
- The following events are reported:
- Sending / Receiving of a variable (optional)
- Sending / Receiving of a message
- Sending of a list of aperiodic requests
- Reporting the switch of bus arbiter from idle to active status
- Reporting of bus arbiter suspension
NOTE: This function should be called cyclically in order to regularly pop the internal device event stack. For PCI/PCIe device types, it is recommanded to call it inside the callback cb_fip_event.- Parameters
- Input
hnd
Session handle.- Output
event_code
Event code received [see FIP_EVENT_CODE enumeration].event_parameter
Additional parameter related to event_code parameter.
Note : This parameter is significant only for the following event codes:
- FIP_EVT_SEND_VAR_P / FIP_EVT_SEND_VAR_T :
event_parameter = Variable access key
See also: fipcore_get_var_id_by_key - FIP_EVT_RECEIVE_VAR_P / FIP_EVT_RECEIVE_VAR_T :
event_parameter = Variable access key
See also: fipcore_get_var_id_by_key - FIP_EVT_SEND_MSG :
event_parameter = Emission status
- Cr_Emission: Emission report
- MSG_SDN_ACK :
message (without ack) sent - MSG_SDN_ERROR :
error in emission for message (without ack) - MSG_NO_ACK :
message (with acknowledgement) sent but not ack - MSG_ACK_POS :
positive acknowledgement - MSG_ACK_POS_REP :
positive acknowledgement after repeat - MSG_ACK_NEG :
negative acknowledgement - MSG_ACK_NEG_REP :
negative acknowledgement after repeat
- MSG_SDN_ACK :
- FIFO: FIFO emission number (0: aperiodic - 1..8: periodic)
- Block: Block number in FIFO emission (0 to 63)
- Cr_Emission: Emission report
- FIP_EVT_BA_SUSPEND :
event_parameter = BA suspension address program (16-bit address in zone reserved for BA)
See also : fipcore_continue_ba
- FIP_EVT_SEND_VAR_P / FIP_EVT_SEND_VAR_T :
- Return Value
- See Error Codes section.
Network - Statistical Information
fipcore_reset_stats
- Prototype
- Description
- This function clears all the counters associated with FIP_STATISTICS structure.
- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_get_stats
- Prototype
- Description
- This function retrieves the statistics counters for the PCI/PCIe devices type.
Note : To keep the FIP_STATISTICS structure up to date, the user must ensure that the events of the FIP network are correctly popped by calling the fipcore_read_evt function.
- Parameters
- Input
hnd
Session handle.- Output
stats
Statistics structure.- Return Value
- See Error Codes section.
Network - OPC UA Server
fipcore_opcua_run_startup
- Prototype
- Description
- This function starts an OPC UA server and expose the current FIP network context.
NOTE: This function must be called only for a non-blocking operation of the server. Otherwise please use fipcore_opcua_run.- Parameters
- Input
hnd
Session handle.port
TCP Port.opc_conf
OPC UA server configuration.
Note: If this parameter is not set (null), by default the server will start with an unencrypted channel and allow anonymous client connections.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_opcua_run_iterate
- Prototype
- Description
- This function executes a single iteration of the server's main loop.
NOTE: This function must be called only for a non-blocking operation of the server. Otherwise please use fipcore_opcua_run.- Parameters
- Input
hnd
Session handle.wait_internal
Should we wait for messages in the network layer? Otherwise, the timeouts for the network layers are set to zero. The default max wait time is 50millisec.- Output
timeout
Returns how long we can wait until the next scheduled job (in millisec)- Return Value
- See Error Codes section.
fipcore_opcua_run_shutdown
- Prototype
- Description
- This function stops the OPC UA server.
NOTE: This function must be called only for a non-blocking operation of the server. Otherwise please use fipcore_opcua_run.- Parameters
- Input
hnd
Session handle.- Output
NONE
- Return Value
- See Error Codes section.
fipcore_opcua_run
- Prototype
- Description
- This function starts an OPC UA server and expose the current FIP network context. It's a blocking function, so to stop the server the 'running' boolean must be set to false.
- Parameters
- Input
hnd
Session handle.port
TCP Port.running
Server state (Force to false to exit the function).opc_conf
OPC UA server configuration.
Note: If this parameter is not set (null), by default the server will start with an unencrypted channel and allow anonymous client connections.- Output
NONE
- Return Value
- See Error Codes section.
Enumerations
EXO_FILE_TYPE
- Definition
- Description
- This enum describes the file types supported by the Exoligent softwares.
- Values
-
Constant Value Description XML 0 The file has "xml" structure type CNF 1 The file has "cnf" structure type (obsolete) - See also
EXO_DEVICE_TYPE
- Definition
- Description
- This enum describes the FIP arbitrator devices families supported by the Exoligent softwares.
- Values
-
Constant Value Description PCI_PCIE_TYPE 1 PCI/PCIe FIP Arbiter board (pci, pcie, pci104, pcie104, pxi, pxie, mpcie) USB_TYPE 2 USB FIP Arbiter board - See also
EXO_SOFT_TYPE
- Definition
- Description
- This enum describes the Exoligent software names.
- Values
-
Constant Value Description FIPCORE 0 API library to control a FIP Arbitrator device FIPCOREPLUS 1 Extended functions for FipCore library. This soft option includes:
- FipBusView library (lvlib): To control a FIP Arbitrator device from Labview.
- OPC UA server functions (from FipCore and FipBusView libraries)
FIPLABS 2 GUI for designing, controlling and analyzing a FIP network (based on FipCore library) - FipBusView library (lvlib): To control a FIP Arbitrator device from Labview.
- See also
EXO_SUBSYSID
- Definition
- Description
- This enum describes the Subsystem Device IDs for Exoligent FIP Arbiter boards.
- Values
-
Constant Value Description EXO_SUBSYSID_OLD_PCI 0x9050 PCI FIP Arbiter on copper (old model) EXO_SUBSYSID_PCI 0x5201 PCI FIP Arbiter on copper EXO_SUBSYSID_PCIE 0x5301 PCIe FIP Arbiter on copper EXO_SUBSYSID_PCI104 0x5401 PCI/104 FIP Arbiter on copper EXO_SUBSYSID_PCIE104 0x5501 PCIe/104 FIP Arbiter on copper EXO_SUBSYSID_PXI 0x5601 PXI FIP Arbiter on copper EXO_SUBSYSID_PXIE 0x5701 PXIe FIP Arbiter on copper EXO_SUBSYSID_MPCIE 0x5801 mPCIe FIP Arbiter on copper EXO_SUBSYSID_CPCI 0x5901 cPCI FIP Arbiter on copper EXO_SUBSYSID_PCI_OPT 0x7201 PCI FIP Arbiter on optical fiber EXO_SUBSYSID_PCIE_OPT 0x7301 PCIe FIP Arbiter on optical fiber EXO_SUBSYSID_PCI104_OPT 0x7401 PCI/104 FIP Arbiter on optical fiber EXO_SUBSYSID_PCIE104_OPT 0x7501 PCIe/104 FIP Arbiter on optical fiber EXO_SUBSYSID_PXI_OPT 0x7601 PXI FIP Arbiter on optical fiber EXO_SUBSYSID_PXIE_OPT 0x7701 PXIe FIP Arbiter on optical fiber EXO_SUBSYSID_MPCIE_OPT 0x7801 mPCIe FIP Arbiter on optical fiber EXO_SUBSYSID_CPCI_OPT 0x7901 cPCI FIP Arbiter on optical fiber
FIP_SPEED
- Definition
- Description
- This enum describes the FIP speeds.
- Values
-
Constant Value Description SPEED_31K25 0 FIP speed at 31.25 Kbps SPEED_1M 1 FIP speed at 1 Mbps SPEED_2M5 2 FIP speed at 2.5 Mbps SPEED_5M 3 FIP speed at 5 Mbps - See also
FIP_IMPEDANCE
- Definition
- Description
- This enum describes the FIP impedance.
- Values
-
Constant Value Description IMPEDANCE_150 0 Network 150 Ω IMPEDANCE_120 1 Network 120 Ω - See also
FIP_FRAME_TYPE
- Definition
- Description
- This enum describes the FIP frame types.
- Values
-
Constant Value Description FRAME_TYPE_FIP 0 FIP frame FRAME_TYPE_WORLDFIP 1 WorldFIP frame FRAME_TYPE_SLOWFIP 2 SlowFIP frame
LED_RGB_COLOR
- Definition
- Description
- This enum describes the available colors for a RGB LED.
- Values
-
Constant Value Description BLACK 0 Switched off LED BLUE 1 Blue LED GREEN 2 Green LED BLUE_SKY 3 Blue Sky LED RED 4 Red LED FUSCHIA 5 Fuschia LED YELLOW 6 Yellow LED WHITE 7 White LED - See also
MEDIUM_CMD
- Definition
- Description
- This enum describes the allowed commands to send to the FIP channels controller (Fieldual).
- Values
-
Constant Value Description MEDIUM_CMD_CLR_CHANNELS_ERR 0x0010 Clear channels errors MEDIUM_CMD_RST_CH1 0x0020 Reset channel 2 MEDIUM_CMD_RST_CH2 0x0040 Reset channel 1 MEDIUM_CMD_ACTIVATE_CH1 0x0009 Only channel 1 selection MEDIUM_CMD_ACTIVATE_CH2 0x0006 Only channel 2 selection MEDIUM_CMD_ACTIVATE_CH1_AND_CH2 0x0005 Both channels selection - See also
MEDIUM_STATUS_FLAGS
- Definition
- Description
- This enum describes useful flags to know the status of the channels .
- Values
-
Constant Value Description MEDIUM_STATUS_CH1_VALID 0x0001 Channel 1 active MEDIUM_STATUS_CH2_VALID 0x0002 Channel 2 active MEDIUM_STATUS_CH1_TX_ERROR 0x0004 Channel 1 TX Error MEDIUM_STATUS_CH2_TX_ERROR 0x0008 Channel 2 TX Error MEDIUM_STATUS_CH1_WATCHDOG 0x0010 Channel 1 watchdog error MEDIUM_STATUS_CH2_WATCHDOG 0x0020 Channel 2 watchdog error - See also
fipcore_get_medium, FIP_NETWORK_STATUS (FIELDUAL_Status)
BA_STATUS_CODE
- Definition
- Description
- This enum describes the different possible bus arbiter statuses.
- Values
-
Constant Value Description BA_STATUS_STOPPED 0x0000 Bus arbiter stopped BA_STATUS_STARTING 0x0003 Bus arbiter in start-up phase BA_STATUS_IDLE 0x0007 Bus arbiter in idle - Another BA is already active BA_STATUS_MACRO_END 0x8022 End of macrocycle BA_STATUS_SENDING_ID_DAT 0x8023 ID_DAT frame emission in progress BA_STATUS_SENDING_ID_MSG 0x8025 ID_MSG frame emission in progress BA_STATUS_TESTING 0x8028 Presence test in progress BA_STATUS_TESTING_END 0x8029 End of presence test BA_STATUS_PENDING 0x8038 Bus arbiter in pending - Wait for user action BA_STATUS_APER_WINDOW 0x800B Processing of aperiodic requests for variables BA_STATUS_MSG_WINDOW 0x8004 Processing of aperiodic requests for messages BA_STATUS_WAITING_TIME 0x8010 Internal re-synchronization BA_STATUS_WAITING_SYNC 0x8031 External re-synchronization BA_STATUS_WAITING_SYNC_SILENT 0x8032 External re-synchronization - Silence - See also
fipcore_get_medium, FIP_NETWORK_STATUS (BA_Status)
FIP_EVENT_CODE
- Definition
- Description
- This enum describes the possible network event codes returned by the fipcore_read_evt function.
- Values
-
Constant Value Description FIP_EVT_NONE 0x0000 No event FIP_EVT_SEND_VAR_P 0x8100 Sending of a variable - permanent FIP_EVT_SEND_VAR_T 0x0100 Sending of a variable - temporary FIP_EVT_RECEIVE_VAR_P 0x8200 Reception of a variable - permanent FIP_EVT_RECEIVE_VAR_T 0x0200 Reception of a variable - temporary FIP_EVT_RECEIVE_MSG 0x0240 Reception of a message FIP_EVT_SEND_MSG 0x0140 Sending of a message FIP_EVT_SEND_APU 0x0130 Sending of a list of urgent aperiodic requests FIP_EVT_SEND_APN 0x0131 Sending of a list of normal aperiodic requests FIP_EVT_BA_ACTIVITY 0x0400 Bus arbiter reactivation (active on network) FIP_EVT_BA_STOP1 0x0401 Stopping of bus arbiter following a timeout recorded on execution of program instructions BA_SUSPEND or BA_WAIT_SYNC FIP_EVT_BA_STOP2 0x0402 Stopping of bus arbiter following detection of network anomalies or decoding of an unknown instruction code FIP_EVT_BA_STOP3 0x0404 Stopping of bus arbiter following user request FIP_EVT_BA_IDLE 0x0408 Return of bus arbiter to idle status FIP_EVT_BA_SUSPEND0 0x0500 Suspension of bus arbiter program following decoding of the macro–instruction BA_SUSPEND (here on event number 0) ... 0x0501 to 0x05fe Other codes relative to the suspension of bus arbiter program FIP_EVT_BA_SUSPEND255 0x05ff Suspension of bus arbiter program on event number 255 - See also
FILE_TRANSFER_STATE
- Definition
- Description
- This enum describes the status of the file transert on the FIP network.
- Values
-
Constant Value Description IDLE 0 No file transfer in progress IN_PROGRESS 1 File transfer in progress COMPLETE 2 File transfer complete ABORTED 3 File transfer aborted
Structures
DEVICE_VERSION
- Definition
- Members
-
Name Type Description major uint8_t
Major number minor uint8_t
Minor number revision uint8_t
Revision number
FIP_DEVICECONF
- Definition
- Members
-
Name Type Description device_type EXO_DEVICE_TYPE
Device type [PCI_FIP, PCIE_FIP ...] device_index uint8_t
Device index [0 to 255] device_is_used uint8_t
0 : Free device – 1 : Device is used device_handle device_handle_t
Device handle product_number uint32_t
Device product number device_version DEVICE_VERSION
Device version fip_speed FIP_SPEED
Device FIP speed fip_impedance FIP_IMPEDANCE
Device FIP Impedance - See also
INSTRUCTION
- Definition
- Members
-
Name Type Description op_code char[32]
Instruction code for arbiter scan table
USERDEF_STATION_INF
- Definition
- Members
-
Name Type Description subscriber_number uint8_t
Station address subscriber_name char[255]
Station name
USERDEF_ARBITER
- Definition
- Members
-
Name Type Description ba_max_subscriber_number uint8_t
Address of the last FIP station connectable to network ba_priority uint8_t
Priority level (0 [highest] to 15) ba_max_priority uint8_t
The highest bus arbiter priority level on the network ba_optimization uint8_t
BA Optimization mode
[see also <BAOptimization> XML tag]nb_ba_1_instructions uint16_t
Number of instructions in BA scan table number 1 ba_1_instructions INSTRUCTION*
Instructions of BA scan table 1 nb_ba_2_instructions uint16_t
Number of instructions in BA scan table number 2 ba_2_instructions INSTRUCTION*
Instructions of BA scan table 2
USERDEF_VARIABLE
- Definition
- Members
-
Name Type Description name char[255]
Variable name identifier uint16_t
Variable identifier pdu uint16_t
Variable PDU
[see also <PDU> XML tag]length uint16_t
Length type uint8_t
Direction (0 : OUT, 1 : IN) refreshment_type uint8_t
0 : Refreshment not required
1 : Refreshment required
2 : Dynamic refreshment required
[see also <Refreshment> XML tag]refreshment_period uint16_t
Between 1 [0x0001] and 16 383 [0x3FFF]
It's a time slot multiple.
[see also <Refreshment> XML tag]promptitude_type uint8_t
0 : Promptness not required
1 : Promptness required
[see also <Promptness> XML tag]promptitude_period uint16_t
Between 1 [0x0001] and 16 383 [0x3FFF]
It's a time slot multiple.
[see also <Promptness> XML tag]msg_channel int16
-1 : No Channel
0 : Aperiodic channel
1 to 8 : Periodic channel
[see also <MessagingService> XML tag]messages_service uint8_t
b0 = 1 -> Message reception enabled
b1 = 1 -> Message emission enabled
b6 = 1 -> Aperiodic variable request enabled
[see also <AperiodicService> XML tag]
[see also <MessagingService> XML tag] - See also
USERDEF_MESSAGE
- Definition
- Members
-
Name Type Description name char[255]
Message name type uint8_t
0 : Input Message, 1 : Output Message, 8 : Input File, 9 : Output File channel uint8_t
0: Aperiodic Channel, 1..8: Periodic Channel acknowledgment uint8_t
0: no, 1: yes destination_identifier uint16_t
Destination ID destination_segment uint8_t
Destination Segment source_identifier uint16_t
Source ID source_segment uint8_t
Source Segment - See also
USERDEF_TAG
- Definition
- Members
-
Name Type Description tag_name char[255]
Tag name tag_id uint16_t
Tag ID type_name char[255]
Tag type name (Bool, UInt8, Int8, UInt16, Int16, UInt64, Int64, Float, ASCII, Hexa) type_id uint16_t
Tag type ID (ex: TAG_TYPES_BOOLEAN ...) access_rights uint8_t
Access Rights: 0: Read/Writeable, 1: Readable description char[255]
Tag description: value unit, comment ... identifier uint16_t
FIP variable identifier start_bit uint16_t
Start bit value in FIP frame stop_bit uint16_t
Stop bit value in FIP frame endianness int8_t
Endianness: -1: not significant, 0: big-endian, 1: little-endian - See also
FIP_USERCONF
- Definition
- Members
-
Name Type Description this_station USERDEF_STATION_INF*
Station Information speed uint8_t
0 : 31.25 kb/s, 1 : 1 Mb/s, 2 : 2.5 Mb/s, 3 : 5 Mb/s t_slot uint8_t
TSlot silence uint8_t
Silence_Par turn_around uint8_t
RPTime_Par frame_type uint8_t
0 : FIP - 1 : WorldFIP - 2 : SlowFIP is_arbiter bool
0 : no - 1 : yes arbiter USERDEF_ARBITER*
Arbiter Structure nb_variables uint16_t
Variables number variables USERDEF_VARIABLE*
Variable Structure(s) nb_messages uint16_t
Messages number messages USERDEF_MESSAGE*
Message Structure(s) nb_tags uint16_t
Tags number tags USERDEF_TAG*
Tag Structure(s) - See also
OPCUA_LOGIN
- Definition
- Members
-
Name Type Description username char*
Login username password char*
Login password - See also
OPCUA_USERCONF
- Definition
- Members
-
Name Type Description server_certificate_der char*
Server certificate file (*.der)
Note: If enable_encryption flag is set, this parameter is mandatory else optional.OPC UA Security Policies Section enable_encryption bool
Encryption support: 1: enable, 0: disable
Note: If this flag is disable, all other parameters of this section become non-significant.private_key_der char*
Path to the private key file (*.der) trust_list_folder char*
Path to the folder containing the trust files issuer_list_folder char*
Path to the folder containing the issuer files revocation_list_folder char*
Path to the folder containing the revocation files disable_unencrypted bool
Unencrypted channel: 1: disable, 0: enable disable_basic128 bool
Basic128Rsa15 secure channel: 1: disable, 0: enable disable_basic256 bool
Basic256 secure channel: 1: disable, 0: enable disable_basic256Sha256 bool
Basic256Sha256 secure channel: 1: disable, 0: enable OPC UA Control Access Section disable_anonymous bool
Anonymous user access: 1: disable, 0: enable nb_logins uint16_t
Number of username/password logins to register into OPC UA control access plugin logins OPCUA_LOGIN*
OPC UA logins - See also
FIP_USERCALLBACKS
- Definition
- Members
-
Name Type Description file_completion cb_file_completion
File completion callback file_progression cb_file_progression
File progression callback fip_synchro cb_fip_synchro
Synchro variable 0x9003 callback (harware irq) fip_event cb_fip_event
Other FIP event callback (hardware irq) - [see also fipcore_read_evt] ctx_ptr void*
Callbacks context (ex: object pointer in cpp app) - See also
CONSUMED_VARIABLE
- Definition
- Members
-
Name Type Description Pdu uint8_t
Frame PDU Length uint8_t
Useful Data Length Data_Var uint8_t [128]
Useful Data Production_Status uint8_t
Production Status Byte - See also
CONSUMED_VARIABLE_TIME
- Definition
- Members
-
Name Type Description Pdu uint8_t
Frame PDU Length uint8_t
Useful Data Length Data_Var uint8_t [128]
Useful Data Production_Time uint32_t
Production Time Production_Status uint8_t
Production Status Byte - See also
PRODUCED_VARIABLE
- Definition
- Members
-
Name Type Description Data_Var uint8_t [126]
Useful Data - See also
PRESENT_LIST
- Definition
- Members
-
Name Type Description Pdu uint8_t
0x50 (SM_MPS_PDU) Total_Length uint8_t
0x46 (70) Medium_Tab1_Id uint8_t
0x80 Medium_Tab1_Length uint8_t
0x20 (32) Medium_Tab1 uint8_t [32]
Subscribers presence on medium 1 Medium_Tab2_Id uint8_t
0x80 Medium_Tab2_Length uint8_t
0x20 (32) Medium_Tab2 uint8_t [32]
Subscribers presence on medium 2 - See also
MESSAGE_FRAME_OUT
- Definition
- Members
-
Name Type Description Msg_Mode uint8_t
MSG_SDA / MSG_SDN (yes/no acknowledgment) Reserved_Byte_0 uint8_t
Reserved Msg_Length_PF uint8_t
High order message length Msg_Length_Pf uint8_t
Low order message length Dest_Add_PF uint8_t
Recipient LSAP – High order byte Dest_Add_Pf uint8_t
Recipient LSAP – Low order byte Dest_Segment uint8_t
Recipient segment number Src_Add_PF uint8_t
Source address – High order byte Src_Add_Pf uint8_t
Source address – Low order byte Src_Segment uint8_t
Source segment number Useful_Data uint8_t [256]
Useful data - See also
MESSAGE_FRAME_IN
- Definition
- Members
-
Name Type Description Msg_Reception_Time uint16_t
Message reception date Msg_Length uint16_t
Message length Dest_Add_PF uint8_t
Recipient LSAP – High order byte Dest_Add_Pf uint8_t
Recipient LSAP – Low order byte Dest_Segment uint8_t
Recipient segment number Src_Add_PF uint8_t
Source address – High order byte Src_Add_Pf uint8_t
Source address – Low order byte Src_Segment uint8_t
Source segment number Useful_Data uint8_t [256]
Useful data - See also
BA_PARAMETERS
- Definition
- Members
-
Name Type Description BA_Subscriber_Number uint16_t
Network subscriber address BA_Max_Subscriber_Number uint16_t
Address of the last network subscriber BA_Priority uint16_t
Bus arbiter priority BA_Start_Time uint16_t
Start timeout of bus arbiter BA_Election_Time uint16_t
Election timeout of bus arbiter - See also
FIP_NETWORK_STATUS
- Definition
- Members
-
Name Type Description No_Error_Channel1 uint16_t
Number of transactions (ch. 1) No_Error_Channel2 uint16_t
Number of transactions (ch. 2) Error_Channel1 uint16_t
Number of transaction errors in reception (ch. 1) Error_Channel2 uint16_t
Number of transaction errors in reception (ch. 2) Error_No_Echo uint16_t
Number of transaction errors in emission (ch. 1/ch.2) Error_Testp_Channel1 uint16_t
Number of errors during testing of subscribers present (ch. 1) Error_Testp_Channel2 uint16_t
Number of errors during testing of subscribers present (ch. 2) BA_Current_Macrocyle uint16_t
Macrocycle address of bus arbiter BA_Status uint16_t
Bus arbiter operating status FIELDUAL_Status uint16_t
FIELDUAL component status - Details
BA_Status : (16-bit)
See enumeration: BA_STATUS_CODE
FIELDUAL_Status : (16-bit)
- b0 : Channel 1 active (0: no, 1: yes)
- b1 : Channel 2 active (0: no, 1: yes)
- b2 : Channel 1 TX Error (0: no, 1: yes)
- b3 : Channel 2 TX Error ((0: no, 1: yes)
- b4 : Channel 1 watchdog error (0: no, 1: yes)
- b5 : Channel 2 watchdog error (0: no, 1: yes)
See enumeration: MEDIUM_STATUS_FLAGS
- See also
FIP_STATISTICS
- Definition
- Members
-
Name Type Description Irq_Handled_Count uint32_t
Interrupt request produced by the fip device Irq_Non_Handled_Count uint32_t
Interrupt request produced by another device (same IRQ line) Cycle_Count uint64_t
Number of macrocycles - linked with fip synchro var (0x9003) Cycle_Time uint64_t
Last macrocycle time (period) - nanosecond resolution Var_P_Sent_Count uint64_t
Number of variables sent with a network event flag sets to "permanent" Var_T_Sent_Count uint64_t
Number of variables sent with a network event flag sets to "temporary" Var_P_Received_Count uint64_t
Number of variables received with a network event flag sets to "permanent" Var_T_Received_Count uint64_t
Number of variables received with a network event flag sets to "temporary" Msg_Received_Count uint64_t
Number of message received Msg_Sent_Count uint64_t
Number of message sent APU_List_Sent_Count uint64_t
Number of "urgent" requests for aperiodic variable list sent APN_List_Sent_Count uint64_t
Number of "normal" requests for aperiodic variable list sent BA_Activity_Count uint64_t
Counter of bus arbiter (re)activation BA_Stop_On_Timeout_Count uint64_t
Counter of stopping of bus arbiter following timeout BA_Stop_On_Anomalies_Count uint64_t
Counter of stopping of bus arbiter following network anomalies BA_Stop_By_User_Count uint64_t
Counter of stopping of bus arbiter following user request BA_Idle_Count uint64_t
Counter of return of bus arbiter to idle status BA_Suspend_Count uint64_t
Counter of bus arbiter suspend - See also
Callbacks
cb_fip_synchro
- Definition
- Description
- This callback is used to signal an event associated with the reception of a synchronization variable ID(0x9003). This is useful to synchronize the user application with the FIP macrocycle.
- Parameters
- Input
hnd
Session handle.callback_ctx
Pointer to the user context of the callback function.- Output
- NONE
- Return Value
- NONE
cb_fip_event
- Definition
- Description
- This callback is used to signal the following event:
- Messaging processing events
They systematically report the sending (with detailed report) or receiving of a message. - Aperiodic request processing events
They systematically report the sending of a list of Urgent or Normal aperiodic requests to the bus arbiter. - BA status change events
They report suspension, activation or return to idle status of the bus arbiter. - Variable send/receive events
These events can be temporary or permanent. A permanent event is sent each time the variable is sent or received, whereas temporary events are reported to the user just once [see also fipcore_def_var_event_by_id].
- Messaging processing events
- See also : fipcore_read_evt
- Parameters
- Input
hnd
Session handle.callback_ctx
Pointer to the user context of the callback function.- Output
- NONE
- Return Value
- NONE
cb_file_progression
- Definition
- Description
- This callback allows to retrieve file transfer progress information.
- Parameters
- Input
hnd
Session handle.direction
File transfer direction (0: File Input, 1: File Output).dest_id
File destination ID.dest_seg
File destination segment.src_id
File source ID.src_seg
File source segment.chunk_number
Number of the current package.total_chunks
Number of total packages that make up the file.time_elapsed_s
Time elapsed (in seconds) since transfer started.callback_ctx
Pointer to the user context of the callback function.- Output
- NONE
- Return Value
- NONE
cb_file_completion
- Definition
- Description
- This callback is called when a file transfer is complete.
- Parameters
- Input
hnd
Session handle.direction
File transfer direction (0: File Input, 1: File Output).dest_id
File destination ID.dest_seg
File destination segment.src_id
File source ID.src_seg
File source segment.error
Return code on completion.transaction_duration_s
Total transaction time (in seconds).target_path
Path of the directory where the file is located.callback_ctx
Pointer to the user context of the callback function.- Output
- NONE
- Return Value
- See Error Codes section.