[32_yowsup.pm] Whatsapp versenden (Mit Handy- oder Festnetznummer)

Begonnen von AHA1805, 01 Oktober 2014, 21:58:55

Vorheriges Thema - Nächstes Thema

Thoffi1978

Hallo,
ich habe nur eine Fritzbox ohne weitere "Kindersicherung" laufen.
Emailversandt funktioniert problemlos. Verbindung ins I-Net sollte da sein.

Hoffi

Xaser

Hallo.

Ich möchte Whatsapp zum steuern meiner Heizung verwenden. Mein Notify sieht aktuell so aus:

HandyBasti:message.* {
if( $EVENT eq 'message: eco' ) {
   fhem "set HandyBasti send Heizung wird auf ECO gestellt.";
   fhem "set AllHeaters desiredTemperature eco";

} elsif( $EVENT eq 'message: auto' ) {
     fhem "set HandyBasti send Heizung wird auf AUTO gestellt.";
     fhem "set AllHeaters desiredTemperature auto";

} elsif( $EVENT eq 'message: Arbeitzimmer $zahl' ) {
     fhem "set HandyBasti send Arbeitszimmer wird auf $zahl gestellt";
     fhem "set Thermostat_Arbeitszimmer desiredTemperature $zahl";

} else {
     fhem "set HandyBasti send Wie bitte?"

}
}


