GPS-Daten in FHEM einlesen - gelöst

Begonnen von fstefan1960, 22 August 2017, 18:08:45

Vorheriges Thema - Nächstes Thema

morph

#60
Ok, also für mich selbst als Marker, äh ich mein natürlich für alle anderen mit einem Pi3 oder Zero (einem mit Bluetooth und WLAN on Board).

1. Image installieren, Updates etc durchführen.
2. In der /boot/cmdline.txt alles was mit console und serial und AMA0 oder was auch immer entfernen

console=ttyAMA0,115200
kgdboc=ttyAMA0,115200
serial0,115200
console=ttyS0,115200

3. in der /etc/inittab alles bis auf vt100 auskommentieren, falls dort etwas drin ist.
4.

sudo systemctl stop serial-getty@ttyS0.service
sudo systemctl disable serial-getty@ttyS0.service

5. Via sudo nano /boot/config.txt dort die Zeile ergänzen, ganz unten am besten

enable_uart=1

6. reboot und gpsd + Zubehör installieren

sudo apt-get install gpsd gpsd-clients
sudo apt-get install libnet-gpsd3-perl
FALSCH: [s]sudo cpan force install GPSD::Parse[/s]
sudo cpan -i install GPSD::Parse

7. Danach noch folgendes und es läuft:

sudo killall gpsd
sudo rm /var/run/gpsd.sock
sudo systemctl stop gpsd.socket
sudo systemctl disable gpsd.socket
sudo gpsd /dev/ttyS0 -G -n -F /var/run/gpsd.sock

8. cgps und fertig...

Es kann so einfach sein....

morph

#61
Zitat von: peterk_de am 30 Mai 2018, 09:58:32
Läuft denn gpsd überhaupt?

sudo service gpsd status

Ja, der lief. Ich denke, es liegt/lag an Punkt 7 Zeile 2

Nur scheitert es jetzt mittlerweile wie beim Kollegen vorher beim Laden des Moduls.


nach einem reload 49_GPSD.pm

Can't locate GPSD/Parse.pm in @INC (you may need to install the GPSD::Parse module) (@INC contains: . /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/arm-linux-gnueabihf/perl5/5.24 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/arm-linux-gnueabihf/perl-base ./FHEM) at ./FHEM/49_GPSD.pm line 24.
BEGIN failed--compilation aborted at ./FHEM/49_GPSD.pm line 24.


Denn auch die Installation des Teils CPAN ist am Ende fehlerhaft


pi@SchantallPi:/opt/fhem $ sudo cpan force install GPSD::Parse
Loading internal null logger. Install Log::Log4perl for logging messages
Reading '/root/.cpan/Metadata'
  Database was generated on Wed, 30 May 2018 05:54:08 GMT
Warning: Cannot install force, don't know what it is.
Try the command

    i /force/

to find objects with matching identifiers.
install is up to date (0.01).
Running install for module 'GPSD::Parse'
Checksum for /root/.cpan/sources/authors/id/S/ST/STEVEB/GPSD-Parse-1.02.tar.gz ok
'YAML' not installed, will not store persistent state
Configuring S/ST/STEVEB/GPSD-Parse-1.02.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for GPSD::Parse
Writing MYMETA.yml and MYMETA.json
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for S/ST/STEVEB/GPSD-Parse-1.02.tar.gz
cp lib/GPSD/Parse.pm blib/lib/GPSD/Parse.pm
Manifying 1 pod document
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/make -- OK
Running make test
PERL_DL_NONLAZY=1 PERL_USE_UNSAFE_INC=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-load.t ................ 1/? In socket mode...
t/00-load.t ................ ok
t/05-poll.t ................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/05-poll.t ................ 1/?

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 5.

