how to get roomnode id?

I just took delivery of a jeelink usb v3 and jeenode v6 with room plug.

I managed to flash the jeelink with hahcentral.hex and the jeenode with roomnode2.hex

When i run microcom -s 57600 /dev/ttyUSB0 with the jeelink connected it reports:

[HAHCentral.1] D i4 g212 @ 433 MHz 

 

But when i run it with the jeenode attached i don't get anything.
What am I doing wrong?
Thanks!

 

Member for

16 years 10 months

brett

14 years 11 months ago

You are NODE 4 and 433Mhz.

Adjust to 868Mhz and make it node 1.

    "Available commands:" "\n"
" <nn> i - set node ID (standard node ids are 1..26)" "\n"
" <n> b - set MHz band (4 = 433, 8 = 868, 9 = 915)" "\n"
" <nnn> g - set network group (RFM12 only allows 212, 0 = any)" "\n"
" ...,<nn> a - send data packet to node <nn>, with ack" "\n"
" ...,<nn> s - send data packet to node <nn>, no ack" "\n"
" <n> q - set quiet mode (1 = don't report bad packets)" "\n"

Brett

Member for

17 years

derek

14 years 11 months ago

We've only verified operation on the HAH with the attach cable from the Shop and with the Sparkfun FTDI cable adaptor. If you are using a cable to hookup to a PC/MAC ... you are into unchartered territory.

Derek.

Member for

16 years 10 months

brett

14 years 11 months ago

Just trying to find out what part of the wiki write up is unclear on the jeenodes so the documentation can be improved.  A few people seem to be coming unstucking getting these setup.

Edit: I've modified the wiki page on flashing the nodes to try to clarify where I think people are getting lost.

Brett

Member for

15 years

tickett

14 years 11 months ago

Yes- i'd say there are a few bits missing. I can hopefully help clear it up once i get it all working :)

 

The first mistake i'd like to point out is the curl command for the hahcentral.hex - which appears to work but in fact downloads a 404 file not found page. This is because the filename is case sensitive.

 

The next thing I think i've discovered is that you have to set the node, group and band with either the rf12demo or hahcentral sketch flashed- you cannot do it with the roomnode sketch. And that the band must be 868 Mhz (or at least for these devices i think?)

 

I've now got to a stage where the jeelink and jeenode are on the correct band and group. From the hah:

 

[HAHCentral.1] D i4 g212 @ 868 MHz 

OK 2 0 0 0 0

OK 2 0 0 0 0

But i don't really know what i'm supposed to do next? I've configured the jeenodeApplet.lua and enabled serial schema service and plugboard scripting engine but nothing is happening? (not sure what i'm expecting to happen).
If i try to run xap-plugboard i get:
# xap-plugboard
lua: error loading module 'jeenodeApplet' from file '/etc/plugboard/jeenodeApplet.lua':
/etc/plugboard/jeenodeApplet.lua:4: unexpected symbol near '?'
stack traceback:
[C]: ?
[C]: in function 'require'
/etc_ro_fs/plugboard/plugboard.lua:23: in function 'fun'
/usr/share/lua/5.1/pl/tablex.lua:365: in function 'foreach'
/etc_ro_fs/plugboard/plugboard.lua:71: in main chunk
[C]: ?
Loading /etc/plugboard/jeenodeApplet.lua        # 
Not sure if that's because it is already running or something is broke!
Thanks for the help- i am rather excited with my progress!
Lee

Member for

16 years 10 months

brett

14 years 11 months ago

You should only every run xap-plugboard once you have stop any other plugboard script... you can't run two!  If you want it run it manually you can but this is only useful when debugging and saying that only if you have debug enabled in your applet.    Do a ps and make sure plugboard.lua is not active before running xap-plugboard.

That stack trace would indicate that you made an editing error when configuring the applet - what I don't know.

ALSO you CANNOT and MUST NOT run xap-serial AND microcom to the jeenode at the same time.

Fire up xFXviewer and check the output for the xap-serial program this way.

Brett

Member for

15 years

tickett

14 years 11 months ago

The jeenodeApple.lua file had become corrupted. Must have been the way i got it onto the box (used wget). That's another step i think missed off the wiki... how to get the file onto the box and how to edit it? I hate VI :)

Now i've fixed the .lua file xap-plugboard works... watch this space.

Thanks for all your help- sure there'll be a few more questions yet.

L

Member for

15 years

tickett

14 years 11 months ago

How do I get xFXviewer hooked in? When i run it on my pc I just see:

 

xap-hbeat

{

v=13

Hop=1

UID=FFD86600

Class=xap-hbeat.alive

Source=xFx.Viewer.winxp-01

Interval=60

Port=3639

PID=1096

}

Which is the pc that xFXviewer is running on. No sign of the hah etc.

 

How is it supposed to see the stuff into the hah from the jeenodes via the jeelink?

Member for

15 years

Pentala

14 years 11 months ago

Hi,

I had this problem when running on Windows 7 - make sure your firewall on the PC is either disabled or configured to allow the xAP messages through, also, you need to run the xFX Viewer as Administrator.

Hope this helps,

Andy.

