oregon scientific wind speed always north

Posted on
Fri Jun 27, 2014 5:14 pm
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

oregon scientific wind speed always north

the wind speed seems to be ok, the direction is always 0 / North. I also mounted it point south. no change.


here the debug log.
Jun 27, 2014, 6:03:45 PM
RFXCOM Debug getConfiguration start
RFXCOM initializing communication on port /dev/cu.usbserial-08WCLA8J at speed 38400
RFXCOM Debug serial port opened
RFXCOM Debug send reset cmd: 13 0 0 0 0 0 0 0 0 0 0 0 0 0 (0D 00 00 00 00 00 00 00 00 00 00 00 00 00)
RFXCOM Debug PIC INIT IS: none
RFXCOM Debug send init cmd: 13 0 0 1 2 0 0 0 0 0 0 0 0 0 (0D 00 00 01 02 00 00 00 00 00 00 00 00 00)
RFXCOM Debug rcvd init reply: 13 1 0 0 2 82 66 0 0 32 1 1 0 0 (0D 01 00 00 02 52 42 00 00 20 01 01 00 00)
RFXCOM connected to RFXrec 433.92 MHz, firmware version 66
RFXCOM currently enabled receiver protocols: Oregon Scientific
RFXCOM enabling undecoded packet displaying
RFXCOM Debug send set mode cmd: 13 0 0 2 3 82 0 128 0 32 0 0 0 0 (0D 00 00 02 03 52 00 80 00 20 00 00 00 00)
RFXCOM Debug rcvd set mode reply: 13 1 0 1 3 82 66 128 0 32 1 1 0 0 (0D 01 00 01 03 52 42 80 00 20 01 01 00 00)
RFXCOM Debug processing: 16 86 2 2 63 0 0 0 0 20 0 18 0 0 0 0 89 (10 56 02 02 3F 00 00 00 00 14 00 12 00 00 00 00 59)
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 2.00 gust 1.80.
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 4.50 gust 4.00.
RFXCOM Debug Wind sensor 63 in list
RFXCOM Debug ++++++++++++++
RFXCOM Debug processing: 16 86 2 3 63 0 0 0 0 15 0 18 0 0 0 0 89 (10 56 02 03 3F 00 00 00 00 0F 00 12 00 00 00 00 59)
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 1.50 gust 1.80.
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 3.40 gust 4.00.
RFXCOM Debug Wind sensor 63 in list
RFXCOM Debug ++++++++++++++
RFXCOM Debug processing: 10 82 1 4 196 4 0 238 55 1 73 (0A 52 01 04 C4 04 00 EE 37 01 49)
RFXCOM Debug Temp sensor 1220 now 74.84 degrees and 55 humidity.
RFXCOM Debug Temp sensor 1220 in list
RFXCOM Debug UpdateMinMax state temperature value 74.8
RFXCOM Debug check if new day: last date 2014/06/27, new date 2014/06/27


is this a hardware or software problem?


