Test and Measurement Forum

AC coupling

Post general discussions on using our drivers to write your own software here

AC coupling

Postby ARC » Thu Jan 24, 2013 11:28 am

Hello,

I need to change the channel settings to AC rather than DC, im controlling the C console code as a DLL, and the struct for CHANNEL_SETTINGS only contains DCcoupled.
To change the channel to read in AC do i simply add short AC (for example) to the CHANNEL_SETTINGS struct and change ps2000aSetChannel to:


status = ps2000aSetChannel(unit->handle, (PS2000A_CHANNEL) PS2000A_CHANNEL_A + i,
unit->channelSettings[PS2000A_CHANNEL_A + i].enabled,
(PS2000A_COUPLING) unit->channelSettings[PS2000A_CHANNEL_A + i].AC,
(PS2000A_RANGE) unit->channelSettings[PS2000A_CHANNEL_A + i].range, 0);


Thanks for the help :)
ARC
Newbie
 
Posts: 0
Joined: Wed Aug 08, 2012 8:38 am

Re: AC coupling

Postby Martyn » Thu Jan 24, 2013 11:44 am

In ps2000aSetChannel the type needs to be from the following enumeration

Code: Select all
typedef enum enPS2000ACoupling
{
   PS2000A_AC,
   PS2000A_DC
} PS2000A_COUPLING;
Martyn
Technical Specialist
Martyn
Site Admin
Site Admin
 
Posts: 2287
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: AC coupling

Postby ARC » Fri Jan 25, 2013 2:52 pm

ah great thanks :)
ARC
Newbie
 
Posts: 0
Joined: Wed Aug 08, 2012 8:38 am


Return to General Software Discussions

Who is online

Users browsing this forum: No registered users and 0 guests