The camera does not appear in Measurement & Automation Explorer (MAX)
When first connecting a GigE Vision camera, MAX can be used to configure and test the camera. The camera should appear in the MAX Configuration window under My System»Devices and Interfaces»NI-IMAQdx Devices. If it does not appear in this location, check for the following possible causes:
Case 1: The camera is not GigE Vision compliant.
The camera must comply with the AIA GigE Vision Specification version 1.0 or later. All GigE Vision cameras should display the compliance logo on the camera or in marketing literature (Refer to Figure 1).
Figure 1. The GigE Vision Logo
Note that even though the marketing literature for a GigE camera may indicate that it is GigE Vision compliant, it is possible that the firmware on the camera is old and must be updated in order to achieve full GigE Vision compliance as indicated in the literature. Contact the camera manufacturer to verify if the camera is GigE Vision compliant and request a firmware update that is compatible with GigE Vision.
Case 2: The NI-IMAQdx driver is not installed.
The NI-IMAQdx driver must be installed for a GigE Vision camera to be used with NI software.
-
In the MAX Configuration window, select My System»Software.
-
Expand Software, and verify that NI-IMAQdx appears in the list. If it is not listed, then NI-IMAQdx must be installed.
-
The latest version of Vision Acquisition Software, which includes NI-IMAQdx, can be downloaded from the Drivers and Updates page.
Note: NI-IMAQdx is not available for free. You can use it as a full featured evaluation version for 30 days after which you will need to activate for further use.
Case 3: The link local address (LLA) or automatic private IP address has not been resolved.
When a GigE network interface controller (NIC) is first connected to a camera or a switch, it may take up to 60 seconds or more for the LLA to be resolved. During this time, the Windows Task bar will show an icon with the message “Acquiring Network Address”. Once the message changes to “Limited or no Connectivity”, the camera should be recognized in MAX (Refer to Figure 2).
Figure 2. Windows displays a warning. You can ignore it.
Case 4: The camera subnet does not match the NIC subnet.
The camera and the NIC must be on the same subnet. So if the camera is configured with a network address of 192.168.x.x, then the NIC must be configured with a similar network address of 192.168.y.y. To reset the address on the interface, do the following:
-
Open Network Connections.
-
Right-click your Local Area Connection and select Properties.
-
Select the General tab in the Properties window, and select “Internet Protocol (TCP/IP)”.
-
Click the Properties button, and verify that “Obtain IP Address Automatically” is selected.
-
Select the Alternate Configuration tab, and verify that “Automatic private IP address” is selected.
-
Return to MAX. The camera should now appear in the configuration window.
Figure 3. Setup the Network Connection
Case 5: The driver supplied by the camera vendor is conflicting with NI-IMAQdx.
If the camera runs just fine with the vendor software that comes with the camera but the camera does not show up in MAX, try uninstalling the 3rd party software and driver, and then reinstall NI-IMAQdx. Sometimes the vendor software does not give total access to the camera for the NI-IMAQdx driver, thus preventing the camera from being detected in MAX.
The camera appears in MAX, but a red “x” symbol appears next to the camera name
If the camera appears in MAX with a red “x” symbol next to its name, or no settings can be selected for the camera, then the camera failed to correctly initialize. Check for following possible causes:
Case 1: The camera is already in use.
Only one user may control a camera at any given time. Another user on your machine vision network may be using the camera. You may also have the camera open in another process like LabVIEW or Vision Builder for Automated Inspection. Locate the current user of the camera and close the open connection.
Case 2: Unable to load camera's XML file.
When first opening a camera, an XML file describing the camera attributes is downloaded and parsed. If the XML file is found to be corrupt or incorrect, then an error message will be displayed (“Invalid XML file” or "Error 0xBFF6901D Unable to load camera's XML file." Refer to Figure 4). Contact your camera vendor for an updated version of the cameras firmware.
Figure 4. XML file error
Case 3: Unable to get and/or set an attribute.
In rare circumstances, the XML file downloaded from camera does not match the capabilities of the camera. If the driver is trying to access an attribute described by the XML file which is not implemented in the camera hardware, then an “Unable to set attribute” error message will be displayed. Run the CameraValidator.exe utility with the “/ATTRIBUTES” flag to detect which attributes are generating errors and contact your camera vendor for a new and updated version of the camera firmware. Take the following steps to run the CameraValidator.exe utility:
- Select Start»Run to bring up the Run dialog.
- Type in the following command: "<National Instruments>\NI-IMAQdx\Utility\CameraValidator.exe" /ATTRIBUTES where <National Instruments> is the installed directory of your NI software, typically "C:\Program Files\National Instruments".
- CameraValidator.exe will create an attribute report for each camera. You can find this report in the same folder as CameraValidator.exe. This report validates each attribute in the XML file. Check if any attribute has failed any of the steps. Then contact the camera manufacturer for an updated XML file or camera firmware to correct this attribute. In case the updated XML file or camera firmware does not solve the issue, try to comment out the attributes that didn't pass the validation directly in the XML file. Then, save the changes and restart NI MAX.
Case 4: NI MAX associated a corrupt .XML with your camera
It also is possible that there was an issue when initially associating your camera to an .XML file. In the case that you are unable to select your camera without an error message stating "Error 0xBFF6901E Unable to Read/Write to file", then try to have NI-MAX regenerate this XML file. The steps for this are to:
- Unplug your camera.
- Delete all of the files in the data file located here: C:\Users\Public\Documents\National Instruments\NI-IMAQdx\Data. You can delete all files and folders in the NI-IMAQdx\Data folder
- Plug the camera back in, and MAX will regenerate all the required files once this step is completed
The camera can be opened in MAX, but it does not acquire images
When the camera appears in MAX, it can be tested by running a snap or grab. If an error message appears when clicking the Snap or Grab buttons, stating that packet loss has been detected, check for the following possible causes:
Case 1: The High Performance Driver for Intel Pro/1000 NIC is not installed.
If you are using the Intel Pro/1000 NIC to communicate with your camera, it is recommended that you use the High Performance Driver. This will allow the NI-IMAQdx driver to perform more efficiently, and it will allow for a larger packet size. The High Performance Driver must be enabled manually if hardware is inserted after software installation:
-
Open Device Manager and expand Network Adapters.
-
Select NIC used to communicate with the camera. If the NIC is not an Intel(R) Pro/1000 Adapter, skip to Case 2
-
Right-click the Intel Pro/1000, and select Properties.
-
Select the Driver tab in the Properties window, and select Update Driver.
-
Continue through the Hardware Update Wizard, and manually select National Instruments GigE Vision Adapter.
Figure 5a. Updating the Driver
Figure 5b. Choosing the NI Driver
Case 2: Jumbo Frames are not enabled on Generic NIC.
Some NIC devices other than the Intel Pro/1000 support Jumbo Frames (packet sizes greater than the standard 1500 bytes). Jumbo Frames must be enabled manually on most NIC devices:
-
Open Device Manager, and expand Network Adapters.
-
Right-click the NIC you are using, and select Properties.
-
Select the Advanced tab in the Properties window, and select Jumbo Frames. If Jumbo Frames is not listed, skip to Case 3.
-
Choose the desired packet size from the Value pull-down menu. NI recommends a default size of 9014 bytes for Jumbo Frames.
Figure 6. Enable Jumbo Frames
Case 3: The Generic NIC does not support Jumbo Frames.
If Jumbo Frames are not supported, then the maximum allowable packet size is 1500 bytes. By default, the NI-IMAQdx driver uses a larger packet size. The packet size can be reduced in MAX:
-
Select the camera in MAX, and select the Acquisition Attributes tab at the bottom of the screen.
-
Reduce the value of Packet Size to 1500 or smaller. The camera should now acquire images when the Snap or Grab buttons are pressed.
Case 4: Grab or Snap gives a timeout error
If a snap or grab give a timeout error ("Error 0xBFF6901B Timeout" Refer to Figure 7), check to see if a firewall is enabled. A firewall can block data transmissions initiated by the camera.
Figure 7. A firewall typically causes a timeout
Firewalls are typically used to block network traffic originating from an unknown location. The NI-IMAQdx driver does not know the port that the camera will use to stream its image data. Hence the incoming image data is blocked by the firewall. In order for NI-IMAQdx to acquire from a GigE Vision camera, you will need to disable the firewall or make an exception for the port being used.
Unfortunately, there is not an easy way to open a port or range of ports while keeping the firewall enabled on that device. This is due to the way the GigE Vision protocol is defined. Both the camera's port from which the image stream comes and the PC's port are dynamic. The Windows Firewall is not configurable in a manner that can accommodate this configuration.
Note that this is limitation only applies to the Universal Driver. Firewall settings do NOT affect image data if you use the High Performance driver with an Intel PRO/1000 network card. Since the High Performance driver is implemented closer to hardware, the incoming image data is redirected to the driver before it reaches the firewall.
Black bars are appearing / Network connection gets lost
If there are black bars appearing on the image in NI MAX, first thing you need to do is to check if there are any packet losses between the PC and the Camera. The best way to do this is by using the
Ping command.
- Press Win+R.
- The run tab will open. Type cmd in the bar.
- The command prompt will open. Type ping -t x.x.x.x (the IP address of your camera)
- See if there are any timeouts.
If there are Timeouts or high response times, firstly make sure the connection is stable, by checking the
LAN cables and
adapters. If the issue persists, check if the same problem appears with other network devices connected to the PC. In case it happens with other devices as well, consider replacing the
NIC (Network interface controller) card on your PC. If it happens with only one device, please refer to the manufacturer for additional troubleshooting/replacement.