Soll heißen: Wenn ich schreibe "Arbeitszimmer 21" soll die "21" mit "set Thermostat_Arbeitszimmer desiredTemperature 21" gesendet werden. Wie bekomme ich das hin? Eine richtige Lösung oder Hinweis konnte ich bis jetzt über google nicht finden :-(

justme1968

} elsif( $EVENT =~ /message: Arbeitszimmer (\d+)/ ) {
  my $zahl = $1;
  ...


siehe auch weiter oben im thread.

gruss
  andre
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

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

Michael

Moin

Bekomme WhatsApp nicht zum laufen. (Sende/Enpfangen)

Zitat
http://forum.fhem.de/index.php?topic=27543.945
Antwort #949 am: Gestern um 09:40:05 »

1. System neu gestartet, set WhatsApp send 04917xxxxx "test" STATE -> offline sonst passiert nichts.
2. Mach ich ein set WhatsApp reconnect bekommt STATE -> Connected
3. Wenn ich set WhatsApp send 04917xxxxx "test" mache bekomme ich in der Webansicht -> not connected
    und STATE bleibt bei Connected, die Readings state bleibt bei offline und sent ändert sicht.

Habe mir die ganzen 65 Seiten Angesehen und Versucht, was Verbindungsprobleme zu tun hat abzuarbeiten aber ohne Erfolg.
Könnt Ihr mir Helfen ?
   
Gruß, Michael

FHEM 6.0 auf RPi 3
CUL V3 868 Mhz | JeeLink LaCrosse & PCA301 | CCU3
BMP085(180) | 14x TX29DTH-IT | 5x PCA 301 | SMA Peripheries | MobileAlerts MA-10(100,120PRO,200,251,410,650,660,800) | HM IP

VB90

nebenbei... 049... die 0 ist zuviel
hast du in der Konfig zu deiner Nummer eventuell auch diese 0 drin?

vb
Man muss das Rad nicht neu erfinden, nur wissen wie es gedreht wird.

Michael

#965
Sorry !!!
Die 0 ist in der Config nicht dabei.

Nachtrag :
Habe die Verzeichnisse von Hand gelöscht, so weit es ging.
Dann habe ich nach der Anleitung alles nochmal gemacht, auch die Registrierung mit der selben Nummer.

Nun Läuft es, nun wie lange weiß ich noch nicht.
  :D :D :D
Gruß, Michael

FHEM 6.0 auf RPi 3
CUL V3 868 Mhz | JeeLink LaCrosse & PCA301 | CCU3
BMP085(180) | 14x TX29DTH-IT | 5x PCA 301 | SMA Peripheries | MobileAlerts MA-10(100,120PRO,200,251,410,650,660,800) | HM IP

Markus

Hallo

Ich versuche mich auch gerade an der Installation von Whatsapp leider Funktioniert das nicht.

Dazu muss ich aber gestehen das ich schon die dritte Nummer versuche die Erste Handy Nummer wurde von WhatsApp Gesperrt, weil ich ein nicht autorisiertes Programm verwendet habe ;D dann hab ich eine Festnetz Nummer probiert die war zu kurz und die Jetzige Nummer scheint auch nicht zu klappen.
Auszug aus Putty:

pi@Agent-Wohnzimmer:/opt/yowsup-config $ sudo su - fhem
fhem@Agent-Wohnzimmer:~$ cd /opt/yowsup-master
fhem@Agent-Wohnzimmer:/opt/yowsup-master$ python yowsup-cli registration -c /opt/yowsup-config/yowsup.config -r sms
INFO:yowsup.common.http.warequest:{"status":"fail","reason":"incorrect","sms_length":6,"voice_length":6,"sms_wait":43244,"voice_wait":0}

INFO:yowsup.common.http.warequest:{"status":"fail","reason":"too_recent","retry_after":43298,"sms_wait":43298,"voice_wait":0}

status: fail
retry_after: 43298
reason: too_recent
fhem@Agent-Wohnzimmer:/opt/yowsup-master$ python yowsup-cli registration -c /opt/yowsup-config/yowsup.config -r voice
Traceback (most recent call last):
  File "yowsup-cli", line 323, in <module>
    if not parser.process():
  File "yowsup-cli", line 158, in process
    self.handleRequestCode(self.args["requestcode"], config)
  File "yowsup-cli", line 174, in handleRequestCode
    method
  File "/opt/yowsup-master/yowsup/registration/coderequest.py", line 13, in __init__
    idx = StorageTools.getIdentity(cc + p_in)
  File "/opt/yowsup-master/yowsup/common/tools.py", line 59, in getIdentity
    path = StorageTools.getStorageForPhone(phone)
  File "/opt/yowsup-master/yowsup/common/tools.py", line 49, in getStorageForPhone
    return StorageTools.constructPath(phone + '/')
  File "/opt/yowsup-master/yowsup/common/tools.py", line 44, in constructPath
    os.makedirs(os.path.dirname(fullPath))
  File "/usr/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/opt/fhem/.yowsup/4367762030500'
fhem@Agent-Wohnzimmer:/opt/yowsup-master$ python yowsup-cli registration -c /opt/yowsup-config/yowsup.config -r voice
INFO:yowsup.common.http.warequest:{"status":"fail","reason":"incorrect","sms_length":6,"voice_length":6,"sms_wait":42948,"voice_wait":0}

INFO:yowsup.common.http.warequest:{"status":"sent","length":6,"method":"voice","retry_after":172805,"sms_wait":42947,"voice_wait":172805}

Traceback (most recent call last):
  File "yowsup-cli", line 323, in <module>
    if not parser.process():
  File "yowsup-cli", line 158, in process
    self.handleRequestCode(self.args["requestcode"], config)
  File "yowsup-cli", line 176, in handleRequestCode
    result = codeReq.send()
  File "/opt/yowsup-master/yowsup/registration/coderequest.py", line 48, in send
    StorageTools.writeIdentity(self.cc + self.p_in, self.__id)
  File "/opt/yowsup-master/yowsup/common/tools.py", line 54, in writeIdentity
    with open(os.path.join(path, "id"), 'wb') as idFile:
IOError: [Errno 13] Permission denied: '/opt/fhem/.yowsup/4367762030500/id'
fhem@Agent-Wohnzimmer:/opt/yowsup-master$ python yowsup-cli registration -c /opt/yowsup-config/yowsup.config -R 498201
INFO:yowsup.common.http.warequest:{"status":"fail","reason":"too_many_guesses","retry_after":86400}

status: fail
retry_after: 86400
reason: too_many_guesses


Gruß Markus
Raspberry Pi2 als FHEM-Plattform
HM, FS20, 1-Wire, PanStamp,LW12,Intertechno,ESPEasy,Alexa

Xaser

Hi.  Das hatte ich heute auch mal. Entweder Berechtigung nochmal neu setzen oder Config datei wegspeichern, Dateien updaten und dann Config zurück spielen (Lösung ist hier im Forum zu finden).

Ma_Bo

Kurze Info, whatsapp soll demnächst komplett kostenlos sein, also nicht mehr das abo Model für 1$ im Jahr.
NUC mit FHEM, HM Heizungsthermostate, HM Wandthermostate, Intertechno Funksteckdosen, 10" Tablet als Wanddisplay, KeyMatic, Fensterkontakte, Fensterkontakte umgebaut als Wassermelder und Briefkastenmelder, Aussenthermostat, Anwesenheitssteuerung über Fritz Box, Google Home usw. usw.

satprofi

Zitat von: Ma_Bo am 18 Januar 2016, 21:20:11
Kurze Info, whatsapp soll demnächst komplett kostenlos sein, also nicht mehr das abo Model für 1$ im Jahr.

versteh den hype nicht, ich habe noch nie bezahlt. Oder hat jemand von euch beim registrieren für FHEM an whatsapp bezahlt?
gruss
-----------------------------------------------------------------------
beelink miniPC - Fhem 6.x CUL 868, FS20, NetIO230 CUL 433
HMLAN, HM-CC-RT-DN,Homematic Actoren,LD382A,Telegram

JoWiemann

Zitat von: satprofi am 19 Januar 2016, 18:09:57
versteh den hype nicht, ich habe noch nie bezahlt. Oder hat jemand von euch beim registrieren für FHEM an whatsapp bezahlt?

Es gibt Fälle, wo kurz vor Ablauf seitens WhatsApp eine Zahlungsaufforderung zugesandt worden sein soll.

Viel besser ist, dass damit wohl auch die Pishing-Mails aufhören, in denen immer wieder der Betrag eingefordert wurde, verbunden mit dem Nebeneffekt eines kleinen Trojaners.

Grüße Jörg
Jörg Wiemann

Slave: RPi B+ mit 512 MB, COC (868 MHz), CUL V3 (433.92MHz SlowRF); FHEMduino, Aktuelles FHEM

Master: CubieTruck; Debian; Aktuelles FHEM

heinzfo

Hallo an die Yowsup macher

Ich habe am vergangenen Wochenende Yowsup installiert und WhatsApp eingerichtet.
Auf einem Raspberry PI/Jessie image.

Es funktioniert wie am schnürchen   ;D 8)
Ein fettes Lob an die Macher!

