0% found this document useful (0 votes)
76 views3 pages

Retrieve Hardware Information: Determining The Adaptor Name

This document provides steps to retrieve hardware information, determine the supported video formats, and create a video input object for image acquisition using MATLAB: 1. The imaqhwinfo function is used to determine the available adaptors and retrieve information about a specific adaptor and device. 2. The videoinput function creates a video input object, specifying the adaptor name, device ID, and video format obtained from imaqhwinfo. 3. Entering the video input object name at the prompt displays a summary of acquisition parameters and status, including the selected source, frames per trigger, and video format. Optional preview of the video stream is also demonstrated.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
76 views3 pages

Retrieve Hardware Information: Determining The Adaptor Name

This document provides steps to retrieve hardware information, determine the supported video formats, and create a video input object for image acquisition using MATLAB: 1. The imaqhwinfo function is used to determine the available adaptors and retrieve information about a specific adaptor and device. 2. The videoinput function creates a video input object, specifying the adaptor name, device ID, and video format obtained from imaqhwinfo. 3. Entering the video input object name at the prompt displays a summary of acquisition parameters and status, including the selected source, frames per trigger, and video format. Optional preview of the video stream is also demonstrated.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Retrieve Hardware Information

Determining the Adaptor Name:

imaqhwinfo

ans =

InstalledAdaptors: {'dcam' 'winvideo'}


MATLABVersion: '7.4 (R2007a)'
ToolboxName: 'Image Acquisition Toolbox'
ToolboxVersion: '2.1 (R2007a)'

Determining the Device ID:

info = imaqhwinfo('dcam')

info =

AdaptorDllName: [1x77 char]


AdaptorDllVersion: '2.1 (R2007a)'
AdaptorName: 'dcam'
DeviceIDs: {[1]}
DeviceInfo: [1x1 struct]

Determining the Supported Video Formats:

dev_info = imaqhwinfo('dcam',1)

dev_info =

DefaultFormat: 'F7_Y8_1024x768'
DeviceFileSupported: 0
DeviceName: 'XCD-X700 1.05'
DeviceID: 1
ObjectConstructor: 'videoinput('dcam', 1)'
SupportedFormats: {'F7_Y8_1024x768' 'Y8_1024x768'}
Create a Video Input Object

The following example creates a video input object for the DCAM adaptor. Substitute the
adaptor name of the image acquisition device available on your system.

vid = videoinput('dcam',1,'Y8_1024x768')

The videoinput function accepts three arguments: the adaptor name, device ID, and video format.
You retrieved this information in step 2. The adaptor name is the only required argument; the
videoinput function can use defaults for the device ID and video format. To determine the default
video format, look at the DefaultFormat field in the device information structure.

Viewing the Video Input Object Summary:

To view a summary of the video input object you just created, enter the variable name (vid) at
the MATLAB command prompt.

vid

Summary of Video Input Object Using 'XCD-X700 1.05'.

Acquisition Source(s): input1 is available.

Acquisition Parameters: 'input1' is the current selected source.


10 frames per trigger using the selected source.
'Y8_1024x768' video data to be logged upon START.
Grabbing first of every 1 frame(s).
Log data to 'memory' on trigger.

Trigger Parameters: 1 'immediate' trigger(s) on START.


Status: Waiting for START.
0 frames acquired since starting.
0 frames available for GETDATA.

Preview the Video Stream (Optional)

To preview the video stream in this example, enter the preview function at the MATLAB
prompt, specifying the video input object created in step 3 as an argument.

preview(vid)
imaqtool

You might also like