Integration mit der dotNET-API Bibliothek Integration mit der dotNET-API Bibliothek | HBM

PMX - Beispiel - Demo - Software für das Lesen und Schreiben von Befehlen und Visualisieren von Messungen in VisualStudio mit der HBM Common - API

Dieses kleine Beispiel zeigt eine einfache Demo-Software für den an einen PC/Laptop mit VisualStudio von Microsoft angeschlossenen Verstärker PMX.

Einführung

Systemvoraussetzungen

Zur Nutzung der aktuellen Version der HBM. API, sollte der verwendete PC folgende minimalen Systemvoraussetzungen erfüllen:

  • Intel Pentium 1 GHz or equivalent processor
  • Windows® XP (32-Bit or 64-Bit), Windows® VistaTM (32-Bit or 64-Bit)or Windows® 7 (32-Bit or 64-Bit)
  • Microsoft Internet Explorer Version 6.0 (or higher)
  • Main memory (RAM)
  • 512 megabytes for Windows® XP
  • 1024 megabytes for Windows® VistaTM and Windows® 7
  • Graphics card with a resolution of 1024 x 768 Pixel
  • approx. 30 megabytes free space on your hard disk
  • Microsoft or 100% compatible mouse
  • Ethernet interface (10/100 MBit) for connecting the devices

Prerequisites to build a program using HBM. API for .Net:

  • Microsoft Windows XP (or later)•Microsoft Visual Studio .Net 2012 (.Net Framework 4.0 or later)
  • HBM DLLs (Hbm.API.Common.dll, Hbm.API.Scan.dll, Hbm.API.SensorDB.dll, VistaDB.4.dll, HBM_Scan.dll, lib_json.dll )
  • DLLs for the HBM-devices you want to use with your program
  • for PMX devices: Hbm.API.PMX.dll

Prerequisites for the use of the HBM. API from within LabVIEW of National Instruments:

  • Microsoft Windows XP (or later)
  • LabVIEW 2009 (or later) •HBM DLLs (Hbm.API.Common.dll, Hbm.API.Scan.dll, Hbm.API.SensorDB.dll, VistaDB.4.dll, HBM_Scan.dll, lib_json.dll )
  • DLLs for the HBM-devices you want to use with your program
  • for PMX devices: Hbm.API.PMX.dll

To distribute your program, that uses functions and data types of the HBM. API, you need to:

  • Install .NET framework 4.0 on the target system
  • Copy the followingHBM DLLs together with your program to the target system:
  • HBM DLLs (Hbm.API.Common.dll, Hbm.API.Scan.dll, Hbm.API.SensorDB.dll, VistaDB.4.dll, HBM_Scan.dll, lib_json.dll )
  • DLLs for the HBM-devices you want to use with your program
  • for PMX devices: HBM.API.PMX.dll

Zum Testen des Programms stellen Sie sicher, dass ein unterstütztes Gerät (z.B. PMX oder jedes QuantumX) korrekt an dasselbe Netzwerk angeschlossen ist wie Ihr PC und dass die Firewall Ihres PCs die Kommunikation mit dem Gerät nicht blockiert.

Starten des Beispiels

Zum Ausführen des Beispiels starten Sie VisualStudio und laden Sie das Projekt “DemoProject.csproj”.

  • Zum Starten des Beispiels drücken Sie die Schaltfläche 
  • Im Beispiel wird über Ethernet (TCP/IP) eine Verbindung zu einem PMX hergestellt. Verwenden Sie dazu die Schaltflächen auf der linken Seite, von "Initialize" bis "Register", "Scan" und "Connect".
  • "Explore" zeigt alle Messkanäle im PMX:

Weitere Funktionen stehen zur Verfügung, z.B. Einzel-oder Dauermessung.

Über die Schaltfläche "Disconnect" kann die Verbindung beendet werden.

Hilfe zu allen in der HBM Common-API unterstützten PMX-Funktionen und Verfahren bietet die CHM-Hilfedatei “CommonDeviceAPI.chm”, die Bestandteil der API ist.

TIPP

Hilfe zu allen in der HBM Common-API unterstützten PMX-Funktionen und Verfahren bietet die CHM-Hilfedatei “CommonDeviceAPI.chm”, die Bestandteil der API ist.

Rechtlicher Hinweis

Das Beispiel soll die Integration von PMX in LabView über den PMX-Befehlssatz veranschaulichen. Mit diesem Beispiel ist kein Anspruch auf Gewährleistung oder Garantie verbunden.