#   Failed test '...and it contains TPV ok'
#   at t/05-poll.t line 40.
#                   '{"class":"POLL","time":"2018-05-30T08:44:26.397Z","active":0,"tpv":[],"gst":[],"sky":[]}'
#     doesn't match '(?^:TPV)'
# Looks like you failed 1 test of 11.
t/05-poll.t ................ Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/11 subtests
t/10-time.t ................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/10-time.t ................ 1/?
#   Failed test '...and is ok'
#   at t/10-time.t line 27.
#                   undef
#     doesn't match '(?^:^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$)'
# Looks like you failed 1 test of 2.
t/10-time.t ................ Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
t/15-device.t ..............

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/15-device.t .............. 1/?
#   Failed test '...and is ok'
#   at t/15-device.t line 27.
#                   undef
#     doesn't match '(?^:^/dev/ttyS0$)'
# Looks like you failed 1 test of 2.
t/15-device.t .............. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
t/20-tpv.t .................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/20-tpv.t ................. 1/?
#   Failed test 'tpv() key count matches number of stats'
#   at t/20-tpv.t line 48.
#          got: '2'
#     expected: '17'

#   Failed test 'time stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'alt stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'climb stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'speed stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'track stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'device stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'mode stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epx stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epy stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epc stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'ept stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epv stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'eps stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'class stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'tag stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'lat is in proper format'
#   at t/20-tpv.t line 55.
#                   undef
#     doesn't match '(?^:^-?\d+\.\d{4,9}$)'

#   Failed test 'lon is in proper format'
#   at t/20-tpv.t line 55.
#                   undef
#     doesn't match '(?^:^-?\d+\.\d{4,9}$)'
# Looks like you failed 18 tests of 39.
t/20-tpv.t ................. Dubious, test returned 18 (wstat 4608, 0x1200)
Failed 18/39 subtests
t/25-satellites.t ..........

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/25-satellites.t .......... ok
t/30-sky.t .................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/30-sky.t ................. 1/?
#   Failed test 'keys match SKY entry count'
#   at t/30-sky.t line 40.
#          got: '1'
#     expected: '11'

#   Failed test 'SKY stat xdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat ydop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat pdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat tdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat vdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat gdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat hdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat class exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat tag exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat device exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'
t/30-sky.t ................. 14/?
#   Failed test 'SKY satellite entries are hrefs'
#   at t/30-sky.t line 47.
#          got: ''
#     expected: 'HASH'

#   Failed test 'each SKY sat entry has stats'
#   at t/30-sky.t line 48.
#          got: ''
#     expected: '1'
# Looks like you failed 13 tests of 16.
t/30-sky.t ................. Dubious, test returned 13 (wstat 3328, 0xd00)
Failed 13/16 subtests
t/35-unit_conversion.t ..... ok
t/40-metres_feet.t ......... ok
t/45-direction.t ........... ok
t/50-signed.t .............. ok
t/55-unsigned.t ............ ok
t/60-poll_signed_toggle.t .. ok
t/65-tpv_methods.t .........

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-hA7A_a/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/65-tpv_methods.t ......... ok
t/manifest.t ............... skipped: Author tests not required for installation
t/pod-coverage.t ........... skipped: Author tests not required for installation
t/pod.t .................... skipped: Author tests not required for installation

Test Summary Report
-------------------
t/05-poll.t              (Wstat: 256 Tests: 11 Failed: 1)
  Failed test:  9
  Non-zero exit status: 1
