i use a perl script to put the obs on one line then feed it to weewx

if you have tcpflow 1.4.4 you can try
tcpflow -C -p -0 -i eth0


On Sunday, October 30, 2016 at 10:01:59 PM UTC-5, Brad Tucker wrote:
>
> I have setup a bridge running raspberry pi. It is connected as follows:
>
> Acurite Bridge -> RaspberyPi WeeWX Bridge -> Internet Connection
>
> It is passing packets through the bridge. The bridge has been updating 
> myaccurite & weather underground for hours and all is well with it.
>
> I am having problems passing the sniffed data to the weewx driver. I have 
> picked together what I think is a decent script but its not parsing 
> properly.
> sudo tcpdump -A -n -p -l -i eth0 -s0 -w - tcp dst port 80 | stdbuf -oL 
> strings -n8
>
> output:
> tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 
> 262144 bytes
> GET 
> /weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1R
> &id=24C86E06B15C&mt=tower&sensor=00012694R
> &humidity=65&tempf=72.8R
> &baromin=29.35&battery=normal&rssi=3R
>  HTTP/1.1
> hubapi.myacurite.com
> User-Agent: Hub/224R
> Connection: close
> GET 
> /weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1]
> &id=24C86E06B15C&mt=5N1x31&sensor=00002179]
> &windspeedmph=0&winddir=270]
> &rainin=0.00&dailyrainin=0.20&humidity=96&tempf=57.2&dewptf=56]
> &baromin=29.35&battery=normal&rssi=3]
>  HTTP/1.1
> hubapi.myacurite.com
> User-Agent: Hub/224]
> Connection: closeGET 
> /weatherstation/updateweatherstation.php?ID=KCATHOUS110&PASSWORD=password&dateutc=now&action=updateraw&realtime=1^
> &rtfreq=36^
> &id=24C86E06B15C&mt=5N1x31&sensor=00002179^
> &windspeedmph=0&winddir=270^
> &rainin=0.00&dailyrainin=0.20&humidity=96&tempf=57.2&dewptf=56^
> &baromin=29.35&battery=normal&rssi=3^
>  HTTP/1.1
> rtupdate.wunderground.com^
> Connection: close
> GET 
> /weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1b
> &id=24C86E06B15C&mt=tower&sensor=00008384b
> &humidity=48&tempf=81.4b
> &baromin=29.35&battery=normal&rssi=3b
>  HTTP/1.1
> hubapi.myacurite.com
> User-Agent: Hub/224b
> Connection: close
> GET 
> /weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1c
> &id=24C86E06B15C&mt=tower&sensor=00012694c
> &humidity=65&tempf=72.8c
> &baromin=29.35&battery=normal&rssi=3c
>  HTTP/1.1
> hubapi.myacurite.com
> User-Agent: Hub/224c
> Connection: close
> GET 
> /weatherstation/updateweatherstation?dateutc=now&action=updateraw&realtime=1{
> &id=24C86E06B15C&mt=5N1x38&sensor=00002179{
> &windspeedmph=0&humidity=96{
> &tempf=56.9{
> &baromin=29.35&battery=normal&rssi=3{
>  HTTP/1.1
> hubapi.myacurite.com{
> User-Agent: Hub/224{
> Connection: close
>
> when I run the following through netcat like this:
> sudo tcpdump -A -n -p -l -i eth0 -s0 -w - tcp dst port 80 | stdbuf -oL 
> strings -n8 | nc 192.168.1.22 8080
> the process only stays alive for seconds and I get this:
> tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 
> 262144 bytes
> 19 packets captured
> 19 packets received by filter
> 0 packets dropped by kernel
>
> and syslog reports this:
> Oct 30 19:58:57 weather weewx[781]: interceptor: MainThread: empty queue
> Oct 30 19:59:07 weather weewx[781]: interceptor: MainThread: empty queue
> Oct 30 19:59:17 weather weewx[781]: interceptor: MainThread: empty queue
> Oct 30 19:59:27 weather weewx[781]: interceptor: MainThread: empty queue
> Oct 30 19:59:37 weather weewx[781]: interceptor: MainThread: empty queue
>
> After spending the better part of a day with this Im out of ideas.
>
> Please Help!
> 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