Send commands to Axum/mambanet

In the last snapshot I see ‘mambanet sensor’… Wow :slight_smile:

Looks like you created this. Tnx

But, after installing the snapshot, I stil only see the actuators, and nothing changed in the mambanet remote settings.

Do I have to do some magic to make it visible, or is there another way(place) to use the mambanet sensors?

I’m super excited about snapshot Build 4455:
Mambanet: added state sensor and scripting support.

If anyone can point me in the right direction where I can find/activate this? I’m willing to make a nice how-to for other D&R mambanet users.

I couldn’t see the mambanet remote before in my license. Maybe that’s the problem?

I added the MambaNetRemote function and the SetSensor method of IMambaNetRemote which you use like this:

MambaNetRemote(0).SetSensor(1, true);

Sensors range from 1…64 (I believe you should see them in the MambaNet environment somewhere), and values are true or false.

Now you can go on and create a background script that uses OnCartwallPlayerStateChange etc. and sets the sensor values accordingly.

Thanks Torben!

I’m not sure where to put those scripts.
Can anyone point me to the right wiki?

I hope the ‘mairlist surface’ in axum will also recognize the ‘new’ sensors.

Has anyone tested this?
I’m happy the be tester and documenter, but I need some help where to look/ test.

I found out where to put the background scripting…

But the sensors are not visible in Axum/mambanet.
I guess they need to be created/addressed by mAirlist the same way the actuators are addressed.
Somewhere mairlist tells there are 64 actuators. At the same way mairlist should tell there are 64 sensors I guess.

I’m sure a d&r technical genius can tell you more.
But at this moment axum/mambanet isnt aware that a script van send sensor signals. So nothing can be set at the Axum side. :frowning:

1 Like

Maybe this can help?

Got an error:
Runtime error “List index out of bounds (5198049)” in background script D:(…)\mambanet-stopplayers.mls, handling message: PLAYERCONTROL_STOP 7CD1F4A2735A1531 00 00000000 00000001 244,875 ?

Which build are you running now? The sensors should be visible in any case, regardless of whether you have a script that “brings them to life” or not.

Disclaimer: I only implemented it according to the docs. Have been trying to obtain a demo unit from D&R to no avail.

Hi Torben,

I’m using 6.3.15 Build 4455

When I look in the AXUM config:
Axum » Console 1-4 configuration » Surface configuration » Node ‘Mairlist’
I only see Command0 to Command63 Type A

Connected by UDP to the IP of the Axum.
So If I should see the Type S commands over there, something seems not working.

As the official D&R Aircast developer, you should expect a testing posibility provided by D&R…
For now I will keep trying/testing.

[+] MambaNet: Added state sensor and scripting support

And… Jorik, getting along with this ?

Long story short: it doesn’t work yet. Torben will test it, and debug But he needs the hardware to do a proper test. D&R is also supporting, so it’s a matter of time now.

That’s what we wait for. Would be a delight when it works… I’ll keep you posted.

Ok, invested some time to check this again. I originally implemented the sensors as parts of the existing actuator objects, e.g. combined actuator/sensor objects. Which is allowed according to the documentation, there is even an example for it

Anyway, I changed it now so that the sensors are separate objects. There should now be a total of 128 objects, 64 actutators and 64 sensors.

This is in the latest snapshot 4459, can you please have a look?

Disclaimer: I had to change the code quite a bit, hope I didn’t break anything regarding the (working) actuators, so be prepared to downgrade if there is an issue. As you know, I am unable to test it here.

1 Like

Thank you. I will try the lastest snapshot and will let you know

Do you have any instructions? Should I reload or do anything?
I installed the snapshot. And can’t see sensors yet. Not in mairlist remote settings, nor in axum node.

Do I need te reinstall the remote?
Maybe a restart of the axum?
I’ll try. (But its an active studio).

   Error (de-)activating object "D&R AXUM (MambaNet)": mbnInit: This library has been built to only allow ManufacturerID 8

and after creating en NEW mambanet remote I get error:

   Error (de-)activating object "D&R AXUM (MambaNet)": Access violation at address 6FF5315E in module 'mbn.dll'. Write of address 6FF5D5E0

Oops, I think I removed something accidentally :wink: Try build 4462 now please.

Yes! now I see the sensors in het mairlist node in axum!

I guess I now need to send signals by a script. I tweaked a code I have found.

Do You think this should work to send a signal when the player stops ?

procedure OnPlayerStop(PlaylistIndex: integer; PlayerIndex: integer; Duration: TTimeValue);
var
i : integer;
begin
if (PlaylistIndex= 0) and (PlayerIndex= 1) and (CurrentPlaybackControl.GetAutomation = false) then begin
MambaNetRemote(0).SetSensor(1, false);
end;
if (PlaylistIndex= 0) and (PlayerIndex= 2) and (CurrentPlaybackControl.GetAutomation = false) then begin
MambaNetRemote(0).SetSensor(2, false);
end;

Well, now here comes my general lack of knowledge of the MambaNet system…

I assume the sensors are “tally”, which means that you will have to set them to true when the player starts, and to false when it stops again.

Oh, I just wondered If you think this code should send the commands. I can set a action for each sensor true/false in the axum/axite settings.

The code you posted sets the sensors to false when the players stop. But never sets them to true on start in the first place. That was my point :wink:

I got this error

17-1-2022 10:44:27 Fout Runtime error “List index out of bounds (5198049)” in background script D:\stopplayers.mls, handling message: PLAYERCONTROL_STOP 089CCFC8487770EA 00 00000001 00000000 3,968 ?