NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to call a function in DLL file, while writing test scripts in ATML standards

Hello all,

 

            I am trying to develop test scripts in ATML standards. I need to call a function in DMM.dll file. How can i do that in ATML standards, please explain with some example ATML standard XML file. Someone please help me in doing so. Thanks a lot in advance.

 

 

With Regards,

kalyan

 

0 Kudos
Message 1 of 8
(4,150 Views)

Hi Kalyan,

For clear understanding of your use case, I request you to clarify the following:
1. By test scripts in ATML standards, do you mean the ATML Test Description (TD) file?
2. Can you give me more information regarding when the function is to be called?

With Best Regards,
Srivinayaka
National Instruments
0 Kudos
Message 2 of 8
(4,117 Views)

Hi srivinayak,

 

                   Yes by the name "Test Scripts in ATML Standards" means ATML TD file. I want to develop test scripts for a UUT. Some voltage is generated by SORENSEN DC powersupply, I need to measure that voltage dynamically in DMM. Thanks a lot for responding.

 

 

 

With Regards,

kalyan

0 Kudos
Message 3 of 8
(4,106 Views)

Hi Kalyan,

Thanks for clarifying on the use case. You can use NI TestStand ATML Toolkit 2010 to translate the ATML TD file to a TestStand sequence file.

There are two ways to achieve the expected behavior based on the application you used to create your dll.

 

  1. If the DMM.dll is generated using the NI's LabWindows CVI application, then set the path of the code module in TestStand (Tools -> Configure ATML TD translator -> Code Module Settings tab -> LabWindows/CVI) to your dll. The main constraint here is that the value of the "name" attribute of the "Action" element in the TD file should be the same as the name of the function that you have in your dll.

  2. If the DMM.dll is not generated using the NI's LabWindows CVI application, translate the ATML TD file in TestStand with code module option (Tools -> Configure ATML TD translator -> Code Module Settings tab) set to LabWindows/CVI. During translation, TestStand generates the CVI code module at the location set in the code module option. You can make the CVI code module call into your dll by either manually editing the code module after the translation or by using the custom code generator feature of the ATML Toolkit to get it done during the translation process.

 

With Best Regards,
Srivinayaka
National Instruments
0 Kudos
Message 4 of 8
(4,098 Views)

Hi srivinayak,

 

                   Thanks a lot for your reply. It is really a helpful solution. As per your solution we can call functions of the same dll which we have specified in the code module settings. But according to my requirement i need to work on two or more instruments in the same test script, then how can we call two or more dll's in the same test script. Please give corresponding solution to my requirement. Once again thanks for responding.

 

 

Thanking you,

 

 

With Best Regards,

Kalyan 

0 Kudos
Message 5 of 8
(4,078 Views)

Hi Kalyan,

 

               In case you need to call functions from different dlls, you can use the solution 2 mentioned in my previous reply. Solution 2 works in case of single or multiple dlls irrespective of whether or not the NI's LabWindows CVI application was used to create the dlls.

With Best Regards,
Srivinayaka
National Instruments
0 Kudos
Message 6 of 8
(4,074 Views)

Hi srivinayaka,

 

                     I am attaching the XML file i have written in ATML standards and the Labwindows/CVI code that was generated when the XML file is opened in TESTSAND. actually the defenition of the function "IALdcpwr_reset()" is in IALdcpwr.lib and IALdcpwr.h files.

"How can we add this library and header files?" so that i can show the path of definition. whether it should be done manually or can we do some changes in the XML file and make the work done?. Thanks in advance. If you have any example for this type of sequences. please forward me which would be helpful for me.

 

With best regards,

kalyan

Download All
0 Kudos
Message 7 of 8
(4,038 Views)

Hi srivinaya,

 

               In my last post i have attached only the XML file. sorry for that. please find the Attachment of generated Labwindows/CVI code.

 

 

with best regards,

kalyan

0 Kudos
Message 8 of 8
(4,037 Views)