Radar,

Thanks again for script and all the help. I ran my tcpdump through your 
script and it actually logs data!!! I have added some of the logs so you 
can see. One thing Ive noticed is it doesn't log barometric pressure. Not 
sure why. I did see that after getting processed by the perl script it adds 
two areas for humidity. Not sure if the duplicate value is the culprit or 
not.


*Couple Questions for you if you have the time:*
1. Is my "tcpdump" syntax what you would use?
2. Any idea on why the Barometric Pressure is not logging?
3. Why does the Console say ""checkversion": "126" when my bridge is the 
latest 2.24 firmware?


*Here is the command Im running:*
sudo tcpdump -A -n -p -l -i eth0 -s0 -W tcp dst port 80 | stdbuf -oL 
strings -n8 | stdbuf -oL grep "&" | ./acurite-lwp.pl

*Raw Dump not processed with the perl script for 5n1:*
..P.....C.&P....0..GET 
/weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1
..P...0.C.&P....p..&id=24C86E06B15C&mt=5N1x38&sensor=00002179
..P...Z.C.&P...cl..&windspeedmph=2&humidity=50
..P...u.C.&P.......&tempf=71.0
..P.....C.&P.......&baromin=29.30&battery=normal&rssi=3
..P.....C.&P....... HTTP/1.1
..P.....C.&P.......hubapi.myacurite.com


*From Console for 5n1 Sensor after issuing the above command:*
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=5N1x38&sensor=00002179&windspeedmph=3
*&humidity=50&humidity=50*&tempf=71.5&baromin=29.30&battery=normal&rssi=3
{ "success": 1, "checkversion": "126" }

*syslog for 5n1:*
Oct 31 13:25:39 weather weewx[15893]: interceptor: ServerThread: POST: 
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=5N1x38&sensor=00002179&windspeedmph=3
*&humidity=50&humidity=50*&tempf=71.5&baromin=29.30&battery=normal&rssi=3
Oct 31 13:25:39 weather weewx[15893]: interceptor: MainThread: raw data: 
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=5N1x38&sensor=00002179&windspeedmph=3
*&humidity=50&humidity=50*&tempf=71.5&baromin=29.30&battery=normal&rssi=3
Oct 31 13:25:39 weather weewx[15893]: interceptor: MainThread: ignored 
parameter realtime=1
Oct 31 13:25:39 weather weewx[15893]: interceptor: MainThread: ignored 
parameter action=updateraw
Oct 31 13:25:39 weather weewx[15893]: interceptor: MainThread: raw packet: 
{'sensor_type.00002179.24C86E06B15C': '5N1x38', 
'sensor_id.00002179.24C86E06B15C': '00002179', 
'temperature.00002179.24C86E06B15C': 71.5, 
'dateTime.00002179.24C86E06B15C': 1477945540, 
'usUnits.00002179.24C86E06B15C': 1, 'battery.00002179.24C86E06B15C': 0, 
'dateTime': 1477945540, 'humidity.00002179.24C86E06B15C': 50.0, 
'bridge_id.00002179.24C86E06B15C': '24C86E06B15C', 
'barometer.00002179.24C86E06B15C': 29.3, 'rssi.00002179.24C86E06B15C': 
0.75, 'windspeed.00002179.24C86E06B15C': 3.0, 'usUnits': 1}
Oct 31 13:25:39 weather weewx[15893]: interceptor: MainThread: mapped 
packet: {'txBatteryStatus': 0, 'outHumidity': 50.0, 'dateTime': 1477945540, 
'outTemp': 71.5, 'windSpeed': 3.0, 'rxCheckPercent': 0.75, 'usUnits': 1}
Oct 31 13:25:40 weather weewx[15893]: manager: added record 2016-10-31 
13:25:00 PDT (1477945500) to database 'weewx.sdb'



I also have 2 Tower Sensors attached so I included logs for this incase one 
of them is conflicting...



*Raw Dump not processed with the perl script for the TowerSensor:*
..P}hNg.MdvP.......GET 
/weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1
..P}hN..MdvP...K...&id=24C86E06B15C&mt=tower&sensor=00008384
..P}hN..MdvP.......&humidity=44&tempf=83.8
..P}hN..MdvP...U"..&baromin=29.30&battery=normal&rssi=3

*From Console for the TowerSensor after issuing the above command:*
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=tower&sensor=00012694&humidity=61&tempf=73.4&baromin=29.30&battery=normal&rssi=3
{ "success": 1, "checkversion": "126" }

*syslog for **the TowerSensor**:*
Oct 31 13:25:42 weather weewx[15893]: interceptor: ServerThread: POST: 
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=tower&sensor=00012694&humidity=61&tempf=73.4&baromin=29.30&battery=normal&rssi=3
Oct 31 13:25:43 weather weewx[15893]: interceptor: MainThread: raw data: 
dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=tower&sensor=00012694&humidity=61&tempf=73.4&baromin=29.30&battery=normal&rssi=3
Oct 31 13:25:43 weather weewx[15893]: interceptor: MainThread: ignored 
parameter realtime=1
Oct 31 13:25:43 weather weewx[15893]: interceptor: MainThread: ignored 
parameter action=updateraw
Oct 31 13:25:43 weather weewx[15893]: interceptor: MainThread: raw packet: 
{'dateTime.00012694.24C86E06B15C': 1477945543, 
'sensor_type.00012694.24C86E06B15C': 'tower', 'rssi.00012694.24C86E06B15C': 
0.75, 'battery.00012694.24C86E06B15C': 0, 'dateTime': 1477945543, 
'bridge_id.00012694.24C86E06B15C': '24C86E06B15C', 'usUnits': 1, 
'humidity.00012694.24C86E06B15C': 61.0, 'usUnits.00012694.24C86E06B15C': 1, 
'barometer.00012694.24C86E06B15C': 29.3, 
'temperature.00012694.24C86E06B15C': 73.4, 
'sensor_id.00012694.24C86E06B15C': '00012694'}
Oct 31 13:25:43 weather weewx[15893]: interceptor: MainThread: mapped 
packet: {'txBatteryStatus': 0, 'outHumidity': 61.0, 'dateTime': 1477945543, 
'outTemp': 73.4, 'rxCheckPercent': 0.75, 'usUnits': 1}
Oct 31 13:25:43 weather weewx[15893]: manager: unable to add record 
2016-10-31 13:25:00 PDT (1477945500) to database 'weewx.sdb': UNIQUE 
constraint failed: archive.dateTime



*Added Bonus:*

I have the latest tcpflow and it now works with -0. I have a nice pretty 
output from that by issuing the following:

*sudo tcpflow -C -0 -s tcp dst port 80:*
GET 
/weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=5N1x38&sensor=00002179&windspeedmph=2&humidity=50&tempf=70.9&baromin=29.31&battery=normal&rssi=3
 
HTTP/1.1
Host: hubapi.myacurite.com
User-Agent: Hub/224
Connection: close

GET 
/weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=tower&sensor=00008384&humidity=44&tempf=83.8&baromin=29.31&battery=normal&rssi=3
 
HTTP/1.1
Host: hubapi.myacurite.com
User-Agent: Hub/224
Connection: close

GET 
/weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1&id=24C86E06B15C&mt=tower&sensor=00012694&humidity=63&tempf=73.0&baromin=29.31&battery=normal&rssi=3
 
HTTP/1.1
Host: hubapi.myacurite.com
User-Agent: Hub/224
Connection: close



Thanks Again!
Brad

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to