Beste Grüße
Heinz

Markus

Hallo
Ich bin jetzt einen schritt weiter ich kann mit fhem nachrichten empfangen aber nicht senden
STATE und state von whatsapp ist conected
STATE von der Number ist: drei Fragezeichen
im log steht:

2016.01.19 21:29:22 2: WhatsApp: starting yoswup-cli: /opt/local/bin/yowsup-cli demos -c /root/config.yowsup --yowsup
2016.01.19 21:29:22 1: PERL WARNING: Can't exec "/opt/local/bin/yowsup-cli": No such file or directory at ./FHEM/32_yowsup.pm line 177.
2016.01.19 21:29:22 1: exec failed
2016.01.19 21:29:22 1: set the cmd attribut to: <path1>/yowsup-cli demos -c <path2>/config.yowsup --yowsup
2016.01.19 21:29:32 2: WhatsApp: starting yoswup-cli: /opt/local/bin/yowsup-cli demos -c /root/config.yowsup --yowsup
2016.01.19 21:29:32 1: PERL WARNING: Can't exec "/opt/local/bin/yowsup-cli": No such file or directory at ./FHEM/32_yowsup.pm line 177.
2016.01.19 21:29:32 1: exec failed
2016.01.19 21:29:32 1: set the cmd attribut to: <path1>/yowsup-cli demos -c <path2>/config.yowsup --yowsup
2016.01.19 21:29:42 2: WhatsApp: starting yoswup-cli: /opt/local/bin/yowsup-cli demos -c /root/config.yowsup --yowsup
2016.01.19 21:29:42 1: PERL WARNING: Can't exec "/opt/local/bin/yowsup-cli": No such file or directory at ./FHEM/32_yowsup.pm line 177.
2016.01.19 21:29:42 1: exec failed
2016.01.19 21:29:42 1: set the cmd attribut to: <path1>/yowsup-cli demos -c <path2>/config.yowsup --yowsup
2016.01.19 21:29:53 2: WhatsApp: starting yoswup-cli: /opt/local/bin/yowsup-cli demos -c /root/config.yowsup --yowsup
2016.01.19 21:29:53 1: PERL WARNING: Can't exec "/opt/local/bin/yowsup-cli": No such file or directory at ./FHEM/32_yowsup.pm line 177.
2016.01.19 21:29:53 1: exec failed
2016.01.19 21:29:53 1: set the cmd attribut to: <path1>/yowsup-cli demos -c <path2>/config.yowsup --yowsup
2016.01.19 21:30:16 2: WhatsApp: starting yoswup-cli: /opt/local/bin/yowsup-cli demos -c /root/config.yowsup --yowsup
2016.01.19 21:30:16 1: PERL WARNING: Can't exec "/opt/local/bin/yowsup-cli": No such file or directory at ./FHEM/32_yowsup.pm line 177.
2016.01.19 21:30:16 1: exec failed
2016.01.19 21:30:16 1: set the cmd attribut to: <path1>/yowsup-cli demos -c <path2>/config.yowsup --yowsup
2016.01.19 21:30:19 2: WhatsApp: starting yoswup-cli: /opt/yowsup-master/yowsup-cli demos -c /opt/yowsup-config/yowsup.config --yowsup
2016.01.19 21:30:28 1: PERL WARNING: Argument "ok" isn't numeric in numeric lt (<) at FHEM/Color.pm line 469.
INFO:yowsup.layers.axolotl.layer:Axolotl layer is generating keys
2016.01.19 21:30:30 1: No Logdevice FileLog_sysmon
2016.01.19 21:30:35 1: No Logdevice FileLog_sysmon
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 763, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/opt/yowsup-master/yowsup/demos/cli/cli.py", line 154, in startInputThread
    wait = self.execCmd(cmd)
  File "/opt/yowsup-master/yowsup/demos/cli/cli.py", line 138, in execCmd
    return self.doExecCmd(lambda :targetFn(*args))
  File "/opt/yowsup-master/yowsup/demos/cli/cli.py", line 141, in doExecCmd
    return fn()
  File "/opt/yowsup-master/yowsup/demos/cli/cli.py", line 138, in <lambda>
    return self.doExecCmd(lambda :targetFn(*args))
  File "/opt/yowsup-master/yowsup/demos/cli/layer.py", line 407, in image_send
    entity = RequestUploadIqProtocolEntity(RequestUploadIqProtocolEntity.MEDIA_TYPE_IMAGE, filePath=path)
  File "/opt/yowsup-master/yowsup/layers/protocol_media/protocolentities/iq_requestupload.py", line 27, in __init__
    assert os.path.exists(filePath), "Either specified path does not exist, or yowsup doesn't have permission to read: %s" % filePath
