Plugwise Stick: strange messages when read directly

Plugwise Forum about Plugwise devices and the Source software.
Post Reply
wusel
Starting Member
Starting Member
Posts: 19
Joined: Sat Jan 16, 2010 6:48 pm
Contact:

Plugwise Stick: strange messages when read directly

Post by wusel »

Hi,

I'm trying to communicate with The Stick from Linux, based on Maartens protocol info (doing a module for FHEM). I crafted a package, but if I send this to /dev/ttyUSB0, I get rather strage data back (Stick's and Circle's firmwares are from 2008):

Code: Select all

 firstshell@plug-2:~# xxd /tmp/1 
0000000: 0505 0303 3030 3233 3030 3044 3646 3030  ....0023000D6F00
0000010: 3030 3442 4532 3436 3830 4138 0d0a       004BE24680A8..
firstshell@plug-2:~# cat /tmp/1 >/dev/ttyUSB0

Code: Select all

othershell@plug-2:~# cat </dev/ttyUSB0 | xxd
0000000: 5075 7446 6966 6f55 6e69 6361 7374 2034  PutFifoUnicast 4
0000010: 3020 3a20 3030 3044 3646 3030 3030 3442  0 : 000D6F00004B
0000020: 4532 3436 0d0a 0505 0303 3030 3030 3030  E246......000000
0000030: 4331 4142 3932 0d0a 8349 6e73 7065 6374  C1AB92...Inspect
0000040: 4669 666f 556e 6963 6173 7420 3430 0d0a  FifoUnicast 40..
0000050: 4e52 746f 4e43 2032 2030 0d0a 656d 6265  NRtoNC 2 0..embe
0000060: 724d 6573 7361 6765 5365 6e74 4861 6e64  rMessageSentHand
0000070: 6c65 7228 2920 202a 2a20 436c 7573 7465  ler()  ** Cluste
0000080: 7249 6420 3430 202a 2a20 2053 7461 7475  rId 40 **  Statu
0000090: 7320 3020 2a2a 0d0a 2043 6c75 7374 6572  s 0 **.. Cluster
00000a0: 4964 2034 3020 2053 7563 6365 7373 0d0a  Id 40  Success..
00000b0: 9734 3120 3a20 3030 3044 3646 3030 3030  .41 : 000D6F0000
00000c0: 3442 4532 3436 0d0a 0505 0303 3030 3234  4BE246......0024
00000d0: 3030 3044 3646 3030 3030 3442 4532 3436  000D6F00004BE246
00000e0: 3030 3030 3541 3835 3030 3034 3434 3730  00005A8500044470
00000f0: 3031 3835 3030 3030 3034 3733 3030 3037  0185000004730007
0000100: 3438 4234 3235 3338 3031 4244 3342 0d0a  48B4253801BD3B..
I double checked that no other process has /dev/ttyUSB0 open, so my question is: has someone seen this behaviour before (as it's not mentioned anywhere)? Did I accidently enter a debug mode of The Stick or is it just confused/broken? pol.y still gives readings which look ok ...

Regards,
-kai
--
Kai 'wusel' Siering, Blog: http://blogdoch.net/
User avatar
RDNZL
Forum Moderator
Forum Moderator
Posts: 1008
Joined: Sun Sep 24, 2006 1:45 pm
Location: Dordrecht, The Netherlands
Contact:

Re: Plugwise Stick: strange messages when read directly

Post by RDNZL »

Your looking at output from the Ember Zigbee protocol/chipset.

Google on "emberMessageSentHandler()"

It's a bug/bad programming, or both ;-)
Regards, Ron.
wusel
Starting Member
Starting Member
Posts: 19
Joined: Sat Jan 16, 2010 6:48 pm
Contact:

Re: Plugwise Stick: strange messages when read directly

Post by wusel »

RDNZL wrote:Your looking at output from the Ember Zigbee protocol/chipset. [...]
It's a bug/bad programming, or both ;-)
Thanks for the info; funny, now one knows even which stack Plugwise uses (and, thanks to the PDFs available, how e. g. OTA updates shall work). So, I'll just drop anything before the <ENQ><ENQ><ETX><ETX> sequence? Now I know why that funny sequence exists (instead of just reading a CRLF terminated line) ... Did they at least fix that bogus output in Firmware 2? ;)
-kai
--
Kai 'wusel' Siering, Blog: http://blogdoch.net/
wusel
Starting Member
Starting Member
Posts: 19
Joined: Sat Jan 16, 2010 6:48 pm
Contact:

Plugwise Stick: re-initialize communications?

Post by wusel »

Well, The Stick's "garbage" looks more like debugging info; I somehow managed to "upset" my Circle+, trying to get information off it yields:

Code: Select all

PutFifoUnicast 40 : 000D6F00004BE246
000000C1AB92
InspectFifoUnicast 40
NRtoNC 2 0
InspectFifoUnicast 40
NRtoNC 1 0
emberMessageSentHandler()  ** ClusterId 40 **  Status 102 ** ClusterId 40  Fail
emberMessageSentHandler()  ** ClusterId 40 **  Status 102 ** ClusterId 40  Fail
InspectFifoUnicast 40
NRtoNC 0 0
emberMessageSentHandler()  ** ClusterId 40 **  Status 102 **
Note the "ClusterId 40 Fail"; talking to my 2. Circle still works. I even "power-cycled" the Circle+ (plug-out of wall socket, wait some seconds, re-plug), but, well, it's still not playing with me anymore ;)

Anyone in the know of the magic bytes to send to The Stick so it will "repair" the Mesh? (Will try The Source to regain access, but as my home automation runs on Linux/ARM, knowing how to restart the Mesh network has a high priority (or I'll have to drop Plugwise and restart researching alternatives :().)

EDIT: While awaiting moderation approval of this post, I tried the Source: it finds both my plugs, Circle+ and Circle, talks to 'em, I can even switch Circle+. Back on Linux, I still can't talk to my Circle+; neither with my own software nor with pol.py. The Circle still works with my software als well as pol.py. Is there a way (from within The Source I assume?) to reset the Circle+ in some way?

-kai
--
Kai 'wusel' Siering, Blog: http://blogdoch.net/
Mdamen
Forum Moderator
Forum Moderator
Posts: 390
Joined: Sat Nov 22, 2008 6:58 pm
Location: Netherlands
Contact:

Re: Plugwise Stick: strange messages when read directly

Post by Mdamen »

This hasn't been fixed in firmware version 2.. messages are still there!
ojaro
Starting Member
Starting Member
Posts: 1
Joined: Fri Jun 04, 2010 5:06 pm

Re: Plugwise Stick: strange messages when read directly

Post by ojaro »

Hi all,

I have this same problem. Did anyone find out how to fix this or filter the noice out from the message?

Regards,

Olli
Post Reply

Return to “Plugwise Forum”