Search the web
Sign In
New User? Sign Up
ultimaserial_group · UltimaSerial Users
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Help with DI-148U-SP in VB   Message List  
Reply | Forward Message #650 of 794 |
Help with DI-148U-SP in VB

I'm doing some research for a professor, working with equipment that
he purchased and have next to no programming experience. The
DI-148U-SP is being used to measure sensed signals at unique, discrete
increments. We are not using the first two channels, which have the
string pots, only channels 3 and 4. What I need to be able to do is
take X samples over a single second, store it in a variable array,
then write it to a data file, such as a .txt or another type. Below
is the code I was using.

Private Sub Command1_Click()

UltimaSerial.Device = Val(148)
UltimaSerial.CommPort = Val(USB)
UltimaSerial.AcquisitionMode = NoCondition
UltimaSerial.ChannelCount = 2
UltimaSerial.EventLevel = 2
UltimaSerial.SampleRate = 240
UltimaSerial.Start

End Sub


Private Sub UltimaSerial_NewData(ByVal Count As Integer)

Dim A(240) as integer
Ultimaserial1.GetDataEx A(0), 240

End Sub


But the output A variable was only a 240 x 1 array. How should I go
about extracting the 240 samples from the 4 channels (even though I
only need channels 3 and 4)?





Mon Feb 4, 2008 7:19 pm

e.marken
Offline Offline

Forward
Message #650 of 794 |
Expand Messages Author Sort by Date

I'm doing some research for a professor, working with equipment that he purchased and have next to no programming experience. The DI-148U-SP is being used to...
e.marken
Offline
Jan 30, 2008
9:07 pm

I'm doing some research for a professor, working with equipment that he purchased and have next to no programming experience. The DI-148U-SP is being used to...
e.marken
Offline
Feb 4, 2008
7:21 pm

*I am sorry, but I think accidentally deleted a good post from an user replying to this post when I was deleting spam posts :(...
ultimaserial
Offline
Feb 4, 2008
7:27 pm

Found it, here it is: I think you would use the PChannel to set up just channels 3 & 4 of the 148. http://www.ultimaserial.com/standard.html For...
ultimaserial
Offline
Feb 4, 2008
7:33 pm

Any suggestions on the taking just 240 samples in a second and stop taking measurements, and then store those 240 values in an array for those channels? The...
e.marken
Offline
Feb 4, 2008
8:24 pm

UltimaSerial.EventLevel = 480 Take a closer look at the VB samples that comes with the installation Also see NewEvent, EventLevel, GetData & Stop ... an user ...
ultimaserial
Offline
Feb 4, 2008
8:39 pm

Hopefully some kind soul can recover it or answer it. :)...
e.marken
Offline
Feb 4, 2008
7:58 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help