Test and Measurement Forum

Streaming PicoLog PT-104 on excel

Forum for discussing PicoLog

Streaming PicoLog PT-104 on excel

Postby wyk » Wed Feb 05, 2014 10:07 am

Hi,

I'm a beginner in the Visual Basic programming world. I intend to use PT-104 to stream data into an excel file. The data source is from a load cell connected to the PT-104 itself. I've been using the excel example provided in the SDK, however I've been receiving this response

"Unit not opened"

I believe this is the section of the code in the macro that affects outcome

Code: Select all

status = UsbPt104OpenUnit(handle, 0)

If status <> 0 Then
    MsgBox "Unit not opened", vbOKOnly, "Error Message"
    Cells(2, "A").value = "Not opened"
    Exit Sub
End If

'Get serial number
status = UsbPt104GetUnitInfo(handle, S, 255, requiredSize, 4)
Cells(2, "A").value = S

'Channel 1: 4-wire PT-100 measurement
status = UsbPt104SetChannel(handle, 1, 1, 4)

'Channel 2: 4-wire PT-100 measurement
status = UsbPt104SetChannel(handle, 2, 1, 4)

'Channel 3: 4-wire PT-100 measurement
status = UsbPt104SetChannel(handle, 3, 1, 4)

'Channel 4: 4-wire PT-100 measurement
status = UsbPt104SetChannel(handle, 4, 1, 4)



Please help! i'm at my wits end!
wyk
Newbie
 
Posts: 0
Joined: Wed Feb 05, 2014 7:37 am

Re: Streaming PicoLog PT-104 on excel

Postby Martyn » Wed Feb 05, 2014 10:47 am

Does the Picolog software detect and run the logger ?
Martyn
Technical Specialist
Martyn
Site Admin
Site Admin
 
Posts: 2348
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots


Return to PicoLog

Who is online

Users browsing this forum: No registered users and 0 guests