Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
4.4 Beta Discussion Thread
#21
OK, I took a look at it, and adding latching for expression based field triggers was actually quite easy and safe. It was all very self contained and easy to do without affecting anything else. If I'd realized it was going to be that easy I'd have done it long ago. I'll go ahead and get a drop out with this new feature so that folks can really make use of the new logic server field for all the things that this is important for.
Dean Roddey
Explorans limites defectum
#22
I also added a 'select field value' button to the field trigger dialog, similar to that in the command editor, to allow you to select the comparison value for expression based field triggers graphically. And I added support to that little graphical field value getter system for Time based fields. So if it's a time based field, it'll present you with three spin boxes, for hours, minutes, and seconds. Just spin them to the desired values and it'll insert the calculated 100-ns value for you. That'll be there in the command editor as well of course since it uses the same system. It also parses the incoming value and sets up the spin boxes with correct initial values, though it may fail to get the initial value if it is in hex and doesn't have the 0x prefix, though that should be the case. If not, once you set it up and insert the value it'll add the prefix correctly when it inserts it.
Dean Roddey
Explorans limites defectum
#23
OK, give .907 a try. It now has the latched field triggers.
Dean Roddey
Explorans limites defectum
#24
And another day of SIP study today. I read through the application user docs of some other SIP stacks, to see how they expose their functionality to the application and how they generally structure themselves. That provided me with a lot of insight and ideas. Some of those ideas imply doing a good bit more grunt work code before getting to the meat of the matter, but I ain't scared of no grunt work code particularly.
Dean Roddey
Explorans limites defectum
#25
Dean Roddey Wrote:There is a driver backdoor command to manually reset non-auto-reset fields, if you need to set one back.

Hi Dean, I've loaded up .907 and playing with the latching trigger and Logic server timer stuff. Very useful. Also nice to be able to just select hours/mins/secs within the triggers vs converting to hex manually.

One question tough. How do I go about sending a backdoor command to the logic server to reset the non-autoreset timer? Something like:
Devices::SendDrvCmd
P1=LogicServer
P2=$(LogicServer.FrontDoorTimer)
P3=0

This doesn't quite work. What's the proper syntax for this guy?

Thanks
#26
You want to send the actual field name, not the value in the field. And you only need the name part of it, not the moniker, since you are already sending the command to the logic server anyway. So it knows you are referring to its own fields. So just pass FrontDoorTimer instead.
Dean Roddey
Explorans limites defectum
#27
Dean Roddey Wrote:You want to send the actual field name, not the value in the field. And you only need the name part of it, not the moniker, since you are already sending the command to the logic server anyway. So it knows you are referring to its own fields. So just pass FrontDoorTimer instead.


Still having some trouble. So I did this now:
Devices::SendDrvCmd
P1=LogicServer
P2=FrontDoorTimer
P3=0

I assume I have the P1,P2 fields correct so will explain a litle more what I'm doing to make sure its valid.

When my front door opens it starts the logicserver timer counting up(auto reset timer). This all works fine. I trigger on this timer at 30secs (with a latch enabled). The trigger is firing too and running logic.

Within the triggered logic my hope is that while the timer is still counting up I can send the SendDrvCmd and reset the timer back to 0. Since the door would still be open the counter would start counting up again from 0 and trigger again after 30 secs. In this way I get a door open message every 30secs until the door is closed. Would this work like this if I figure out how to reset the timer? Do I send a 0 in P3 to reset the timer?

Thanks
#28
Actually, P1 should be ResetElapsedTmFld, which tells it what to do. P2 tells it what to do it to. I may have failed to document that correctly in the release notes. I'll update it if so.

It will reset it to zero, whether it's auto reset or manual reset. And yeh, if the door is still open, it'll start counting again from zero right away.
Dean Roddey
Explorans limites defectum
#29
Dean Roddey Wrote:Actually, P1 should be ResetElapsedTmFld, which tells it what to do. P2 tells it what to do it to. I may have failed to document that correctly in the release notes. I'll update it if so.

I'm really struggling with this one for some reason :-)

Assume you meant P3 (not P1) should be ResetElapsedTmFld correct?

I've now tried
SendDrvCmd (Moniker,id,value) as:
P1=LogicServer (The name of my logicserver driver)
P2=FrontDoorTimer (the name of the timer to reset in the logic server)
P3=ResetElapsedTmFld (what to do)

Do I now have the syntax correct? I'm doing this via a button to test vs in the events server, but assume it would still work.

Here's what I get back in the trace:

----------------------------------------------------------
TRC: Start Action

CMD: 001. (1ms) - Devices::SendDrvCmd
P1=LogicServer
P2=FrontDoorTimer
P3=ResetElapsedTmFld

TRC: End Action [Result=Success]


But the timer doesn't seem to go back to 0. Am I still missing something?

Also, when you said release notes are you talking about what you post in the Beta thread or is there somewhere else I could read up on this?
#30
Sorry, I was low on blood sugar there... Yeh, it should be the moniker, then the command (ResetElapsedTmFld), then the name of the field. I was thinking about it from the driver's perspective, where the moniker is not one of the parameters.
Dean Roddey
Explorans limites defectum


Possibly Related Threads...
Thread Author Replies Views Last Post
  Official 5.4 Beta Discussion Thread Dean Roddey 441 41,755 06-15-2019, 02:33 AM
Last Post: Bugman
  Official 5.4 Beta Release Thread Dean Roddey 55 7,324 06-07-2019, 07:02 PM
Last Post: Dean Roddey
  Official 5.3 Beta Discussion Thread Dean Roddey 815 151,300 07-05-2018, 12:44 PM
Last Post: Dean Roddey
  Official 5.3 Release Thread Dean Roddey 27 7,910 07-05-2018, 12:44 PM
Last Post: Dean Roddey
  Official 5.2 Beta Discussion Thread Dean Roddey 244 87,644 10-14-2017, 07:57 PM
Last Post: Dean Roddey
  Official 5.2 Beta Release Thread Dean Roddey 13 8,804 10-09-2017, 06:49 PM
Last Post: Dean Roddey
  Official 5.1 Beta Discussion Thread Dean Roddey 453 197,132 05-16-2017, 03:45 PM
Last Post: Dean Roddey
  Official 5.1 Beta Release Thread Dean Roddey 28 19,502 05-12-2017, 05:44 PM
Last Post: Dean Roddey
  Official 5.0 Beta Discussions Dean Roddey 2,019 489,144 11-09-2016, 04:34 PM
Last Post: Dean Roddey
  Official 5.0 Beta Release Thread Dean Roddey 15 13,314 11-01-2016, 10:32 AM
Last Post: Dean Roddey

Forum Jump:


Users browsing this thread: 1 Guest(s)