Endpoint mapping issue?

2 replies [Last post]
AndrewJ
Offline
United Kingdom
Joined: 22 Nov 2012

Recovered from a soft brick the other week (possible web hack on my livebox) now backup and running on bretts latest beta 311.10

however for the life of me i cant seem to get my room node to map to the endpoint in XFX Viewer

i can see the data coming in with microcom -s 57600 /dev/ttyUSB0 as below


[RF12nocfg.1] A i1 g212 @ 868 MHz

Current basenode configuration:
 A i1 g212 @ 868 MHz
OK 2 7 0 10 3

and my Roomnode is on ID 2 as detailed in my jeenodeapplet

info={
   version="4.0", description="JeeNode"
}

local jeemon={
      port="/dev/ttyUSB0",
      baud=57600,
      stop=1,
      databits=8,
      parity="none",
      flow="none"
}

-- Keyed by NODE ID
local nodes = {
   [2] = RoomNode{instance="jeenode:room1", endpoints={temp=1,light=1,humi=1,moved=1,lobat=1}, ttl=900},

message from XFX viewer shows no data depite seeing the serial data OK on USB0

xap-header
{
v=12
hop=1
uid=FF00D804
class=xAPBSC.info
source=dbzoo.livebox.jeenode:room1.temp
}
input.state
{
state=?
text=?
}

A little bit puzzled...

Andrew

brett
Offline
Providence, United States
Joined: 9 Jan 2010
Make sure xap-serial is

Make sure xap-serial is running.  I know you where messing around in the assists area, perhaps you turned it off.

My feed for my jeenodes some from an external RF xap-serial gateway (virtual serial port) however the LUA code path is pretty much the same internally.  Mine looks like this - which is a bit funky I admit.

module(...,package.seeall)
local monitor = require("xap.jeenode").monitor
RoomNode = require("xap.roomnode")
info={
   version="4.0", description="JeeNode"
}
function init()
   monitor({ target="dbzoo.nanode.gateway", port="/dev/ttyUSB0" },
           { [2] = RoomNode{deviceid="nanode",instance="jeenode:2", endpoints={lobat=1,temp=1,light=1},ttl=900},
             [3] = RoomNode{deviceid="nanode",instance="jeenode:3", endpoints={lobat=1,temp=1,light=1},ttl=900},
             [4] = RoomNode{deviceid="nanode", instance="jeenode:4", endpoints={lobat=1,temp=1,light=1},ttl=900},
             [5] = RoomNode{deviceid="nanode", instance="jeenode:5", endpoints={temp=1,lobat=1,light=1,humi=0,moved=1}, ttl=900},
             [7] = RoomNode{deviceid="nanode", instance="jeenode:7", endpoints={lobat=1,temp=1,humi=1},ttl=1800},
           })
end

Brett

AndrewJ
Offline
United Kingdom
Joined: 22 Nov 2012
Thanks Brett, Thats fixed it,

Thanks Brett,

 

Thats fixed it, it was indeed the Xap-serial, i checked PS and it wasnt listed, i assumed as microm was seeing the data everything was ok

 

cheers for the tip

 

Andrew

Hardware Info