Obtain process model name in CVI

How can I get the name of the process model in CVI?
The process model is switched between sequential and batch model and need to obtain the name of the currently used process model.
In the fiunction
CVIVALLBACK ApplicationMgr_OnStartExecution(
CAObjHandle caServerObjHandle, void* caCallBackData, TSUIObj_Execution execution, TSUIObj_Thread thread, VBOOL initiallyHidden)
CAObjHandle processModelSeqFileName;
char *processModelName = {0};
tsErrChk( TS_ExecutionGetModelSequenceFile (gMainWindow.engine, &errorInfo, &processModelSeqFileName));
tsErrChk( TS_SequenceGetName (processModelSeqFileName, &errorInfo, &processModelName));
if(processModelSeqFileName)
CA_DiscardObjHandle(processModelSeqFileName);
CA_FreeMemory(processModelName);
The function TS_ExecutionGetModelSequenceFile () returns "No such interface supported"?
TIA.
CLD,CTD

Here are the changes made that got rid of the error but still does not get the process model path. processModelName in TS_SeqFileGetModelSeqFile returns "none" always and SeqFileObject is zero, any ideas?
if(execution)
tsErrChk( TS_ExecutionGetModelSequenceFile (execution, &errorInfo, &processModelSeqFileHdl));
if( processModelSeqFileHdl )
tsErrChk( TS_SeqFileGetModelSeqFile (processModelSeqFileHdl, &errorInfo, &processModelName, &SeqFileObject ));
if( SeqFileObject )
tsErrChk( TS_SeqFileGetModelPath (SeqFileObject, &errorInfo, &processModelPath));
CLD,CTD