it looks as if the data used are position 6 and 7 (starting at 0) : direction = (ord(data[6]) << 8) + ord(data[7]) (bolded in the log file.


position 6 and 7 are always 0.


any advice appreciated

Karl

ps. it was an adventure to put this on top of the roof... and it is difficult to change..


the python code looks like:
Code: Select all
   def handleWind(self, data):
      devicetype = ord(data[1])
      subtype = ord(data[2])
      sensor = (ord(data[5]) << 8) + ord(data[4])

      direction = (ord(data[6]) << 8) + ord(data[7])    ####################<<<<<<< this where it gets calculated..
      avgSpeed = float(((ord(data[8]) << 8) + ord(data[9]))) / 10
      gust = float(((ord(data[10]) << 8) + ord(data[11]))) / 10
      
      batteryAndSignalData = data[16]
      batteryLevel = self.getBatteryLevel(batteryAndSignalData)
      signalStrength = self.getSignalStrength(batteryAndSignalData)
      
      temp = 0
      chill = 0
      
      #WIND 1-3 Temperature & wind chill not supported
      #WIND 4 Temperature & wind chill are supported
      if (subtype == 4):
         temp = ord(data[13])
         vFactor = 1
         temp2 = ord(data[12])
         if ord(data[12])>127:
            temp2 = ord(data[12])-128
            vFactor = -1

         temp+=(temp2*256)
         temp = temp*vFactor*0.1
         
         chill = ord(data[15])
         vFactor = 1
         chill2 = ord(data[14])
         if ord(data[14])>127:
            chill2 = ord(data[14])-128
            vFactor = -1

         chill+=(chill2*256)
         chill = chill*vFactor*0.1

      self.plugin.debugLog(u"Wind sensor %d direction %d avgSpeed %.2f gust %.2f." % (sensor, direction, avgSpeed, gust))
      avgSpeed = self.convertWindspeedToUnits(avgSpeed)
      gust = self.convertWindspeedToUnits(gust)
      self.plugin.debugLog(u"Wind sensor %d direction %d avgSpeed %.2f gust %.2f." % (sensor, direction, avgSpeed, gust))
      if sensor in self.tempList.keys():
         self.plugin.debugLog(u"Wind sensor %d in list" % sensor)
         self.tempList[sensor].updateStateOnServer(key=u"avgSpeed", value=avgSpeed)
         self.tempList[sensor].updateStateOnServer(key=u"gust", value=gust)
         self.tempList[sensor].updateStateOnServer(key=u"directionDegrees", value=direction)
         self.tempList[sensor].updateStateOnServer(key=u"directionText", value=self.convertDirectionDegreesToText(direction))
         if (subtype == 4):
            self.tempList[sensor].updateStateOnServer(key=u"temperature", value=self.convertTemperatureToUnit(temp))
            self.tempList[sensor].updateStateOnServer(key=u"windChill", value=self.convertTemperatureToUnit(chill))
         self.tempList[sensor].updateStateOnServer(key=u"type", value=subtype)
         self.tempList[sensor].updateStateOnServer(key=u"lastUpdated", value=time.strftime('%Y/%m/%d %H:%M:%S'))
         self.tempList[sensor].updateStateOnServer(key=u"batteryLevel", value=batteryLevel)
         self.tempList[sensor].updateStateOnServer(key=u"signalStrength", value=signalStrength)
         
         display = "--"
         displayMode = self.tempList[sensor].pluginProps["displayField"]
         if displayMode == "Speed":
            display = "%d %s" % (avgSpeed, self.plugin.unitsWind)
         elif displayMode == "SpeedDirection":
            display = "%s at %d %s" % (self.convertDirectionDegreesToText(direction), avgSpeed, self.plugin.unitsWind)
         elif displayMode == "SpeedCompass":
            display = "%d %s %s" % (avgSpeed, self.plugin.unitsWind, direction)
         elif displayMode == "SpeedGust":
            display = "%d %s (%d %s)" % (avgSpeed, self.plugin.unitsWind, gust, self.plugin.unitsWind)
         self.tempList[sensor].updateStateOnServer(key=u"display", value=display)

      else:
         self.handleUnknownDevice(devicetype,sensor)         
Last edited by kw123 on Sat Jun 28, 2014 8:07 pm, edited 1 time in total.

Posted on
Sat Jun 28, 2014 2:51 am
b_weijenberg offline
Posts: 172
Joined: Jun 14, 2006

Re: oregon scientific wind speed always north

The sensor transmits direction = 0! Check the WGR800 sensor.
Or a firmware problem in the RFXtrx, check with the latest firmware.

if you enter the received (hex) data in RFXmngr - Simulate with spaces removed you get:
Simulate: 105602033F000000000F00120000000059
------------------------------------------------
105602033F000000000F00120000000059
Packettype = WIND
subtype = WIND2 - WGR800
Sequence nbr = 3
ID = 16128
Direction = 0 degrees N
Average speed = 1,5 mtr/sec = 5,4 km/hr = 3,36 mph
Wind gust = 1,8 mtr/sec = 6,48 km/hr = 4,03 mph
Signal level = 5
Battery = OK

Posted on
Sat Jun 28, 2014 7:06 am
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

RFXCOM Debug Teststring=105602033F000000000F00120000000059
RFXCOM Debug processing: 16 86 2 3 63 0 0 0 0 15 0 18 0 0 0 0 89 (10 56 02 03 3F 00 00 00 00 0F 00 12 00 00 00 00 59)
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 1.50 gust 1.80.
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 3.40 gust 4.00.
RFXCOM Debug Wind sensor 63 in list


I get north when I use the test string..

I guess, I should upgrade the RFX software?

the link I found: http://www.rjdekok.nl/downloads/rfxtrx_ ... plugin.zip does not work..

where can I down load the latest version?

Thanks

Karl

I have the following version:
RFXCOM initializing communication on port /dev/cu.usbserial-08WCLA8J at speed 38400
RFXCOM connected to RFXrec 433.92 MHz, firmware version 66

Posted on
Sat Jun 28, 2014 9:21 am
b_weijenberg offline
Posts: 172
Joined: Jun 14, 2006

Re: oregon scientific wind speed always north

RFXtrx433/RFXrec433 firmware is available at http://rfxcom.com/Downloads

I have tested with firmware version 77 and this version operates correct:
------------------------------------------------
28-6-2014 17:19:49= 1056010036000087000000000000001A69
Packettype = WIND
subtype = WIND1 - WTGR800
Sequence nbr = 0
ID = 13824
Direction = 135 degrees SE
Average speed = 0 mtr/sec = 0 km/hr = 0 mph
Wind gust = 0 mtr/sec = 0 km/hr = 0 mph
Signal level = 6
Battery = OK

Your sensor must be bad if you still receive North in the latest firmware version.

Posted on
Sat Jun 28, 2014 9:43 am
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

ok downloaded the firmware. how to I install? could not find anything for the mac -- the attached EXE only works with windows.

Posted on
Sat Jun 28, 2014 10:28 am
b_weijenberg offline
Posts: 172
Joined: Jun 14, 2006

Re: oregon scientific wind speed always north

RFXflash can be used in Windows or Linux with mono.

Posted on
Sat Jun 28, 2014 11:13 am
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

Does it work in a mac virtualbox win xp ?


Sent from my iPhone using Tapatalk

Posted on
Sat Jun 28, 2014 1:10 pm
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

tried a spare wind sensor from Norm, same result, must be the software.

Posted on
Sat Jun 28, 2014 7:55 pm
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

have successfully flashed RFXcom 433 with version 77 in windows7 in a virtual box. I am astonished that that worked.

BUT no change its still just north. tried 2 oregon wind sensor devices!


Jun 28, 2014, 8:51:12 PM
RFXCOM Debug getConfiguration start
RFXCOM initializing communication on port /dev/cu.usbserial-08WCLA8J at speed 38400
RFXCOM Debug serial port opened
RFXCOM Debug send reset cmd: 13 0 0 0 0 0 0 0 0 0 0 0 0 0 (0D 00 00 00 00 00 00 00 00 00 00 00 00 00)
RFXCOM Debug PIC INIT IS: none
RFXCOM Debug send init cmd: 13 0 0 1 2 0 0 0 0 0 0 0 0 0 (0D 00 00 01 02 00 00 00 00 00 00 00 00 00)
RFXCOM Debug rcvd init reply: 13 1 0 1 2 82 77 0 0 32 1 1 0 0 (0D 01 00 01 02 52 4D 00 00 20 01 01 00 00)
RFXCOM connected to RFXrec 433.92 MHz, firmware version 77
RFXCOM currently enabled receiver protocols: Oregon Scientific
RFXCOM enabling undecoded packet displaying

RFXCOM Debug UpdateMinMax state temperature value 86.5
RFXCOM Debug check if new day: last date 2014/06/28, new date 2014/06/28
RFXCOM Debug UpdateMinMax state humidity value 0
RFXCOM Debug check if new day: last date 2014/06/28, new date 2014/06/28
RFXCOM Debug ++++++++++++++
RFXCOM Debug processing: 16 86 2 15 63 0 0 0 0 9 0 14 0 0 0 0 89 (10 56 02 0F 3F 00 00 00 00 09 00 0E 00 00 00 00 59)
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 0.90 gust 1.40.
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 2.00 gust 3.10.
RFXCOM Debug Wind sensor 63 in list
RFXCOM Debug ++++++++++++++
RFXCOM Debug processing: 16 86 2 16 63 0 0 0 0 14 0 17 0 0 0 0 89 (10 56 02 10 3F 00 00 00 00 0E 00 11 00 00 00 00 59)
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 1.40 gust 1.70.
RFXCOM Debug Wind sensor 63 direction 0 avgSpeed 3.10 gust 3.80.
RFXCOM Debug Wind sensor 63 in list
RFXCOM Debug ++++++++++++++
RFXCOM Debug processing: 10 82 1 17 196 4 0 224 56 1 73 (0A 52 01 11 C4 04 00 E0 38 01 49)
RFXCOM Debug Temp sensor 1220 now 72.32 degrees and 56 humidity.
RFXCOM Debug Temp sensor 1220 in list
RFXCOM Debug UpdateMinMax state temperature value 72.3

any other idea?

Karl

Posted on
Sat Jun 28, 2014 8:06 pm
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

when I use the windows manager, I get:

------------------------------------------------
1056020F3F000000000C000C0000000069
Packettype = WIND
subtype = WIND2 - WGR800
Sequence nbr = 15
ID = 16128
Direction = 0 degrees N
Average speed = 1.2 mtr/sec = 4.32 km/hr = 2.68 mph
Wind gust = 1.2 mtr/sec = 4.32 km/hr = 2.68 mph
Signal level = 6
Battery = OK

still just north. Its hard to believe that 2 wind sensors have the same hardware defect. or may be they do.
An y suggestions?

Karl

Posted on
Sat Jun 28, 2014 11:16 pm
berkinet offline
User avatar
Posts: 3290
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: oregon scientific wind speed always north

kw123 wrote:
...Any suggestions?

Well, you could move to the South Pole. Then the wind direction would always be correct. :wink:

Posted on
Sun Jun 29, 2014 12:26 am
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

And I don't need AC

Posted on
Sun Jun 29, 2014 6:55 am
b_weijenberg offline
Posts: 172
Joined: Jun 14, 2006

Re: oregon scientific wind speed always north

Which Oregon sensor is this?

Posted on
Sun Jun 29, 2014 7:54 am
kw123 offline
User avatar
Posts: 8363
Joined: May 12, 2013
Location: Dallas, TX

Re: oregon scientific wind speed always north

WGR 800

Posted on
Sun Jun 29, 2014 10:58 am
b_weijenberg offline
Posts: 172
Joined: Jun 14, 2006

Re: oregon scientific wind speed always north

Is the wind direction correct displayed on the Oregon base station?

Who is online

Users browsing this forum: No registered users and 1 guest