Digital I/O über Labview ansprechen

      Digital I/O über Labview ansprechen

      Hallo liebes Forum,

      bei meiner Anwendung ist es notwendig die digitalen I/Os anzusprechen. Ich möchte das jedoch über Labview machen.
      Gibt es hierzu schon Erfahrungen?

      I need to access the digital I/O via labview. Is there some experience in this field?

      regards
      Jürgen

      Re: Digital I/O über Labview ansprechen

      Hello,
      i have no experience with LabView, but how do you access a serial port with using LabView? I think IO ports are accessable in the same way.
      F&S Elektronik Systeme GmbH
      As this is an international forum, please try to post in English.
      Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

      Re: Digital I/O über Labview ansprechen

      In Labview mobile Module there are functions for accessing the serial port on a WinCE device. I don't use the device drivers to access the serial port, but to control the GPIO Pins I think I have to use these drivers.

      Has anybody experience with calling the CreateFile WINAPI in labview on a WinCE based device? Maybe this could be a solution...

      Thanks for your help! :-)

      kind regards
      Jürgen

      Re: Digital I/O über Labview ansprechen

      Hello,
      when i understand you right, basically LabView works on the device?
      If yes you should refer to a LabView forum, e.g. labviewforum.de/Forum-LabVIEW-…0&sortby=views&order=desc. I think the members there have more experience how to access HW form LabView.
      Hope this helps.
      F&S Elektronik Systeme GmbH
      As this is an international forum, please try to post in English.
      Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

      Re: Digital I/O über Labview ansprechen

      "fs-support_ZU" wrote:

      Hello,
      when i understand you right, basically LabView works on the device?
      If yes you should refer to a LabView forum, e.g. labviewforum.de/Forum-LabVIEW-…0&sortby=views&order=desc. I think the members there have more experience how to access HW form LabView.
      Hope this helps.

      I run Labview on a PicoCOM1 and also want to access GPIO, I2C and SPI.
      The COM ports are supported by the drivers supplied with the Labview touch panel module, but of course there's no Labview support for the F&S specific drivers.
      However, it is possible to call external code and DLLs from Labview. So to access the F&S drivers, I'd need the DLL files so that Labview can determine the functions and their parameters, and also some documention about these parameters. The parameter functions are described in the driver documentation available as PDFs on the F&S web site, but the variable type notation seems to be a bit Visual Studio specific and is not compatible with the standard Labvies variable types like I32, double, string etc.
      A parameter list with generic parameter types would be very helpful.
      Can this information be supplied by F&S?

      Re: Digital I/O über Labview ansprechen

      Hello,

      F&S does not use "special" functions for access drivers from applications! As API interface for our drivers we use the common windows functions ( like CreateFile, WriteFile, ReadFile, DeviceIOControl, CloseFile, SetFilePointer, ...). So i think there exist already a solution for access the drivers on our boards. Or did i misunderstood something?

      PS: it is also possible to create own DLLs which wrapps the Windows API functions. By the way, you cannot access any driver function from user mode!
      F&S Elektronik Systeme GmbH
      As this is an international forum, please try to post in English.
      Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

      Re: Digital I/O über Labview ansprechen

      "fs-support_ZU" wrote:

      Hello,

      F&S does not use "special" functions for access drivers from applications! As API interface for our drivers we use the common windows functions ( like CreateFile, WriteFile, ReadFile, DeviceIOControl, CloseFile, SetFilePointer, ...). So i think there exist already a solution for access the drivers on our boards. Or did i misunderstood something?

      PS: it is also possible to create own DLLs which wrapps the Windows API functions. By the way, you cannot access any driver function from user mode!


      Thanks for that information.
      I managed to get access to the digital IO and the analog inputs using the standard LabView file functions.
      I didn't test the other drivers (I2C, SPI...) yet, but I'm shure those are accessible the same way.
      So using LabView instead of text based development environments (like Visual Studio) really is an option to produce application software for the F&S boards.
      If anybody is interested, I could supply a sample VI running a loop that sends the lower 4 bits of the loop counter to PC16..19, using PC20..23 as input and displaying the logic level and presenting the AD1 analog input as a chart.

      Re: Digital I/O über Labview ansprechen

      Hello,
      thanks for your update. And yes, i think you are right, I2C, SPI, ... should also work in the same way.
      F&S Elektronik Systeme GmbH
      As this is an international forum, please try to post in English.
      Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

      Re: Digital I/O über Labview ansprechen

      After the first success with file create, read, write and close it came out that I2C etc. is a bit more complicating, as these drivers need access via the DeviceIoControl function, for wich there's no VI in LabView.
      I'm trying to solve this now by a LabView call to the kernel32.dll, which includes Device IoControl. The difficulty still is to allocate the correct LabView variable types to the parameters DeviceIoControl needs. Also LabView seems to need the DLL for reference.
      Is possible to get a copy of the kernel32.dll supplied with the Windows CE core?

      Re: Digital I/O über Labview ansprechen

      Hello,

      you will find the complete describtion of this function on the MSDN (e.g. msdn.microsoft.com/en-us/library/ms898288.aspx). The function is includeed in the cordll.dll (or cordll.lib which you will find under <sdk install dir>\Windows ce Tools\...\lib ).

      Hope this helps.
      F&S Elektronik Systeme GmbH
      As this is an international forum, please try to post in English.
      Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.