Similar Messages

  • Get running process model name

    Hi,
    I'd like to test during the execution of my sequence
    1) If there is a process model which has launched the sequence
    2) The name of the process model which has been launched
    Does someone knows the sentence ??
    Cause i've tried this in a "if" step and it doesn't seem to work properly :
    RunState.IsProcessModel && RunState.Execution.GetModelSequenceFile().AsPropertyObject().Name == "Single Pass"
    Solved!
    Go to Solution.

    HI Nanor,
    you should try this:
    .... && StrComp(RunState.Execution.GetModelSequenceFile().AsPropertyObject().Name, "Single Pass") == 0 
    Hope this helps
    juergen
    =s=i=g=n=a=t=u=r=e= Click on the Star and see what happens :-) =s=i=g=n=a=t=u=r=e=

  • Finding the name of my teststand sequence in the process model

    I would like to be able to find the file path and name of a teststand sequence in the process model. I have created a simple vi which will display this information when run in a sequence. If i insert the vi into the process model, the file path and name returned is that of the process model and not the sequence under exectution. Is there a way of extracting this information in the process model?

    Davepar -
    If you are executing in the process model you can use the following as a lookup string if you are in the root context "RunState.ProcessModelClient.Path" or "RunState.Root.RunState.ProcessModelClient.Path" if you are not in the root context.
    Scott Richardson (NI)
    Scott Richardson
    National Instruments

  • Add serial number in the report file name when using batch process model

        I would like to append a string containing the current UUT serial number to the base name of the report file. For example, uut_report.html becomes uut_report[SN000001].html. This setting is not available if I use NI BatchModel.seq as my process model.
    Thanks!
    Jacky

    duplicate post
    Ask your question only once.

  • Getting sequence filename and sequence name in process model error handler

    We are using the sequential process model and would like to log sequence step error information to a file.  We have an Error Handler callback in SequentialModel.seq and that is where we will write to the error file.  In the Error Handler callback, I can get the error container info for the step where the error occurs and the name of the that step thru the Error Handler Step parameter.  I would also like to record the sequence file and the sequence where the error occurred, but I have not been able to find those in the sequence context.  I know they are available because the TestStand RunTime Error dialog box displays them.  How can I access the name of the sequence file and the name of the sequence where the error occurred?
    Thanks,
    Hans

    Hey hans,
    Use the API.  Since you already have the Step object reference coming in as a parameter you can just use a few ActiveX steps to get the Sequence File and Sequence from which the error was thrown.
    Step.Sequence
    Sequence.Name (gets the name of the sequence)
    Sequence.SequenceFile
    SequenceFile.Path (gets the path of the sequence file)
    So basically just 4 activex steps.  I hope this helps.
    Regards,
    jigg
    CTA, CLA
    teststandhelp.com
    ~Will work for kudos and/or BBQ~

  • What property is the current step name in MainSequen​ce (client sequence) stored in to access in a process model?

    I'm trying to get the name of the current step that is about to be run in the MainSequence from a Process Model. This will be accessed in a "ProcessModelPreStep" callback. Thanks!

    Hi
    (TestStand 2.0.1f1)
    I have a attached an example ProcessModelPreStep callback to get that step name. I use the NameOf ( Parameters.Step).
    I hope this is what you are after.
    Regards
    Ray Farmer
    Regards
    Ray Farmer
    Attachments:
    SequentialModel.seq ‏161 KB

  • How to add process model results to the sequence file results?

    After my sequence file runs, I would like to add some additional results using the process model. I need to log my equipment list which is obtained by the process model. Alternatively, I could add a sub-sequence to the end of each of my sequence files for doing this, but that would create maintenance problems if I ever needed to change the way equipment is logged. Does anyone know a way to (1) append process model results to the sequence file results or (2) force each client sequence file to call a sub-sequence before returning to the process model.

    Mark -
    The report and database process model routines expect a single subsequence step result that invoked MainSequence. This result contains the results from the sequence call.
    In TestStand after the process model root sequence call to MainSequence is performed, the property Locals.ResultList[0] is the MainSequence result. The subproperty Locals.ResultList[0].TS.SequenceCall.ResultList contains the results from the steps in MainSequence.
    One option is to create a subsequence call in the process model that logs the equipment info in the results for its steps. The call to the subsequence should not be checked to record results.
    This subsequence would have a parameter called ResultList. The Result type does not exist in the Insert menu, so you can only create the parameter by copying the empty Locals.ResultList and pasting it in the parameters. Then change its type from By Value to By Reference.
    In the setup of the subsequence, add the following steps which do not record results. These steps rename the Locals.ResultList parameter to ResultListOrig, and then create a new Locals.ResultList alias property that really references Parameters.ResultList. This way any additions to the Locals.ResultList really append to the Parameter.ResultList.
    Setup
    Step: "Rename Locals.ResultList"
    StepType, Adapter: Action, Active-X
    Description:
    Action, Set PropertyObject.Name = "ResultListORIG"
    Record Results: False
    Step: "Create Alias in Locals"
    StepType, Adapter: Actioin, Active-X
    Description:
    Action, Call PropertyObject.SetPropertyObject ("ResultList",
    0x201 ' Not Owning and Create, Parameters.ResultList)
    Record Results: False
    In the Main steps, you add your equipment info steps which record results.
    In the Cleanup steps you undo the steps performed in Setup.
    Cleanup
    Step: "Delete Alias in Locals"
    StepType, Adapter: Action, Active-X
    Description:
    Action, Call PropertyObject.DeleteSubProperty ("ResultList",
    0x400 ' Refer to Alias)
    Record Results: False
    Step: "Rename Locals.ResultListORIG"
    StepType, Adapter: Action, Active-X
    Description:
    Action, Set PropertyObject.Name = "ResultList"
    Record Results: False
    I have attached a TS 2.0 version of SequentialModel.Seq that has a AppendResults subsequence in it and this is invoked after MainSequence in Single Pass entry point.
    Hope this helps...
    Scott Richardson (NI)
    Scott Richardson
    National Instruments
    Attachments:
    SequentialModel.Seq ‏174 KB

  • Parallel Process Model Entry

    Hello,
    First, using LabVIEW 2011 and TestStand 2010 SP1.
    We have a custum GUI setup to use the sequential model.  At the heart of it, when we hit start, it accesses the Single Pass entry point and runs it with some modifications we've made.  Now, we'd like to have a setup that can test multiple DUTs and use the Parallel Process Model.  I'd like to have our GUI basically perform the same functions as the built in popup when running the TestUUTs entry point.  I've seen the PreUUT callback where you can disable the built in popup.  But what I can't seem to figure out is how to initiate a test socket test because it doesn't seem to line up with an entry point necessarily.
    When they push the start button next to DUT 0, I want to start socket 0.  And if they hit the start button next to DUT 1, I want to start socket 1.  What entry point does the GUI use to make this happen?  Does the GUI need to start an entry point (IE Test UUTs) then send more information later to start a test?  if so, where does TestStand wait for that information within the parallel process model?
    Thanks.

    One way you could do it is as follows:
    Still override PreUUT like in the example and add code which posts a UIMessage synchronously to the UI and then waits for a persocket notification (e.g. you can use the socket index as part of the name to make a per socket notification). Then in your UI, handle the UIMessageEvent on the ApplicationMgr. When you get the UIMessage from your PreUUT you will know it's ready and you can then update your UI to enable the start button, and when the user presses it, you can then Set() the notification to tell the testsocket thread to continue.
    for example, in preuut:
    Create Notification "MyUIStartNotification Socket 1"
    Thread.PostUIMessage(UIMsg_UserMessageBase + 1, RunState.TestSockets.MyIndex, "MyUIStartNotification Socket 1", null, true)
    Wait on Notification "MyUIStartNotification Socket 1"
    In your UI
    Handle UIMsg_UserMessageBase + 1
    Enable Start Button
    When start button pushed, Set Notification that corresponds to that socket. Pass any data needed with the notification, for example, create a container that contains a serialnumber property and a continuetesting property and pass that with the Set operation. In your PreUUT code get that data from the notification and update your parameters.
    Not simple, but doable.
    -Doug

  • How to release process model sequence file object?

    Calling engine's method GetStationModelSequenceFile we get the reference to the process model sequence file object. According to TestStand Help, you should "Release this reference when you are done using it." The question is: how do you release it? Call engine's method ReleaseSequenceFileEx passing the reference to the model sequence file gotten from GetStationModelSequenceFile won't work, it returns FALSE which means the sequence file can't be released. Similar problems exist with methods SequenceFile.GetModelSequenceFile, Execution.GetModelSequenceFile. My aplication is written in VB. Using the statement like
    Set modelSequenceFile = Nothing also does not solve the problem.  I want to get some information of process model, such as version number, so I call those API functions in my code, which was developed under TestStand 3.1. I post this question because when I ran my application with TestStand 3.5 or 4.0 beta, I got the warning dialog when loading a sequence file and then closing the application. The dialog listed all the unreleased objects which I figured out is due to that the process model file was not released. Because message in the dialog is as following:
    The following top-level objects were not released:
            Sequences [1 object(s) not released]
                Sequence #1:
                    Name: Test UUTs
            Type Definitions [43 object(s) not released]
                Type Definition #1:
                    Name: TimeDetails
                Type Definition #2:
                    Name: ReportOptions
    Of course there are more in the list, but the sequence file loaded into the application is released correctly by calling engine's method ReleaseSequenceFileEx, so it does not appear in the list.
    Any help will be greatly appreciated.

    Here are what I did after launch the operator interface:
    1) Call Engine.GetSequenceFileEx to get a reference to a sequence file.
    2) Display steps of MainSequence of the sequence file in GUI.
    3) Call Engine.GetStationModelSequenceFile to get a reference to the station process model sequence file. The variable used to save the reference of process model sequence file is modelSequenceFile.
    4) Loop through all the sequences in process model sequence file, get the references of entrypoint sequences in the process model and put them in a container (VB Collection).
    At this point,
    Calling modelSequenceFile.CanUnload returns TRUE
    Calling modelSequenceFile.IsExecuting returns FALSE
    Calling Engine.ReleaseSequenceFileEx(modelSequenceFile, ReleaseSeqFile_UnloadFile) returns FALSE
    There is no other loaded process model sequence file reference at this point.

  • How to Read DAQmx Product name in cvi

    How do I read the USB product names in CVI. I need to know which DAQmx instruments I have connected. If its a USB-6009 and/or USB-6221.  Any help would be appreciated.
    Thanks

    Device product type can be obtained with
       DAQmxGetDeviceAttribute ("DeviceName", DAQmx_Dev_ProductType, msg, 4096);
    There is a whole series of properties that you can retrieve on installed devices: I suggest you study the list of attributes available for this function in order to detect if some of them can be of some help for you.
    The list of all devices present in the system (regardless they are simulated or actual devices) can be obtained with
          DAQmxGetSystemInfoAttribute (DAQmx_Sys_DevNames, msg, 4096);
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Organization unit in process modeler

    In process modeler I have created stores, like SUPPLIERS, INVOICES, which will be entities. I placed them in the unspecified organization unit. It is better to create a new organization unit like IT_DATABASE? Is an IT_DATABASE an organization unit? What do you think about it?

    I think "DEPARTMENTS" is a generic name... you may give a specific name....
    Anyway , you can pose the "INVOICES" datastore to the ACCOUNTING dept.... and the SUPPLIERS datastore to the ACCOUNTING DEPT or to DEPARTMENTAL DEPT regarding the department which deals with them (the management of suppliers) ....
    Greetings,
    Sim

  • Process Modelling

    Hi All,
    I just got EHP-1 installed. I would like to know more about Process Modelling using BPM.
    Please point out some documents that would serve as a good starting point to understand BPM.
    Why is the BPX Community different than SDN ?
    Thanks,
    ~Veena.

    Here is a starter. You may search directly on sdn many more articles.
    https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/90126032-e589-2910-1ca6-f97c96e86130
    Why is the BPX Community different than SDN ?
    You can find thousands of views for this question on these forums Let me tell you some bit of it. SDN as the name suggests is SAP Developer's Network. The business areas were earlier merged as a part of SDN and there was no regulatory distinction. With introduction of BPX, not only technical group of SAP consultants, but also business process designers and owners could share their views and experience thereby enriching the knowledge base of SAP.
    Regards,
    Prateek

  • A short survey: Business Process Modeling Tools

    Hi everybody,
    my name is Leonie Fütterer and I am a student at the Karlsruhe Institute of Technology. I do research on freeware business process modeling tools.
    Please take two minutes and help me by completing the following survey. The results will be released in february 2011 in terms of an academic paper.
    www.bpm-toos.net
    Thank you!
    If you have any questions, don't hesitate to contact me (see link above)!
    Leonie Fütterer

    I guess the link is rather http://www.bpm-tools.net/ ?
    I will circulate it to my friends.... here where I work they use Excel =:o( and ARGOS-UML much to my dismay

  • Each time I use a USB,IPHOTO,DVD or VMware Fusion connection the desktop mouse pointer freezes regards Model Name:       Model Identifier:MacBookPro10.6.8, 2   Processor Name:Intel Core i7   Processor Speed:2 GHz   Number of ProcesJohn

    Each time I use a USB,IPHOTO,DVD or VMware Fusion connection the desktop mouse pointer freezes regards Model Name:  Regards  John
      Model Identifier:MacBookPro10.6.8, 2
    Model Name: MacBook Pro 10.6.8
      Model Identifier: MacBookPro 8.2
      Processor Name: Intel Core i7
      Processor Speed: 2 GHz
      Number of Processors: 1
      Total Number of Cores: 4
      L2 Cache (per Core): 256 KB
      L3 Cache: 6 MB
      Memory: 4 GB
      Boot ROM Version: MBP81.0047.B27
      SMC Version (system): 1.69f4
      Serial Number (system): C2*******F8V
      Hardware UUID: *****
      Sudden Motion Sensor:
      State: En
    <Edited By Host>

    Hi Allan,
    Thank you for your early response, I eventually managed to unZip the requested download, each time I tried the computer froze.
    EtreCheck version: 1.9.12 (48)
    Report generated 19 July 2014 19:27:23 GMT+01:00
    Hardware Information:
         MacBook Pro (15-inch, Early 2011) (Verified)
         MacBook Pro - model: MacBookPro8,2
         1 2 GHz Intel Core i7 CPU: 4 cores
         4 GB RAM
    Video Information:
         AMD Radeon HD 6490M - VRAM: 256 MB
         Intel HD Graphics 3000 - VRAM: 384 MB
              Color LCD 1440 x 900
    System Software:
         Mac OS X 10.6.8 (10K549) - Uptime: 0 days 0:4:34
    Disk Information:
         Hitachi HTS545050B9A302 disk0 : (465.76 GB)
              - (disk0s1) : 200 MB
              Macintosh HD (disk0s2) / : 465.44 GB (58.8 GB free)
         MATSHITADVD-R   UJ-898 
    USB Information:
         Apple Inc. FaceTime HD Camera (Built-in)
         Apple Inc. BRCM2070 Hub
              Apple Inc. Bluetooth USB Host Controller
         Apple Inc. Apple Internal Keyboard / Trackpad
         Apple Computer, Inc. IR Receiver
    Thunderbolt Information:
         Apple, Inc. MacBook Pro
    Kernel Extensions:
              com.NovatelWireless.driver.NovatelWirelessUSBCDCECMControl (3.0.13) Support
              com.NovatelWireless.driver.NovatelWirelessUSBCDCECMData (3.0.13) Support
              com.ZTE.driver.ZTEUSBCDCACMData (1.3.35) Support
              com.ZTE.driver.ZTEUSBMassStorageFilter (1.3.35) Support
              com.novamedia.driver.IceraUSB_MSD_Bypass (1.3.0) Support
              com.novatelwireless.driver.3G (3.0.13) Support
              com.novatelwireless.driver.3GData (3.0.13) Support
              com.novatelwireless.driver.DisableAutoInstall (3.0.13) Support
              com.option.driver.Option72 (2.15.0) Support
              com.option.driver.OptionHS (3.26.0) Support
              com.option.driver.OptionMSD (1.21.0) Support
              com.option.driver.OptionQC (1.11.0) Support
              com.rim.driver.BlackBerryUSBDriverInt (0.0.67) Support
              com.rim.driver.BlackBerryUSBDriverVSP (0.0.67) Support
              com.tomtom.driver.UsbEthernetGadget (1.0.0d1) Support
              com.vmware.kext.vmci (3.1.2) Support
              com.vmware.kext.vmioplug (3.1.2) Support
              com.vmware.kext.vmnet (3.1.2) Support
              com.vmware.kext.vmx86 (3.1.2) Support
              com.vodafone.driver (3.0.9) Support
              com.vodafone.driver.Data (3.0.9) Support
              com.vodafone.driver.DisableAutoInstall (2.0.6) Support
              com.zte.driver.cdc_ecm_qmi (1.0.26) Support
              com.zte.driver.cdc_usb_bus (1.0.26) Support
              de.novamedia.driver.NMSamsung (0.0.2) Support
              de.novamedia.driver.NMSmartplugSCSIDevice (1.0.1) Support
              de.novamedia.driver.NMUSBCDCACMControl (3.2.12) Support
              de.novamedia.driver.NMUSBCDCACMData (3.2.12) Support
              de.novamedia.oem.vodafone.vtp.huawei.cdc (0.0.2) Support
              net.kromtech.kext.AVKauth (2.3.6 - SDK 10.8) Support
              net.kromtech.kext.Firewall (2.3.6 - SDK 10.8) Support
    Startup Items:
         HWNetMgr: Path: /Library/StartupItems/HWNetMgr
         HWPortDetect: Path: /Library/StartupItems/HWPortDetect
    Problem System Launch Daemons:
              de.novamedia.nmnetmgrd.plist Support
    Launch Daemons:
              com.adobe.fpsaud.plist Support
              com.citrixonline.GoToMyPC.CommAgent.plist Support
              com.trusteer.rooks.rooksd.plist Support
              com.vmware.launchd.vmware.plist Support
              com.zeobit.MacKeeper.AntiVirus.plist Support
    Launch Agents:
              com.citrixonline.GoToMyPC.LaunchAgent.plist Support
              com.conduit.loader.agent.plist Support
              com.epson.ews.launcher.plist Support
              com.hp.devicemonitor.plist Support
              com.hp.messagecenter.launcher.plist Support
              com.trusteer.rapport.rapportd.plist Support
              de.novamedia.VodafoneDeviceObserver.plist Support
    User Launch Agents:
              com.adobe.ARM.[...].plist Support
              com.apple.CSConfigDotMacCert-[...]@me.com-SharedServices.Agent.plist
              com.google.keystone.agent.plist Support
              com.zeobit.MacKeeper.Helper.plist Support
    User Login Items:
         VMCStatusMenu
         Dropbox
         Vodafone Mobile Broadband
         HP Product Research
    Internet Plug-ins:
         Flip4Mac WMV Plugin: Version: 2.4.4.2 Support
         FlashPlayer-10.6: Version: 14.0.0.145 - SDK 10.6 Support
         JavaAppletPlugin: Version: 13.9.8 - SDK 10.6 Check version
         AdobePDFViewerNPAPI: Version: 10.1.7 Support
         Flash Player: Version: 14.0.0.145 - SDK 10.6 Support
         AdobePDFViewer: Version: 10.1.7 Support
         QuickTime Plugin: Version: 7.6.6
         Google Earth Web Plug-in: Version: 7.1 Support
         GarminGpsControl: Version: 4.0.4.0 Release - SDK 10.6 Support
         Silverlight: Version: 5.1.20913.0 - SDK 10.6 Support
         iPhotoPhotocast: Version: 7.0 - SDK 10.7
    iTunes Plug-ins:
         Quartz Composer Visualizer: Version: 1.2
    3rd Party Preference Panes:
         Flash Player  Support
         Flip4Mac WMV  Support
         GoToMyPC Preferences  Support
         Trusteer Endpoint Protection  Support
    Top Processes by CPU:
             18%     mdworker
              7%     WindowServer
              2%     Dock
              2%     Vodafone Mobile Broadband
              1%     SystemUIServer
    Top Processes by Memory:
         242 MB     AntiVirus
         78 MB     Dropbox
         53 MB     WindowServer
         45 MB     rapportd
         37 MB     MacKeeper Helper
    Virtual Memory Information:
         2.00 GB     Free RAM
         864 MB     Active RAM
         182 MB     Inactive RAM
         995 MB     Wired RAM
         164 MB     Page-ins
         0 B     Page-outs
    I appreciate your assistance in this problem
    Regards
    John  (omegajon)

  • Client fileglobal access by process model

    I have the same question as posted in knowledge base article:
    http://digital.ni.com/public.nsf/allkb/f970e072b4b41ef786256e30007505b2
    However, the stated solution in the knowledge based article appears to be unavailable for TestStand1.03.
    Basically I'm trying to access the fileglobals of a client from within the process model.  The only appearent path is the RunState.ProcessModelClient.Data.FileGlobalDefaults but this is just the default states of the client's variables.  I need the actual runtime copies.
    {section from the knowledge based article}
    Configuration for first step
    Object Reference: RunState.Execution
    Automation Server: NI Teststand API 3.0 (1.0)  TestStand API 1.0
    Object Class: Execution
    Action: Call Method
    Method: GetFileGlobals    (option is not available,  there is GetModelSequenceFile, GetSequenceFile, GetStates, and GetThread)
    Parameters
    Return Value: Locals.FileGlobals
    sequencefileParam: RunState.ProcessModelClient
    I'm actually using a CVI Dll to access the variables.  I'm passing in "ThisContext" and then using:
    CAObjHandle      SeqContextHandle = ThisContext passed from teststand
        tsErrChk(TS_PropertyGetValString(SeqContextHandle, &errorInfo, "FileGlobals.SoftwarePN",0,&pszKeyName));
    This works great for accessing the FileGlobals of the process model, but not for the fileglobals of the client.
    Maybe there is a different ObjHandle to get to the client, but I don't know where it is.

    Hi,
    Not sure if this is available in version 1.03, but have you tried setting the SequenceFile properties to use the same fileglobals for each execution. This maybe your only option if available.
    Regards
    Ray Farmer
    Regards
    Ray Farmer

Maybe you are looking for