t/10-time.t              (Wstat: 256 Tests: 2 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/15-device.t            (Wstat: 256 Tests: 2 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/20-tpv.t               (Wstat: 4608 Tests: 39 Failed: 18)
  Failed tests:  2-3, 6-21
  Non-zero exit status: 18
t/30-sky.t               (Wstat: 3328 Tests: 16 Failed: 13)
  Failed tests:  2, 4-13, 15-16
  Non-zero exit status: 13
Files=17, Tests=176, 19 wallclock secs ( 1.26 usr  0.25 sys + 15.12 cusr  0.96 csys = 17.59 CPU)
Result: FAIL
Failed 5/17 test programs. 34/176 subtests failed.
Makefile:832: die Regel für Ziel ,,test_dynamic" scheiterte
make: *** [test_dynamic] Fehler 255
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports STEVEB/GPSD-Parse-1.02.tar.gz


oder auch mit "-i"


pi@SchantallPi:~ $ sudo cpan -i install GPSD::Parse
Loading internal null logger. Install Log::Log4perl for logging messages
Reading '/root/.cpan/Metadata'
  Database was generated on Wed, 30 May 2018 05:54:08 GMT
install is up to date (0.01).
Running install for module 'GPSD::Parse'
Checksum for /root/.cpan/sources/authors/id/S/ST/STEVEB/GPSD-Parse-1.02.tar.gz ok
'YAML' not installed, will not store persistent state
Configuring S/ST/STEVEB/GPSD-Parse-1.02.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for GPSD::Parse
Writing MYMETA.yml and MYMETA.json
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for S/ST/STEVEB/GPSD-Parse-1.02.tar.gz
cp lib/GPSD/Parse.pm blib/lib/GPSD/Parse.pm
Manifying 1 pod document
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/make -- OK
Running make test
PERL_DL_NONLAZY=1 PERL_USE_UNSAFE_INC=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-load.t ................ 1/? In socket mode...
t/00-load.t ................ ok
t/05-poll.t ................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/05-poll.t ................ 1/?

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 5.

#   Failed test '...and it contains TPV ok'
#   at t/05-poll.t line 40.
#                   '{"class":"POLL","time":"2018-05-30T08:53:20.183Z","active":0,"tpv":[],"gst":[],"sky":[]}'
#     doesn't match '(?^:TPV)'
# Looks like you failed 1 test of 11.
t/05-poll.t ................ Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/11 subtests
t/10-time.t ................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/10-time.t ................ 1/?
#   Failed test '...and is ok'
#   at t/10-time.t line 27.
#                   undef
#     doesn't match '(?^:^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$)'
# Looks like you failed 1 test of 2.
t/10-time.t ................ Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
t/15-device.t ..............

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/15-device.t .............. 1/?
#   Failed test '...and is ok'
#   at t/15-device.t line 27.
#                   undef
#     doesn't match '(?^:^/dev/ttyS0$)'
# Looks like you failed 1 test of 2.
t/15-device.t .............. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
t/20-tpv.t .................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/20-tpv.t ................. 1/?
#   Failed test 'tpv() key count matches number of stats'
#   at t/20-tpv.t line 48.
#          got: '2'
#     expected: '17'

#   Failed test 'time stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'alt stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'climb stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'speed stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'track stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'device stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'mode stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epx stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epy stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epc stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'ept stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'epv stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'eps stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'class stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'tag stat exists in return'
#   at t/20-tpv.t line 51.
#          got: ''
#     expected: '1'

#   Failed test 'lat is in proper format'
#   at t/20-tpv.t line 55.
#                   undef
#     doesn't match '(?^:^-?\d+\.\d{4,9}$)'

#   Failed test 'lon is in proper format'
#   at t/20-tpv.t line 55.
#                   undef
#     doesn't match '(?^:^-?\d+\.\d{4,9}$)'
# Looks like you failed 18 tests of 39.
t/20-tpv.t ................. Dubious, test returned 18 (wstat 4608, 0x1200)
Failed 18/39 subtests
t/25-satellites.t ..........

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/25-satellites.t .......... ok
t/30-sky.t .................

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/30-sky.t ................. 1/?
#   Failed test 'keys match SKY entry count'
#   at t/30-sky.t line 40.
#          got: '1'
#     expected: '11'
t/30-sky.t ................. 3/?
#   Failed test 'SKY stat xdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat ydop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat pdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat tdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat vdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat gdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat hdop exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat class exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat tag exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY stat device exists'
#   at t/30-sky.t line 43.
#          got: ''
#     expected: '1'

#   Failed test 'SKY satellite entries are hrefs'
#   at t/30-sky.t line 47.
#          got: ''
#     expected: 'HASH'

#   Failed test 'each SKY sat entry has stats'
#   at t/30-sky.t line 48.
#          got: ''
#     expected: '1'
# Looks like you failed 13 tests of 16.
t/30-sky.t ................. Dubious, test returned 13 (wstat 3328, 0xd00)
Failed 13/16 subtests
t/35-unit_conversion.t ..... ok
t/40-metres_feet.t ......... ok
t/45-direction.t ........... ok
t/50-signed.t .............. ok
t/55-unsigned.t ............ ok
t/60-poll_signed_toggle.t .. ok
t/65-tpv_methods.t .........

incomplete or empty dataset returned from GPS...

Use of uninitialized value $lat in pattern match (m//) at /root/.cpan/build/GPSD-Parse-1.02-JzvE1z/blib/lib/GPSD/Parse.pm line 185, <GEN0> line 4.
t/65-tpv_methods.t ......... ok
t/manifest.t ............... skipped: Author tests not required for installation
t/pod-coverage.t ........... skipped: Author tests not required for installation
t/pod.t .................... skipped: Author tests not required for installation

Test Summary Report
-------------------
t/05-poll.t              (Wstat: 256 Tests: 11 Failed: 1)
  Failed test:  9
  Non-zero exit status: 1
t/10-time.t              (Wstat: 256 Tests: 2 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/15-device.t            (Wstat: 256 Tests: 2 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/20-tpv.t               (Wstat: 4608 Tests: 39 Failed: 18)
  Failed tests:  2-3, 6-21
  Non-zero exit status: 18
t/30-sky.t               (Wstat: 3328 Tests: 16 Failed: 13)
  Failed tests:  2, 4-13, 15-16
  Non-zero exit status: 13
Files=17, Tests=176, 19 wallclock secs ( 1.38 usr  0.10 sys + 14.99 cusr  1.03 csys = 17.50 CPU)
Result: FAIL
Failed 5/17 test programs. 34/176 subtests failed.
Makefile:832: die Regel für Ziel ,,test_dynamic" scheiterte
make: *** [test_dynamic] Fehler 255
  STEVEB/GPSD-Parse-1.02.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports STEVEB/GPSD-Parse-1.02.tar.gz

Wernieman

Hast Du mal probiert, anstelle von CPAN mit apt-get (siehe ein paar Seiten vorher) zu installieren?

Bitte CPAN nur, wenn es die Libary NICHT in der Distri gibt ....
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

morph

#63
via apt-get install GPSD::Parse ?

Ich finde nichts weiter was du da meinen könntest.

Das obige geht nicht.

Das GPS Modul ab , das CPAN ausführen und wieder anlöten war das richtige... :-(

morph

Und mit dem Track gings dann auch gleich weiter.


gpspipe -d  -l -r -o /home/pi/GPXLog/route.txt


erstellt eine Textdatei mit nmea Rohdaten


gpsbabel -i nmea -f /home/pi/GPXLog/route.txt -o kml -F /home/pi/GPXLog/track.kml



Erstellt dann direkt die passende kml Datei.

Das lasse ich mir dann ebenfalls, jenachdem was das für ne Größe ergibt, auf die Dropbox laden, und habe dann somit

- immer einen Aktuellen Google Link in der Dropbox
- immer eine Aktuellen GPX, mit dem ich dann was auch immer noch mit anstellen kann
- und die Route die das Wohnmobil zurückgelegt hat.

Wernieman

WIe schon geschrieben: Habe es einige Seiten vorher geschrieben (Sorry, suche es für Dich nicht raus).

"GPSD::Parse" ist natürlich Perl und nicht apt-get Syntax. Da muß man raussuchen, wie die Libary richtig heißt ...

Edit:
Ausnahmsweise:

Mal Probiert:
apt-cache search GPSD
gosmore - Betrachter, Routenplaner und Such-Client für Openstreetmap.org
gpsbabel - Umwandlung von GPS-Dateien plus Transfer zum/vom GPS-Gerät
gpsd - Daemon für das Global Positioning System (GPS)
gpsd-clients - Globales Positionierungssystem - Clients
gpsd-dbg - Global Positioning System - debugging symbols
libgps-dev - Global Positioning System - development files
libgps22 - Global Positioning System - library
libqgpsmm-dev - Global Positioning System - Qt wrapper for libgps (development)
libqgpsmm22 - Global Positioning System - Qt wrapper for libgps
navit - Navigationssystem für Automobile mit Routenplaner
navit-data - Car navigation system with routing engine - data files
navit-graphics-gtk-drawing-area - Car navigation system with routing engine - GTK+ graphic plugin
navit-gui-gtk - Car navigation system with routing engine - GTK+ GUI
navit-gui-internal - Car navigation system with routing engine - internal GUI
python-gps - Global Positioning System - Python libraries
fso-gpsd - gpsd subset compatibility daemon for the freesmarpthone.org frameworkd
gypsy-daemon - A GPS Multiplexing Daemon
libnet-gpsd3-perl - Perl interface to the gpsd server daemon protocol version 3 (JSON)


Nach der Liste würde ich denken: libnet-gpsd3-perl
apt-get install libnet-gpsd3-perl

Gibt auch Suchmaschinen dafür im Netz, habe nur gerade keinen Link dafür zur Hand .....

Leider schreiben HowTows meistens den CPAN weg, der aber gerade für Anfängern wegen der Update-Problematik NICHT gewählt werden sollte .....
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

morph

Ich danke dir für die mühen.

Aber das eigentliche Problem hab ich mit einem Ab und wieder An löten erledigt. Danke

hanami

Zitat von: morph am 18 Januar 2018, 22:46:24
:o

Soooo einfach....

und Das mit dem GPX hab ich auch hinbekommen:

define Filelog_GPX FileLog ./log/Filelog_GPX-%Y-%m.log GPS:(gpx).*

Bekomme ich nun die, und nur die Zeilen:


2018-01-18_22:39:24 GPS gpx: <trkpt lat="48.41" lon="10.29"><time>2018-01-18T21:39:24.000Z</time></trkpt>
2018-01-18_22:39:54 GPS gpx: <trkpt lat="48.41" lon="10.2"><time>2018-01-18T21:39:54.000Z</time></trkpt>
2018-01-18_22:40:24 GPS gpx: <trkpt lat="48.41" lon="10.2"><time>2018-01-18T21:40:24.000Z</time></trkpt>
2018-01-18_22:40:54 GPS gpx: <trkpt lat="48.41" lon="10.2"><time>2018-01-18T21:40:54.000Z</time></trkpt>
2018-01-18_22:41:24 GPS gpx: <trkpt lat="48.41" lon="10.29"><time>2018-01-18T21:41:24.000Z</time></trkpt>
2018-01-18_22:41:55 GPS gpx: <trkpt lat="48.41" lon="10.29"><time>2018-01-18T21:41:54.000Z</time></trkpt>
2018-01-18_22:42:25 GPS gpx: <trkpt lat="" lon=""><time>2018-01-18T21:42:25.000Z</time></trkpt>
2018-01-18_22:42:55 GPS gpx: <trkpt lat="48.413" lon="10.29"><time>2018-01-18T21:42:55.000Z</time></trkpt>
2018-01-18_22:43:25 GPS gpx: <trkpt lat="48.411" lon="10.29"><time>2018-01-18T21:43:25.000Z</time></trkpt>
2018-01-18_22:44:01 GPS gpx: <trkpt lat="48.411" lon="10.29"><time>2018-01-18T21:44:01.000Z</time></trkpt>
2018-01-18_22:44:33 GPS gpx: <trkpt lat="48.411" lon="10.29"><time>2018-01-18T21:44:33.000Z</time></trkpt>


Okidoki.. Also soweit wie du :-)

Hallo Ihr nochmal,

ich habe es indes auch geschafft das Modul zum laufen zu bekommen und erhalte valide Daten in den Readings.
Was jedoch leider nicht so recht funktionieren will, ist das FileLog define Filelog_GPX FileLog ./log/Filelog_GPX-%Y-%U.log KastenGPS:(gpx).*
DasLogFile wird leider nicht gefüllt.

Wenn ich jedoch beispielsweise das DOIF doif_gpx doif (["KastenGPS:lat"])((setreading KastenGPS gpx <trkpt lat="[KastenGPS:lat]" lon="[KastenGPS:lon]"><time>[KastenGPS:time_utc]</time></trkpt>))DOELSE
manuell über set doif_gpx cmd_1 auslöse wird einmalig ein Reading ins Logfile geschrieben, das war es dann aber auch.
attr. do always für das DOIF ist hinterlegt.


Vielleicht könnt Ihr mir nochmal mit eurem Wissen zur Seite stehen, dafür wär ich echt Dankbar :-)

Vielen Dank vorab.
beste Grüße Patrick

UweUwe

Hallo,
ich hatte auch schon über einen Pi/FHEM im Wohnwagen nachgedacht. Wäre interessiert zu verstehen, welche Anwendungen ihr dort habt. Merci

UweUwe

Hi, wollte nochmals nachfragen. Denke stark an einer GPS Anbindung für meinen Rasperry 3 nach.
Ich bin sicher, dass ich bei der Konfiguration etwas Unterstützung benötige. Ist da in den nächsten Tagen/Wochen jemand im Forum bereit und im Forum verfürgbar?  Welche GPS Modul soll man denn kaufen?


StephanFHEM

ich hatte noch folgendes Problem: nach dem Reboot war die GPS-Verbindung bei mir immer wieder deaktiviert und ich musste sie manuell starten.
Hier die Lösung:

sudo nano /etc/default/gpsd

eingeben und folgende Daten in der Datei ändern/eintragen:

START_DAEMON="true"
GPSD_OPTIONS="-n"
DEVICES="/dev/ttyS0"
USBAUTO="false"
GPSD_SOCKET="/var/run/gpsd.sock"


danach ist GPS auch mit einem Reboot verfügbar

karlheinzmabroe

#71
Hallo zusammen, ich habe dieses Problem auch noch. Bin auf einem frisch installierten rpi 3b und cpan baut gpsd parse nicht durch, ich bekomme immer Fehler bei den Tests. Habe schon diverse XML und json libs installiert aber es hilft nicht.
jemand noch eine Idee? Bin wie von morph beschrieben vorgegangen, cgps zeigt interessanterweise sogar gültige Daten, es scheint also eher ein Problem in der Bibliothek zu sein.

finde im netzt leider überhaupt nichts sinnvolles zu diesem Problem.

EDIT: genau hinschauen hilft ... wie ärgerlich, musste nur den letzten Teil der Anleitung vor dem cpan machen (gpsd.sock entfernen, services stoppen, ...) dann klappt die Installation und GPS steht in FHEM zur Verfügung.

UweUwe

Hallo,

ich bin zwischenzeitlich auf Bullseye umgestiegen und bekomme meine GPS-Maus in FHEM nicht zum Laufen.

Ich hab auf Linux Ebene soweit alles klar:
ZitatTime:        2022-11-29T12:00:20.000Z (0) ││GNSS   PRN  Elev   Azim   SNR Use│
│ Latitude:         50.60366320 N           ││GP  5    5  59.0  241.5  39.3  Y │
│ Longitude:         6.29292499 E           ││GP  7    7  27.0   61.5  24.7  Y │
│ Alt (HAE, MSL):    598.597,    552.218 m  ││GP 13   13  61.5  291.0  31.5  Y │
│ Speed:             0.00 km/h              ││GP 14   14  46.0  132.0  37.4  Y │
│ Track (true, var):     0.0,   1.9     deg ││GP 20   20  36.5  193.5  36.2  Y │
│ Climb:             0.00 m/min             ││GP 30   30  63.0   67.5  40.1  Y │
│ Status:         3D DGPS FIX (58 secs)     ││SB123  123  27.0  148.5  41.3  Y │
│ Long Err  (XDOP, EPX):  0.61, +/-  2.3 m  ││GP  3    3  73.0  157.5   0.0  N │
│ Lat Err   (YDOP, EPY):  0.96, +/-  3.6 m  ││GP 10   10  65.0   76.5   0.0  N │
│ Alt Err   (VDOP, EPV):  1.53, +/-  8.8 m  ││GP 17   17  44.5  151.5   0.0  N │
│ 2D Err    (HDOP, CEP):  1.40, +/-  6.7 m  ││GP 22   22  48.5  190.5   0.0  N │
│ 3D Err    (PDOP, SEP):  1.91, +/-  9.1 m  ││GP 27   27  39.5  304.5   0.0  N │
│ Time Err  (TDOP):       2.31              ││                                 │
│ Geo Err   (GDOP):       2.22              ││                                 │
│ ECEF X, VX:    4032136.000 m    0.000 m/s ││                                 │
│ ECEF Y, VY:     444648.000 m    0.000 m/s ││                                 │
│ ECEF Z, VZ:    4906142.000 m    0.000 m/s ││                                 │
│ Speed Err (EPS):       +/- 26.0 km/h      ││                                 │
│ Track Err (EPD):        n/a               ││                                 │
│ Time offset:            0.386457326 s     ││                                 │
│ Grid Square:            JO30do54          ││                                 │

Gehe ich aber jetzt in Fhem und versuche das Modul zu installieren, so bekomme ich:

Mein Befehl lautet:

Zitatdefine meinGPS GPSD
das Ergebnis ist:


ZitatCannot load module GPSD

Ich hab mir das Modul aus diesem Threat heruntergeladen und in /opt/fhem/FHEM abgelegt.

Ich hatte mir noch notiert, dass ich eine Zeile ändern muss:

Zitatdie Zeile angepasst in 49_GPSD.pm zu 127.0.0

Dies hab ich nicht gemacht, ich finde die Zeile nicht mehr.

Kann mir bitte jemand einen TIP geben

rudolfkoenig

ZitatCannot load module GPSD
Die Ursache muesste im FHEM Log stehen.

UweUwe

Hallo,

hier ist die Fehlermeldung in Logfile.

2022.11.29 13:23:19 1: reload: Error:Modul 49_GPSD deactivated:
Can't locate GPSD/Parse.pm in @INC (you may need to install the GPSD::Parse module) (@INC contains: ./lib ./FHEM . /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.32.1 /usr/local/share/perl/5.32.1 /usr/lib/arm-linux-gnueabihf/perl5/5.32 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl-base /usr/lib/arm-linux-gnueabihf/perl/5.32 /usr/share/perl/5.32 /usr/local/lib/site_perl ./FHEM/lib) at ./FHEM/49_GPSD.pm line 24.
BEGIN failed--compilation aborted at ./FHEM/49_GPSD.pm line 24.

2022.11.29 13:23:19 0: Can't locate GPSD/Parse.pm in @INC (you may need to install the GPSD::Parse module) (@INC contains: ./lib ./FHEM . /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.32.1 /usr/local/share/perl/5.32.1 /usr/lib/arm-linux-gnueabihf/perl5/5.32 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl-base /usr/lib/arm-linux-gnueabihf/perl/5.32 /usr/share/perl/5.32 /usr/local/lib/site_perl ./FHEM/lib) at ./FHEM/49_GPSD.pm line 24.
BEGIN failed--compilation aborted at ./FHEM/49_GPSD.pm line 24.

2022.11.29 13:24:25 1: RMDIR: ./restoreDir/save/2022-11-21
2022.11.29 13:24:33 1: reload: Error:Modul 49_GPSD deactivated:
Can't locate GPSD/Parse.pm in @INC (you may need to install the GPSD::Parse module) (@INC contains: ./lib ./FHEM . /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.32.1 /usr/local/share/perl/5.32.1 /usr/lib/arm-linux-gnueabihf/perl5/5.32 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl-base /usr/lib/arm-linux-gnueabihf/perl/5.32 /usr/share/perl/5.32 /usr/local/lib/site_perl ./FHEM/lib) at ./FHEM/49_GPSD.pm line 24.
BEGIN failed--compilation aborted at ./FHEM/49_GPSD.pm line 24.

2022.11.29 13:24:33 0: Can't locate GPSD/Parse.pm in @INC (you may need to install the GPSD::Parse module) (@INC contains: ./lib ./FHEM . /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.32.1 /usr/local/share/perl/5.32.1 /usr/lib/arm-linux-gnueabihf/perl5/5.32 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl-base /usr/lib/arm-linux-gnueabihf/perl/5.32 /usr/share/perl/5.32 /usr/local/lib/site_perl ./FHEM/lib) at ./FHEM/49_GPSD.pm line 24.
BEGIN failed--compilation aborted at ./FHEM/49_GPSD.pm line 24.


In Zeile 24 steht:
use GPSD::Parse;

Parse hab ich installiert:

pi@Vagabundi02:/opt/fhem/FHEM $ sudo cpan install GPSD::Parse
Reading '/root/.local/share/.cpan/Metadata'
  Database was generated on Tue, 29 Nov 2022 11:41:01 GMT
Running install for module 'GPSD::Parse'
CPAN: Digest::SHA loaded ok (v6.02)
CPAN: Compress::Zlib loaded ok (v2.093)
Checksum for /root/.local/share/.cpan/sources/authors/id/S/ST/STEVEB/GPSD-Parse-1.03.tar.gz ok
CPAN: YAML loaded ok (v1.30)
CPAN: CPAN::Meta::Requirements loaded ok (v2.140)
CPAN: Parse::CPAN::Meta loaded ok (v2.150010)
CPAN: CPAN::Meta loaded ok (v2.150010)
CPAN: Module::CoreList loaded ok (v5.20210123)
Configuring S/ST/STEVEB/GPSD-Parse-1.03.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for GPSD::Parse
Writing MYMETA.yml and MYMETA.json
  STEVEB/GPSD-Parse-1.03.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK
Running make for S/ST/STEVEB/GPSD-Parse-1.03.tar.gz
cp lib/GPSD/Parse.pm blib/lib/GPSD/Parse.pm
Manifying 1 pod document
  STEVEB/GPSD-Parse-1.03.tar.gz
  /usr/bin/make -- OK
CPAN: CPAN::DistnameInfo loaded ok (v0.12)
Running make test for STEVEB/GPSD-Parse-1.03.tar.gz
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-load.t ................ 1/? In socket mode...
t/00-load.t ................ ok
t/05-poll.t ................ ok
t/10-time.t ................ ok
t/15-device.t .............. ok
t/20-tpv.t ................. 1/?
#   Failed test 'tpv() key count matches number of stats'
#   at t/20-tpv.t line 51.
#          got: '33'
#     expected: '15'
# Looks like you failed 1 test of 37.
t/20-tpv.t ................. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/37 subtests
t/25-satellites.t .......... 1/?
#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '40.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '31.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '39.2'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '76.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '34.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '58.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '262.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '41.3'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '148.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '29.2'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '205.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '42.4'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '83.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '118.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '139.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '45.5'
#     doesn't match '(?^:^\d+$)'

#   Failed test '...and is an integer'
#   at t/25-satellites.t line 53.
#                   '280.5'
#     doesn't match '(?^:^\d+$)'
# Looks like you failed 17 tests of 171.
t/25-satellites.t .......... Dubious, test returned 17 (wstat 4352, 0x1100)
Failed 17/171 subtests
t/30-sky.t ................. 1/?
#   Failed test 'keys match SKY entry count'
#   at t/30-sky.t line 43.
#          got: '12'
#     expected: '10'

#   Failed test 'SKY stat tdop exists'
#   at t/30-sky.t line 51.
#          got: ''
#     expected: '1'
# Looks like you failed 2 tests of 15.
t/30-sky.t ................. Dubious, test returned 2 (wstat 512, 0x200)
Failed 2/15 subtests
t/35-unit_conversion.t ..... ok
t/40-metres_feet.t ......... ok
t/45-direction.t ........... ok
t/50-signed.t .............. ok
t/55-unsigned.t ............ ok
t/60-poll_signed_toggle.t .. ok
t/65-tpv_methods.t ......... ok
t/manifest.t ............... skipped: Author tests not required for installation
t/pod-coverage.t ........... skipped: Author tests not required for installation
t/pod-linkcheck.t .......... skipped: Author test: RELEASE_TESTING not set
t/pod.t .................... skipped: Author tests not required for installation

Test Summary Report
-------------------
t/20-tpv.t               (Wstat: 256 Tests: 37 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/25-satellites.t        (Wstat: 4352 Tests: 171 Failed: 17)
  Failed tests:  64, 66, 73, 77, 102, 104, 113, 118, 122
                127, 131, 136, 138, 140, 149, 165, 167
  Non-zero exit status: 17
t/30-sky.t               (Wstat: 512 Tests: 15 Failed: 2)
  Failed tests:  2, 7
  Non-zero exit status: 2
Files=18, Tests=341, 16 wallclock secs ( 0.64 usr  0.15 sys + 12.66 cusr  1.30 csys = 14.75 CPU)
Result: FAIL
Failed 3/18 test programs. 20/341 subtests failed.
make: *** [Makefile:839: test_dynamic] Fehler 255
  STEVEB/GPSD-Parse-1.03.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports STEVEB/GPSD-Parse-1.03.tar.gz



Wo liegt mein Fehler?