Issues about applying "parallel tasks" with serial serial port

Hi all,
I'm doing a routine (vi) that is intended to be used for calibration of 3 temperature probes of a temperature controller device (TCD), in parallelTCD has a serial port, I can communicate with successfully using a low level routine that implement Modbus protocol functions and use the VISA serial VIs.I can read/write some registers that adjust the temperature value.So, for example, if you have 30 �F on display of TCD, and calibration register is -1, you can modify it (with a known formula) to 4, and the temperature will be 32�F.
I wrote a routine that works, and it's called "Cal.probe", it works for 1 probe, and it follows the state diagram in FIG.2 (attached).I would like to call this function in a "parallel" way, see FIG.1 where I pass parameters that I need.
ISSUE 1)The inner serial functions for serial communication are NOT "reentrant", they weren't make with "parallel tasks" in mind...If I declare the single "Cal Probe" VI as REENTRANT, I see that they are called and run ALMOST at the same time (verified enabling the "open vi when called" and "close if origially closed" options), instead it is not reentrant, the same function is not called in parallel so I lose the advantages of LabView hassle-free multithreading (it's called and executed, then called again and executed, ecc..)
Is this correct?
ISSUE 2)All the instances works with the SAME COM port, but if reentrant, they work in "separate memory enviroinment".What problems can arise? Is this approach correct? a better approach in design?The inner serial function is made like this (EVERY time it's called do this):1) initialize serial port2) send modbus packet to write buffer of PC 3) waits and poll the receive serial buffer of PC because a modbus packet response will be received (otherways has a timeout error and/or retries)
This implementation is correct in your opinion? I tried that in different project and it works, until now I've never read/write data of other registers, because it seems there is a inner queuing system in the VISA, and probably they keep track the "owner" of the data requestedMessage Edited by Slyfer on 04-17-2008  04:21 AM


fig2 - state diagram my routine.png:
http://forums.ni.com/attachments/ni/170/316818/2/fig2 - state diagram my routine.png
x9561 (148440)
4/17/2008 9:40:05 AM
comp.lang.labview 35213 articles. 1 followers. vasusachin24 (1) is leader. Post Follow

5 Replies

Similar Articles

[PageSpeed] 40

Hi Slyfer, you only have one COM port - how do you want to perform simultanous (parallel) communication???Either you put the 3 COM accesses into one (I'm not familiar with modbus, can you read/write several registers in one access?) or you have to check the modbus in sequential order (ask for register1, read register1, ask reg2, read reg2, you get the scheme:smileywink:)...
x9561 (148440)
4/17/2008 9:40:07 AM
By "parallel communication" I mean (my goal) "independent communication".I try to explain better what I'm trying to do.If you have a routine R that does a task using 1 serial COM port and a set of parameters P_1, and you must invoke the same routine for other 2 different set of parameters P_2 and P_3, what can you do?
Solution 1 (serialization approach):You call R passing P_1, then R passing P_2, then R passing P_3.You call R three times in sequence (slow .... )
Solution 2 ( correct?:smileyindifferent: )Consider that each routine R is independent (it doesn't use global variables, so I don't have the problems of dealing with semaphores, because I don't risk to write/read a variable from two different points), and consider that R is described (implemented) by the state machine in FIG2.So each instance of R runs on it's own state-machine.Inside each R, there could be some calls to the serial write/read VISA... but there is a timeout waiting the response, example:modbus_read(register_1) = init serial port + send_modbus_packet_request_to_outSerialBuffer + read the response (retry&timeout protocol)
Is it possible that meantime, another process (the same R also!?), get access to the serial port and queues another modbus request???
Only function 3 and 6 of modbus protocol are available:3 = read one single register6 = write one single register
So in your opinion this is impossible? I think it's possible, otherways the whole ModBus chain over RS485 would be impossible to do ( = multiple devices sharing the same COM port, access to this common medium is ruled by Modbus protocol state machine,all device receive the packet_request, but only the one which match the address responds). This is the scheme:
PC + COM1 < --- Modbus over serial line RS485---->> DEV 1 (addr=1) + DEV 2 (addr.34) + DEV 3 (addr.22) + .... etc... 
x9561 (148440)
4/17/2008 12:10:05 PM
Hi Slyfer, " Is it possible that meantime, another process (the same R also!?), get access to the serial port and queues another modbus request???"I would say YES. There is only one COM port, but 3 routines are trying to access it. Surely they will interfere with each other...Btw. you only have to init the serial port once at the start of your program!
x9561 (148440)
4/17/2008 12:40:05 PM
I initialize and close the VISA resource every time I call the read_register / write_register routine to achieve this behaviour:
it is possibile to have 2 distinct exe files that use the same port at the same time, without conflict.
If you have a program that at the beginning initializes one COM (to use it only sometimes in the program, not continuosly), and then you build it, you have an application that will reserve that COM for itself.But if you need an extra instance of this program (so two exe running in parallel) and you want to use it on the same COM, they will conflict.The approach is to initialize/opeon/close practically on demand...I don't know if there are better ways to do this, but what I said is proven and working (even if I don't fully understand how :smileyvery-happy:)
But this brings to me another question about the topic:In this last case (2 exe running, the same program opened two times, just copy paste his folder elsewhere) opening/closing on demand the same COM port, how are they handled in case of simultaneous access to the COM?Is the OS (multithreaded) that seemless time-shares the resources, letting resolve one or the other application access to the COM??? Message Edited by Slyfer on 04-17-2008  09:27 AM
x9561 (148440)
4/17/2008 2:40:08 PM
Hi Slyfer, what kind of OS?Well I doubt this will work as I told before: only one resource that cannot be shared. Imagine this scenario: 2 processes start serial communication. Both request values of certain modbus registers, the both are waiting for an answer. Which process gets which answer? How do they know it's the answer to their request? What happens when they read the answer and then they find out it's not the correct one?
x9561 (148440)
4/17/2008 3:10:07 PM

Similar Artilces:

"VI was stopped at node " " at a call to "In Port Old 6.x.vi""
Hi. I am having problems with&nbsp;a VI&nbsp;that was initially developed for LABView 6i. I have upgraded to LABView 8.2 but whenever I run the program in LABView 8.2 I get the error message that my VI was stopped at node&nbsp; " " at a call to "In Port Old 6.x.vi". The VI generally aquires data from a measurement instrument via an RS232 COM port. I have searched the forum and the only reference to this problem mentioned that it can be solved by making "minor modifications" to the polymorphic In Port VI in LABView 8.2 but I have no idea how to do this. &nbsp; I would be most grateful if anyone can help me to do this. I am a newbie to LABView programming so I would require as much detail as possible. Thanks. &nbsp; tronix Hello, &nbsp; Have you followed the guidelines found on this document? &nbsp; <a href="http://digital.ni.com/public.nsf/allkb/39129B46944215B686257069006CEC4E?OpenDocument" target="_blank">http://digital.ni.com/public.nsf/allkb/39129B46944215B686257069006CEC4E?OpenDocument</a> &nbsp; Contains information on how to proceed and how you can change the VI's needed to new ones. &nbsp; Hopes this helps! Hello. Thanks for your response. I did see the link. Part of the document says: tronix wrote: Hi. I am having problems with&nbsp;a VI&nbsp;that was initially developed for LABView 6i. I have upgraded to LABView 8.2 but whenever I run the program in L...

Adding an &quot;IMAQ Image.ctl&quot; to the &quot;Display State.ctl&quot; of an XControl prevents LabVIEW from creating a probe of &quot;Display State.ctl&quot;
I am working on an extended IMAQ Display control using LabVIEWs XControl capabilities. &nbsp; I need a copy of the original image passed to add some overlays which must not affect the original image. To achieve this I am creating a backup image in the "Init.vi" and deleting it in the "Uninit.vi". I am storing the reference&nbsp;of this image&nbsp;in the "Display State.ctl" which is part of every XControl. &nbsp; As soon as I am adding an "IMAQ Image.ctl" to the Display State cluster, it is no longer possible to generate a probe of the Display State cluster for debugging purposses. I am always getting the message: "Failed to load or create probe." Deleting the "IMAQ Image.ctl" from the cluster makes the probe working again. &nbsp; Is it a bug or am I doing something wrong? &nbsp; I am working with LabVIEW 8.5 and Vision 8.5. &nbsp; Regards &nbsp; Ingo Bartsch Hello Mr. Bartsch, is it possible for you to post a small example to reproduce the behaviour? It would be helpful to get a description in which way you use the typedef files. I found a example/knowledge base where some informations were included to XControl and LV but not with Vision. <a href="http://digital.ni.com/public.nsf/allkb/1DC1ADD2A136DA298625712C00635758?OpenDocument" target="_blank">http://digital.ni.com/public.nsf/allkb/1DC1ADD2A136DA298625712C00635758?OpenDocument</a> Best wishes Ja...

ActiveRecord & Sqlite3 & serialize & "f"
What's wrong with the code below? It returns this "f" instead of "". Where does "f" come from? Thanks. gegroet, Erik V. - http://www.erikveen.dds.nl/ ---------------------------------------------------------------- $ ruby test.rb :bar "f" <<<< Should be "" nil $ echo "select * from key_values;" | sqlite3 test.db 1|--- :foo |--- :bar 2|--- :empty |f 3|--- :nil | ---------------------------------------------------------------- require "rubygems" require "active_record" cl...

&quot;re-entrant&quot; &quot;file I/O&quot; &quot;QSM_State Machines&quot;
&nbsp; &nbsp; I have trouble with writing (appending) to text file in a QSM that is in an "occurence mode" of operation whereby the queue waits for outside engueue to go ahead and do a task. The task is simply to write to a file a line of text. &nbsp; Outside producers give the queue its go ahead and data is sent along etc... &nbsp; WHat I am seeing in the logging functions are multiple errors (Error 1) Somehow Labview&nbsp;is not noticing that the reference is valid or it is invalidating the reference. &nbsp; Q is Should I just let the QSM loop to keep it alive and would that work? &nbsp; What is the rule concerning queue waiting for an event? Does the VI get flagged as idle and is that why the ref appears to be dropped?&nbsp; THere is no reason I can think of for the ref to be dropped. It is opened in the init frame then kept in a shift register. and available at each iteration in the QSM. &nbsp; The example works in a simple loop but not a loop that is waiting on an occurence.&nbsp; Why? &nbsp; The only work around I can manage is to use the path and open the reference when it is not valid which feels kind of&nbsp; silly if you get my drift &nbsp; Anyone seen this before? &nbsp; Thank You &nbsp; &nbsp; &nbsp; ...

Build Error: &quot;VISA Configure Serial Port&quot;
Hi, &nbsp; I want to upgrade some&nbsp;old 6.i vi's to 8.5 But&nbsp;on building&nbsp;the project&nbsp;&nbsp;i am&nbsp;getting an Error: &nbsp; Please take a look in to the screenhots &nbsp; Greetings from the lake of Constance, Germany &nbsp; juergen &nbsp; MESSAGE.jpg: http://forums.ni.com/attachments/ni/170/296847/1/MESSAGE.jpg VI-LIB.jpg: http://forums.ni.com/attachments/ni/170/296847/2/VI-LIB.jpg ...

plug-in &quot;not installed&quot; in my LabVIEW project's &quot;Build Specifications&quot;
I moved my LabVIEW project from one computer to another, now when I click on any item under the project's "Build Specifications", I get an error reading "The plug-in for the selected item is not installed on your system." Does anybody know how to fix this? I have no idea what this "plug-in" is.Attached is a screenshot. plug-in error.PNG: http://forums.ni.com/attachments/ni/170/222664/1/plug-in error.PNG ...

What's the equivalent of a &quot;TCP/IP listen&quot; for a serial port?
Hi, &nbsp; I want to listen to a serial port and wait til the data comes. I want something exactly like a TCP/IP listen because this function always wait&nbsp;til there's data. &nbsp; Any suggestion? &nbsp; Thank you &nbsp; Stephanie Hi again, &nbsp; Thank you for your answer. I've try what you said with the VISA Wait&nbsp;on event (see detectevent.JPG). I took the "Detect Break Event.vi" example&nbsp;and instead of the "Serial Break" event, I took Serial Character (or sometimes Serial Term Char). I always get&nbsp;these errors ("Could not perform operation because of I/O error." or "Timeout expired before operation completed."). What I want to do is always wait til I receive an CRLF and then&nbsp;read it. Something as easy as the&nbsp;TCP/IP listen.&nbsp;Do you know why I have these errors? &nbsp; Also I have another error. I've try the "Basic Serial Write and Read.vi" example and I get the same error (see basicserialwriteandread.JPG). I can easily write and I get the error when&nbsp;it tries&nbsp;to read it. Do you have any idea why it works only in one way? &nbsp; Thank you again &nbsp; St�phanie detectevent.JPG: http://forums.ni.com/attachments/ni/170/250899/1/detectevent.JPG basicserialwriteandread.JPG: http://forums.ni.com/attachments/ni/170/250899/2/basicserialwriteandread.JPG In your detectevent.jpg example the problem is likely due t...

VI &quot;FindInstrumentDrivers.vi&quot; was stopped at node &quot;&quot; at a call to &quot;IDF_WsIdOpen.vi&quot;
This what I get trying to download Instrument Drivers in LabVIEW 8.2. LabVIEW 8.6 doesn't succeed either. any ideas? Could just be an intermittent server problem. Does this happen all the time? At what point does it fail? When you first launch it, after you login? The network traffic indicates that it uses port 3339. Is this being blocked by your firewall? ...

How to change &quot;ASRL2:... &quot; to &quot;COM1&quot;?
Dear All, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; I have used com port in my vi. And When I run it in edit mode,&nbsp;the selection of com displays "COM1,COM2,LTP1". &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; But when I build it, and run it in another PC, it displays "ASRL2:...". &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; How can I modify my vi to make it display COM1... in another PC? &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; And If I only want to display all serial port such as COM1,...

Programmatic &quot;undo&quot; for &quot;FitControlToPane&quot; ?
Howdy neighbors!, (using LV8.2)&nbsp; I'm trying to develop a GUI that lets the user toggle a Tab-control between "Full Pane" and a&nbsp;reduced size/position - sorta-like&nbsp;the "Full Screen" option on many Video apps.&nbsp; The effect of the&nbsp;invoke-node method "FitControlToPane" is perfect (- :smileyhappy: -), but how to undo that effect?&nbsp; After&nbsp;FitControlToPane,&nbsp;"Scale Object with Pane" is selected in the IDE, yet I can't find a "property" for it. :smileysad:&nbsp; FitControlToPane also changes the visibility of vertical and horizontal scroll-bars - are these [VI Properties] programmatically settable? &nbsp; Cheers! &nbsp; &nbsp; &nbsp; follow up... FitControlToPane also changes the visibility of vertical and horizontal scroll-bars - are these [VI Properties] programmatically settable? Feel kinda silly now, having advised someone else to search LabVIEW's HELP first! :smileytongue: &nbsp;- found Scrollbar Visibility can be set via (LV8.2)\ VI \Panel(reference)\Panes[0].HorizScrollbarVisibility. <img src="http://forums.ni.com/attachments/ni/170/239318/1/ScrollBar.JPG"> Still hunting for an&nbsp;elusive "Set Scaling Mode" method... (The&nbsp;Tab Control's&nbsp;"AutoGrow?" property doesn't seem to do anything!?)Message Edited by tbd on 04-03-2007 12:56 AM ScrollBar.JPG: ht...

Serial port programming question----no "COM1" selection in the "VISA resource name" of "VISA Configure Serial Port "
Hi , i am new to progrom with LabVIEW. Here is some question of serial port control. &nbsp; The document of "Serial Quick Reference Guide", there is a simple example of controlling of serial port, but ,in my LabVIEW, there is some different . LabVIEW can not &nbsp; find the COM1 ,so I can not select it. &nbsp; Why ? and how to solve it? &nbsp; thanks. &nbsp; BR. Your question has very little details. Which version of LV are you using? Are you seeing a list of things you don't understand? Are you seeing an empty list? If you are seeing a list of things like A...

Tick box &quot;include Serial Port Support&quot; missing in 8.1
In version 7.1, I recall a tick box when building an application that read "include Serial Port Support". Why is this missing in 8.x? I like the idea of making a very small installer having only serial port support. Thanks Richard &nbsp; ...

I need a data step that is equivalent to data _NULL_; file print; put '&&&&&&a=' "&&&&&&a"; run; Yet the number of & is a variable, I need to write a Macro, so far I got only half of the code('&&&&&&a.='), I don't know how to put the other half ("&&&&&&a.") into Macro Thanks. %Macro R(k); data _NULL_; file print; put %do i= 1 %to &k.; '&' %end; 'a=' ; run; %mend; %R(10); ==================================================...

how to connect &quot;IMAQ Get Buffer.vi&quot; output terminal of &quot;Image Out&quot; to the input terminal of &quot;Image&quot; of &quot;IMAQ ColorImageToArray.vi&quot;
Hi, Thanks a lot for helping me till this stage.I am again stuck up with some problem.Please help me this time also. Actually i am making changes in already existingblock diagram and also i am new to this labview programming.And also time is very crucial. So i want to know if there is any way to connect the output of Image out terminal of IMAQ Get Buffer.vi to the input terminal of Image of IMAQ ColorImageToArray.vi. In the actual block diagram the output of Image out terminal of IMAQ GetBuffer.vi is connected to the input terminal of Image of IMAQ ImageToArray.vi. I want to change this becos i want to take RGB image as input and seperate R, G, B components. Please explain in terms of bloack diagram. ...

Problems with "&amp;" changing to "&"
A lot of Firefox users I know, says they have problems with validation where the ampersand sign has to be written as &amp; to be valid. I don't have Firefox my self and don't wont to install it only because of this, so I hope some of you gurus can enlighten me with this :) In what circumstances can the "&amp;" in the source code be involuntary changed to "&" by a browser when or other software, when editing and uploading the file to the web server? E.g. writing a string like "sc_project=402887&amp;java=0&amp;security" is cha...

How to use &quot;GetLastInputInfo&quot; in &quot;user32.dll&quot;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Hi, &nbsp; I need to logout user if he doesn't make action during 5 minutes, "GetLastInputInfo" method in the "user32.dll" library, return the tick of the last action, so I can&nbsp;know the inactivity time of the login user. &nbsp; But I try to using "Call Dll function" item in Labview 8.1, and each time I run VI, Labview crash. &nbsp; Next, is information about the method : &nbsp; DLL###############################User32.dll &nbsp; Syntax###############################BOOL GetLastInputInfo(PLASTINPUTINFO plii); &nbsp; Parameters###############################plii : [out] Pointer to a LASTINPUTINFO structure that receives the time of the last input event. Private Type LASTINPUTINFO &nbsp;&nbsp;&nbsp; cbSize As Long &nbsp;&nbsp;&nbsp; dwTime As Long End Type Return Value###############################If the function succeeds, the return value is nonzero.If the function fails, the return value is zero. &nbsp; Remarks###############################This function is useful for input idle detection. However, GetLastInputInfo does not provide system-wide user input information across all running sessions. Rather, GetLastInputInfo provides session-specific user input information for only the session that invoked the function. &nbsp; You can see also my VI source. &nbsp; GetLastInputInfo.vi: http://forums.ni.com/attachments/ni/170/31...

How can I modify the &quot;Type definitions&quot; of &quot;Function Prototype&quot; if I want build a DLL in Labview 8.5.1.?
Hello,We have a library with several VIs (API - Interfaces to our Real Time Target). This VIs we provide to our customer to generate own VIs to control the Real Time Target.Now we want to provide the functionality of this VI-library as DLL to our customer. The problem is, that labview use self definite name of type definitions. Also if I use "strict Type definition".Example:void GetOutputValues(VARIANT *Scale_In, int32_t ModelNr, uint16_t SignalID[], TD1:smileymad: *errorIn, VARIANT *Scale_Out, TD2 *Data, TD1 *errorOut, int32_t len)It is possible to modify "TD1" and "TD2"? I want to give useful names.GreetingsSteffen Hi Steffen, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try&nbsp;editing the .h file as follows: CHANGE FROM: typedef struct {&nbsp;LVBoolean status;&nbsp;long code;&nbsp;LStrHandle source;&nbsp;} TD1; CHANGE TO: typedef struct {&nbsp;LVBoolean status;&nbsp;long code;&nbsp;LStrHandle source;&nbsp;} TD1; typedef struct {&nbsp;LVBoolean status;&nbsp;long code;&nbsp;LStrHandle source;&nbsp;} LVErrorCluster; then your GetOutputValues prototype becomes: void GetOutputValues(VARIANT *Scale_In, int32_t ModelNr, uint16_t SignalID[], LVErrorCluster *errorIn, VARIANT *Scale_Out, TD2 *Data, LVErrorCluster *errorOut, int32_t len) If your source-code doesn't refer to "TD1", then&nbsp;you probably won't need to keep the TD1 prototype! Cheers. ...

The use of the &quot;XY graph&quot; with the &quot;Read Traces&quot;
Hi, I'm trying to plot on "XY Graph"&nbsp; some informations wich are taken directly from the "Read Traces", and the problem is that the Start timestamp wich i enter to the "Read Traces" don't correspond to the beginning of the X axeof the graph. Can some one help me please. Question pour le forum NI.doc: http://forums.ni.com/attachments/ni/170/334716/1/Question pour le forum NI.doc Hi basile Have you found an issue about your problem? Could you attach you code(.vi) please? Thanks. Regards. Hi&nbsp;&nbsp; R_DUVALThank you for your help but I found the solution to my problem.Best Regards ...

The .NET assembly expected to be at &quot;&quot; was loaded from &quot;NULL&quot;
Hello, &nbsp; I use NET Components in a LabVIEW 8.2.1. VI and all work very fine. Now I convert it to LabVIEW 8.5 and I always get a warning, when open it. The Warning is : &nbsp;The .NET assembly expected to be at "" was loaded from "NULL". As example I add my CallbackVI in the Attachment. If somebody has an idea to remove this warning I would be thankful. &nbsp; Thanks in advance TE_NET_ToolStrip.ClickCallback.vi: http://forums.ni.com/attachments/ni/170/304243/1/TE_NET_ToolStrip.ClickCallback.vi Oh I was glad to early. The problem was only solved one time. When I changed something and saved again, I had again the troubles. &nbsp; I will recreate the VIs now. I already done, but it didn't helped. Now I read, that old one should be closed. ...

Difference between &quot;FP Close&quot; and &quot;FP Hidden&quot;
What is the difference between "Front Panel Close" and "Front Panel Hidden" ? "FP Close" works similar to "FP Hidden" at programming mode but not at the executable ! Is this normal ? At the executable "FP Close" seems to terminate the current vi. One more question: "FP Close" prevents the code that follows from been executed. It is a "violent" way to stop your current vi, but not the whole application. Am i right ? To add one additional thing: I made some tests now on how the Close/Hide differs for SubVIs, and saw no difference. So regardless of hiding or closing the FP of a SubVI, the execution of the VI keeps going on until either the VI is stopped or the MainVI gets unloaded.Attached you can find my test: Sub.VI is the Vi called by closeFP.VI using VI-Server. You can toggle several functions of the Sub, but please note that Sub does not get unloaded until closeFP is stopped.Norbert closeFP.vi: http://forums.ni.com/attachments/ni/170/299668/1/closeFP.vi sub.vi: http://forums.ni.com/attachments/ni/170/299668/2/sub.vi ...

How to define &quot;byte stream type&quot; for &quot;open file&quot;?
Hello, I created some numbers (type "double") in Matlab and stored in a file. What value should I use to specify the "byte stream type" for "open file" in Labview? Should I put something like "DBL" or "I32". I don't know where to find the list of legal "types" in Labiew help. Thanks so much! Felicia Looks like 7.1:<img src="http://forums.ni.com/attachments/ni/170/347924/1/read%20file%207.png"> The Matlab "double" is 64 bits (8 bytes). It doesn't make much sense to use an integer datatype to read a floating point value, so you would use DBL in LabVIEW. The numeric data types table can be found <a href="http://zone.ni.com/reference/en-XX/help/lv/71/lvhelp/Numeric_Data_Types_Table/" target="_blank">here</a>. By the way, this assumes you saved the file as raw binary, as opposed to a .mat file, which is something different. Message Edited by smercurio_fc on 08-08-2008 11:21 AM read file 7.png: http://forums.ni.com/attachments/ni/170/347924/1/read file 7.png Thank both of you! I'm using Labview 6.1 base "Read File", just like the picture above. I've specified the byte stream type as DBL; however, the output is an array of string. What should I do with the string? I've tried to use "Decimal String To Number" but I got an output of "0". I've also tried the "Read From SGL File" in Labivew and ...

Unconfigured, Bad Status &quot;A&quot;, Bad Status &quot;B&quot;
Greeting All. I recently upgraded to LabVIEW 8.5.1, including LabVIEW-RT.My application acquires data from an AI-110 -- Compact FP module.Anyhow, to make a long story short, my program started to malfunction.[After lots of pain and suffering,] I learned that the call fo FP Read produces the error:Unconfigured, Bad Status "A", Bad Status "B"The error is frequent, and I cannot help to think that it is considerably diminishing the performance of all other tasks.Any Ideas? Can you post your code?&nbsp; RayR&nbsp; Certainly. Attached, you'll find a VI that resembles my worker-VI - which I use in my project.I run this VI inside of a state machine.&nbsp; It is initialized at the onset of execution.Thereafter, it is called upon [to read data] at 2Hz.The session is closed at the end.Thanks. ai110.vi: http://forums.ni.com/attachments/ni/170/328071/1/ai110.vi ...

Race Condition: &quot;Elapsed Time&quot; and &quot;Boolean Crossing&quot;
Hello. We are experiencing a pretty strange issue here and we are not sure how to solve it. The attached VI's are a simplified version of the code, but that exhibits the same behavior: The MAIN vi controls a boolean that is an input of the SUB vi. The SUB vi analyzes this boolean, and if its state is different than the last one read, a timer is reset. While the required time (2 sec) has NOT elapsed, the SUB vi outputs the last remembered value after the time has elapsed, the SUB vi finally outputs the new value. Now, the problem appears when depending on how we change the input boolean (for instance, if you change its state as soon as the "elapsed time pulse" is generated), the new value is NEVER sent to the SUB vi's output. In other words, depending on the moment the input is changed, the SUB vi doesn't get the change and never resets the timer. How can we solve this issue? Is there any special configuration that needs to be done in the used functions? Thank you very much for all help. Daniel ...

Acqiuring data in &quot;Idle&quot; case and &quot;Go&quot; case
See SM Tester Bill 8-16-07 in the attached llb. &nbsp; On the block diagram, upper while loop, case "Idle" I have a Daq&nbsp;sub vi that displays the value on the front panel in a cluster on the front panel. (Works great) This allows the user to see the readings of the devices when they are mounting the pecimen under test.&nbsp; &nbsp; Next, I want to use the same Daq sub vi to display the data (to the same cluster on the fromt panel)&nbsp;&nbsp;for the&nbsp;"Go" case. In addition, I want the data collected in the "Go" case to be saved to a file. The intent is to collect the data as the motor moves. &nbsp; If I place my Daq sub vi in the "Go" case the data isn't collected because the "SM Move" vi then runs.&nbsp; If I place the Daq sub vi in the "SM Move" vi, the cluster appears on the front panel of the "SM Move" vi, not the main panel.&nbsp; &nbsp; Can someone suggest some good programming practices? &nbsp; Thanks, &nbsp; Bill SmartMotor.llb: http://forums.ni.com/attachments/ni/170/265911/1/SmartMotor.llb Hi Bill, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; I looked at your code (there are a few missing&nbsp;"SER"ial-port related VI, nothing serious)&nbsp;and have a question before suggesting a solution:&nbsp; I want the data collected in the "Go" case to be saved to a file. The intent is to collect th...

Web resources about - Issues about applying &quot;parallel tasks&quot; with serial serial port - comp.lang.labview

Resources last updated: 3/19/2016 11:06:32 AM