[Solved] Something in the code

Hi Guys

Messing around trying to get my location detection code up and running and I'm getting some weird issues.

When I run this applet:

Member for

16 years 10 months

brett

11 years 10 months ago

Gary,

Don't reinitialize XAP inside your applet if integrating with plugboard.  That is going to break things.

    xap.init{instance="Locate", uid="FF00DF00"}

I think I know why you did this.

There are two way to construct the endpoint name for a BscEndpoint.

    bsc.Endpoint{name="home.Hall", direction=bsc.OUTPUT, type=bsc.LEVEL}

That will build this: dbzoo.<hostname>.plugboard:home.Hall

I think what you are trying to do is build this:  dbzoo.<hostname>.Locate:home.Hall

** EDIT - we do support instance.  Don't mix "instance" and "name"  - combine like this **

In which case you should initialize your BSC endpoint like this:

    bsc.Endpoint{instance="Locate:home.Hall", direction=bsc.OUTPUT, type=bsc.LEVEL}

Brett

Member for

16 years 5 months

BodgeIT

11 years 10 months ago

I was only trying to set the "instance names" and use my own uid for 'Locate' so the system would auto select the ids for the devices.

Thanks, modified the code and all well.