[alexa-fhem | Generell] Alles zu Installation und damit verbundenen Problemen

Begonnen von prodigy7, 09 November 2016, 19:42:01

Vorheriges Thema - Nächstes Thema

chapelhill

Hi all.
Sorry for the English.

I have been running fhem on my pi for a couple of years, but for Alexa I had too many problems installing nodejs presumably because my version was based from Wheezy and not Jesse, so I have complete fresh install of jessie and fhem, restored fhem from backup, updated fhem to 5.8 and all running normally.

Following wiki instructions I have now manged to get nodejs installed, but after downloading latest alexa-fhem using the pi I have done the following from /opt/fhem directory.


sudo tar -xvzf alexa-fhem-0.3.0.tgz
sudo mv package alexa-fhem

Then as per wiki without sudo
npm install



npm ERR! tar.unpack untar error /home/pi/.npm/chalk/1.1.3/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/request/2.79.0/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/commander/2.8.1/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/nat-upnp/1.1.0/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/nat-pmp/1.0.0/package.tgz
npm ERR! Linux 4.4.38-v7+
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! node v4.8.0
npm ERR! npm  v2.15.11
npm ERR! path /opt/fhem/alexa-fhem/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall mkdir

npm ERR! Error: EACCES: permission denied, mkdir '/opt/fhem/alexa-fhem/node_modules'
npm ERR!     at Error (native)
npm ERR!  { [Error: EACCES: permission denied, mkdir '/opt/fhem/alexa-fhem/node_modules']
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'mkdir',
npm ERR!   path: '/opt/fhem/alexa-fhem/node_modules',
npm ERR!   fstream_type: 'Directory',
npm ERR!   fstream_path: '/opt/fhem/alexa-fhem/node_modules/chalk',
npm ERR!   fstream_class: 'DirWriter',
npm ERR!   fstream_stack:
npm ERR!    [ '/usr/lib/node_modules/npm/node_modules/fstream/lib/writer.js:171:25',
npm ERR!      '/usr/lib/node_modules/npm/node_modules/mkdirp/index.js:47:53',
npm ERR!      'FSReqWrap.oncomplete (fs.js:82:15)' ] }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! Linux 4.4.38-v7+
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! node v4.8.0
npm ERR! npm  v2.15.11
npm ERR! path npm-debug.log.2344105117
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall open

