I just got a couple of 1048_0 temperature sensors
I am having a hard time I have not done this in years and years
I looked at the sample code I downloaded from the website and I cant figure it out
Can anyone help me with just simple code to get me started ???
Please
I am also using VB2012 64bit is that a problem ???
Thanks
Biggs
I cant figure out how to use multiple 1048-0 temperature sensor
This is what I got
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
sensor = New Phidgets.TemperatureSensor
sensor.open(284703)
End Sub
Private Sub sensor_TemperatureChange(ByVal sender As Object, ByVal e As Phidgets.Events.TemperatureChangeEventArgs) Handles sensor.TemperatureChange
If e.Index = 0 Then
NumericUpDown19.Text = e.Temperature.ToString
ElseIf e.Index = 1 Then
NumericUpDown20.Text = e.Temperature.ToString
ElseIf e.Index = 2 Then
NumericUpDown21.Text = e.Temperature.ToString
ElseIf e.Index = 3 Then
NumericUpDown22.Text = e.Temperature.ToString
End If
End Sub
Were do I open the second 1048 SN# 284285 ??? and how do I do the sensor_TemperatureChange for the second 1048
You need to create a second temperature sensor object.
sensor = New Phidgets.TemperatureSensor
sensor.open(284703)
Like that, only a second one. Use the appropriate serial number as well. You can use the same event handler for both devices. You can differentiate in the handler which device generated the event by checking the serial number of the sender object.
This is what I did not sure if its right as for the handle I cant figure one out
I also have been looking for multiple phidgets examples from the example pack I downloaded from you guys I cant find it
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
sensor = New Phidgets.TemperatureSensor
sensor.open(284703)
sensor.open(284285)