Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Using Drivers within CML Macro
#1
How do I use other drivers from within a macro? For example, I'm using a V2 driver for my AVR. How do I create an object for this AVR driver within my new macro and use its methods?
Reply
#2
(01-01-2017, 09:15 AM)Jnetto Wrote: How do I use other drivers from within a macro? For example, I'm using a V2 driver for my AVR. How do I create an object for this AVR driver within my new macro and use its methods?

You have to use the SimpleFldClient object. To access it via the field interface.

SimpleFldClient m_fldClient;  

strValue := m_fldClient.ReadField(strMoniker, strField);
m_fldClient.WriteField(strMoniker, strWriteField, strWriteVal);

There is also a backdoor way to call drivers with that same object if you have implemented them into the AVR driver. (QueryData/SendDrvCmd) But IMHO anything useful should be exposed as a field so users can call it as well and it is self documenting. Backdoor stuff needs to be documented separately, they will not show up in any of the client interfaces so no one knows they are there without looking at the driver code. I think probably they are most used for more dynamic ways of passing data, since fields have to be registered when the driver loads.
Wuench
My Home Theater/Automation Website

[THREAD=5957]BlueGlass CQC Config[/THREAD]
[THREAD=10624]Wuench's CQC Drivers[/THREAD]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Weather Drivers simplextech 10 3,314 01-05-2020, 10:51 AM
Last Post: simplextech
  Edit Macro Parameters Jnetto 5 4,264 01-02-2017, 11:22 AM
Last Post: Dean Roddey
  Drivers for new equipment George M 10 6,590 12-17-2016, 07:36 AM
Last Post: Mark Stega
  Non-Shipped Drivers Links Dean Roddey 6 9,333 01-09-2016, 10:42 AM
Last Post: Dean Roddey
  Wuench's Drivers wuench 3 11,989 06-09-2014, 02:44 PM
Last Post: Dean Roddey
  Lighting IP Drivers willplaice 3 4,167 04-27-2013, 02:30 AM
Last Post: znelbok
  Any drivers need to be added/updated for 4.2? Dean Roddey 8 6,108 08-01-2012, 10:01 AM
Last Post: Dean Roddey
  Can a CML macro be called in PDL? zpollock 7 5,395 04-13-2010, 06:41 AM
Last Post: zpollock
  Any PTZ Drivers In Existence? zpollock 0 3,396 11-03-2009, 11:37 AM
Last Post: zpollock
  Drivers in Progress Discussion IVB 296 108,316 04-14-2009, 10:08 AM
Last Post: Dean Roddey

Forum Jump:


Users browsing this thread: 1 Guest(s)