| MIP_SDK
    v4.0.0
    MicroStrain Communications Library for embedded systems | 
#include "mip_types.h"Go to the source code of this file.
| Classes | |
| struct | mip::C::mip_packet_view | 
| Structure representing a MIP Packet.  More... | |
| Namespaces | |
| microstrain | |
| microstrain::C | |
| mip | |
| A collection of C++ classes and functions covering the full mip api. | |
| mip::C | |
| Typedefs | |
| typedef struct mip::C::mip_packet_view | mip::C::mip_packet_view | 
| Structure representing a MIP Packet.  More... | |
| typedef enum mip::C::mip_packet_index | mip::C::mip_packet_index | 
| typedef enum mip::C::mip_packet_index_length | mip::C::mip_packet_index_length | 
| typedef enum mip::C::mip_packet_sync_byte | mip::C::mip_packet_sync_byte | 
| Enumerations | |
| enum | mip::C::mip_packet_index { mip::C::MIP_PACKET_INDEX_SYNC_1 = 0, mip::C::MIP_PACKET_INDEX_SYNC_2 = 1, mip::C::MIP_PACKET_INDEX_DESC_SET = 2, mip::C::MIP_PACKET_INDEX_LENGTH = 3, mip::C::MIP_PACKET_INDEX_PAYLOAD = 4 } | 
| enum | mip::C::mip_packet_index_length { mip::C::MIP_PACKET_HEADER_LENGTH = 4, mip::C::MIP_PACKET_CHECKSUM_LENGTH = 2, mip::C::MIP_PACKET_PAYLOAD_LENGTH_MIN = 0, mip::C::MIP_PACKET_PAYLOAD_LENGTH_MAX = 255, mip::C::MIP_PACKET_LENGTH_MIN = MIP_PACKET_HEADER_LENGTH + MIP_PACKET_CHECKSUM_LENGTH + MIP_PACKET_PAYLOAD_LENGTH_MIN, mip::C::MIP_PACKET_LENGTH_MAX = MIP_PACKET_HEADER_LENGTH + MIP_PACKET_CHECKSUM_LENGTH + MIP_PACKET_PAYLOAD_LENGTH_MAX } | 
| enum | mip::C::mip_packet_sync_byte { mip::C::MIP_SYNC_1 = 0x75, mip::C::MIP_SYNC_2 = 0x65 } | 
| Functions | |
| void | mip::C::mip_packet_create (mip_packet_view *packet, uint8_t *buffer, size_t buffer_size, uint8_t descriptor_set) | 
| Create a brand-new MIP packet in the given buffer.  More... | |
| bool | mip::C::mip_packet_add_field (mip_packet_view *packet, uint8_t field_descriptor, const uint8_t *payload, uint8_t payload_length) | 
| Adds a pre-constructed MIP field to the packet.  More... | |
| int | mip::C::mip_packet_create_field (mip_packet_view *packet, uint8_t field_descriptor, uint8_t payload_length, uint8_t **payload_ptr_out) | 
| Allocate a MIP field within the packet and return the payload pointer.  More... | |
| int | mip::C::mip_packet_update_last_field_length (mip_packet_view *packet, uint8_t *payload_ptr, uint8_t new_payload_length) | 
| Changes the size of the last field in the packet.  More... | |
| int | mip::C::mip_packet_cancel_last_field (mip_packet_view *packet, uint8_t *payload_ptr) | 
| Removes the last field from the packet after having allocated it.  More... | |
| void | mip::C::mip_packet_finalize (mip_packet_view *packet) | 
| Prepares the packet for transmission by adding the checksum.  More... | |
| void | mip::C::mip_packet_reset (mip_packet_view *packet, uint8_t descriptor_set) | 
| Reinitialize the packet with the given descriptor set.  More... | |
| void | mip::C::mip_packet_from_buffer (mip_packet_view *packet, const uint8_t *buffer, size_t length) | 
| Initializes a MIP packet from an existing buffer.  More... | |
| uint8_t | mip::C::mip_packet_descriptor_set (const mip_packet_view *packet) | 
| Returns the MIP descriptor set for this packet.  More... | |
| uint_least16_t | mip::C::mip_packet_total_length (const mip_packet_view *packet) | 
| Returns the total length of the packet, in bytes.  More... | |
| uint8_t | mip::C::mip_packet_payload_length (const mip_packet_view *packet) | 
| Returns the length of the payload (MIP fields).  More... | |
| const uint8_t * | mip::C::mip_packet_buffer (const mip_packet_view *packet) | 
| Returns a read-only pointer to the data buffer.  More... | |
| uint8_t * | mip::C::mip_packet_buffer_w (mip_packet_view *packet) | 
| Returns a writable pointer to the data buffer.  More... | |
| const uint8_t * | mip::C::mip_packet_data (const mip_packet_view *packet) | 
| Returns a pointer to the data buffer containing the packet.  More... | |
| const uint8_t * | mip::C::mip_packet_payload (const mip_packet_view *packet) | 
| Returns a pointer to the packet's payload (the first field).  More... | |
| uint8_t * | mip::C::mip_packet_payload_w (mip_packet_view *packet) | 
| Returns a writable pointer to the packet's payload (the first field).  More... | |
| uint16_t | mip::C::mip_packet_checksum_value (const mip_packet_view *packet) | 
| Returns the value of the checksum as written in the packet.  More... | |
| uint16_t | mip::C::mip_packet_compute_checksum (const mip_packet_view *packet) | 
| Computes the checksum of the MIP packet.  More... | |
| bool | mip::C::mip_packet_is_sane (const mip_packet_view *packet) | 
| Returns true if the packet buffer is not NULL and is at least the minimum size (MIP_PACKET_LENGTH_MIN).  More... | |
| bool | mip::C::mip_packet_is_valid (const mip_packet_view *packet) | 
| Returns true if the packet is valid.  More... | |
| bool | mip::C::mip_packet_is_empty (const mip_packet_view *packet) | 
| Returns true if the mip packet contains no payload.  More... | |
| uint_least16_t | mip::C::mip_packet_buffer_length (const mip_packet_view *packet) | 
| Returns the size of the buffer backing the MIP packet.  More... | |
| int | mip::C::mip_packet_remaining_space (const mip_packet_view *packet) | 
| Returns the remaining space available for more payload data.  More... | |
| bool | mip::C::mip_packet_is_data (const mip_packet_view *packet) | 
| Returns true if the packet is from a data descriptor set.  More... | |
 1.8.17
 1.8.17