GigE Vision Image Acquisition Quick Start Guide
Using the Image Acquisition Toolbox™ Support Package for GigE Vision® Hardware to acquire images requires specific configuration for the Ethernet network
adapter and network connection outside of MATLAB®. The configuration requirement applies to either the
videoinput object using the
gige adaptor or
You must first follow these steps in the following order to get started using a GigE Vision camera with the Image Acquisition Toolbox.
Recommended Hardware Setup
The recommended configuration to get started using the Image Acquisition Toolbox to acquire images from a single GigE Vision camera consists of:
GigE Vision compliant camera
Computer with a camera-dedicated Gigabit Ethernet network adapter (for example a PCI Express Gigabit Ethernet network interface card) that supports jumbo frame sizes, such as 4 KB or 9 KB
Direct connection between the camera and dedicated Gigabit Ethernet adapter
Separate network adapter for any additional computer network connection, such as an Internet connection or your organization’s local area network
Although other hardware setups are possible, the recommended configuration ensures that:
You have maximum bandwidth available for streaming images from the camera.
The camera-dedicated private network connection can have different network or firewall settings than the Internet or domain network connection.
Gigabit Ethernet Network Adapter Configuration
To ensure proper operation and optimum performance when acquiring images, configure your Ethernet adapter using the recommended settings for your platform.
Firewalls and the GigE Vision Camera Network Connection
Firewalls can block the UDP packets used for image data transfer by the GigE Vision Streaming Protocol. The ports used for image data transfer by the camera and gigabit network adapter are dynamic, and setting up the required firewall rules is an advanced operation. Firewall processing of the image data stream can also reduce performance.
The recommended and convenient getting-started configuration is to turn off the firewall for the dedicated network connection of the camera, while keeping the firewall enabled for the other network connections, such as the Internet connection or your local area network connection.
Windows® uses network location profiles to group firewall settings for different types of connections, and turning off Windows firewall selectively for an individual network connection is not directly possible. For more information about network and firewall configurations, see Windows Firewall and GigE Vision Cameras.
GigE Vision Camera Streaming Parameters in MATLAB
Each image acquired by the camera is transferred to the computer as a data block of UDP packets, which are processed by MATLAB. For a lower CPU load during image acquisition and to prevent dropped frames, you can configure the camera streaming parameters (packet size and packet delay) in MATLAB.
The toolbox configures the packet size automatically after the connection between MATLAB and the camera has been established.
The packet size value can also be configured manually by setting the
PacketSizeproperty of the
Set the packet size value to the largest size that the network adapter and camera can handle (not larger than the Ethernet adapter jumbo packet size configured in Gigabit Adapter Settings).
To prevent dropped frames, you can configure the camera to introduce a time delay between the image data packets by setting the
PacketDelayproperty of the
Optimum values for the packet delay depend on the packet size, acquired frame size (image height and width), specified pixel format (for example
'Mono8'), camera frame rate, and other camera-specific settings.
For details about determining the recommended packet delay value, and setting the packet size and packet delay values in MATLAB, see How do I calculate the packet delay for a GigE Vision camera to prevent dropped frames?.
- Configure Gigabit Ethernet Network Adapter on Windows
- Configure Gigabit Ethernet Network Adapter on Linux
- Configure Gigabit Ethernet Network Adapter on macOS
- Additional GigE Vision Setup Options