Go to Post Remember that the reason that you do something should NEVER be for the sole purpose of winning an award. To paraphrase something said by one of the Hall of Fame teams: "You should choose to do something because it is fun and the right thing to do." - tim-tim [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 12-03-2015, 00:29
cbf cbf is offline
Registered User
FRC #2877
 
Join Date: Feb 2012
Location: Newton, MA
Posts: 74
cbf is just really nicecbf is just really nicecbf is just really nicecbf is just really nicecbf is just really nice
Post IMAQdx -- how do I set the camera mode?

In C++. I've dumped the modes and I want #95 (this is part of the list):

Video mode[94] is 320 x 240 JPEG 20.00 fps = 94
Video mode[95] is 320 x 240 JPEG 15.00 fps = 95
Video mode[96] is 320 x 240 JPEG 10.00 fps = 96

can one of the NI guys tell me how to form the proper IMAQdxSetAttribute call to get that mode? I'm thinking I pass in IMAQdxAttributeVideoMode (uisitionAttributes::VideoMode"), but what's the IMAQdxValueType? IMAQdxValueTypeU32? and I just pass a 95?

I'm still experimenting, but if one of you is online..

When I enumerate the attributes, I get:

attr[38] is AcquisitionAttributes::VideoMode, type 4, writeable 0, value=0

Should I be worried about the Writable being zero? Does that mean I can't change video modes by writing to this attribute (.h file says its "get/set").

But does type 4 mean I set it as a character string and not an integer?
  #2   Spotlight this post!  
Unread 12-03-2015, 08:48
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,752
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: IMAQdx -- how do I set the camera mode?

According to the reference manual, it is a U32. I'm not used to using in in C, but I'd expect videoMode to be writable. I'm not sure why the driver returns a 0 for writable. Type 4 seems to indicate that it is an enum. If you search NIIMAQdx.h for IMAQdxValueType and take the fourth element from the enum, it is IMAQdxValueTypeEnumItem, indicating that the value of that tag has a list of enum strings if you ask for them.

Greg McKaskle
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 01:04.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi