HGF Base Class Library and Design Patterns

I started a project to create a LVOOP base class library that can serve as a base for LVOOP projects. HGF is an abbreviation for Helmholz, GSI, FAIR. The sources are published with GNU Public License (GPL).

Publications

  • H. Brand, “Object oriented programming with LabVIEW”, SEI-Herbsttagung 2008, HMI-B623 Berlin, Dez. 2008, Seiten 217–256, ISSN-0936-0891
    HGF_BaseClasses.ppt: Introductory talk to the HGF Base Class library.
  • H. Brand, D.Beck, “The HGF Base Class Library based on LVOOP”, GSI Scientific Report 2008, page 260, ISSN: 0174-0814, GSI-Report-2009-1
  • H.Brand, D. Beck, F.Berck Machbarkeitsstudie: LVOOP basiertes Agenten-System erschienen in "Virtuelle Instrumente in der Praxis - Begleitband zum Kongress VIP 2009", Rahman Jamal, Hans Jascchinski (Hrsg.), Hüthig Verlag, ISBN 978-3-7785-4057-2
  • F.Berck, H.Brand Prototyp für ein mobiles Agentensystem in LVOOP erschienen in "Virtuelle Instrumente in der Praxis 2010 - Begleitband zum 15. VIP-Kongress", Rahman Jamal, Ronald Heinze (Hrsg.), VDE Verlag, ISBN 978-3-8007-3235-7

Sources

Sources under development are available in our Subversion repository
  • HGF_Classes.lvproj in LVSCC\LVxxx\GPL\lib.lib\LVOOP.
  • HGF_DesignPatterns.lvproj in LVSCC\LVxxx\GPL\lib.lib\LVOOP\HGF_DesignPatterns
  • HB_BaseClass_Test.lvproj in LVSCC\LVxxx\GPL\User\Brand\HGF_DesignPatterns.
  • Source snapshots:
    • LabVIEW 8.6.1
      • The snapshot HB_BaseClasses_V0_8.zip includes HGF base class library, design patterns and test project for download. The NI Instrument Simulator device driver project style library is already included.
      • This snapshot is monolitic and you need to install all necessary drivers and LabVIEW Modules to avoid problems.
    • LabVIEW 2009 SP1 (SVN6384)
      • HGF_BaseClasses.zip: This zip-file contains the HGF LVOOP base classes.
      • HB_BaseClass_Examples.zip: This zip-file contains classes and demo VIs illustrating the application of HGF_LVC library and corresponding design patterns.
      • HGF_GPG.zip: This zip-file contains the HGF GPG base classes.
      • HGF_SharedVariable.zip: This zip-file contains classes to interface to Shared Variables.
      • VISA required
        • HB_Device_Exampless.zip: This zip-file contains classes and demo VIs illustrating the application of HGF_LVC library using the NI Instrument Simulator.
      • IMAQ and IMAQdx required
        • HGF_IMAQ.zip: This zip-file contains classes to access cameras via NI-IMAQ or NI-IMAQdx.
        • HB_IMAQ_Exampless.zip: This zip-file contains classes and demo VIs illustrating the application of HGF_LVC library and HGF_IMAQ classes.
      • LabVIEW StateChart Module and VISA required
        • HGF_DeviceFSMs.zip: This zip-file contains classes to drive stationary device agents by using the StateChart Module.
      • LabVIEW DSC required
      • DIM required
        • HGF_DIM.zip: This zip-file contains classes to interface to DIM.
        • HB_DIM_Examples.zip: This zip-file contains classes and demo VIs illustrating the application of HGF_BaseClasses library using DIM as network communication layer.
      • LabVIEW StateChart Module, VISA and DIM required
        • HB_DIM_DFSM_Device_Exampless.zip: This zip-file contains classes and demo VIs illustrating the implementation of an stationary device agent using the HGF_BaseClasses library using the NI Instrument Simulator and DIM.

We will start to evaluate options for an successor for the CS Framework based on this base classes library.

Following design patterns and base classes are already available.

HGF Design Patterns

HGF Base Class Hierarchy

Following picture shows the HGF Base Class Library. The classes in red/yellow belong to the HB_BaseClass_Test.lvproj.

