Drivers/Managers connectivity status

Find and share HowTos to various installations / configurations!
Search

Post Reply
22 posts • Page 2 of 3
User avatar
leoknipp
Posts: 2846
Joined: Tue Aug 24, 2010 7:28 pm

Re: Drivers/Managers connectivity status

Post by leoknipp »

If the _DriverCommon datapoint does not exist you get errors in the PVSS_II.log file when starting the project.
The driver itself writes the information to the DP element if the datapoint exists.

There is no need to use the Access Control Plug In.
You can simply connect to the elements of the _Connections datapoint to check which drivers are running.
If the list of driver changes you can check if the _DriverCommon datapoints exist. If not, the datapoint can be created and via the DP element _Managers.Exit a restart of the driver can be initiated.

Best Regards
Leopold Knipp
Senior Support Specialist

tpjctrl
Posts: 141
Joined: Tue May 08, 2018 10:30 am

Re: Drivers/Managers connectivity status

Post by tpjctrl »

Wouldn't it be easier for the script which attempts a write into the _Driver# dp to check if the dp exists and if not, to simply create the dp? That would then remove the need for additional scripts to monitor connected drivers and having to restart them when _Driver# dps are created.

User avatar
leoknipp
Posts: 2846
Joined: Tue Aug 24, 2010 7:28 pm

Re: Drivers/Managers connectivity status

Post by leoknipp »

As written in the previous posting the driver itself writes the DP element. There is no script running which sets the elements of the _DriverCommon datapoint.

Best Regards
Leopold Knipp
Senior Support Specialist

tpjctrl
Posts: 141
Joined: Tue May 08, 2018 10:30 am

Re: Drivers/Managers connectivity status

Post by tpjctrl »

Are the drivers not capable of checking if the dps exist / creating dps? are they not just chunks of code?

dbindernagel
Posts: 151
Joined: Mon Feb 23, 2015 1:34 pm

Re: Drivers/Managers connectivity status

Post by dbindernagel »

Can't you just simply create as many _DriverCommon datapoints as you will need beforehand?

User avatar
kilianvp
Posts: 422
Joined: Fri Jan 16, 2015 10:29 am

Re: Drivers/Managers connectivity status

Post by kilianvp »

You get a warning in the logviewer if the DP doesn't exists.

dbindernagel
Posts: 151
Joined: Mon Feb 23, 2015 1:34 pm

Re: Drivers/Managers connectivity status

Post by dbindernagel »

What I mean is just create the datapoints at the beginning.

Apparantly drivers are added to this project dynamically. If the max amount is known beforehand (e.g. 20) than you can just create _Driver_1 to _Driver_20. Exactly the way an empty project comes with _Driver_1 to _Driver_3 already, even if they are not used.

This is way better than to create an API manager or use the some scripting to create the datapoints on demand. This creates just a bunch of code that needs to be managed, tested, and probably still could fail.

It's not like creating these datapoints in advance is slowing down the system or anything.

tpjctrl
Posts: 141
Joined: Tue May 08, 2018 10:30 am

Re: Drivers/Managers connectivity status

Post by tpjctrl »

dbindernagel wrote: Mon Sep 11, 2023 1:25 pm Can't you just simply create as many _DriverCommon datapoints as you will need beforehand?
I'm just not a fan of creating 20 dps when all you need is 4 and it would be much easier if the drivers "made" the dps themselves.

And btw it's not even for drivers created on the fly, it's more when you need to "expand" the project and simply add an extra driver which might not necessarily have the next free number, sometimes you just throw in a num 10 driver for testing purposes and then it turns out the dps don't exist (and it's not just this particular _Driver# dp, you need other dps for which you get errors in the log if they don't exist).

dbindernagel
Posts: 151
Joined: Mon Feb 23, 2015 1:34 pm

Re: Drivers/Managers connectivity status

Post by dbindernagel »

Ah, yes. I completely agree with that; same for Ui and control debugging.

User avatar
kilianvp
Posts: 422
Joined: Fri Jan 16, 2015 10:29 am

Re: Drivers/Managers connectivity status

Post by kilianvp »

I agree and the Ui DP is especially bad because a new UI won't start if the DP doesn't exist.

Post Reply
22 posts • Page 2 of 3