AssertionError: Either specified path does not exist, or yowsup doesn't have permission to read: genial


Gruß Markus
Raspberry Pi2 als FHEM-Plattform
HM, FS20, 1-Wire, PanStamp,LW12,Intertechno,ESPEasy,Alexa

JoWiemann

Hallo,

zum Senden benötigt yowsup Schreibrechte. Schau mal, ob das Dein Problem löst: http://forum.fhem.de/index.php/topic,27543.msg299183.html#msg299183

Grüße Jörg
Jörg Wiemann

Slave: RPi B+ mit 512 MB, COC (868 MHz), CUL V3 (433.92MHz SlowRF); FHEMduino, Aktuelles FHEM

Master: CubieTruck; Debian; Aktuelles FHEM

Thoffi1978

Hallo,
nun habe ich die Registration geschafft, :)
Beim versenden der Testnachricht kommt folgender Fehler:
No module named google.protobuf

Hier der ganze Text:
fhem@raspberrypi:/opt/yowsup-master$ python yowsup-cli demos -c /opt/yowsup-config/yowsup.config -s 491793999572 "Das ist ein Test"
Traceback (most recent call last):
  File "yowsup-cli", line 323, in <module>
    if not parser.process():
  File "yowsup-cli", line 231, in process
    self.startSendClient()
  File "yowsup-cli", line 279, in startSendClient
    not self.args["unmoxie"])
  File "/opt/yowsup-master/yowsup/demos/sendclient/stack.py", line 24, in __init__
    from yowsup.layers.axolotl                     import YowAxolotlLayer
  File "/opt/yowsup-master/yowsup/layers/axolotl/__init__.py", line 1, in <module>
    from .layer import YowAxolotlLayer
  File "/opt/yowsup-master/yowsup/layers/axolotl/layer.py", line 3, in <module>
    from axolotl.util.keyhelper import KeyHelper
  File "build/bdist.linux-armv7l/egg/axolotl/util/keyhelper.py", line 3, in <module>
  File "build/bdist.linux-armv7l/egg/axolotl/identitykeypair.py", line 1, in <module>
  File "build/bdist.linux-armv7l/egg/axolotl/state/storageprotos.py", line 6, in <module>
ImportError: No module named google.protobuf

Lieben Dank
Hoffi