HGF Class Hierarchy

  • HGF_Reference, can be used to treat objects as entities.
  • HGF_Factory, can be used to create initialized named objects dynamically fron class name. Refer to http://en.wikipedia.org/wiki/Abstract_factory_pattern for explanation.
  • HGF_Base, base class for all HGF classes. It provides some basic attributes, which are usefull for all HGF classes.
  • HGF_Event, base class for event handling, Children:
    • Internal events
      • HGF_WaitMultiple and HGF_Wait and HGF_Rendezvous
    • Triggered events
      • HGF_Occurrence, HGF_Notifier and HGF_Queue
    • Network events
      • HGF_DIMEvent, HGF_SVEvent (Shared Variable)
  • HGF_Visitor can perform actions on a HGF_Visitable object. Refer to http://en.wikipedia.org/wiki/Visitor_pattern for explanation.
  • HGF_FGV is an object oriented Functional Global Variable. Several HGF_FGV_Action classes are provided to access the objects in a FGV instance or to send a HGF_Visitor to them.
  • HGF_Composite consisting of HGF_Component and HGF_Leaf. Refer to http://en.wikipedia.org/wiki/Composite_pattern for explanation.
  • HGF_ThreadPool starts the HGF_Worker threads. They can be visited by a HGF_Task . Refer to http://en.wikipedia.org/wiki/Thread_pool_pattern for explanation.
    Recommended further reading:
  • HGF_DeviceBase and HGF_VISADevice inheriting from HGF_Visitable. They are the base class for devices. Also some HGF_DeviceVisitor classes are already exisiting.
  • Device Agent: To implement this pattern one additional Task has been developed, HGF_TaskDFSM derived from HGF_Task, that drives the Device Finite State Machine HGF_DeviceFSM.lvsc which defines the behavior. The State Chart defining the behavior of the HGF_DeviceAgent is shown in the following picture:
    State Chart defining the behavior of the HGF_DeviceAgent

Following picture contains a part of the HGF Class Library created with the Endevo UML Modeller:
Part of the HGF Class Library created with the Endevo UML Modeller

