mc-Things

mc-Products => mc-Module => Topic started by: Conthings on August 06, 2016, 04:06:45 pm

Title: [SOLVED] Unable to connect to mcmodule
Post by: Conthings on August 06, 2016, 04:06:45 pm
Hi,

I've got a problem with a Lightsensor test I conducted.
I uploaded the following code.
This code works but since then I'm unable to connect to the module or upload new code (I wanted to change RaiseEvent to 30 seconds).
I can find the module in the update tool, but to connect throug the mcgateway is impossible.
Any suggestions? The mcmodule has an reset pin - any change to use this to get back on track?

Code: [Select]
Define PinMode Pin0 As AnalogInput Alias lightVoltage
Define PinMode Pin6 As DigitalOutput Alias enableLightVoltage   

Class LightVideo         
   
    Shared Event measureLight() RaiseEvent Every 500 Milliseconds                 
       
        enableLightVoltage = True 'turn on voltage divider         
        Thread.Sleep(20000) 'sleep 20ms for voltage to stabilize         
        Dim voltage As Short = lightVoltage   
        Dim voltagepayload As ListOfByte = New ListOfByte()
        Dim voltagestring As String
        voltagestring = voltage.ToString
       
        voltagepayload.Add(voltagestring)
       
        Lplan.Publish("mcThings/sensor/000107D6/light", voltagepayload)                   
    End Event       
End Class


Thanks & kind regards
Title: Re: [ISSUE] Unable to connect to mcmodule
Post by: Conthings on August 22, 2016, 05:06:42 pm
I solved it by erasing the Code with the new mc-OTA

Kind regards