Skip to main content

viva_gige/
lib.rs

1#![cfg_attr(docsrs, feature(doc_cfg))]
2//! GigE Vision transport: discovery and control (GVCP), streaming (GVSP),
3//! events and action commands.
4//!
5//! The modules are private; what is public is re-exported here (ADR-0030).
6//! [`consts`] is the one public namespace: GVCP's opcodes, bootstrap register
7//! addresses and protocol limits, the vocabulary the fake camera shares.
8
9mod action;
10pub mod consts;
11mod gvcp;
12mod gvsp;
13mod message;
14mod nic;
15mod status;
16mod time;
17
18pub use action::{AckSummary, ActionParams, ActionRefusal, send_action};
19pub use gvcp::{
20    DeviceInfo, DiscoveryOptions, FORCE_READMEM_ENV, GVCP_PORT, GigeDevice, GigeError,
21    GvcpCapability, StreamParams, discover, discover_all, discover_ip, discover_on_interface,
22    discover_with, encode_packet_resend, force_ip,
23};
24pub use gvsp::{
25    ChunkError, ChunkRaw, GVSP_EXTENDED_HEADER_SIZE, GVSP_HEADER_SIZE, GvspContent, GvspError,
26    GvspHeader, GvspLeader, GvspPacketRef, GvspTrailer, ImageLeader, PAYLOAD_TYPE_CHUNK_DATA,
27    PAYLOAD_TYPE_EXTENDED_CHUNK, PAYLOAD_TYPE_EXTENDED_CHUNK_DATA, PAYLOAD_TYPE_IMAGE,
28    PacketBitmap, StreamConfig, StreamDest, has_extended_chunks, is_chunk_data_payload,
29    is_image_payload, parse_chunks, parse_header, parse_packet_ref,
30};
31pub use message::{EVENT_QUEUE_CAPACITY, EventPacket, EventSocket, EventStats};
32pub use nic::{
33    ASSUMED_MTU, DEFAULT_RCVBUF_BYTES, Iface, IfaceSelector, McOptions, Mtu, RecvBuffer,
34    best_packet_size, bind_multicast, bind_udp, mtu, set_recv_buffer, wait_readable,
35};
36pub use status::GigeStatus;
37pub use time::{DEFAULT_TIME_WINDOW, TimeSync};