Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

net::gpsd3::return::poll(3pm) [debian man page]

Net::GPSD3::Return::POLL(3pm)				User Contributed Perl Documentation			     Net::GPSD3::Return::POLL(3pm)

NAME
Net::GPSD3::Return::POLL - Net::GPSD3 Return POLL Object SYNOPSIS
use Net::GPSD3; use Data::Dumper qw{Dumper}; my $gpsd = Net::GPSD3->new; my $poll = $gpsd->poll; print Dumper($poll); DESCRIPTION
Provides a Perl object interface to the POLL object returned by the GPSD daemon. METHODS
class Returns the object class string Returns the JSON string parent Return the parent Net::GPSD3 object time timestamp datetime active fix, tpv Returns the first fix from the Fixes array or undef if none. my $fix=$poll->fix #isa Net::GPSD3::Return::TPV or undef Note: I will try to keep this method consistant Fixes Object wrapper around JSON data my $fix=$poll->Fixes #isa [] of Net::GPSD3::Return::TPV objects my @fix=$poll->Fixes #isa () of Net::GPSD3::Return::TPV objects Note: I'm not sure why this is an array from the protocol but do not count on this staying the same sky Returns the first object from the Skyviews array or undef if none. my $sky=$poll->sky #isa Net::GPSD3::Return::SKY or undef Note: I will try to keep this method consistant Skyviews Object wrapper around JSON data my $sky=$poll->Skyviews #isa [] of Net::GPSD3::Return::SKY objects my @sky=$poll->Skyviews #isa () of Net::GPSD3::Return::SKY objects Note: I'm not sure why this is an array from the protocol but do not count on this staying the same Gst Object wrapper around JSON data my $gst=$poll->Gst #isa [] of Net::GPSD3::Return::GST objects my @gst=$poll->Gst #isa () of Net::GPSD3::Return::GST objects Note: I'm not sure why this is an array from the protocol but do not count on this staying the same BUGS
Log on RT and send to gpsd-dev email list SUPPORT
DavisNetworks.com supports all Perl applications including this package. Try gpsd-dev email list AUTHOR
Michael R. Davis CPAN ID: MRDVT STOP, LLC domain=>michaelrdavis,tld=>com,account=>perl http://www.stopllc.com/ COPYRIGHT
This program is free software licensed under the... The BSD License The full text of the license can be found in the LICENSE file included with this module. SEE ALSO
Net::GPSD3, Net::GPSD3::Return::Unknown::Timestamp perl v5.14.2 2011-12-27 Net::GPSD3::Return::POLL(3pm)

Check Out this Related Man Page

Net::GPSD3(3pm) 					User Contributed Perl Documentation					   Net::GPSD3(3pm)

NAME
Net::GPSD3 - Interface to the gpsd server daemon protocol versions 3 (JSON). SYNOPSIS
Watch Interface use Net::GPSD3; my $gpsd=Net::GPSD3->new; $gpsd->watch; One Liner perl -MNet::GPSD3 -e 'Net::GPSD3->new->watch' Poll Interface use Net::GPSD3; use Data::Dumper qw{Dumper}; my $gpsd=Net::GPSD3->new; my $poll=$gpsd->poll; print Dumper($poll); One Liner perl -MNet::GPSD3 -e 'printf "Protocol: %s ", Net::GPSD3->new->poll->parent->cache->VERSION->protocol;' Protocol: 3.4 POE Interface See Net::GPSD3::POE DESCRIPTION
Net::GPSD3 provides an object client interface to the gpsd server daemon utilizing the version 3 protocol. gpsd is an open source GPS daemon from http://gpsd.berlios.de/. Support for Version 3 of the protocol (JSON) was added to the daemon in version 2.90. If your daemon is before 2.90 (protocol 2.X), please use the Net::GPSD package. CONSTRUCTOR
new Returns a new Net::GPSD3 object. my $gpsd=Net::GPSD3->new; my $gpsd=Net::GPSD3->new(host=>"127.0.0.1", port=>2947); #defaults METHODS
host Sets or returns the current gpsd host. my $host=$obj->host; port Sets or returns the current gpsd TCP port. my $port=$obj->port; poll Sends a Poll request to the gpsd server and returns a Net::GPSD3::Return::POLL object. The method also populates the cache object with the Net::GPSD3::Return::VERISON and Net::GPSD3::Return::DEVICES objects. my $poll=$gpsd->poll; #isa Net::GPSD3::Return::POLL object Note: In order to use the poll method consistently you should run the GPSD daemon as a service. You may also need to run the daemon with the "-n" option. watch Calls all handlers that are registered in the handler method. $gpsd->watch; #will not return unless something goes wrong. addHandler Adds handlers to the handler list. $gpsd->addHandler(&myHandler); $gpsd->addHandler(&myHandler1, &myHandler2); A handler is a sub reference where the first argument is a Net::GPSD3::Return::* object. handlers List of handlers that are called in order to process objects from the gpsd wathcer stream. my @handler=$gpsd->handlers; #() my $handler=$gpsd->handlers; #[] cache Returns the Net::GPSD3::Cache caching object. METHODS Internal default_handler socket Returns the cached IO::Socket::INET6 object my $socket=$gpsd->socket; #try to reconnect on failure json Returns the cached JSON::XS object decode Returns a perl data structure given a JSON formated string. my %data=$gpsd->decode($string); #() my $data=$gpsd->decode($string); #{} encode Returns a JSON string from a perl data structure constructor Constructs a class object by lazy loading the classes. my $obj=$gpsd->constructor(%$data); my $obj=$gpsd->constructor(class=>"DEVICE", string=>'{...}', ...); Returns and object in the Net::GPSD3::Return::* namespace. BUGS
Log on RT and Send to gpsd-dev email list There are no two GPS devices that are alike. Each GPS device has a different GPSD signature as well. If your GPS device does not work out of the box with this package, please send me a log of your devices JSON sentences. echo '?POLL;' | nc 127.0.0.1 2947 echo '?WATCH={"enable":true,"json":true};' | socat -t10 stdin stdout | nc 127.0.0.1 2947 SUPPORT
DavisNetworks.com supports all Perl applications including this package. Try gpsd-dev email list AUTHOR
Michael R. Davis CPAN ID: MRDVT STOP, LLC domain=>michaelrdavis,tld=>com,account=>perl http://www.stopllc.com/ COPYRIGHT
This program is free software licensed under the... The BSD License The full text of the license can be found in the LICENSE file included with this module. SEE ALSO
Net::GPSD, Net::GPSD3::POE, GPS::Point, JSON::XS, IO::Socket::INET6, DateTime perl v5.14.2 2011-12-27 Net::GPSD3(3pm)
Man Page