Expand description
Auto generated (bindgen) wrapper for LibOSDP C API exposed from osdp.h here.
Structs§
- @brief User defined communication channel abstraction for OSDP devices. The methods for read/write/flush are expected to be non-blocking.
- @brief OSDP Command Structure. This is a wrapper for all individual OSDP commands.
- @brief Sent from CP to control the behaviour of a buzzer in the PD.
- @brief Sent in response to a COMSET command. Set communication parameters to PD. Must be stored in PD non-volatile memory.
- @brief File transfer start command
- @brief This command transfers an encryption key from the CP to a PD.
- @brief Sent from CP to PD to control the behaviour of it’s on-board LEDs
- @brief LED params sub-structure. Part of LED command. See @ref osdp_cmd_led.
- @brief Manufacturer Specific Commands
- @brief Command sent from CP to Control digital output of PD.
- @brief Command to manipulate any display units that the PD supports.
- @brief OSDP Event structure.
- @brief OSDP event cardread
- @brief OSDP Event Keypad
- @brief OSDP Event Manufacturer Specific Command
- @brief LibOSDP event notification
- @brief OSDP File operations struct that needs to be filled by the CP/PD application and registered with LibOSDP using osdp_file_register_ops() before a file transfer command can be initiated.
- @brief PD capability structure. Each PD capability has a 3 byte representation.
- @brief PD ID information advertised by the PD.
- @brief OSDP PD Information. This struct is used to describe a PD to LibOSDP.
- @brief Status report structure. Used by OSDP_CMD_STATUS and OSDP_EVENT_STATUS. In case of command, it is used to send a query to the PD while in the case of events, the PD responds back with this structure.
Constants§
- < Reader buzzer control command
- < PD communication configuration command
- < File transfer command
- < Encryption Key Set Command
- < Reader LED control command
- < Manufacturer specific command
- < Output control command
- < Max command value
- < Status report command
- < Reader text output command
- < ASCII card format
- < Unspecified card format
- < Wiegand card format
- < Max card format value
- Application command outcome report.
- PD state change
- Secure Channel state change
- < Card read event
- < Keypad press event
- < Manufacturer specific reply event
- < LibOSDP notification event
- < Max event value
- < Status event
- < Amber
- < Blue
- < Cyan
- < Green
- < Magenta
- < No color
- < Red
- < Max value
- < White
- < Log level Alert
- < Log level Critical
- < Log level Debug
- < Log level Emergency
- < Log level Error
- < Log level Info
- < Log level max value
- < Log level Notice
- < Log level Warning
- This capability indicates the ability of the reader to handle biometric input
- This capability indicates the form of the card data is presented to the Control Panel.
- All PDs must be able to support the checksum mode. This capability indicates if the PD is capable of supporting CRC mode.
- This capability indicates the extent to which the PD supports communication security (Secure Channel Communication)
- This function indicates the ability to monitor the status of a switch using a two-wire electrical connection between the PD and the switch. The on/off position of the switch indicates the state of an external device.
- This capability indicates the maximum size multi-part message which the PD can handle.
- This function provides a switched output, typically in the form of a relay. The Output has two states: active or inactive. The Control Panel (CP) can directly set the Output’s state, or, if the PD supports timed operations, the CP can specify a time period for the activation of the Output.
- This capability indicates the number of credential reader devices present. Compliance levels are bit fields to be assigned as needed.
- This capability indicates the presence of and type of an Audible Annunciator (buzzer or similar tone generator)
- This capability indicates the presence of and type of LEDs.
- This capability indicates that the PD supports a text display emulating character-based display terminals.
- This capability indicates the maximum size single message the PD can receive.
- Capability Sentinel
- This capability indicates whether the PD supports the transparent mode used for communicating directly with a smart card.
- This capability indicates that the type of date and time awareness or time keeping ability of the PD.
- Dummy.
- < BIO_FORMAT not supported
- < BIO_TYPE not supported
- < Command length error
- < Unknown Command Code – Command not implemented by PD
- < Message check character(s) error (bad cksum/crc)
- < No error
- < Unable to process command record
- < unsupported security block or security conditions not met
- < Secure Channel is not supported by PD
- < NAK codes max value
- < Sequence number error
- @brief Status report of the inputs attached the PD
- @brief Local tamper and power status report
- @brief Status report of the output attached the PD
- @brief Remote tamper and power status report
Functions§
- @brief Deletes all commands queued for a give PD
- @brief Get capability associated to a function_code that the PD reports in response to osdp_CAP(0x62) command. Calling this method before the CP has had a the chance to get this information will return invalid/stale results.
- @brief Get PD ID information as reported by the PD. Calling this method before the CP has had a the chance to get this information will return invalid/stale results.
- @brief Set or clear OSDP public flags
- @brief Periodic refresh method. Must be called by the application at least once every 50ms to meet OSDP timing requirements.
- @brief Generic command enqueue API.
- @brief Set callback method for CP event notification. This callback is invoked when the CP receives an event from the PD.
- @brief This method is used to setup a device in CP mode. Application must store the returned context pointer and pass it back to all OSDP functions intact.
- @brief Cleanup all osdp resources. The context pointer is no longer valid after this call.
- @brief Register a global file operations struct with OSDP. Both CP and PD modes should have done so already before CP can sending a OSDP_CMD_FILE_TX.
- @brief Query file transfer status if one is in progress. Calling this method when there is no file transfer progressing will return error.
- @brief Get a bit mask of number of PD that are online and have an active secure channel currently.
- @brief Get LibOSDP source identifier as a
const char *
. This string has info about the source tree from which this version of LibOSDP was built. Used in diagnostics. - @brief Get a bit mask of number of PD that are online currently.
- @brief Get LibOSDP version as a
const char *
. Used in diagnostics. - @brief Configure OSDP Logging.
- @brief Deletes all events from the PD’s event queue.
- @brief API to notify PD events to CP. These events are sent to the CP as an alternate response to a POLL command.
- @brief Periodic refresh method. Must be called by the application at least once every 50ms to meet OSDP timing requirements.
- @brief Set PD’s capabilities
- @brief Set callback method for PD command notification. This callback is invoked when the PD receives a command from the CP.
- @brief This method is used to setup a device in PD mode. Application must store the returned context pointer and pass it back to all OSDP functions intact.
- @brief Cleanup all osdp resources. The context pointer is no longer valid after this call.
- @brief A callback function that gets called when LibOSDP wants to emit a log line. All messages (of all log levels) are passed on to this callback without any log formatting. This API is for users who may already have a logger configured in their application.
Type Aliases§
- @brief Callback for CP event notifications. After it has been registered with
osdp_cp_set_event_callback
, this method is invoked when the CP receives an event from the PD. - @brief OSDP application exposed commands
- @brief Various card formats that a PD can support. This is sent to CP when a PD must report a card read.
- @brief LibOSDP event notification type
- @brief OSDP PD Events
- @brief Close file that corresponds to a given file descriptor
- @brief Open a pre-agreed file
- @brief Read a chunk of file data into buffer
- @brief Write a chunk of file data from buffer to disk.
- @brief pointer to function that drops all bytes in TX/RX fifo. This function should be non-blocking.
- @brief LED Colors as specified in OSDP for the on_color/off_color parameters.
- @brief A callback function to be used with external loggers
- @brief Different levels of log messages; based on importance of the message with LOG_EMERG being most critical to LOG_DEBUG being the least.
- @brief Puts a string to the logging medium
- @brief Various PD capability function codes.
- @brief OSDP specified NAK codes
- @brief pointer to function that copies received bytes into buffer. This function should be non-blocking.
- @brief OSDP Status report types
- @brief To keep the OSDP internal data structures from polluting the exposed headers, they are typedefed to void before sending them to the upper layers. This level of abstraction looked reasonable as technically no one should attempt to modify it outside of the LibOSDP and their definition may change at any time.
- @brief pointer to function that sends byte array into some channel. This function should be non-blocking.
- @brief Callback for PD command notifications. After it has been registered with
osdp_pd_set_command_callback
, this method is invoked when the PD receives a command from the CP.
Unions§
- Command
- Event