npm ERR! Error: EACCES: permission denied, open 'npm-debug.log.2344105117'
npm ERR!     at Error (native)
npm ERR!  { [Error: EACCES: permission denied, open 'npm-debug.log.2344105117']
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'open',
npm ERR!   path: 'npm-debug.log.2344105117' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! Please include the following file with any support request:
npm ERR!     /opt/fhem/alexa-fhem/npm-debug.log


Since the instructions specifically say without sudo and this is completely fresh install I suspect other may also encounter this problem and I presume it is a permissions issue.

Output from checking permissions:
ls -la
total 44
drwxr-xr-x  4  501 root    4096 Feb 20 21:36 .
drwxr-xr-x 12 fhem dialout 4096 Feb 26 14:23 ..
drwxr-xr-x  2  501 root    4096 Feb 26 14:23 bin
-rw-r--r--  1  501 root     573 Feb 19 18:24 config-sample.json
-rwxr-xr-x  1  501 root     150 Nov  5 21:09 createKey.sh
-rw-r--r--  1  501 root    1183 Dec 23 10:14 lambda.js
drwxr-xr-x  2  501 root    4096 Feb 26 14:23 lib
-rw-r--r--  1  501 root      33 Nov  5 21:25 .npmignore
-rw-r--r--  1  501 root     373 Feb 19 16:36 package.json
-rw-r--r--  1  501 root    2830 Nov  8 22:59 README.md
-rw-r--r--  1  501 root    1915 Feb 18 11:30 TODO


Many thanks for any help.
Regards
Chapelhill

MadMax-FHEM

Zitat von: tagedieb am 26 Februar 2017, 15:31:42
Hallo zusammen

nach dem ich mit der tollen Hilfe aus diesem Thread mein Alexa-fhem zum "laufen" und mein Echo dot zum "schalten bekommen habe, bin ich aufgrund der vielen geräte, vorsichtshalber mit dem Alexa server auf den anderen Cubi umgezogen - die Config wurde dementsprechend geändert - so auch die Portfreigabe.
Solange ich die Console des cubie offen habe, auf welchen jetzt der Server läuft, funktioniert alles prächtig - der server liest die geräte ein, amazon dot auch und schaltet diese
Doch sobald die putty Verbindung getrennt ist, sagt mir alexa, das diese befehle nicht zur Verfügung stehen und wenn ich mich wieder an der Console anmelde, muss ich den Alexa server neu starten, da dieser nicht mehr läuft
was habe ich hier jetzt nicht mit installiert? - auf diesem Cubie ist eine Mini fhem installation, welche jedoch ordnungsgemäss weiterfunktioniert und auch beim erneuten einloggen auf der console noch läuft

ich weiss, das dies nichts mit dem prächtigen Modul von Andre zu tun hat, doch kann mir bitte trotzdem jemand weiterhelfen?

Gruss tagedieb

Du hast vergessen den automatischen Start per Script (/etc/init.d/alexa) bzw. halt den passenden für dein System zu "installieren".

Wie bei Linux üblich ist das gestartete Programm/Script solange aktiv wie die Console/Terminal offen/aktiv ist.

Alternative 'nohup', dann allerdings musst du es nach dem Neustart des Rechners wieder von Hand starten...

https://de.wikipedia.org/wiki/Nohup

Gruß, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

MadMax-FHEM

Zitat von: chapelhill am 26 Februar 2017, 15:43:14
Hi all.
Sorry for the English.

I have been running fhem on my pi for a couple of years, but for Alexa I had too many problems installing nodejs presumably because my version was based from Wheezy and not Jesse, so I have complete fresh install of jessie and fhem, restored fhem from backup, updated fhem to 5.8 and all running normally.

Following wiki instructions I have now manged to get nodejs installed, but after downloading latest alexa-fhem using the pi I have done the following from /opt/fhem directory.


sudo tar -xvzf alexa-fhem-0.3.0.tgz
sudo mv package alexa-fhem

Then as per wiki without sudo
npm install



npm ERR! tar.unpack untar error /home/pi/.npm/chalk/1.1.3/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/request/2.79.0/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/commander/2.8.1/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/nat-upnp/1.1.0/package.tgz
npm ERR! tar.unpack untar error /home/pi/.npm/nat-pmp/1.0.0/package.tgz
npm ERR! Linux 4.4.38-v7+
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! node v4.8.0
npm ERR! npm  v2.15.11
npm ERR! path /opt/fhem/alexa-fhem/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall mkdir

npm ERR! Error: EACCES: permission denied, mkdir '/opt/fhem/alexa-fhem/node_modules'
npm ERR!     at Error (native)
npm ERR!  { [Error: EACCES: permission denied, mkdir '/opt/fhem/alexa-fhem/node_modules']
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'mkdir',
npm ERR!   path: '/opt/fhem/alexa-fhem/node_modules',
npm ERR!   fstream_type: 'Directory',
npm ERR!   fstream_path: '/opt/fhem/alexa-fhem/node_modules/chalk',
npm ERR!   fstream_class: 'DirWriter',
npm ERR!   fstream_stack:
npm ERR!    [ '/usr/lib/node_modules/npm/node_modules/fstream/lib/writer.js:171:25',
npm ERR!      '/usr/lib/node_modules/npm/node_modules/mkdirp/index.js:47:53',
npm ERR!      'FSReqWrap.oncomplete (fs.js:82:15)' ] }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! Linux 4.4.38-v7+
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! node v4.8.0
npm ERR! npm  v2.15.11
npm ERR! path npm-debug.log.2344105117
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall open

npm ERR! Error: EACCES: permission denied, open 'npm-debug.log.2344105117'
npm ERR!     at Error (native)
npm ERR!  { [Error: EACCES: permission denied, open 'npm-debug.log.2344105117']
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'open',
npm ERR!   path: 'npm-debug.log.2344105117' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! Please include the following file with any support request:
npm ERR!     /opt/fhem/alexa-fhem/npm-debug.log


Since the instructions specifically say without sudo and this is completely fresh install I suspect other may also encounter this problem and I presume it is a permissions issue.

Output from checking permissions:
ls -la
total 44
drwxr-xr-x  4  501 root    4096 Feb 20 21:36 .
drwxr-xr-x 12 fhem dialout 4096 Feb 26 14:23 ..
drwxr-xr-x  2  501 root    4096 Feb 26 14:23 bin
-rw-r--r--  1  501 root     573 Feb 19 18:24 config-sample.json
-rwxr-xr-x  1  501 root     150 Nov  5 21:09 createKey.sh
-rw-r--r--  1  501 root    1183 Dec 23 10:14 lambda.js
drwxr-xr-x  2  501 root    4096 Feb 26 14:23 lib
-rw-r--r--  1  501 root      33 Nov  5 21:25 .npmignore
-rw-r--r--  1  501 root     373 Feb 19 16:36 package.json
-rw-r--r--  1  501 root    2830 Nov  8 22:59 README.md
-rw-r--r--  1  501 root    1915 Feb 18 11:30 TODO


Many thanks for any help.
Regards
Chapelhill

So I guess you installed under /home/pi/

and you "untared" with sudo (not necessary when user pi is doing something in his home folder) so the rights of the untared stuff is then (as shown in you output) "root" so now the npm install without "root"/sudo has no privillage to do anything...

So remove the folder (using sudo otherwise you might not be able) and again untar without "sudo" OR change ownership of the folder and subfolders:

sudo chown -R pi:pi /home/pi/INSTALL-FOLDER

Regards, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

chapelhill

Hi Thanks for the help that has resolved it.

My mistake was to unpack the alexa-fhem download directly into /opt/fhem which required sudo permissions so had root permissions and we want it there with permissions for the pi user or whichever user we are going to run the service under.
I have now moved the alexa-fhem download back to pi home folder and uncompressed as pi user with no sudo so that it gets the pi user permissions.


pi@raspberrypi:/opt/fhem $ cd ~
pi@raspberrypi:~ $ tar -xvzf alexa-fhem-0.3.0.tgz
pi@raspberrypi:~ $ sudo mv package /opt/fhem/alexa-fhem/
pi@raspberrypi:~ $ cd /opt/fhem/alexa-fhem
pi@raspberrypi:/opt/fhem/alexa-fhem $ npm install

Steffen

Hallo!

Ich habe seit heute ein Problem und weiss nicht weiter, denn ich habe heute ein Fhem Update durchgeführt und seit dem klappt Alexa nicht mehr. Es lief jetzt seit Wochen mit dem CustomSkill ohne Probleme durch, doch wie gesagt nach Update sagt es immer das es keine geräte mit Name xxx usw nicht finden konnte. Mein Homeskill kann ich starten über Alexa.

Ich musste vor ein paar Tage mein Amazone Passwort ändern kann das was damit zu tun haben und jetzt nach neustart kann er sich vielleicht nicht mehr verbinden?!

Ich weiss auch gar nicht wo ich jetzt ansetzten könnte...

Hat jemand eine Idee wo ich auf Fehler suche gehen könnte???

Mfg Steffen

MadMax-FHEM

Zitat von: Steffen am 26 Februar 2017, 18:15:24
Hallo!

Ich habe seit heute ein Problem und weiss nicht weiter, denn ich habe heute ein Fhem Update durchgeführt und seit dem klappt Alexa nicht mehr. Es lief jetzt seit Wochen mit dem CustomSkill ohne Probleme durch, doch wie gesagt nach Update sagt es immer das es keine geräte mit Name xxx usw nicht finden konnte. Mein Homeskill kann ich starten über Alexa.

Ich musste vor ein paar Tage mein Amazone Passwort ändern kann das was damit zu tun haben und jetzt nach neustart kann er sich vielleicht nicht mehr verbinden?!

Ich weiss auch gar nicht wo ich jetzt ansetzten könnte...

Hat jemand eine Idee wo ich auf Fehler suche gehen könnte???

Mfg Steffen

Den Hinweis auf FeatureLevel 5.8 etc. hast du gelesen?

Welche Version von alexa-fhem hast du?

Allerdings wäre komisch, dass der Smart Home Skill dann einfach so weiter laufen sollte...

Gruß, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

Steffen

Zitat von: MadMax-FHEM am 26 Februar 2017, 18:19:47
Den Hinweis auf FeatureLevel 5.8 etc. hast du gelesen?

Welche Version von alexa-fhem hast du?

Allerdings wäre komisch, dass der Smart Home Skill dann einfach so weiter laufen sollte...

Gruß, Joachim

Hallo!

Ich hatte durch Zeitmangel mich in letzter Zeit nicht mehr so damit beschäftigt, da ja auch bis heute alles genau so lief.
Den Heinweis habe ich noch nicht gelesen, wo finde ich diesen?
Die Version war doch eigentlich unter myAlexa in Fhem zu sehen, da finde ich aber nichts mehr?!

Ich weis man sollte immer alles in eigener Arbeit erledigen, würde ich auch aber leider ist durch Arbeit meine Zeit sehr knapp um das alles in ruhe auf zu Arbeiten und wäre für Hilfe sehr dankbar...

Mfg Steffen

MadMax-FHEM

Zitat von: Steffen am 26 Februar 2017, 18:48:36
Hallo!

Ich hatte durch Zeitmangel mich in letzter Zeit nicht mehr so damit beschäftigt, da ja auch bis heute alles genau so lief.
Den Heinweis habe ich noch nicht gelesen, wo finde ich diesen?
Die Version war doch eigentlich unter myAlexa in Fhem zu sehen, da finde ich aber nichts mehr?!

Ich weis man sollte immer alles in eigener Arbeit erledigen, würde ich auch aber leider ist durch Arbeit meine Zeit sehr knapp um das alles in ruhe auf zu Arbeiten und wäre für Hilfe sehr dankbar...

Mfg Steffen

Rechts oben ;)

Oder hier:

https://forum.fhem.de/index.php/topic,67419.0.html

Gruß, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

ThommyTom

Hallo zusammen,

ich habe mich auch mal daran versucht, alexa und hem zusammen zubringen.
Habe es nach Wiki und nach Video gemacht.

Alexa startet auch auf meinem Pi, allerdings erscheint bei mir unter alexa.amazon.de kein Still.

Ich bin alles mehrmals durchgegangen und habe alles überprüft, aber es will nichts erscheinen...

Kennt jemand das Problem und hat evtl. einen Tipp oder einen Lösungsvorschlag!?

Vielen Lieben Dank

Tom
Intel NUC
Harmony Smart Control
div. HUE Komponenten
div. HM-IP Komponenten
1x Kühlschrank voll mit Bier

MadMax-FHEM

Zitat von: ThommyTom am 26 Februar 2017, 19:59:24
Hallo zusammen,

ich habe mich auch mal daran versucht, alexa und hem zusammen zubringen.
Habe es nach Wiki und nach Video gemacht.

Alexa startet auch auf meinem Pi, allerdings erscheint bei mir unter alexa.amazon.de kein Still.

Ich bin alles mehrmals durchgegangen und habe alles überprüft, aber es will nichts erscheinen...

Kennt jemand das Problem und hat evtl. einen Tipp oder einen Lösungsvorschlag!?

Vielen Lieben Dank

Tom

Gleicher Account bei Echo und Developer-Amazon?

Der Skill ist ja erst mal nur ein "privater" Developer-Skill...

...auch unter "meine Skills" geschaut?

Gruß, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

Mavo460

Hi zusammen,

ich muss mich nun nachdem ich die letzten 30 Seiten gelesen habe und die verschiedenen Fehler alles geprüft habe, nun doch um Hilfe bitten.

Ich habe den Smart Home Skill nach Anleitung installiert.

FHEM läuft auf Version 5.8
Alexa-FHEM ist 0.3.0
vorhin erst aktualisiert (die alten Installationen liefen lokal, Alexa-FHEM hat immer Geräte gefunden, aber Alexa Smart Home Skill hat keine Geräte gefunden)

Nun bin ich mit der Video Anleitung von Haus Automatisierung nochmal alles durchgegangen. Auch nochmal alles gelöscht, sprich Security Profile usw.

Wenn ich Alexa starte bekomme ich folgende Ausgabe:

pi@raspberrypi /opt/fhem/alexa-fhem $ ./bin/alexa
[2/26/2017, 8:09:44 PM] using /home/pi/.alexa/config.json
[2/26/2017, 8:09:44 PM] ---
[2/26/2017, 8:09:44 PM] this alexa-fhem 0.3.0
[2/26/2017, 8:09:44 PM] Fetching FHEM devices...
[2/26/2017, 8:09:44 PM] [FHEM] starting longpoll: http://127.0.0.1:8083/fhem?XHR=1&inform=type=status;addglobal=1;filter=.*;since=null;fmt=JSON&timestamp=1488136184582
[2/26/2017, 8:09:44 PM] Server listening on: http://:::3000
[2/26/2017, 8:09:44 PM] [FHEM] Checking devices and attributes...
[2/26/2017, 8:09:44 PM] [FHEM]   executing: http://127.0.0.1:8083/fhem?cmd=%7BAttrVal(%22global%22,%22userattr%22,%22%22)%7D&XHR=1
[2/26/2017, 8:09:44 PM] [FHEM]   executing: http://127.0.0.1:8083/fhem?cmd=jsonlist2%20TYPE=alexa&XHR=1
[2/26/2017, 8:09:44 PM] [FHEM] Fetching FHEM devices...
[2/26/2017, 8:09:44 PM] [FHEM] fetching: http://127.0.0.1:8083/fhem?cmd=jsonlist2%20room=alexa&XHR=1
[2/26/2017, 8:09:44 PM] [FHEM] got: 1 results
[2/26/2017, 8:09:44 PM] [FHEM] Schlafzimmer.Lichtschalter is switch
[2/26/2017, 8:09:44 PM] [FHEM] Schlafzimmer.Lichtschalter has
[2/26/2017, 8:09:44 PM] [FHEM]   FirmwareRevision [D-firmware]
[2/26/2017, 8:09:44 PM] [FHEM]   On [state;on,off]
  2017-02-26 20:09:44 caching: Schlafzimmer.Lichtschalter-D-firmware: 2.8
  2017-02-26 20:09:44 caching: Schlafzimmer.Lichtschalter-state: on
[2/26/2017, 8:09:44 PM] [FHEM] alexa device is MyAlexa
[2/26/2017, 8:09:44 PM] [FHEM] MyAlexa is switch
[2/26/2017, 8:09:44 PM] [FHEM] MyAlexa has
[2/26/2017, 8:09:44 PM] [FHEM] homebridgeMapping: #Characteristic=<name>=<value>,...
On=verb=schalte,valueOn=an;ein,valueOff=aus,valueToggle=um

Brightness=verb=stelle,valuePrefix=auf,values=AMAZON.NUMBER,valueSuffix=prozent

TargetPosition=verb=mach,articles=den,values=auf:100;zu:0
TargetPosition=verb=stelle,valuePrefix=auf,values=AMAZON.NUMBER,valueSuffix=prozent

Hue=verb=stelle,valuePrefix=auf,values=rot:0;grün:128;blau:200
Hue=verb=färbe,values=rot:0;grün:120;blau:220

TargetTemperature=verb=stelle,valuePrefix=auf,values=AMAZON.NUMBER,valueSuffix=grad

#Weckzeit=verb=stelle,valuePrefix=auf;für,values=AMAZON.TIME,valueSuffix=uhr
[2/26/2017, 8:09:44 PM] [FHEM]   executing: http://127.0.0.1:8083/fhem?cmd=%7B$defs%7BMyAlexa%7D-%3E%7B%22active%22%7D%20=%201%7D&XHR=1
[2/26/2017, 8:09:44 PM] [FHEM]   executing: http://127.0.0.1:8083/fhem?cmd=%7B$defs%7BMyAlexa%7D-%3E%7B%22alexa-fhem%20version%22%7D%20=%20%220.3.0%22%7D&XHR=1
[2/26/2017, 8:09:44 PM] [FHEM]   executing: http://127.0.0.1:8083/fhem?cmd=%7B$defs%7BMyAlexa%7D-%3E%7B%22active%22%7D%20=%200%7D&XHR=1
[2/26/2017, 8:09:44 PM] perfectOfVerb:
[2/26/2017, 8:09:44 PM] { stelle: 'gestellt',
  schalte: 'geschaltet',
  'färbe': 'gefärbt',
  mach: 'gemacht' }
[2/26/2017, 8:09:44 PM] [ OnIntent: [ 'schalte' ],
  prozentIntent: [ 'stelle' ],
  TargetPositionIntent: [ 'mach' ],
  HueIntent: [ 'stelle' ],
  HueIntentB: [ 'färbe' ],
  gradIntent: [ 'stelle' ] ]
[2/26/2017, 8:09:44 PM] { OnIntent: [ 'On' ],
  prozentIntent: [ 'Brightness', 'TargetPosition' ],
  TargetPositionIntent: [ 'TargetPosition' ],
  HueIntent: [ 'Hue' ],
  HueIntentB: [ 'Hue' ],
  gradIntent: [ 'TargetTemperature' ] }
[2/26/2017, 8:09:44 PM] { OnIntent: undefined,
  prozentIntent: 'auf',
  TargetPositionIntent: undefined,
  HueIntent: 'auf',
  HueIntentB: undefined,
  gradIntent: 'auf' }
[2/26/2017, 8:09:44 PM] { OnIntent: undefined,
  prozentIntent: 'prozent',
  TargetPositionIntent: undefined,
  HueIntent: undefined,
  HueIntentB: undefined,
  gradIntent: 'grad' }
[2/26/2017, 8:09:44 PM] alexaTypes:
[2/26/2017, 8:09:44 PM] { light: [ 'licht', 'lampen' ],
  blind:
   [ 'rolladen',
     'rolläden',
     'jalousie',
     'jalousien',
     'rollo',
     'rollos' ] }
[2/26/2017, 8:09:44 PM] fhemIntents:
[2/26/2017, 8:09:44 PM] { FHEMgutenMorgenIntent: 'gutenMorgen',
  FHEMguteNachtIntent: 'guteNacht' }
  2017-02-26 20:10:44 caching: Schlafzimmer.Lichtschalter-state: off


Meine config.json sieht wie folgt aus:
{
    "alexa": {
        "name": "Alexa FHEM",
        "keyFile": "./key.pem",
        "certFile": "./cert.pem",
        "ssl": false,
        "applicationId": "amzn1.ask.skill.cbdf3854-83ef-xxxx-86ef-xxx0fc8ac91",
"oauthClientID": "amzn1.application-oa2-client.b8ce34xxxxxxxxx9b95424599653aefc"
    },

    "connections": [
        {
            "name": "FHEM",
            "server": "127.0.0.1",
            "port": "8083",
            "filter": "room=alexa"
        }
    ]
}


Ein List Schlafzimmer.Lichtschalter ergibt:
Internals:
   CUL_0_MSGCNT 2
   CUL_0_RAWMSG A0D48A41051CAE526EBF806010000::-66:CUL_0
   CUL_0_RSSI -66
   CUL_0_TIME 2017-02-26 20:10:44
   DEF        51CAE5
   HMLAN1_MSGCNT 2
   HMLAN1_RAWMSG E51CAE5,0000,0983FEF2,FF,FFCC,48A41051CAE526EBF806010000
   HMLAN1_RSSI -52
   HMLAN1_TIME 2017-02-26 20:10:44
   IODev      CUL_0
   LASTInputDev HMLAN1
   MSGCNT     4
   NAME       Schlafzimmer.Lichtschalter
   NOTIFYDEV  global
   NR         279
   NTFY_ORDER 50-Schlafzimmer.Lichtschalter
   STATE      off
   TYPE       CUL_HM
   lastMsg    No:48 - t:10 s:51CAE5 d:26EBF8 06010000
   protLastRcv 2017-02-26 20:10:44
   protSnd    2 last_at:2017-02-26 20:10:44
   protState  CMDs_done
   rssi_at_CUL_0 lst:-66 avg:-74.75 min:-83.5 cnt:2 max:-66
   rssi_at_HMLAN1 lst:-52 avg:-52.5 min:-53 max:-52 cnt:2
   Readings:
     2017-02-25 23:04:20   CommandAccepted yes
     2017-02-18 22:58:55   D-firmware      2.8
     2017-02-18 22:58:55   D-serialNr      NEQ1648185
     2017-02-20 18:53:18   PairedTo        0x26EBF8
     2017-02-20 18:53:18   R-pairCentral   0x26EBF8
     2017-02-20 18:53:19   R-powerUpAction off
     2017-02-20 18:53:19   R-sign          off
     2017-02-20 18:53:18   RegL_00.        02:01 0A:26 0B:EB 0C:F8 15:FF 18:00 00:00
     2017-02-20 18:53:19   RegL_01.        08:00  30:06 57:24 56:00 00:00
     2017-02-26 20:10:44   deviceMsg       off (to VCCU)
     2017-02-26 20:10:44   level           0
     2017-02-26 20:10:44   pct             0
     2017-02-26 20:10:44   recentStateType info
     2017-02-26 20:10:44   state           off
     2017-02-26 20:10:44   timedOn         off
   Helper:
     HM_CMDNR   72
     mId        0069
     rxType     1
     supp_Pair_Rep 0
     Ack:
     Expert:
       def        1
       det        0
       raw        1
       tpl        0
     Io:
       newChn     +51CAE5,00,02,00
       nextSend   1488136244.09845
       rxt        0
       vccu       VCCU
       p:
         51CAE5
         00
         02
         00
       prefIO:
         CUL_0
     Mrssi:
       mNo        48
       Io:
         CUL_0      -64
         HMLAN1     -52
     Prt:
       bErr       0
       sProc      0
       Rspwait:
     Q:
       qReqConf   00
       qReqStat
     Role:
       chn        1
       dev        1
       prs        1
     Rpt:
       IO         CUL_0
       flg        A
       ts         1488136244.00242
       ack:
         HASH(0x2bdaa88)
         48800226EBF851CAE500
     Rssi:
       At_cul_0:
         avg        -74.75
         cnt        2
         lst        -66
         max        -66
         min        -83.5
       At_hmlan1:
         avg        -52.5
         cnt        2
         lst        -52
         max        -52
         min        -53
Attributes:
   IODev      CUL_0
   IOgrp      VCCU:CUL_0
   alexaName  schlafzimmerlicht
   alexaRoom  schlafzimmer
   autoReadReg 4_reqStatus
   expert     2_raw
   firmware   2.8
   genericDeviceType switch
   model      HM-LC-Sw1PBU-FM
   room       Schlafzimmer,alexa
   serialNr   NEQ1648185
   subType    switch
   webCmd     statusRequest:toggle:on:off


Wenn ich aber (das ist auch der Grund, warum ich nochmal die Skills und auch den Lamda Trigger gelöscht habe) in AWS den Lamda Trigger testen möchte, erhalte ich dort folgende Meldung:
{
  "errorMessage": "RequestId: 2c9f240d-fc57-11e6-a621-9980f679e7bc Process exited before completing request"
}


Die config.jason habe ich dort eingetragen, den Host angepasst, Port ist 3000.

Von extern kann ich auf Port 3000 zugreifen, dann erhalte ich auch in der Console eine Fehlermeldung:
Zitat[2/26/2017, 8:25:28 PM] ERROR: SyntaxError: Unexpected end of input from ::ffff:91.52.74.139

Meine Lokale FHEM Installation war Passwort geschützt, dieses habe ich auskommentiert. Nun bekomme ich beim Restart von FHEM auch die Info, das kein Passwort gesetzt ist.

Schon seit vielen Tagen und viiiieeelen Seiten aus diesem Thread hier, kann ich mir vorstellen das es was mit dem Trigger zu tun hat. Nur die Fehlermeldung, welche ich beim Triggertest bekomme, kann ich nicht lösen.

Vielen Dank vorab!

Viele Grüße,
Marco

€dit: Ich versuche nur den Smart Home Skill einzurichten, den Custom Skill hatte ich erst auch immer gleich mit eingerichtet, da ich auch der Annahme war, es müsste wie im Wiki alles abgearbeitet werden.

ThommyTom

Zitat von: MadMax-FHEM am 26 Februar 2017, 20:16:21
Gleicher Account bei Echo und Developer-Amazon?

Der Skill ist ja erst mal nur ein "privater" Developer-Skill...

...auch unter "meine Skills" geschaut?

Gruß, Joachim

Überall der gleiche Account! Wenn ich unter "meine Skills schaue" sehe ich nichts!

Bringt es vielleicht etwas, wenn ich unter Amazon, AWS und Developer eine ganz neue frische Mail-Adresse einsetze?
Intel NUC
Harmony Smart Control
div. HUE Komponenten
div. HM-IP Komponenten
1x Kühlschrank voll mit Bier

Mavo460

Hallo zusammen,

ich habe nochmal einen Test durchgeführt, ohne laufenden Alexa-FHEM, dabei erhalte ich folgende Fehlermeldung im AWS:

START RequestId: d878e28c-fcc0-11e6-ad4a-635fc717120c Version: $LATEST
2017-02-27T07:46:27.886Z d878e28c-fcc0-11e6-ad4a-635fc717120c EVENT: [object Object]
2017-02-27T07:46:27.934Z d878e28c-fcc0-11e6-ad4a-635fc717120c CONTEXT: [object Object]
2017-02-27T07:46:28.644Z d878e28c-fcc0-11e6-ad4a-635fc717120c problem with request: connect ECONNREFUSED meine.externe.ip.adresse:3000
2017-02-27T07:46:28.645Z d878e28c-fcc0-11e6-ad4a-635fc717120c ReferenceError: createError is not defined
    at ClientRequest.<anonymous> (/var/task/index.js:42:20)
    at emitOne (events.js:77:13)
    at ClientRequest.emit (events.js:169:7)
    at TLSSocket.socketErrorListener (_http_client.js:256:9)
    at emitOne (events.js:77:13)
    at TLSSocket.emit (events.js:169:7)
    at emitErrorNT (net.js:1255:8)
    at nextTickCallbackWith2Args (node.js:437:9)
    at process._tickDomainCallback (node.js:392:17)
END RequestId: d878e28c-fcc0-11e6-ad4a-635fc717120c
REPORT RequestId: d878e28c-fcc0-11e6-ad4a-635fc717120c Duration: 834.66 ms Billed Duration: 900 ms Memory Size: 128 MB Max Memory Used: 19 MB
RequestId: d878e28c-fcc0-11e6-ad4a-635fc717120c Process exited before completing request

Das erscheint mir auch logisch, da kein Alexa-FHEM zum Verbinden vorhanden ist.

Starte ich Alexa-FHEM auf der Console und lasse erneut einen Test laufen, bekomme ich diese Meldung:

{
  "errorMessage": "RequestId: 2bc2e799-fcc1-11e6-bfa6-95ad333a537f Process exited before completing request"
}

Log Output:
START RequestId: 2bc2e799-fcc1-11e6-bfa6-95ad333a537f Version: $LATEST
2017-02-27T07:48:47.635Z 2bc2e799-fcc1-11e6-bfa6-95ad333a537f EVENT: [object Object]
2017-02-27T07:48:47.636Z 2bc2e799-fcc1-11e6-bfa6-95ad333a537f CONTEXT: [object Object]
2017-02-27T07:48:48.269Z 2bc2e799-fcc1-11e6-bfa6-95ad333a537f problem with request: socket hang up
2017-02-27T07:48:48.294Z 2bc2e799-fcc1-11e6-bfa6-95ad333a537f ReferenceError: createError is not defined
    at ClientRequest.<anonymous> (/var/task/index.js:42:20)
    at emitOne (events.js:77:13)
    at ClientRequest.emit (events.js:169:7)
    at TLSSocket.socketErrorListener (_http_client.js:256:9)
    at emitOne (events.js:77:13)
    at TLSSocket.emit (events.js:169:7)
    at emitErrorNT (net.js:1255:8)
    at nextTickCallbackWith2Args (node.js:437:9)
    at process._tickDomainCallback (node.js:392:17)
END RequestId: 2bc2e799-fcc1-11e6-bfa6-95ad333a537f
REPORT RequestId: 2bc2e799-fcc1-11e6-bfa6-95ad333a537f Duration: 883.71 ms Billed Duration: 900 ms Memory Size: 128 MB Max Memory Used: 8 MB
RequestId: 2bc2e799-fcc1-11e6-bfa6-95ad333a537f Process exited before completing request


Die Meldung "socket hang up" habe ich ständig im Cloudwatch Log. Kann hiermit jemand etwas anfangen?

Vielen Dank vorab,
Marco

€dit: Fehler gefunden:

In meiner config.json war von mir "ssl": "false" eingestellt. Das habe ich nun gelöscht. Zusätzlich habe ich gesehen, das in der neuen 0.3.0 Version noch ein webname hinterlegt ist. Der war bei mir auch nicht vorhanden.

Mein Fehler, der wohl schon seit Wochen bestand, war der Eintrag "ssl false"... Nun läuft es auch bei mir, Geräte wurden gefunden, socket hang up erscheint nicht mehr usw.

t_schlueter

Hallo,

bei mir lief Alexa bis ich vor 2 Tagen den Raspi neu gestartet habe. Ich bekomme die gleiche Fehlermeldung vom Lambda Service

"errorMessage": "RequestId: e426a50b-fdbe-11e6-965d-33931eb69f18 Process exited before completing request"

START RequestId: e426a50b-fdbe-11e6-965d-33931eb69f18 Version: $LATEST
2017-02-28T14:04:59.669Z e426a50b-fdbe-11e6-965d-33931eb69f18 EVENT: [object Object]
2017-02-28T14:04:59.670Z e426a50b-fdbe-11e6-965d-33931eb69f18 CONTEXT: [object Object]
2017-02-28T14:05:00.249Z e426a50b-fdbe-11e6-965d-33931eb69f18 problem with request: connect ECONNREFUSED
2017-02-28T14:05:00.250Z e426a50b-fdbe-11e6-965d-33931eb69f18 ReferenceError: createError is not defined
    at ClientRequest.<anonymous> (/var/task/index.js:41:20)
    at emitOne (events.js:77:13)
    at ClientRequest.emit (events.js:169:7)
    at TLSSocket.socketErrorListener (_http_client.js:256:9)
    at emitOne (events.js:77:13)
    at TLSSocket.emit (events.js:169:7)
    at emitErrorNT (net.js:1255:8)
    at nextTickCallbackWith2Args (node.js:437:9)
    at process._tickDomainCallback (node.js:392:17)
END RequestId: e426a50b-fdbe-11e6-965d-33931eb69f18
REPORT RequestId: e426a50b-fdbe-11e6-965d-33931eb69f18 Duration: 817.10 ms Billed Duration: 900 ms Memory Size: 128 MB Max Memory Used: 17 MB
RequestId: e426a50b-fdbe-11e6-965d-33931eb69f18 Process exited before completing request


Kannst du mir mal etwas genauer beschreiben wo der von Dir erwähnte Webname stehen muss?
Bin in dem Thema noch nicht lange drin. Wie gesagt lief Alexa und FHem bis vor 2 tagen noch einwandfrei.
Nach dem Update auf 5.8 musste ich lediglich den csrfToken auf none setzen dann lief es wieder. Nun stehe ich aber etwas auf dem Schlauch  :)

Danke

justme1968

für alexa-fhem und homebridge-fhem muss man csrfToken nicht auf none setzen sondern nur die jeweils aktuellste version verwenden. die funktioniert auch mit gesetztem token.

@Mavo460: wo ist die ssl false zeile her? das ist nicht dokumentiert und sollte nicht verwendet werden. der webname ist für eine normale fhem installation nicht nötig.

@t_schlueter: deine meldung deutet auf eine nicht funktionierendes port forwarding oder eine falsche ip (intern oder extern) hin.
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

https://github.com/sponsors/justme-1968