-- HolgerBrand - 29 Oct 2010
I Attachment Action Size Date Who Comment
HB_BaseClass_Examples.zipzip HB_BaseClass_Examples.zip manage 563 K 2010-11-01 - 12:22 HolgerBrand This zip-file contains classes and demo VIs illustrating the application of HGF_BaseClasses library and corresponding design patterns for LabVIEW 2009 SP1 (SVN6384)
HB_BaseClasses_V0_6.zipzip HB_BaseClasses_V0_6.zip manage 6 MB 2008-06-10 - 07:59 HolgerBrand LV 8.5.1HGF Base Class Library, Design Patterns and Test Project
HB_BaseClasses_V0_7.zipzip HB_BaseClasses_V0_7.zip manage 7 MB 2009-01-21 - 10:17 HolgerBrand LV 8.6 HGF Base Class Library, Design Patterns and Test Project
HB_BaseClasses_V0_8.zipzip HB_BaseClasses_V0_8.zip manage 8 MB 2009-06-25 - 15:32 HolgerBrand LV 8.6.1 HGF Base Class Library, Design Patterns and Test Project including Device Agent and HGF_IMAQ classes in development status
HB_DIM_DFSM_Device_Exampless.zipzip HB_DIM_DFSM_Device_Exampless.zip manage 145 K 2010-11-01 - 12:23 HolgerBrand This zip-file contains classes and demo VIs illustrating the implementation of an stationary device agent using the HGF_BaseClasses library using the NI Instrument Simulator and DIM for LabVIEW 2009 SP1 (SVN6384)
HB_DIM_Examples.zipzip HB_DIM_Examples.zip manage 106 K 2010-11-01 - 12:22 HolgerBrand This zip-file contains classes and demo VIs illustrating the application of HGF_BaseClasses library using DIM as network communication layer for LabVIEW 2009 SP1 (SVN6384)
HB_Device_Exampless.zipzip HB_Device_Exampless.zip manage 632 K 2010-11-01 - 12:22 HolgerBrand This zip-file contains classes and demo VIs illustrating the application of HGF_LVC library using the NI Instrument Simulator for LabVIEW 2009 SP1 (SVN6384)
HB_IMAQ_Exampless.zipzip HB_IMAQ_Exampless.zip manage 184 K 2010-11-01 - 12:23 HolgerBrand This zip-file contains classes and demo VIs illustrating the application of HGF_LVC library and HGF_IMAQ classes for for LabVIEW 2009 SP1 (SVN6384)
HB_PollingAgent.zipzip HB_PollingAgent.zip manage 123 K 2010-11-01 - 12:24 HolgerBrand This zip-file contains an example for a Mobile Agent class for for LabVIEW 2009 SP1 (SVN6384)
HB_VIP_2009_mit_Bild.pdfpdf HB_VIP_2009_mit_Bild.pdf manage 148 K 2009-10-27 - 08:48 HolgerBrand H.Brand, D. Beck, "Machbarkeitsstudie: LVOOP basiertes Agenten-System", in "Virtuelle Instrumente in der Praxis - Begleitband zum Kongress VIP 2009", Rahman Jamal, Hans Jascchinski (Hrsg.), Hüthig Verlag, ISBN 978-3-7785-4057-2
HGF_BaseClasses.pptppt HGF_BaseClasses.ppt manage 4 MB 2009-03-31 - 08:43 HolgerBrand Introductory talk to the HGF Base Class library
HGF_BaseClasses.zipzip HGF_BaseClasses.zip manage 3 MB 2010-11-01 - 09:49 HolgerBrand This zip-file contains the HGF LVOOP base classes for LabVIEW 2009 SP1 (SVN6384)
HGF_DIM.zipzip HGF_DIM.zip manage 319 K 2010-11-01 - 09:50 HolgerBrand This zip-file contains classes to interface to DIM for for LabVIEW 2009 SP1 (SVN6384)
HGF_DSC.zipzip HGF_DSC.zip manage 662 K 2010-11-01 - 09:51 HolgerBrand This zip-file contains classes to access Shared Variables via DSC Module (Data Logging and Supervisory Control) for LabVIEW 2009 SP1 (SVN6384)
HGF_DeviceFSMs.zipzip HGF_DeviceFSMs.zip manage 935 K 2010-11-01 - 09:50 HolgerBrand This zip-file contains classes to drive stationary device agents by using the StateChart Module for LabVIEW 2009 SP1 (SVN6384)
HGF_GPG.zipzip HGF_GPG.zip manage 501 K 2010-11-01 - 09:49 HolgerBrand This zip-file contains the HGF GPG base classes for LabVIEW 2009 SP1 (SVN6384)
HGF_IMAQ.zipzip HGF_IMAQ.zip manage 5 MB 2010-11-01 - 09:51 HolgerBrand This zip-file contains classes to access cameras via NI-IMAQ or NI-IMAQdx for for LabVIEW 2009 SP1 (SVN6384)
HGF_MobileAgent.zipzip HGF_MobileAgent.zip manage 2 MB 2010-11-01 - 12:24 HolgerBrand This zip-file contains the HGF MoAgSy_Base classes for LabVIEW 2009 SP1 (SVN6384)
HGF_SharedVariable.zipzip HGF_SharedVariable.zip manage 956 K 2010-11-01 - 09:51 HolgerBrand This zip-file contains classes to interface to Shared Variables for LabVIEW 2009 SP1 (SVN6384)
HGF_Singleton.zipzip HGF_Singleton.zip manage 89 K 2010-11-01 - 13:04 HolgerBrand This zip-file contains the HGF_Singleton pattern example for LabVIEW 2009 SP1 (SVN6384)
VIP2010.pdfpdf VIP2010.pdf manage 159 K 2010-11-01 - 13:40 HolgerBrand F.Berck, H.Brand "Prototyp für ein mobiles Agentensystem in LVOOP" erschienen in "Virtuelle Instrumente in der Praxis 2010 - Begleitband zum 15. VIP-Kongress", Rahman Jamal, Ronald Heinze (Hrsg.), VDE Verlag, ISBN 978-3-8007-3235-7
VIP2010Vortragpub.pptppt VIP2010Vortragpub.ppt manage 1 MB 2010-11-01 - 13:53 HolgerBrand F.Berck, H.Brand "Prototyp für ein mobiles Agentensystem in LVOOP" Vortrag zum Beitrag in "Virtuelle Instrumente in der Praxis 2010 - Begleitband zum 15. VIP-Kongress", Rahman Jamal, Ronald Heinze (Hrsg.), VDE Verlag, ISBN 978-3-8007-3235-7
VIPBeitrag2010.pdfpdf VIPBeitrag2010.pdf manage 63 K 2011-01-26 - 16:00 HolgerBrand F.Berck, H.Brand
Topic revision: r35 - 2011-06-16, HolgerBrand
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding GSI Wiki? Send feedback | Legal notice | Privacy Policy (german)