Member for

16 years 10 months

brett

14 years 11 months ago

xFXViewer between release v3 and v4 a significant change was made.

V3 did not require a hub.  V4 does require a hub, use the xFx-Express Hub.

If you don't run a hub on your windows box V4 will return ZERO data.

Personally the only thing I run on windows is xFXviewer anyway so I just run V3 when I need to examine the xap packets.  Its still just as functional as V4 and I don't have to start yet another program before I use it.

Attachments

Member for

16 years 10 months

brett

14 years 11 months ago

You don't need to use wget to get a sample jeeNodeApplet.lua program onto your HAH just copy the one out of the sample directory that is shipped in the HAH

# cp /etc_ro_fs/plugboard/samples/jeenodeApplet.lua /etc/plugboard

Then edit away - I'll add this to the wiki note :)

Member for

15 years

tickett

14 years 11 months ago

Is there an alternative to VI? :)

I'm making a little progress. I installed xFXviewer on a different machine and I can see the endpoints.

I also uncommented _DEBUG and when I cat /var/log/xap-plugboard i can see some activity:

# cat xap-plugboard.log 

Loading /etc/plugboard/jeenodeApplet.lua        [ HAHNode ]

build RoomNode[1]

build RoomNode[2]

Running...

Reaping RoomNode[1] alive=true ttl=300 timeout=10

Reaping RoomNode[2] alive=true ttl=300 timeout=10

Reaping RoomNode[1] alive=true ttl=300 timeout=20

Reaping RoomNode[2] alive=true ttl=300 timeout=20

Reaping RoomNode[1] alive=true ttl=300 timeout=30

Reaping RoomNode[2] alive=true ttl=300 timeout=30

Reaping RoomNode[1] alive=true ttl=300 timeout=40

Reaping RoomNode[2] alive=true ttl=300 timeout=40

Reaping RoomNode[1] alive=true ttl=300 timeout=50

Reaping RoomNode[2] alive=true ttl=300 timeout=50

Reaping RoomNode[1] alive=true ttl=300 timeout=60

Reaping RoomNode[2] alive=true ttl=300 timeout=60

Reaping RoomNode[1] alive=true ttl=300 timeout=70

Reaping RoomNode[2] alive=true ttl=300 timeout=70

Reaping RoomNode[1] alive=true ttl=300 timeout=80

Reaping RoomNode[2] alive=true ttl=300 timeout=80

Reaping RoomNode[1] alive=true ttl=300 timeout=90

Reaping RoomNode[2] alive=true ttl=300 timeout=90

Reaping RoomNode[1] alive=true ttl=300 timeout=100

Reaping RoomNode[2] alive=true ttl=300 timeout=100

{

  data = "OK 1 0 0 0 0", 

  port = "/dev/ttyUSB0", 

}

process RoomNode[1]

moved=0

humi=0

temp=0

lobat=0

light=0

Reaping RoomNode[1] alive=true ttl=300 timeout=10

Just need to try and work out why i'm not getting any values for light/temp/humid etc. Is the roomnode2.hex build to work with the jeenode + room plug v2? is the source available? I think i probably need to hook the roomnode directly up to laptop and debug locally somehow...
Thanks again for the help- nearly there?! :)

 

Member for

16 years 10 months

brett

14 years 11 months ago

As you are getting OK reports the Central + HAH are working fine - the bug is with the hardware on your roomnode.  Make sure you have correctly orientated the daughter board and its connected to the right ports.

data = "OK 1 0 0 0 0",   <-- this is what we expect to see MINUS all the 0's of course.

This means that the sensors on your roomboard are not working, so its a wiring issue.

ALSO: The HEX file that is supplied called RoomNode2 is setup to work with the DS18B20 temp sensor.  If you have a room board from JeeLabs and have the SHT11 connected you will need to use THEIR code and compile that up with the right configuration for the sensors you have installed.  Its output is however compatibile with the HAH backend.

Brett

Member for

15 years

tickett

14 years 11 months ago

Thanks for all the help. Pretty much got everything sussed now- to a point where the hah is collecting and posting some data to pachube. Ordered a load more bits from jeelabs and just need to spend some time setting everything up how i want it!

Member for

16 years 10 months

brett

14 years 11 months ago

Good stuff looking forward to reading about your experience in your blog.  Don't go too crazy buying jeenode stuff we aim to have our own boards very soon which should be cheaper than Jee.

Member for

16 years 10 months

brett

14 years 11 months ago

Ineed it should be HAHCentral.hex I've updated the wiki notes.

Brett

PS: If anybody feels the need or wants to get wiki R/W access so they can assist with documentation do let me know  ;)

Member for

15 years

Pentala

14 years 11 months ago

Brett,

Happy to add some of my notes to the Wiki and provide some 'walk-through' type stuff if you like?

Andy

p.s. also interested in the HAHNode HW when it becomes available :-)

Member for

16 years 10 months

brett

14 years 11 months ago

Unforunate the wiki pre-dates the HAH by several years and its a seperate entity.  If you create yourself a username/password I can grant you access to the part of the wiki you'll be able to update.

http://www.dbzoo.com/start?do=register