<?xml version="1.0"?>
<rss version="2.0"><channel><title>Real-Time Latest Topics</title><link>https://lavag.org/forum/13-real-time/</link><description>Real-Time Latest Topics</description><language>en</language><item><title>Debugging of reentrant VIs on RT</title><link>https://lavag.org/topic/9816-debugging-of-reentrant-vis-on-rt/</link><description><![CDATA[<p>Hi.</p>
<p>How about debugging of reentrant VIs on LabVIEW RT (Real Time)? I often need that, or, as a temporary workaround, the ability to specify the target on which to open a VIs front panel on. The latter would entail that reentrant VIs should maintain a copy of their front panels, even on RT, and that this front panel could be spawned on a remote Host, and then connected to the block diagram of the reentrant Vi on the RT target.</p>
<p>Cheers,</p>
<p>Steen</p>
]]></description><guid isPermaLink="false">9816</guid><pubDate>Thu, 02 Apr 2009 10:57:24 +0000</pubDate></item><item><title>Can't Update the Firmware of a Newly Purchased cRIO (Update Firmware Button Missing)</title><link>https://lavag.org/topic/22452-cant-update-the-firmware-of-a-newly-purchased-crio-update-firmware-button-missing/</link><description><![CDATA[<p>
	Just got a cRIO-9047 out of the box.  I am running LabVIEW 2020 SP1 on the host computer, and the cRIO is running firmware 6.1.0f2 (why so old for a device that just shipped?).  We ordered this controller/chassis months ago, but delivery was delayed, supposedly due to the chip shortage.  The host computer is running CompactRIO 21.0 drivers.  When I try to install the latest software (anything newer than 'legacy'), the installer tells me I need to update the firmware on the controller to version 7 first.  However, when I select the device in MAX, the 'Update Firmware' button that is supposed to be on the System Settings tab is missing.  I have 4 sbRIOs on the same subnet, and they are all good (Update Firmware button showing, running newer, non-legacy software loads).  When I run the legacy installer for 20.5, and try to use the 'Update BIOS' button on the installer dialog box, I get a dialog saying the host has no new firmware load higher than the one installed, even though I am running the latest CompactRIO drivers.  Has anyone else had this problem?  Without a solution, I can only run the legacy software load.  Thanks for any help.
</p>

<p>
	 
</p>

<p><a href="https://lavag.org/uploads/monthly_2022_02/1335026469_criosystemsettings.png.5c7f0265d595242565e9fbbbf34c1752.png" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="16480" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="58.31" width="650" class="ipsImage ipsImage_thumbnailed" alt="crio system settings.png" data-src="https://lavag.org/uploads/monthly_2022_02/1335026469_criosystemsettings.png.5c7f0265d595242565e9fbbbf34c1752.png"></a></p>
<p><a href="https://lavag.org/uploads/monthly_2022_02/1759652452_crioupdatebios.png.a3d42f0c1ed6c0f1a35801748c7dba11.png" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="16481" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="83.56" width="663" class="ipsImage ipsImage_thumbnailed" alt="crio update bios.png" data-src="https://lavag.org/uploads/monthly_2022_02/1759652452_crioupdatebios.png.a3d42f0c1ed6c0f1a35801748c7dba11.png"></a></p>]]></description><guid isPermaLink="false">22452</guid><pubDate>Wed, 23 Feb 2022 23:54:46 +0000</pubDate></item><item><title>cRIO complete lockup with no(?) memory leaks</title><link>https://lavag.org/topic/22346-crio-complete-lockup-with-no-memory-leaks/</link><description><![CDATA[<p>
	<em><strong>Warning: this is a very open ended question and I ramble because I'm at the point of tearing my hair out trying to fix this.</strong></em>
</p>

<p>
	We have a remotely deployed cRIO system that requires nothing short of an Act of God to physically access. For the past couple of months we have been trying to troubleshoot a complete cRIO lockup that requires us to power cycle it via a web-based relay between the cRIO and its power supply. This has been happening every 2-5 days on average. The architecture itself is a rtexe that dynamically loads a number of PPLs specified in a config file via Start Asynchronous Call and I've been able to run a similar system on benchtop for weeks without issue.
</p>

<p>
	Physical architecture is a cRIO-9042 with a GPS module, a couple of 9220s, and 2x FD-11601s daisy chained using DAQmx to acquire data from ~70 channels. Software-wise, this particular system launches 6 unique PPLs: (1) performs DAQmx acquisition and publishes its values via a User Event, (2) registers for the DAQ data event and base64 encodes the data and does some other formatting on it to prepare it for network transmission which it sends to a named queue read by another PPL that performs the network transmission, (3) also registers for the DAQ data event and calculates the detection of transient events then sends those results via the same named queue read by the network transmission PPL, (4) one that performs the network transmission, (5) one that reads weather station data via Modbus TCP and formats/sends it to the network transmission PPL via the named queue, (6&amp;7) the same FLIR camera PPL is launched twice but each one targeting a different networked camera which then parses the image and sends it to the network transmission PPL via named queue.
</p>

<p>
	I've monitored memory usage with /proc/meminfo as well as monitoring the specific lvrt application via /proc/(lvrt_proc_id)/status. There seems to be no substantive change in memory over time (i.e., assumedly no leaks) and cRIO CPU usage varies between 10-20% per core, although average seems to be around 13% per core. I do see a very rapid increase in context switches, both voluntary and nonvoluntary, on the order of ~500 voluntary and ~5 nonvoluntary per second, but I have no frame of reference to determine if this is "high" or whether this is even a problem. My Linux knowledge is relatively limited so maybe there's another thing I should be monitoring of which I'm unaware.
</p>

<p>
	Does anybody have any anecdotes about situations where they've had cRIOs crash sporadically without seeing a memory leak and what they did to troubleshoot/debug it? The disappointing thing is the logs I pull from MAX don't even show that anything happened -- it's basically a complete system freeze (doesn't reply to pings from other computers either). I see what I believe to be the power cycle event in the logs once I force the relay on the supply to open/close, but even if I wait days between it going non-responsive and power cycling it I won't see anything representative of the lockup in the logs except the power cycle. We're going through the arduous process of trying to gain physical access to the cRIO so we can look at the status lights on the front and measure the supply voltage when it's frozen, but that'll probably be another couple of weeks before we get permission and I'd love to have a checklist of other potential things we can try in our limited window of time we have physical access.
</p>

<p>
	Unfortunately I can't post any screenshots, let alone any code, due to the nature of the deployment which is why my question is so general and I'm just soliciting some stuff to throw at the wall hoping that it sticks. I've started logging max queue size for the data transmission queue to the cRIO HD, but it consistently remains low enough not to be a concern. We also don't see any delay in ingestion of the data by the database computer -- all of the received timestamps and data are updating completely as expected until the cRIO locks up.
</p>

<p>
	Whether anyone replies to this or not, I feel better that I've ranted so thank you for the mental relief!
</p>
]]></description><guid isPermaLink="false">22346</guid><pubDate>Wed, 01 Dec 2021 17:06:06 +0000</pubDate></item><item><title>Questions about data storage and RAM resource usage in CompactRIO</title><link>https://lavag.org/topic/53531-questions-about-data-storage-and-ram-resource-usage-in-compactrio/</link><description><![CDATA[<p>
	First of all my device is a CRIO-9043.
</p>

<p>
	I want to use one dimensional lookup table for interpolation in FPGA.vi, I am using U16 data type and one lookup table can store 40960 data and I need to store 7 million data. Currently I have inserted only 16 tables and the RAM resources are not enough. My compilation tells me that one lookup table takes up 19 RAM resources (my device has a total of 325 RAM resources).
</p>

<p>
	But on the lookup table it shows that one table uses only 80KB of storage, while on the official website the CRIO-9043 has a RAM size of 2G!
</p>

<p>
	I don't know how to solve this problem. Attached is my program, sorry it's only in Chinese!
</p>

<p><a href="https://lavag.org/uploads/monthly_2024_12/1.png.abc33c680182b6a9446f9fa1e4dbae80.png" class="ipsAttachLink ipsAttachLink_image" ><img data-fileid="22248" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2024_12/1.png.abc33c680182b6a9446f9fa1e4dbae80.png" data-ratio="54.83" width="797" class="ipsImage ipsImage_thumbnailed" alt="1.png"></a></p><p>
<a class="ipsAttachLink" href="https://lavag.org/applications/core/interface/file/attachment.php?id=22247&amp;key=cb4296b065a7f84c9d56f0eca9fc59a4" data-fileExt='vi' data-fileid='22247' data-filekey='cb4296b065a7f84c9d56f0eca9fc59a4'>15.vi</a></p>]]></description><guid isPermaLink="false">53531</guid><pubDate>Mon, 23 Dec 2024 14:22:59 +0000</pubDate></item><item><title>How to implement the expression of discrete transfer function on the LabVIEW FPGA side?</title><link>https://lavag.org/topic/53486-how-to-implement-the-expression-of-discrete-transfer-function-on-the-labview-fpga-side/</link><description><![CDATA[<p>
	<span style="background-color:#ffffff;color:#0d0d0d;font-size:16px;">I have only found this node, named <a href="https://www.ni.com/" rel="external nofollow">Ni</a> FPGA Discrete Transfer Function Direct vi.    Are there other methods to implement a discrete transfer function?</span>
</p>
]]></description><guid isPermaLink="false">53486</guid><pubDate>Tue, 26 Nov 2024 02:23:41 +0000</pubDate></item><item><title>Writing Timed Loops in FPGA Modules</title><link>https://lavag.org/topic/53364-writing-timed-loops-in-fpga-modules/</link><description><![CDATA[<p>
	I now need to program on a labview FPGA module and I need an efficient way to write a timed loop program. The loop program I'm currently using is shown in the diagram, and it looks like the sampling frequency is only 200k, and I'm aiming for 500k.
</p>

<p>
	I know that using User Controlled I/O Sampling Acquire Faster than an I/O Node, but now one of my loops does not involve an I/O Node, and in this loop my program may be too complex to meet the 500k requirement when using the timed loop program as shown.
</p>

<p>
	Is there any other way to write a timed loop?<br />
	Please provide me some help! Thanks!<img class="ipsImage ipsImage_thumbnailed" data-fileid="22181" data-ratio="48.69" width="495" alt="image.png.fc74864fd2f27ab4024717cc3e9cf876.png" data-src="https://lavag.org/uploads/monthly_2024_09/image.png.fc74864fd2f27ab4024717cc3e9cf876.png" src="https://lavag.org/applications/core/interface/js/spacer.png" />
</p>
]]></description><guid isPermaLink="false">53364</guid><pubDate>Sat, 28 Sep 2024 07:10:37 +0000</pubDate></item><item><title>How to implement the expression of discrete transfer function on the LabVIEW FPGA side?</title><link>https://lavag.org/topic/23914-how-to-implement-the-expression-of-discrete-transfer-function-on-the-labview-fpga-side/</link><description><![CDATA[<p>
	<span style="background-color:#ffffff;color:#0d0d0d;font-size:16px;">I have only found this node</span><span style="background-color:#ffffff;color:#0d0d0d;font-size:16px;">, named Nifpga Discrete Transfer Function Direct.vi, but after inputting the transfer function coefficients, its output doesn't work correctly. I tried the same discrete transfer function on the non-FPGA side, and it worked fine. I am not sure what the issue is. Are there other methods to implement a discrete transfer function?</span>
</p>

<p><a href="https://lavag.org/uploads/monthly_2024_05/1332842980_GFLL5LY(ION@J1XQKQM.png.30188d69634899c73f52cd118a6f8605.png" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="18307" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="97.67" width="86" class="ipsImage ipsImage_thumbnailed" alt="GFLL5LY(}%ION@}J1XQK~QM.png" data-src="https://lavag.org/uploads/monthly_2024_05/1332842980_GFLL5LY(ION@J1XQKQM.png.30188d69634899c73f52cd118a6f8605.png"></a></p>]]></description><guid isPermaLink="false">23914</guid><pubDate>Wed, 08 May 2024 14:57:23 +0000</pubDate></item><item><title>Does anyone know anything about 2D interpolation using labview FPGA?</title><link>https://lavag.org/topic/23872-does-anyone-know-anything-about-2d-interpolation-using-labview-fpga/</link><description><![CDATA[<p>
	The point (1,1) corresponds to the value 1, the point (2,2) corresponds to the value 2, when I get the point (0.5,0.5) I need to output the value 0.5, similar to this interpolation<span class="ipsEmoji">😐</span>
</p>
]]></description><guid isPermaLink="false">23872</guid><pubDate>Thu, 18 Apr 2024 12:35:50 +0000</pubDate></item><item><title>How to separate decimals and integers on the FPGA side?</title><link>https://lavag.org/topic/23873-how-to-separate-decimals-and-integers-on-the-fpga-side/</link><description><![CDATA[<p>
	Please give me some advice and help, thanks guys!
</p>
]]></description><guid isPermaLink="false">23873</guid><pubDate>Thu, 18 Apr 2024 14:12:20 +0000</pubDate></item><item><title>FPGA module -Implementation of control algorithms</title><link>https://lavag.org/topic/23844-fpga-module-implementation-of-control-algorithms/</link><description><![CDATA[<p>
	Can you please tell me how to implement this kind of control with transfer function in FPGA module? I can't find any function about transfer function in FPGA! Thanks a lot guys!
</p>

<p><a href="https://lavag.org/uploads/monthly_2024_03/086BC250-E741-4360-8221-BBB9715E9C69.jpeg.6ccaa5c37969988efe1ed697917bd5ed.jpeg" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="18255" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="75.00" width="4032" class="ipsImage ipsImage_thumbnailed" alt="086BC250-E741-4360-8221-BBB9715E9C69.jpeg" data-src="https://lavag.org/uploads/monthly_2024_03/086BC250-E741-4360-8221-BBB9715E9C69.jpeg.6ccaa5c37969988efe1ed697917bd5ed.jpeg"></a></p>]]></description><guid isPermaLink="false">23844</guid><pubDate>Wed, 27 Mar 2024 10:36:10 +0000</pubDate></item><item><title>FTDI driver library wrapper VIs for NI RT Linux</title><link>https://lavag.org/topic/23825-ftdi-driver-library-wrapper-vis-for-ni-rt-linux/</link><description><![CDATA[<p>
	Since FTDI chips are recognized by NI RT Linux out of the box these days, I assume the OS comes packaged with the FTDI chip drivers for Linux.  Are there wrapper VI's available for the RTOS for calling the driver library?  If not, does anyone know off hand where the external driver library is located so I can set up the Call Library function for it?  Thanks in advance.
</p>
]]></description><guid isPermaLink="false">23825</guid><pubDate>Mon, 18 Mar 2024 17:24:58 +0000</pubDate></item><item><title>NI-serial on RT target</title><link>https://lavag.org/topic/23768-ni-serial-on-rt-target/</link><description><![CDATA[<p>
	Hi experts,
</p>

<p>
	I am currently trying to work with an RS485 device connected to my sbRIO9627 RS485 port. The manufacturer developed a LabVIEW library to communicate with the device with a ModBus RTU protocol, requiring both NI-VISA and NI-Serial installed on the target. It worked fine at the beginning, then after a necessary format of the RT target, I am now not able to install the NI-serial drivers on the sbRIO as before, and the communication fails with a timeout error, but I still don't get any deploy or execution error.
</p>

<p>
	The NI-serial drivers do not appear in the list of items I can install during the software installation on the target.
</p>

<p>
	Does anyone have a clue about this? 
</p>

<p>
	I am currently working with LabVIEW 2020, Linux RT image 21.0, NI-MAX 21.0f0, and I have to stick to LabVIEW 2020. 
</p>

<p>
	 
</p>

<p>
	Thanks in advance for your help
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">23768</guid><pubDate>Thu, 08 Feb 2024 08:46:13 +0000</pubDate></item><item><title>Package installation on sbRIO9627</title><link>https://lavag.org/topic/23026-package-installation-on-sbrio9627/</link><description><![CDATA[<p>
	Hi all, 
</p>

<p>
	I am trying to install an external package, OPENG ZIP library, on an sbRIO 9627. I currently work with LabView 2021, I installed on the sbRIO RT Linux version 21.8 and LabVIEW 2021, but the OPENG ZIP library does not appear in the list of available packages in the MAX. I already enabled the offline installation and installed the library on my system via VIPM 2021, I can see it in LabVIEW and correctly write code using the library VIs. 
</p>

<p>
	Moreover, everything was working smoothly on LabVIEW 2019.
</p>

<p>
	How can I solve this problem? 
</p>

<p>
	 
</p>

<p>
	Thanks in advance
</p>
]]></description><guid isPermaLink="false">23026</guid><pubDate>Tue, 28 Feb 2023 15:36:56 +0000</pubDate></item><item><title>Download Labview Real-Time 8.0</title><link>https://lavag.org/topic/22865-download-labview-real-time-80/</link><description><![CDATA[<p>
	HI! I am new in this forum. I have searched a lot for the Labview Real-Time version 8.0 without any success. I am writing in case anyone has the link, zip, rar, iso or any format with this version. It is for an old PXI. Thank you very much in advance!
</p>
]]></description><guid isPermaLink="false">22865</guid><pubDate>Mon, 09 Jan 2023 08:47:57 +0000</pubDate></item><item><title>Detecting and acting on system reboot</title><link>https://lavag.org/topic/22803-detecting-and-acting-on-system-reboot/</link><description><![CDATA[<p>
	Hi,
</p>

<p>
	We have a PXI-system with a PXIe-8821 controller running LabVIEW RT (PharLap). On this controller we have a deployed LabVIEW developed application. So all standard so far.
</p>

<p>
	From time to time the application ends up in an erroneous state. Since the overall system is relatively complex and used as a development tool for another system, it is tedious to detect and debug each situation that leads to an error. So the current solution is to regularly reboot the controller. Both at a fixed time interval and when the controller is suspected to be in an erroneous state.
</p>

<p>
	To achieve this remotely we send a reboot command by spoofing the HTTP POST command sent when clicking on the "restart button" in NI's web based configuration GUI. I was surprised that this worked, but it does, and it does so pretty well.
</p>

<p>
	But there is an issue: we have an instrument that can get upset if the reference to it isn't closed down properly. And since this reboot on system level harshly close down our application this has increasingly started to become an issue.
</p>

<p>
	 
</p>

<p>
	So I have two questions:
</p>

<ol>
	<li>
		Is there a way to detect that a system reboot is imminent and allowing the LabVIEW application to act on it? Closing down references and such.
	</li>
	<li>
		Is there another way to remotely reboot a controller? I am aware of the built in system vi's but those are more about letting the controller reboot itself. What I'm looking for is a method to remotely force a reboot.
	</li>
</ol>

<p>
	 
</p>

<p>
	Any input is most welcome!
</p>
]]></description><guid isPermaLink="false">22803</guid><pubDate>Mon, 14 Nov 2022 08:09:34 +0000</pubDate></item><item><title>I need to run a new .rtexe deployed into a cRIO without rebooting.</title><link>https://lavag.org/topic/22796-i-need-to-run-a-new-rtexe-deployed-into-a-crio-without-rebooting/</link><description><![CDATA[<p>
	Hello guys,
</p>

<p>
	I need to deploy a <strong>startup.rtexe</strong> into my cRIO-9049 (from LabVIEW Project Explorer or CLI, whatever), and I need to use the <strong>./nilvrt start</strong> and <strong>./nilvrt stop</strong> commands to start and stop the RT App respectively, at will. I noted that it is mandatory to reboot the cRIO after deploying the .rtexe to use the  <strong>./nilvrt start</strong> and <strong>./nilvrt stop. </strong>However, I must avoid rebooting the cRIO (because of my customer requirements). I was trying to find a setting for this, but the only file I found related to the startup.rtexe is the <strong>/etc/natinst/share/lvrt.conf</strong> file with the token <strong>RTTarget.LaunchAppAtBoot</strong>. This key is set to True when the <strong>Run As Startup</strong> option is selected from the LabVIEW Project Explorer. I put this key in False to check if this allows me to run the RT App without rebooting the cRIO, but this did not help <span class="ipsEmoji">😔</span>.
</p>

<p>
	Is there another config file to be modified in order to support what I need to do? 
</p>

<p>
	Is it completely necessary to reboot the cRIO to recognize the new .rtexe and use the <strong>./nilvrt start</strong> and <strong>./nilvrt stop</strong> commands?
</p>

<p>
	Thanks!
</p>
]]></description><guid isPermaLink="false">22796</guid><pubDate>Wed, 09 Nov 2022 21:13:20 +0000</pubDate></item><item><title>Executing .rtexe from CLI... is it possible?</title><link>https://lavag.org/topic/21968-executing-rtexe-from-cli-is-it-possible/</link><description><![CDATA[<p>
	Hi guys,
</p>

<p>
	 
</p>

<p>
	A newbie question - say, I have a compactRIO running Linux Real-Time system and it runs my .rtexe set as startup
</p>

<p>
	at the boot. I wonder if there is a way to execute this .rtexe arbitrarily from CLI or by any other means, so you can
</p>

<p>
	actually have a few .rtexe on the system and pick and choose which ones to run at will?
</p>

<p>
	 
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">21968</guid><pubDate>Thu, 11 Mar 2021 16:21:30 +0000</pubDate></item><item><title>Ack , need help with cRIO 9035 ASAP</title><link>https://lavag.org/topic/22677-ack-need-help-with-crio-9035-asap/</link><description><![CDATA[<p>
	Ok , I have a project I need to work on , with out a ton of time , 1.5 months , it uses cRIO (9035 Chassis) , I just need a quick primer on AI,AO and DO... I am reading as much as I can .... but , any examples would be greatly appreciated ...
</p>

<p>
	Ni-Max and <abbr title="LabVIEW"><abbr title="LabVIEW">LV</abbr></abbr> see the 9035 , I have RT and FPGA licenses , Ni-Max says I have all the s/w , but , I cant find how to do a test in Ni-Max like the examples I see on NI.com
</p>

<p>
	I am connected via USB , ultimately it needs to be connected via Ethernet ....
</p>

<p>
	I know I am asking a lot at the moment , but , anything that can get me going would be fantastic.... 
</p>

<p>
	Regards
</p>

<p>
	Dan
</p>
]]></description><guid isPermaLink="false">22677</guid><pubDate>Tue, 23 Aug 2022 22:39:45 +0000</pubDate></item><item><title>Calling a bash script on RT target programmatically</title><link>https://lavag.org/topic/22533-calling-a-bash-script-on-rt-target-programmatically/</link><description><![CDATA[<p>
	The task is simple - call Florence virtual keyboard on a CompactRIO programmatically but I must be overlooking something as I cannot get it to work...
</p>

<p>
	I have Florence installed with opkg and I also made a little bash script to call it. When I execute it from CompactRIO terminal - everything works but if I try to call the script from my application using SytemExec VI - I get the echo output from my script and the error code is 0 but the virtual keyboard does not start. Seems like a trivial problem but I am stuck here...
</p>

<p>
	Can someone explain to me what I've done wrong here and/or, maybe, suggest a better way of doing it, please?
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">22533</guid><pubDate>Thu, 12 May 2022 13:48:18 +0000</pubDate></item><item><title>Programmatically upload the RT code and FPGA bitfile to an sbRIO target</title><link>https://lavag.org/topic/22370-programmatically-upload-the-rt-code-and-fpga-bitfile-to-an-sbrio-target/</link><description><![CDATA[<p>
	Hello,
</p>

<p>
	in the LabVIEW environment one can easily execute a RT vi and if the FPGA bitfile is compiled it is automatically downloaded to the sbRIO target. It is very easy to stop the VI and quickly run a different one.
</p>

<p>
	Without LabVIEW, one can from NI max, via the firmware update, change the code of the FPGA on the sbRIO, but it is much more time consuming.
</p>

<p>
	What we would like is to have a couple of applications on the PC built with the LabVIEW application builder. The PC application should check if the required RT code and FPGA bitfile are already on the target, and if not, upload it and run it.
</p>

<p>
	I do not know if there is a way to achieve that?
</p>

<p>
	Any hints?
</p>

<p>
	Thank you for your help.
</p>
]]></description><guid isPermaLink="false">22370</guid><pubDate>Thu, 23 Dec 2021 11:48:06 +0000</pubDate></item><item><title>NI-9853 FPGA CAN start up code</title><link>https://lavag.org/topic/22225-ni-9853-fpga-can-start-up-code/</link><description><![CDATA[<p>
	Hi guys,
</p>

<p>
	 
</p>

<p>
	I really need some help to kick off J1939 CAN interface development on NI-9853 FPGA.
</p>

<p>
	There are some CANopen examples on the internet but nothing for J1939 and I don't even know where to start.
</p>

<p>
	What makes life even more difficult is that the CAN module is residing on the Ethernet expansion chassis NI-9147.
</p>

<p>
	 
</p>

<p>
	If anyone could give me something to start with that would be absolutely fantastic.
</p>

<p>
	Thank you in advance.
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">22225</guid><pubDate>Thu, 30 Sep 2021 17:29:21 +0000</pubDate></item><item><title>Phar Lap and FTDI</title><link>https://lavag.org/topic/22090-phar-lap-and-ftdi/</link><description><![CDATA[<p>
	Hello experts,
</p>

<p>
	<br>
	I would like to communicate via Phar Lab with a USB device that uses an FTDI chip. Is this easily possible?
</p>

<p>
	Is there a RS232 to USB converter that can be used under Pharlab? A converter for a converter <img alt=":)" data-emoticon="" src="https://lavag.org/applications/core/interface/js/spacer.png" title=":)" data-src="https://lavag.org/uploads/emoticons/default_smile.png">
</p>

<p>
	I would be very grateful for any suggestions.
</p>

<p>
	<br>
	Greetings, Jim
</p>
]]></description><guid isPermaLink="false">22090</guid><pubDate>Tue, 29 Jun 2021 14:30:32 +0000</pubDate></item><item><title>Remote system image creation error and files that are unable to be coppied/removed</title><link>https://lavag.org/topic/22021-remote-system-image-creation-error-and-files-that-are-unable-to-be-coppiedremoved/</link><description><![CDATA[<p>
	Hi everyone.
</p>

<p>
	I'm writing an Utility to retrieve image from Remote RT PXI system under PharLap 15 and RealTime 15. I use Create System Image.vi for that. During the execution this vi returns an error with code -2147220331 and description that some files on remote system might be corrupted. I desided to find out what is wrong with files and what are this files.
</p>

<p>
	So I have "config3.mxs", "config3.mxs.jnl" and "RT" (with no extension).
</p>

<p>
	What kind of problem is this?
</p>
]]></description><guid isPermaLink="false">22021</guid><pubDate>Wed, 21 Apr 2021 10:34:49 +0000</pubDate></item><item><title>Reducing deployment time on cRIO</title><link>https://lavag.org/topic/22013-reducing-deployment-time-on-crio/</link><description><![CDATA[<p>
	Hi
</p>

<p>
	I am currently involved in a project with a test sequencer based on actor framework executed on cRIO platform. One major problem that arose, is very long deploy times for the code to the cRIO. Meaning the start LabVIEW code in debug mode. It takes up to 8 minutes to get the code started.
</p>

<p>
	I want to create a strategy on how to optmize the project to reduce the deploy times. And would be glad to receive some work experiances from the field.
</p>

<p>
	We use LV2020. LVOOP is heavily used.<br />
	We do not use precompiled libraries yet. We heard from another company, that they had problems using it with actor framework, but cannot say what exactly was the problem. Are there any?
</p>

<p>
	Thank you in advance.
</p>

<p>
	Dermot
</p>
]]></description><guid isPermaLink="false">22013</guid><pubDate>Tue, 13 Apr 2021 09:58:13 +0000</pubDate></item><item><title>Tip on how to copy RT build specs to new type of target</title><link>https://lavag.org/topic/21811-tip-on-how-to-copy-rt-build-specs-to-new-type-of-target/</link><description><![CDATA[<p>
	Just thought I should share this little trick I have successfully used for a number of multi-target projects now. LabVIEW does not allow you to copy build specs to another target, or change the target hardware for an existing one, and our build specs are often quite elaborate with a lot of different destination folders/llbs. Having to recreate them manually is a lot of tedious and error prone work. <span class="ipsEmoji">🤢</span><br>
	<br>
	So, until NI decides to support an automatic conversion (which based on the method below should be easy even if they need to take some extra considerations across the spectrum of targets...), I have found another way:<br>
	<br>
	Open the lvproj file in a text editor, preferably one that has some XLM-support (I use NotePad+).
</p>

<p>
	1. Copy the/one of the existing target item sections to a temporary file.
</p>

<p>
	2. edit/replace the target header to define the right target type and hardware, an example is highlighted in the image below:
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="15345" data-ratio="40.74" width="950" alt="image.png.5923704f678c83972eb963cf57328195.png" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_10/image.png.5923704f678c83972eb963cf57328195.png">
</p>

<p>
	(If you do not know the correct DeviceCode (7740 in the case of 9063) and CCSymbol-values for the new target you can always figure it out by adding an empty target of that type to the project first...the device codes are also listed in your firmware folder and on the web.)
</p>

<p>
	3. Then replace all instances of the reference to that target name with the new one in the rest of the spec, here the cRIO-9063 part would be replaced with cRIO-9030 if that is the name of the new target we need:
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="15344" data-ratio="14.64" width="1038" alt="image.png.bb6b4eb85b64596d44ab1aa3aba4ad58.png" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_10/image.png.bb6b4eb85b64596d44ab1aa3aba4ad58.png">
</p>

<p>
	4. Now add the new item to the original project file and save.
</p>

<p>
	A possible next step would be to write a little VI that does this automatically for you, you could make it recreate the build spec of a given target for a whole bunch of targets automatically....I have not done that yet. So far I am happy saving lots of time this way already <span class="ipsEmoji">😀</span>
</p>

<p>
	I have not discovered any pitfalls yet, but perhaps there are(?) The applications build and run fine on each target... 
</p>

<p>
	In my case all the target build specs are/can be identical (in some cases I might need to change a conditional disable symbol here and there though), but if yours are not then you can still use this shortcut to do parts of the job.
</p>
]]></description><guid isPermaLink="false">21811</guid><pubDate>Fri, 30 Oct 2020 11:24:53 +0000</pubDate></item><item><title>FIFO Acquire Read Region Method</title><link>https://lavag.org/topic/21688-fifo-acquire-read-region-method/</link><description><![CDATA[<p>
	Can anyone shed some light for me on the best practices for the FIFO Acquire Read Region technique? I have never used this before, I always have just done the usual trick of reading zero elements to get the size of the buffer and then reading if there are enough elements for my liking. To my knowledge this was a good technique and I have used it quite a few times with no actual worries (including in some VST code with a ridiculous data rate).
</p>

<p>
	This screenshot is taken from <a href="http://zone.ni.com/reference/en-XX/help/371599P-01/lvfpgahelp/fpga_zerocopy_dma/" rel="external nofollow">here</a>.
</p>

<p>
	 
</p>

<p>
	<img alt="image.png.f122522ef944f47c4f6f331feda28ac8.png" class="ipsImage ipsImage_thumbnailed" data-fileid="15137" data-ratio="31.78" width="859" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_07/image.png.f122522ef944f47c4f6f331feda28ac8.png">
</p>

<p>
	 
</p>

<p>
	Is this code really more efficient? Does the Read Region block with high CPU usage like the Read FIFO method does? (I don't want that)
</p>

<p>
	Has anyone used this "new" technique successfully?
</p>

<p>
	For reference this is my current technique:
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="15138" data-ratio="37.72" width="1200" alt="image.png.a499c3abedd8170faf770475fb843f11.png" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_07/image.png.a499c3abedd8170faf770475fb843f11.png">
</p>
]]></description><guid isPermaLink="false">21688</guid><pubDate>Sat, 25 Jul 2020 22:00:45 +0000</pubDate></item><item><title>LV2020 RT Madness</title><link>https://lavag.org/topic/21677-lv2020-rt-madness/</link><description><![CDATA[<p>
	Urgh, I am working on a new framework for RT and LabVIEW has gotten itself so confused. I am getting really weird things when I try and duplicate some of my (homegrown) actor classes. LabVIEW is searching for some of the RT utilities in totally the wrong directory.
</p>

<p>
	I have tried mass compiling and often that just crashes, but I did manage to get this log message:
</p>

<p>
	Search failed to find "NI_Real-Time Target Support.lvlib:RT Get CPU Loads.vi" previously from "&lt;vilib&gt;:\Utility\RT Get CPU Loads.vi"  +=+   Caller: "System Status Actor.lvclass:Update.vi"
</p>

<p>
	Now,<strong> this library does not exist at that directory</strong>, rather there is another vi.lib in Targets\NI\RT and it lives in that vi.lib directory
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="15113" data-ratio="32.57" width="915" alt="image.png.aef58560c4333ffbd640da20f61feca5.png" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_07/image.png.aef58560c4333ffbd640da20f61feca5.png">
</p>

<p>
	Now I am kinda stuck... My code runs sort of ok. Sometimes it just refuses to run on the cRIO (but I have seen this behaviour with RT for years now so just gotten used to it) but I cannot mass compile it or it just crashes. I have tried resetting the class mutation history but his also crashes LabVIEW <span><span class="ipsEmoji">😞</span></span>
</p>

<p>
	Any ideas what I can try? This is a real pain. I do of-course have my history in git, but I don't really feel like trying to step back in time and figuring out what the heck actually happened.
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">21677</guid><pubDate>Tue, 21 Jul 2020 19:25:38 +0000</pubDate></item><item><title>Efficient Real-Time Development Practices</title><link>https://lavag.org/topic/19760-efficient-real-time-development-practices/</link><description><![CDATA[<p>
	So lets say I have a single project, and in it is two targets, a Windows host, and the RT.  Many of the libraries I use in the Windows side, I also use on the RT side.  But I think that this is causing lots of unnecessary "Compiling" of VIs over and over depending on which target I'm open the code from.
</p>

<p>
	Here's an example.  I have a Windows Main.vi, and a RT Main.vi both under their appropriate targets.  If I open the Windows Main.vi it opens relatively quickly, and loads about 2000 VIs and shows the main.  But if I then open the RT Main.vi, it goes through and compiles about 200 of those VIs taking several minutes to open.  So after both are open I perform a Save All, thinking whatever it needed to compile and do it should be done with.  If I then close the project and re open it, and then open the Windows Main.vi it has to recompiles those 200 VIs presumably for the new target, and then if I open the RT Main it has to recompile those 200 VIs again.  Is this how it is supposed to be? Every time I reopen a VI on a new target am I supposed to see it recompile for that target back and forth depending on where it was opened last?
</p>

<p>
	The project has a mix of VIs that have separate compiled code on and some with it off.  Not sure which is better for this.
</p>

<p>
	My computer is relatively powerful, but lately doing LabVIEW development makes me feel like I'm using a 10 year old PC.  Everything about my computer seems fast except LabVIEW development.  Is there tips or tricks, or options I should be using to help make my LabVIEW development more responsive, and require less recompiling when switching targets?
</p>

<p>
	EDIT:  It seems that the VIs that need to recompile all the time are VIs that are in a Polymorphic VI, so the majority of them are reuse and OpenG VIs.
</p>

<p>
	Double Edit:  It seems this thread from an older post on LAVA claims that the compiled cache has separate entries for a VI on multiple targets, so I'm not sure why these VIs need to recompile every time...
</p>
]]></description><guid isPermaLink="false">19760</guid><pubDate>Wed, 17 Aug 2016 15:23:40 +0000</pubDate></item><item><title>Show FP Window (Programatically)</title><link>https://lavag.org/topic/21663-show-fp-window-programatically/</link><description><![CDATA[<p>
	Am I being dumb here?
</p>

<p>
	I have a linux based cRIO and have two problems, surely related:
</p>

<ol>
	<li>
		I want a VI to show its FP when called (just using the tick boxes in the SubVI Node Setup config)
	</li>
	<li>
		I want to be able to programmatically show and hide front panel windows. I pass a message to one of my running VIs and tell it to open the FP Window
	</li>
</ol>

<p>
	Neither of these seem to work. In (1) the SubVI is definitely running it just does not show the FP window and (2) the method to open the FP window executes and there is no error in the code but nothing visibly changes
</p>

<p>
	Now, this is not the kind of thing I have done in the past with a cRIO as I am used to running them headless.
</p>

<p>
	<strong>Note: I do not actually have a display plugged into the cRIO, I was expecting the windows to open on my dev PC. Is this the mistake I am making?</strong>
</p>

<p>
	<strong>Note2: if I move all this code out of the RT platform to the My Computer bit everything works perfectly as expected.</strong>
</p>

<p>
	<strong>Note3: I probably should have mentioned this, the VI I am trying to control is a preallocated re-entrant clone. If I change it to non-reentrant then (1) works correctly but not (2)</strong>
</p>
]]></description><guid isPermaLink="false">21663</guid><pubDate>Tue, 14 Jul 2020 18:19:36 +0000</pubDate></item><item><title>Linux RT CompactRIO segmentation fault</title><link>https://lavag.org/topic/21639-linux-rt-compactrio-segmentation-fault/</link><description><![CDATA[<p>
	Hi all,
</p>

<p>
	I am running a real-time LabVIEW application that calls into compiled .so file. I am getting occasional crashes of the entire system, and the error log shows a segfault
</p>

<p>
	#Date: Mon, Jun 29, 2020 04:59:16 PM<br>
	#Desc: LabVIEW caught fatal signal<br>
	18.0.1 - Received SIGSEGV<br>
	Reason: address not mapped to object<br>
	Attempt to reference address: 0x0x4<br>
	#RCS: unspecified<br>
	#OSName: Linux<br>
	#OSVers: 4.9.47-rt37-ni-6.1.0f0<br>
	#OSBuild: 264495<br>
	#AppName: lvrt<br>
	#Version: 18.0.1<br>
	#AppKind: AppLib<br>
	#AppModDate:
</p>

<p>
	 
</p>

<p>
	am I correct in blaming this on the code in the compiled .so file (which happens to be a ZeroMQ library) ? There really isn't a way for LabVIEW code to create a segfault AFAIK-- you don't have direct access to memory.
</p>

<p>
	Also posted on the darkside but not expecting any response there.
</p>
]]></description><guid isPermaLink="false">21639</guid><pubDate>Tue, 30 Jun 2020 16:42:52 +0000</pubDate></item><item><title>Need help with populating the time of RT device on host software</title><link>https://lavag.org/topic/21470-need-help-with-populating-the-time-of-rt-device-on-host-software/</link><description><![CDATA[<p>
	I am working on a project need to tracking objects in real time by vision. I need to populate the information on the host software. This is still in the process of developing so I want to have the time of the device populate on the screen of the host software like in MAX. Is there a function allow me to do that?
</p>

<p>
	Thanks in advance.
</p>
]]></description><guid isPermaLink="false">21470</guid><pubDate>Fri, 27 Mar 2020 13:28:48 +0000</pubDate></item><item><title>Linux cRIO Memory Usage</title><link>https://lavag.org/topic/21345-linux-crio-memory-usage/</link><description><![CDATA[<p>
	As per <a href="https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P9usSAC&amp;l=en-ZA" rel="external nofollow">this </a>KB it is no longer possible to retrieve the memory usage using the System Session property nodes. Considering the Linux implementation is several years old already this seems like quite an oversight but not something NI seems terribly worried about. The solution proposed in the KB seems quite incomplete.
</p>

<p>
	Strangely, NI do have a way to get this info as it is reported in MAX
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="14522" data-ratio="60.17" width="467" alt="image.png.2cdd012bbb98a8d10b041b99a83c16f3.png" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2020_01/image.png.2cdd012bbb98a8d10b041b99a83c16f3.png">
</p>

<p>
	 
</p>

<p>
	Does anyone have a solution for this?
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">21345</guid><pubDate>Sun, 12 Jan 2020 09:55:25 +0000</pubDate></item><item><title>JKI Caraya on a real time target</title><link>https://lavag.org/topic/20569-jki-caraya-on-a-real-time-target/</link><description><![CDATA[<p>
	Hello guys,
</p>

<p>
	The interface of caraya generated by the test suite appears only if the test program is running on my computer.
</p>

<p>
	if I run the test code in a PXI RT Target, the interface will not show up
</p>

<p>
	Is there any solution to make it appears on my computer.
</p>

<p>
	Thank you
</p>
]]></description><guid isPermaLink="false">20569</guid><pubDate>Tue, 03 Jul 2018 15:00:56 +0000</pubDate></item><item><title>myRIO ADC, max sample rate</title><link>https://lavag.org/topic/21161-myrio-adc-max-sample-rate/</link><description><![CDATA[<p>
	Hello colleagues! I have a next task: It is necessary to get analog data from 4 ADC channels of myRIO with max sample rate. As we know myRIO has max rate 500 kS/s for all channels. So we have 125 kS/s per channel (500/4). It's good. A question in the next: how I can send data from FPGA target to RT in this case? I have tried to use large size FIFO buffer (target to host) but got compilation error. As I understood FIFO buffer doesn't use external memory for data storage and uses FPGA resources. The next step I think to use max available size buffer and interrupt on host when buffer is full, but in this case I will probably get skips in data stream, because interrupt requires about 400 us. Can I read data from buffer on RT level with invoke node in parallel data writing on FPGA target? Will there be an overlay in this case? And where I can read any info about fast data logging with RIO platform?
</p>

<p>
	choose files... Click to choose files
</p>

<p>
	Thank you for your help.
</p>

<p>
	<a class="ipsAttachLink ipsAttachLink_image" data-fileext="PNG" data-fileid="14336" href="https://lavag.org/uploads/monthly_2019_09/Capture.PNG.b598c6ea73de4c9c1fa035dbfe333fc1.PNG" rel=""><img alt="Capture.PNG" class="ipsImage ipsImage_thumbnailed" data-fileid="14336" data-ratio="76.46" width="909" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2019_09/Capture.PNG.b598c6ea73de4c9c1fa035dbfe333fc1.PNG"></a>
</p>
]]></description><guid isPermaLink="false">21161</guid><pubDate>Wed, 04 Sep 2019 15:06:44 +0000</pubDate></item><item><title>Desktop Labview Real Time (Phar Lap ETS OS) discontinued?</title><link>https://lavag.org/topic/21141-desktop-labview-real-time-phar-lap-ets-os-discontinued/</link><description><![CDATA[<p>
	Hello, experts,
</p>

<p>
	in the current description of the NI Vision Acquisition Software it says:
</p>

<p>
	<a href="http://www.ni.com/pdf/manuals/375130k.html" rel="external nofollow"><font color="#0066cc">http://www.ni.com/pdf/manuals/375130k.html</font></a>
</p>

<p>
	<strong><em>Deprecated Features<br>
	<span class="ipsEmoji">◾</span>NI - IMAQ 19.0<br>
	....<br>
	<span class="ipsEmoji">◾</span>Removed support for LabVIEW Real-Time targets running Phar Lap ETS OS</em></strong>
</p>

<p>
	 
</p>

<p>
	Will the OS Labview Real Time (Phar Lap ETS OS) be discontinued and is there an alternative based on Linux?
</p>

<p>
	a good time
</p>

<p>
	Jim
</p>
]]></description><guid isPermaLink="false">21141</guid><pubDate>Tue, 20 Aug 2019 07:09:40 +0000</pubDate></item><item><title>how to convert low status to high status</title><link>https://lavag.org/topic/21157-how-to-convert-low-status-to-high-status/</link><description><![CDATA[<p>
	<a class="ipsAttachLink" data-fileid="14330" href="https://lavag.org/applications/core/interface/file/attachment.php?id=14330" data-fileext="vi" rel="">Coil_IP.vi</a>   
</p>

<p>
	i want to low status 25ns is high status but hi2 case can't achieve, please help me
</p>

<p>
	<br>
	thanks you
</p>

<p><a href="https://lavag.org/uploads/monthly_2019_08/666.PNG.b7628dc461971dbeffb4e8631f3faa24.PNG" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="14331" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="10.31" width="970" class="ipsImage ipsImage_thumbnailed" alt="666.PNG" data-src="https://lavag.org/uploads/monthly_2019_08/666.PNG.b7628dc461971dbeffb4e8631f3faa24.PNG"></a></p>]]></description><guid isPermaLink="false">21157</guid><pubDate>Tue, 27 Aug 2019 08:13:13 +0000</pubDate></item><item><title>How to recompile an image</title><link>https://lavag.org/topic/21133-how-to-recompile-an-image/</link><description><![CDATA[<p>
	Which kind-hearted person can give you some advice：
</p>

<p>
	How to recompile an image that can run on ZYNQ according to the LINUX RT source code on GITHUB?<br>
	The links are as follows:<br>
	<a href="https://github.com/ni/nilrt/tree/nilrt/15.0" rel="external nofollow">Https://github.com/ni/nilrt/tree/nilrt/15.0</a>
</p>
]]></description><guid isPermaLink="false">21133</guid><pubDate>Fri, 16 Aug 2019 07:21:41 +0000</pubDate></item><item><title>Communication issues EtherCAT cRIO 9039</title><link>https://lavag.org/topic/20987-communication-issues-ethercat-crio-9039/</link><description><![CDATA[<p>
	hi,
</p>

<p>
	We are trying to connect a third party EtherCAT slave device to our cRIO 9039, which is configured as an etherCAT master. Problems arise when we try to activate the scan engine of the cRIO. The following error message appears: (see attached). Therefore the scan engine is pretty much stuck in its 'Init'  state and the cRIO is unable to communicate I/O data. We have been able to resolve the issue by replacing the cRIO 9039 with a Beckhoff PLC, suggesting that the third party hardware and .XML file are not at fault.  
</p>

<p>
	Other things we tried to solve the problem include: install the correct Labview version (2018 SP1), device drivers (NI RIO 18.5) and industrial communication EtherCAT package (18.5). Unfortunately this did not resolve the issue.
</p>

<p>
	All suggestions are much appreciated! <span class="ipsEmoji">😄</span>  
</p>

<p><a href="https://lavag.org/uploads/monthly_2019_05/257598682_errorscanengine.PNG.827dfe7f0797f9e4707ffb5410c549c8.PNG" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="14131" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="67.90" width="324" class="ipsImage ipsImage_thumbnailed" alt="error scanengine.PNG" data-src="https://lavag.org/uploads/monthly_2019_05/257598682_errorscanengine.PNG.827dfe7f0797f9e4707ffb5410c549c8.PNG"></a></p>]]></description><guid isPermaLink="false">20987</guid><pubDate>Mon, 27 May 2019 14:41:54 +0000</pubDate></item><item><title>Problem with creation of files with a spacebar</title><link>https://lavag.org/topic/20991-problem-with-creation-of-files-with-a-spacebar/</link><description><![CDATA[<p>
	Hello, 
</p>

<p>
	I have recently hit a peculiar issue when I was deploying a source distribution (SD) on a PXI Target running PharLap. The source of SD contained vis from NI's httpClient library,  so the SD itself contained (among many others) two files Get Lib.vi and GET.vi in one folder. <br>
	Upon attempt to upload the SD to target via FTP, I have seen no errors no warnings, but trying to dynamically launch a file from SD that used httpClient resulted in thread stack overflow.  
</p>

<p>
	By close inspection I have found out that I miss GET.vi file on the target. Moreover I was unable to upload this file by FTP.
</p>

<p>
	Then I run code from snippet on the target can see Error 10 (duplicate path) appearing each time I want to create a file which name part matches "part before a spacebar" of existing file.
</p>

<p>
	This  "feature" prevents me from using httpclient library on RT target, that I am heavily dependent upon.
</p>

<p>
	Is there a way to overcome this problem ?
</p>

<p>
	 
</p>

<p><a href="https://lavag.org/uploads/monthly_2019_05/fileError.png.3251accbcda6707bcf48ab5fee93bbe5.png" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="14133" src="https://lavag.org/applications/core/interface/js/spacer.png" data-ratio="28.38" width="976" class="ipsImage ipsImage_thumbnailed" alt="fileError.png" data-src="https://lavag.org/uploads/monthly_2019_05/fileError.png.3251accbcda6707bcf48ab5fee93bbe5.png"></a></p>]]></description><guid isPermaLink="false">20991</guid><pubDate>Tue, 28 May 2019 12:52:25 +0000</pubDate></item><item><title>Shared Variable RT FIFO: Logging Application</title><link>https://lavag.org/topic/20948-shared-variable-rt-fifo-logging-application/</link><description><![CDATA[<p>
	Hello everyone,
</p>

<p>
	I'm trying to make a data acquisition and logging application for a PXI-8133 with PXI-4300 analog voltage input module, using shared variable single process with RT-FIFO enabled, but I'm having some issues with that.
</p>

<p>
	I'm using a determinist loop for data aquisition and other while loop for logging. But, my log file is losing data, sometimes part of the signal is lost, sometimes the buffer is larger than the amount of data and saves a sequence of zeros. I'm having difficulty adjusting the values for the fifo buffer.
</p>

<p>
	Here are some questions:<br>
	1- Should I use single element or multi-element at FIFO type? I believe a multi-element allows me to have a buffer, right?<br>
	2.1- Points per waveform in RF-FIFO settings should be exactly equal to the size of the waveform read in each execution of the timed loop or can it be larger?<br>
	2.2- The number points in the waveform read in the timed loop keeps oscillating, depending on the sampling rate. Is it normal?<br>
	4- Should the logging loop run faster than the timed loop or at the same rate?
</p>

<p>
	Thank-you !!
</p>

<p>
	 
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="14080" data-ratio="54.56" width="801" alt="Capturar.JPG.e6d7d56fc2bcb83deffbbd9404ce7bda.JPG" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2019_05/Capturar.JPG.e6d7d56fc2bcb83deffbbd9404ce7bda.JPG">
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="14081" data-ratio="46.30" width="1200" alt="Capturar2.JPG.18f388c9a8eba605acb96635dd258da7.JPG" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2019_05/Capturar2.JPG.18f388c9a8eba605acb96635dd258da7.JPG"><img class="ipsImage ipsImage_thumbnailed" data-fileid="14082" data-ratio="58.96" width="921" alt="Capturar3.JPG.b5c176227c973fcdf36a8b2b16d6974e.JPG" src="https://lavag.org/applications/core/interface/js/spacer.png" data-src="https://lavag.org/uploads/monthly_2019_05/Capturar3.JPG.b5c176227c973fcdf36a8b2b16d6974e.JPG">
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">20948</guid><pubDate>Wed, 08 May 2019 16:12:05 +0000</pubDate></item><item><title>cRIO TCP/IP Problems</title><link>https://lavag.org/topic/11372-crio-tcpip-problems/</link><description><![CDATA[<p>Hi,</p>
<p>at the moment I am working at a Projekt where I have to transfer much Data via TCP/IP and handle them via RT-FIFO´s .</p>
<p>So far so good.</p>
<p>But I had a lot of Problems with the cRIO TCP functions. If I send to much Data, Data gets lost or Fifo References got lost.</p>
<p>Maybe the cRIO TCP Buffer runs into a overflow...</p>
<p>Does anyone here have any experince with this behaviours ?? I am stumped...<img src="https://lavag.org/uploads/emoticons/default_throwpc.gif" alt=":throwpc:"></p>
<p>System : cRIO 9014 </p>
<p>RT Software : NI RIO 3.2.0</p>
<p>LabVIEW 8.6.1</p>
]]></description><guid isPermaLink="false">11372</guid><pubDate>Thu, 05 Nov 2009 08:17:09 +0000</pubDate></item><item><title>sbRIO  Shared Variables deployment very slow</title><link>https://lavag.org/topic/20630-sbrio-shared-variables-deployment-very-slow/</link><description><![CDATA[<p>
	We have an application where we communicate to a sbRIO target through Shared Variables. When the host/target are both on the local network all works fine (both are configured with a Static IP address). When both are connected directly with an ethernet cable, the deployement of the Shared Variables on the sbRIO target is extremely slow (5-10 seconds). This behaviour happens only if a DNS server address is defined. As the Shared Variables are deployed locally on the sbRIO, why the DNS server (if there is none) should have any effect on the deployment? Any hints?
</p>]]></description><guid isPermaLink="false">20630</guid><pubDate>Sun, 16 Sep 2018 13:40:47 +0000</pubDate></item><item><title>Weird cRIO Behaviour with DVRs</title><link>https://lavag.org/topic/20586-weird-crio-behaviour-with-dvrs/</link><description><![CDATA[<p style="margin:0px;padding:0px 0px .25em;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	I've got some weird stuff going on with a cRIO project I'm working on wanted to get some opinions on it. The basic architecture is a set of classes that do some process. That process registers with a server. The internal data of the process is held in a DVR and the server get's access to that DVR. Clients use TCP to ask the server to do something, the server makes a call against the classes DVR and returns a response to the client.
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	To simplify the issues I'm seeing I created a class that internally just increments an integer every 500ms. The client asks the server what's the current count, the server asks the Counter class and returns the answer to the client. This works perfectly fine when running the VI in the IDE. When built it connects, will get the JSON message back, but always gets a default value from the DVR call (zero, in this case). As soon as I open a remote debug panel to the cRIO, everything is working. The count is correct, the client calls work, just like normal. As soon as I right-click, close debug, it goes back to zero. Open debug works, close debug, back to zero. I know the DVR isn't getting dropped because the count continues to increment while not in debug, the process is still running happily with no issues.
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	Here's a few screenshots of the code;
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	Count Class process (get the count, increment, write it back to the DVR) -<span> </span><a href="https://imgur.com/jVLUKaO" rel="external nofollow">Counter Class process</a>
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	You can see the DVR vi's are actually vim's using a cast. I can't imagine that's the issue.
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	Server Side call -<span> </span><a href="https://imgur.com/nNTvJQ7" rel="external nofollow">Server Side calls</a>
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	All this does is get the count from the DVR (same as above) and wraps it in JSON and passes it back to the client as a JSON string.
</p>

<p style="margin:0px;padding:.25em 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	I also implemented an Echo class that ignores the process and DVR's, it just takes whatever string you sent form the client to the server and passes it back with a prepended "@echo". This works when running as an executable with the debug turned off so I know the client, server, and the server/class calls are all working as expected.
</p>

<p style="margin:0px;padding:.25em 0px 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	Any thoughts here would be welcome, thanks.
</p>

<p style="margin:0px;padding:.25em 0px 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	edit: I added the any possible errors coming from the variant cast to the JSON reply. When the debug is open there are no errors, when the debugger is closed it throws error 91, but the in-place element structure reading the DVR does not throw any errors. How can a variant not exist until a debugger is opened and than it magically exists?
</p>

<p style="margin:0px;padding:.25em 0px 0px;border:0px;font-style:normal;font-weight:400;font-size:14px;line-height:inherit;font-family:'Noto Sans', sans-serif;vertical-align:baseline;color:rgb(28,28,28);letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);">
	<span style="color:rgb(28,28,28);font-family:'Noto Sans', sans-serif;font-size:14px;font-style:normal;font-weight:400;letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);float:none;">edit: the internal data dictionary is a wrapper around a variant attribute, I wired out the "found?" terminal all the way out to the JSON reply and if the debugger is open the attribute is found, but not if the debugger is closed. Anyone have issues with Variant Attributes in Real-Time?</span>
</p>
]]></description><guid isPermaLink="false">20586</guid><pubDate>Thu, 26 Jul 2018 22:05:07 +0000</pubDate></item><item><title>Gracefully handling EtherCAT slave connection and disconnection</title><link>https://lavag.org/topic/20184-gracefully-handling-ethercat-slave-connection-and-disconnection/</link><description><![CDATA[<p>
	Does any one have any experience dealing with ethercat slave connection and disconnection while the system is running? Say you have a daisy chain of etherCAT slaves and the last one gets disconnected. From what I have seen the Scan Engine stops and goes to configuration mode. What if I want the system to just keep running as normal?
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">20184</guid><pubDate>Thu, 29 Jun 2017 16:54:57 +0000</pubDate></item><item><title>How do you debug your RT code running on Linux targets ?</title><link>https://lavag.org/topic/20128-how-do-you-debug-your-rt-code-running-on-linux-targets/</link><description><![CDATA[<p>
	Hi everybody,
</p>

<p>
	Currently working on VeriStand custom devices, I'm facing a 'huge' problem when debugging the code I make for the Linux RT Target. The console is not availbale on such targets, and I do not want to fall back to the serial port and Hyperterminal-like programs (damn we are in the 21st century !! <img alt=":P" data-emoticon="" src="https://lavag.org/uploads/emoticons/default_tongue.png" title=":P">)...
</p>

<p>
	Several years ago (2014 if I remember well) I posted an request on the Idea Exchange forum on NI's website to get back the console on Linux targets. NI agreed with the idea and it is 'in development' since then. Seems to be so hard to do that it takes years to have this simple feature back to life.
</p>

<p>
	On my side I developped a web-based console : HTML page displaying strings received through a WebSocket link. Pretty easy and fast, but the integration effort (start server, close server, handle push requests, ...)must be done for each single code I create for such targets.
</p>

<p>
	Do you have any good tricks to debug your code running on a Linux target ?
</p>
]]></description><guid isPermaLink="false">20128</guid><pubDate>Wed, 10 May 2017 13:39:55 +0000</pubDate></item><item><title>Profibus communication solutions</title><link>https://lavag.org/topic/20084-profibus-communication-solutions/</link><description><![CDATA[<p>
	Hi all, I would like to communicate to PROFIBUS DP device with a CompactRIO 9035. I did some research and I am not happy about my options. The cRIO module to talk to it is $1500 which seems outrageously expensive for what I want to do, which is talk to a single device at a 9600 baud. It also looks like you need to use it in FPGA mode, which will force me to have to start compiling bitfiles for my nice scan engine only project.
</p>

<p>
	It does look like PROFIBUS DP uses an RS-485 physical layer which is good. Theoretically I could just communicate to the device with my built in RS-485 port. However, I am not finding any PROFIBUS libraries available for download that work with a generic serial port. I believe the NI-PROFINET driver is tightly integrated to the cRIO profinet module. I am also not jazzed about implementing a PROFIBUS protocol from scratch.
</p>

<p>
	Does anyone have suggestions on good 3rd party adaptors or libraries that would allow me to communicate to this PROFIBUS device with a minimum of programming?
</p>
]]></description><guid isPermaLink="false">20084</guid><pubDate>Sat, 01 Apr 2017 02:44:51 +0000</pubDate></item><item><title>Rising Integrator (Modulus function and Simulink model vs Labview VI)</title><link>https://lavag.org/topic/20062-rising-integrator-modulus-function-and-simulink-model-vs-labview-vi/</link><description><![CDATA[<p>
	<span>Hello,</span> everyone. </p>
<p></p>


<p>
	Recently I came across one issue, that I solved within a couple of minutes in Simulink, but cannot crack <span>for</span> a couple of days in LabVIEW. It is a Rising integrator (model and plots from Simulink attached). Mod is the modulus function (i.e. remainder), the integrator reset is triggered by the external “Trigger” signal at 1 sec. After <span>that,</span> as you see the integrator generates a ramp signal. </p>
<p></p>


<p>
	I was trying to represent the same <span>behavior</span> in FPGA LabVIEW in order to use it further on my cRIO. I’ve seen on the forum, that one of the most feasible <span>solutions</span> for the Quotient &amp; Remainder function (<span>i.e.,</span> Modulus in Simulink) is the use of a while loop system with subtraction. But the <span>behavior</span> of the system is different since it generates a ramp signal after the reset is on, but it has a negative <span>slope</span> and saturates at -37k.</p>
<p></p>


<p>
	Just to check in general how the approach works <span>in LabVIEW,</span> I’ve designed the second model with a Quotient &amp; Remainder block (I know that for FPGA it is not the best option, plus I could not figure but how to use it with FXP values). But this model generates the output with a value of 5. <span>Which is even more questionable.</span> </p>
<p></p>


<p>
	In this case, could you please advise what I am doing wrong with the FPGA code for the block? <span>Since FPGA is the main reason, why I am looking for any options but not to use the Quotient &amp; Remainder block.</span> Thank you in advance.</p>
<p></p>


<p>
	P.S. The models are designed in LabVIEW 2014 SP1.</p>
<p></p>

<p><a class="ipsAttachLink" href="//lavag.org/applications/core/interface/file/attachment.php?id=12160">Integrator_SGL.vi</a></p>
<p><a class="ipsAttachLink" href="//lavag.org/applications/core/interface/file/attachment.php?id=12161">Integrator_while_loop.vi</a></p>
<p><a href="https://lavag.org/uploads/monthly_2017_03/Simulink_graphs.jpg.6b46245d70d3f8538488fcdfcbfb3c72.jpg" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="12162" src="https://lavag.org/uploads/monthly_2017_03/Simulink_graphs.thumb.jpg.bf67377caf3d6e5a62144e1123e59ddc.jpg" class="ipsImage ipsImage_thumbnailed" alt="Simulink_graphs.jpg"></a></p>
<p><a href="https://lavag.org/uploads/monthly_2017_03/Simulink_model.jpg.07f5e8eef83106dbce9d9b1073ab28d5.jpg" class="ipsAttachLink ipsAttachLink_image"><img data-fileid="12163" src="https://lavag.org/uploads/monthly_2017_03/Simulink_model.thumb.jpg.e5f08d3621d2485cea949f93fbaf6942.jpg" class="ipsImage ipsImage_thumbnailed" alt="Simulink_model.jpg"></a></p>]]></description><guid isPermaLink="false">20062</guid><pubDate>Wed, 15 Mar 2017 19:48:57 +0000</pubDate></item><item><title>USB RAW Communication with USB-6366</title><link>https://lavag.org/topic/20050-usb-raw-communication-with-usb-6366/</link><description><![CDATA[<p>
	I've got a bit of an unusual situation here.  A customer has an existing cRIO-9036 running real time Linux.  They also have a USB-6366 acquiring some high speed signals for another system.  They would like to interface the high speed signals to the crio system.  They've asked if it's possible to connect the USB-6366 to the cRio.  
</p>

<p>
	The crio system recognizes the USB-6366 as a USB RAW device.  So the question is it possible to control the USB-6366 using RAW communication?  I've got no experience in this area and haven't been able to find any documentation on this.  The application is pretty simple, just wait for a trigger, store some analog data, then download it to the crio for processing.
</p>

<p>
	Ultimately the correct solution is probably to buy a couple NI-9775 modules, but for bureaucratic reasons this isn't possible now.
</p>

<p>
	 
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">20050</guid><pubDate>Tue, 07 Mar 2017 22:11:33 +0000</pubDate></item><item><title>What is this thing?</title><link>https://lavag.org/topic/19836-what-is-this-thing/</link><description><![CDATA[<p>
	I am looking through some RT code, and am a bit confused by the following node. Can anybody tell me how I would make the node with the "chip" icon on it? The VI with this in in under the RT CompactRIO target folder in the project.
</p>

<p>
	I am pretty sure this has something to do with Scan mode on the FPGA or shared variables or user-defined variables, however I am not very familiar with any of these.
</p>

<p>
	Any ideas? 
</p>

<p>
	Edit: the C-Series module that this node refers to is currently tucked away under my FPGA Target, so perhaps this is old test code from when the module was used in Scan mode? If I move the modue out from the FPGA to just under the chassis the little glyph looks different, like a  little blue square wave with a triangular wave just about it.
</p>

<p>
	 
</p>

<p>
	<a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_2016_09/DIO0.png.bcae84c558114299b81cb627cdb37e07.png" data-fileid="11697" rel=""><img alt="DIO0.png" class="ipsImage ipsImage_thumbnailed" data-fileid="11697" src="https://lavag.org/uploads/monthly_2016_09/DIO0.png.bcae84c558114299b81cb627cdb37e07.png"></a>
</p>
]]></description><guid isPermaLink="false">19836</guid><pubDate>Fri, 30 Sep 2016 13:30:37 +0000</pubDate></item><item><title>VirtualBox with RT</title><link>https://lavag.org/topic/15009-virtualbox-with-rt/</link><description><![CDATA[<p>I wanted to test my application which consist of a host PC and a <abbr title="LabVIEW">LV</abbr>-RT.</p>
<p>In max, there's a tool: "Creating Desktop PC Utility USB Drive".</p>
<p>I downloaded the files from NI website</p>
<p>and created an *.iso from the "image" folder.</p>
<p>However i wasn't able to boot that iso from VirtualBox.</p>
<p>Sorry that its off topic, just to check if anyone has the same experience.</p>
<p>I'm running LV2011, VB 4.1.4</p>
<p>Or, anyone has solution for this??</p>
<p>Many thanks!</p>
]]></description><guid isPermaLink="false">15009</guid><pubDate>Tue, 04 Oct 2011 03:39:44 +0000</pubDate></item><item><title>Forcing scanned I/O variables to run simulated input for embedded cRIO applications</title><link>https://lavag.org/topic/19908-forcing-scanned-io-variables-to-run-simulated-input-for-embedded-crio-applications/</link><description><![CDATA[<p>
	I am really just writing this to put thoughts to paper so it is a meandering post with no real point. In past projects I used a layer of indirection between scan engine and fpga I/O by means of the current variable table, with all I/O scanned and written to the table in one place in the code. This made it easy to substitute value in the CVT with simulated values inputted from a test panel.
</p>

<p>
	I abandoned that approach in subsequent projects because it seemed not quite right. You have shared variables, why was I bypassing that entire system, which has a lot of functionality and add ons, for some parallel system ?
</p>

<p>
	For projects where I just use the cRIO scan engine, I want to cook up a system where my test panel programmatically takes control of all the cRIOs's I/O via this "force variable" functionality. I'd like to run my the real time program on an cRIO chassis devoid of modules so I can see how the program performs on the actual hardware while testing out logic and functionality thorough manual test panels as well as unit tests.
</p>

<p>
	Anyone one else do it this way or try it before?
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">19908</guid><pubDate>Thu, 01 Dec 2016 21:24:16 +0000</pubDate></item><item><title>Anyone have experience with Mathscript RT?</title><link>https://lavag.org/topic/19783-anyone-have-experience-with-mathscript-rt/</link><description><![CDATA[<p>
	I have a client who want to be able to use some of the control system code they developed in matlab/mathscript to do actual control with hardware. The loop rate will be in the 10-20 KHz range. Normally when I do RT development I would implement the control loop on FPGA for this sort of thing. I was thinking that perhaps the Mathscript RT module could be used to run matscript on a cRIO. The I/O would go through the FPGA interface node, not the scan engine as that is limited to about 1000Hz from what I understand.
</p>

<p>
	I guess this boils down to two questions. 
</p>

<p>
	1. Will the overhead associated with the matscript node for even the simplest script be high enough to utilize the entire CPU at a low rate like 1 kHz?
</p>

<p>
	2. Can I/O be updated at 10-20 KHz through the FPGA I/O read write node?
</p>

<p>
	Regards,
</p>

<p>
	MarkCG
</p>

<p>
	 
</p>

<p>
	 
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">19783</guid><pubDate>Mon, 29 Aug 2016 23:41:42 +0000</pubDate></item><item><title>Optimizing a serial instrument driver for memory leaks</title><link>https://lavag.org/topic/19764-optimizing-a-serial-instrument-driver-for-memory-leaks/</link><description><![CDATA[<p>
	I'm using a Keithley instrument driver that works over RS-232 on a cRIO. Our app is leaking memory <em>somewhere</em>, and the component that uses this library is highly suspect. I've been refactoring a bunch of it to use shift registers and IPE structures, and I just found these two doozies (attached, <abbr title="LabVIEW">LV</abbr> 14.1). Together, they build a string byte-by-byte when read from VISA and then convert it to an array of DBL element-by-element. Here's a screenshot of one of them:
</p>

<p>
	<img class="ipsImage ipsImage_thumbnailed" data-fileid="11558" src="https://lavag.org/uploads/monthly_2016_08/yikes.png.960f45ecc45ebd503668aef41566e21b.png" alt="yikes.png"></p>

<p>
	What's the best way to modify these two so they're better citizens of LVRT (i.e. no memory copies, or as few as absolutely possible)?
</p>

<p><a class="ipsAttachLink" href="//lavag.org/applications/core/interface/file/attachment.php?id=11556">Query Command.vi</a></p>
<p><a class="ipsAttachLink" href="//lavag.org/applications/core/interface/file/attachment.php?id=11557">Real 64 Converter.vi</a></p>]]></description><guid isPermaLink="false">19764</guid><pubDate>Fri, 19 Aug 2016 21:59:25 +0000</pubDate></item><item><title>NI Linux RT on Desktop PC</title><link>https://lavag.org/topic/19653-ni-linux-rt-on-desktop-pc/</link><description><![CDATA[<p>
	<br><span>Hi Experts</span><span>,</span><br><span>there is a</span> <span>guide, experience or</span> <span>an image</span> <span>with which you can</span> <span>configure a</span> <span>desktop</span> <span>PC</span> <span>to a</span> <span>Linux</span> <span>NI</span> <span>RT</span><span>?</span><br><span>a pleasant week</span><span>,</span> <span>Jim</span>
</p>]]></description><guid isPermaLink="false">19653</guid><pubDate>Wed, 15 Jun 2016 06:45:47 +0000</pubDate></item><item><title>reasonable max number of etherCAT slaves with cRIO</title><link>https://lavag.org/topic/19654-reasonable-max-number-of-ethercat-slaves-with-crio/</link><description><![CDATA[<p>
	Hi all, I am designing the control system for what will be a fairly large machine and I considering the ways the overall system can be architected. I have created systems with a cRIO master and a single cRIO 9144 EtherCAT slave. However I have not tried using multiple EtherCAT cRIOs and/or 3rd party EtherCAT devices like servocontrollers. Has anyone used more than one EtherCAT slave with a cRIO? How many slaves can you realistically daisy chain off one of the newer "value" cRIOs like the 9068? I know this answer will depend on number of scanned variables and the scan engine period. At 10ms scan engine period, what can you expect?
</p>

<p>
	 
</p>
]]></description><guid isPermaLink="false">19654</guid><pubDate>Thu, 16 Jun 2016 00:56:27 +0000</pubDate></item><item><title>NI Linux Real-Time - User Interface</title><link>https://lavag.org/topic/19609-ni-linux-real-time-user-interface/</link><description><![CDATA[<p>
	Hi,
</p>

<p>
	I am currently working on a project that is deployed on cRIO 9030 with NI Linux RT. My host user interface however does not look like the one deployed on the embedded one. Can you please share with me your experience on which fonts and sizes should I use to make it look as neat as possible ?  Maybe there exists a way to install additional fonts to the RT ?
</p>

<p>
	For the moment I have just found this topic on NI community site : <a href="https://decibel.ni.com/content/groups/ni-linux-real-time?view=discussions#/?filter=answered&amp;page=2" rel="external nofollow">https://decibel.ni.com/content/groups/ni-linux-real-time?view=discussions#/?filter=answered&amp;page=2</a>
</p>

<p>
	however it wasn't very helpful for me.
</p>

<p>
	I would like to underline that I am a new member in our society, so if I break any of your rules or commons please feel free to point it out <img alt=";)" data-emoticon="" src="https://lavag.org/uploads/emoticons/default_wink.png" title=";)"></p>
]]></description><guid isPermaLink="false">19609</guid><pubDate>Tue, 10 May 2016 17:55:43 +0000</pubDate></item><item><title>Motor control with FPGA design pattern question</title><link>https://lavag.org/topic/19401-motor-control-with-fpga-design-pattern-question/</link><description><![CDATA[<p>Hi,</p>
<p>I am quite familiar with different design pattern on LabVIEW but I am a newbie on FPGA design. I start working on a project for my own hobby using myRIO to control motor speed with PWM and read back encoder. This is the first part of my project and I plan to expand more later. This project will help me to get use to FPGA too. I am trying to learn a good design pattern by follow the template project which is "LabVIEW FPGA control on Compact RIO". In this template project, feedback value and control signal are analog channels and they connect directly with PID module in FPGA in a normal while loop. The configuration are sent from host. In my prototype project, I already built FPGA module to drive PWM and read encoder using single-cycle time loop. I plan to use PID in real time code. If I want to follow the template design, I have to change the way I implement the code for FPGA and Real-Time. So right now, I am not sure what is a good design I should follow. If you have any advice, I will highly appreciate. </p>
<p> </p>
<p>Thank you very much!</p>
]]></description><guid isPermaLink="false">19401</guid><pubDate>Wed, 13 Jan 2016 04:53:38 +0000</pubDate></item><item><title>Get object type from GUID?</title><link>https://lavag.org/topic/19518-get-object-type-from-guid/</link><description><![CDATA[<p>I'm walking through a LVRT Project using the VI Server API, trying to find a particular build spec on my FPGA target. I can get the target ("FPGA Target") by name and use that ref to find the build spec by its name, but the reference returned can't be cast to type <span style="font-family:'courier new', courier, monospace;">ProjectItem:BuildSpecification</span>. If I probe the reference wire, the only interesting thing I see is the type GUID...</p>
<pre class="ipsCode prettyprint">
{F4C5E96F-7410-48A5-BB87-3559BC9B167F}</pre>
<p>Does anybody know of a way to deduce the VI Server object type from this GUID so I can perform a downcast on it?</p>
]]></description><guid isPermaLink="false">19518</guid><pubDate>Tue, 15 Mar 2016 23:04:28 +0000</pubDate></item><item><title>FIFO DMA Target to Host</title><link>https://lavag.org/topic/19505-fifo-dma-target-to-host/</link><description><![CDATA[<div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">I have a system that composed of</span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">1- NI-cRIO9014</span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">2- Chassis (cRIO-9104)</span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">3- Three Mods. NI9215</span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;"> </span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">I use this system to capture 12 analog signals.</span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;"><span style="font-size:11pt;"><span style="font-size:10pt;">What is the relation between sampling frequency defined by time delay in fpga.vi and the Requested number of Elements defined in FIFO?. </span></span></div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;">
<span style="font-size:11pt;"><span style="font-size:10pt;">When I use a time delay of 40us and </span></span><span style="font-family:Tahoma, sans-serif;font-size:13.3333px;">Requested number of Elements 8191, it produces wrong data.</span>
</div>
<br><div style="color:rgb(0,0,0);font-family:'Segoe UI', Helvetica, Arial, sans-serif;font-size:medium;margin:0px;">
<span style="font-size:11pt;"><span style="font-size:10pt;">When I use a time delay of 40us and </span></span><span style="font-family:Tahoma, sans-serif;font-size:13.3333px;">Requested number of Elements 65535, it produces correct data.</span>
</div>
<br>]]></description><guid isPermaLink="false">19505</guid><pubDate>Wed, 09 Mar 2016 13:55:33 +0000</pubDate></item><item><title>LVRT and Relational Databases</title><link>https://lavag.org/topic/10915-lvrt-and-relational-databases/</link><description><![CDATA[<p>At the request of my sales force and some customers I am going to be writing an article and examples on NI Real-Time targets and Relational Databases (Historical databases seem to be pretty much covered by Citadel).  The idea is to generate some starting points, an provide some examples on how-to.  After speaking with some peers I have some good ideas, and wanted to bounce them off you Lavanians (do we have a name for LAVA posters?)</p>
<p>Before I get too deep I have to ask the most important question.  Is this useful.  So has anyone out there needed Database support on RT?   Ideally there would be information about every topic you could come up with, but the reality is that if no one needs it I am going to use my time on something else.</p>
<p>OK assuming someone needs it, there are three scenarios I am pretty sure I am going to talk about.</p>
<p>1)  The current NI recommended way to have databases on RT Targets is to make a communication layer between your RT and Host.  Then have the host do all the real database operations, and the RT is just passing the information along.  I have an example that has the RT send data over TCP to be recorded to a blank .mdb using the Database Connectivity toolkit.  Then after some time the RT target requests something like 100 records to use in decision for state machine.  Pretty straight forward, and shows that an SQL statement can be passed from RT to host without any translation of data on the host-side (in otherwords the host does not need to know anything about the data, it just works with variants).</p>
<p>2)  The RT target makes files in a specific format, then the host retrieves the files periodically and places the data into the database.  Some FTP operations, and thats about it.  The file format is tricky, so I am still deciding on what to make it.</p>
<p>3)  The coolest one by far, make RT targets actually support databases by porting SQLite to Pharlap and VxWorks targets.  There has been some talks about it but I didn't see anything definitive on OpenG.  Currently trying to get SQLite to build as a DLL in CVI.</p>
<p>SO:</p>
<p>A)  Anybody actually going to use this stuff, or am I wasting time.</p>
<p>B) Does the three above meet pretty much all the scenerios you can think of?</p>
<p>C)  Anyone been working on the SQLite thing lately?</p>
]]></description><guid isPermaLink="false">10915</guid><pubDate>Mon, 31 Aug 2009 11:41:59 +0000</pubDate></item><item><title>Understanding FPGA FXP LMS.vi code</title><link>https://lavag.org/topic/19352-understanding-fpga-fxp-lmsvi-code/</link><description><![CDATA[<p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">Hello everyone,</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">I am working on Active Noise Cancellation project. I need to implement fixed point LMS code on FPGA target of myRIO 1900. I know , I can generate this using <strong>FPGA Target &gt; IP Generator. </strong>I could do that, but I have to modify that code a litlle bit, as I will directly get the <strong>error e</strong> signal from microphone and there is no <strong>desired signal d</strong>available.</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">I did some decoding and understood a bit of how it is working, but still could not understand some essential part of it! </p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">Below I will attach, the FXP LMS vi . There are also two subVIs needed which I cannot include here but I can add pictures of it if needed.</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">I could not understand, how this algorithm performs the Estimated signal step viz. [ y(n) = x_temp(n) vector * w(n) vector '  ; ]. I marked the section of the code where I am facing some problem in the attached picture. The algorithm does not show any clue how it is performing these vector operations.</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">I could not also understand, some logic with numbers that he has chosen like 8, 3 ,7 ,9 etc. </p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">Further clarifications on my understanding will be provided .</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">Any help in this problem will be appreciated.</p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(51,51,51);font-family:Arial;font-size:12px;">PS: I could implement using memory blocks as basic array elements, like intialzing both x and w vectors. But eventually, I have to read and write several times, which is killing time.</p>
<br><div> </div>
<br><p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2015/post-54213-0-68978100-1448552809.png" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2015/post-54213-0-68978100-1448552809.png" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10807" class="ipsImage ipsImage_thumbnailed" alt="post-54213-0-68978100-1448552809.png"></a></p>
<p><a href="https://lavag.org/applications/core/interface/file/attachment.php?id=10808" data-fileid="10808" rel="">FXP LMS.vi</a></p>
]]></description><guid isPermaLink="false">19352</guid><pubDate>Thu, 26 Nov 2015 15:47:24 +0000</pubDate></item><item><title>Choosing an RT Solution : cRIO or PXI</title><link>https://lavag.org/topic/19253-choosing-an-rt-solution-crio-or-pxi/</link><description><![CDATA[<p>Hi,</p>
<p> </p>
<p>My company has been developing and maintaining its own SCADA software in LabVIEW for a few years. It is fairly comprehensive: datalogging, graphing, alarm monitoring, automation, loops for equations and PIDs, and so on. It is a PC-based solution and communicates with many different kinds of hardware through the COM(RS232), USB, and Ethernet ports of the PC. This solution works well and allows keeping the costs low for most of our customers. Most of the loops run around 10Hz (100ms).</p>
<p> </p>
<p>However, more and more we are running into customer specifications that require high control rate (few milliseconds), high determinism (to the millisecond), and high reliability. Not surprisingly, the PC solution becomes unacceptable. We feel it is time to look into a real-time, embedded solution for those customers. That's why I'm currently investigating the different NI embedded RT solutions (namely PXI and cRIO).</p>
<p> </p>
<p>I can find plenty of resources on each of them, but close to nothing when it comes to comparing the 2 solutions and choosing which one to go with. Would you mind giving me some guidance? I guess you'll need more information, which I'll be happy to provide.</p>
<p> </p>
<p>A few elements already:</p>
<p>- There is no request for MHz loops, so the FPGA side of the cRIO is not required I believe</p>
<p>- Our application contains many VIs that are both the engine and the HMI, so there will be some decoupling effort if we need to split it into an HMI application on the PC and an RT application on the cRIO. Would a PXI solution avoid this issue by plugging a monitor directly to the display port of the controller? But then if I have all the code in the PXI controller, is it likely that I will lose my control rate and determinism?</p>
<p> </p>
<p>Thanks!</p>
<p>Emmanuel</p>
<p> </p>
<p> </p>
]]></description><guid isPermaLink="false">19253</guid><pubDate>Thu, 01 Oct 2015 22:50:12 +0000</pubDate></item><item><title>VNC with Embedded UI on RT-Linux Targets</title><link>https://lavag.org/topic/19330-vnc-with-embedded-ui-on-rt-linux-targets/</link><description><![CDATA[<p>Hey there,</p>
<p> </p>
<p>I have a cRIO capable of rendering an embedded UI (cRIO 9039). Is it possible to Control that embedded UI by using VNC? Has anyone attempted anything like this?</p>
<p> </p>
<p>Thanks,</p>
<p> </p>
<p>Robert</p>
]]></description><guid isPermaLink="false">19330</guid><pubDate>Tue, 10 Nov 2015 15:21:24 +0000</pubDate></item><item><title>Dynamically loaded classes on RT</title><link>https://lavag.org/topic/17908-dynamically-loaded-classes-on-rt/</link><description><![CDATA[<p>Has anyone used "Get <abbr title="LabVIEW">LV</abbr> Class Default Value VI" to dynamically load classes on RT?</p>]]></description><guid isPermaLink="false">17908</guid><pubDate>Tue, 14 Jan 2014 23:33:34 +0000</pubDate></item><item><title>LabVIEW Real-Time VI Property Node throws Error Code 1</title><link>https://lavag.org/topic/19156-labview-real-time-vi-property-node-throws-error-code-1/</link><description><![CDATA[<div>Some background: I'm trying to use the name of the library my VI is executing in as part of a string which will be used in the name of a Rendezvous, to keep it distinct from other Rendezvous I will create.</div>
<br><div> </div>
<br><div>
<strong>When attempting to use the VI Property Node to access the Library property on the CompactRIO, error code 1 is returned.</strong> Running the same code on my computer runs as expected and returns the Library. Accessing the VI Name using the Property Node appears to work no problem on the RT, though.</div>
<br><div> </div>
<br><div>Does anyone know what could be causing the problem? I tried searching the documentation, but didn't turn up anything. <strong>Is this error part of some general behavior wherein some VI properties are not accessible when a VI is running on a real-time target?</strong>
</div>
<br><div> </div>
<br><div>Code is attached. Please see attached pictures:</div>
<br><div> </div>
<br><div>Project Explorer:</div>
<br><div><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_08_2015/post-53795-0-33696800-1439243882.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_08_2015/post-53795-0-33696800-1439243882.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10550" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-33696800-1439243882.jpg"></a></div>
<br><div> </div>
<br><div>Block Diagram:</div>
<br><div><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_08_2015/post-53795-0-44778400-1439243550.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_08_2015/post-53795-0-44778400-1439243550.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10545" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-44778400-1439243550.jpg"></a></div>
<br><div> </div>
<br><div>Front Panel - RT Results:</div>
<br><div><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_08_2015/post-53795-0-02588400-1439243603.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_08_2015/post-53795-0-02588400-1439243603.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10547" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-02588400-1439243603.jpg"></a></div>
<br><div> </div>
<br><div>Front Panel - Computer Results:</div>
<br><div><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_08_2015/post-53795-0-94406100-1439243601.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_08_2015/post-53795-0-94406100-1439243601.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10546" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-94406100-1439243601.jpg"></a></div>
<br><p><a href="https://lavag.org/applications/core/interface/file/attachment.php?id=10548" data-fileid="10548" rel="">Experiment with VI Property Node Error.zip</a></p>
]]></description><guid isPermaLink="false">19156</guid><pubDate>Mon, 10 Aug 2015 21:59:30 +0000</pubDate></item><item><title>Modular design approach for FPGA</title><link>https://lavag.org/topic/19143-modular-design-approach-for-fpga/</link><description><![CDATA[<p>I would like to design a FPGA module having an access to the resources like DIO,AIO or CAN which I can develop and test within one LabVIEW project and then use it within another. Idealy, I would like to have an API for RT implemented as a .lvlib and one VI which I have to drop on on my main FPGA vi.</p>
<p> </p>
<p>Currently, I have a .lvlib with virtual folders for RT and FPGA stuff. I have a few issues with this approach like requirement for changing FPGA typedef when I want to use it within another project and manual adding FIFO to the project.</p>
<p> </p>
<p>Well, I can live with this, but maybe you have a better approach which you woluld like to share. I have found something like FPGA Advanced Session Resources <a href="https://decibel.ni.com/content/docs/DOC-35574" rel="external nofollow">https://decibel.ni.com/content/docs/DOC-35574</a> , but still I am not sure whether it something I am looking for. </p>
<p> </p>
<p>Any thoughts?</p>
]]></description><guid isPermaLink="false">19143</guid><pubDate>Sun, 02 Aug 2015 12:44:45 +0000</pubDate></item><item><title>Unable to Access Shared Variable Programmatically on CompactRIO Real Time Target</title><link>https://lavag.org/topic/19118-unable-to-access-shared-variable-programmatically-on-compactrio-real-time-target/</link><description><![CDATA[<p>I would like to use programmatic access to manipulate shared variables on a computer and an NI cRIO 9033, but cannot get programmatic access to shared variables on the cRIO.<br>I have boiled the situation down to a simple example to try to explain what I am seeing. The shared variables are hosted on the cRIO. I am using the same VI to perform the accesses on the computer and the cRIO. On the computer, access to the shared variable via a shared variable node and programmatic access both work. <strong>On the cRIO,</strong> access to the shared variable via a shared variable node is functional, but <strong>programmatic access to the shared variable does not work.</strong><br>The error code received when trying to to a Read Variable or Open Variable Connection on the cRIO to the shared variable is -1950678943. The error text reads "Timed out while attempting to open a connection to the variable."<br><strong>I'm quickly becoming confused as to why the cRIO should have trouble reading a shared variable programmatically that is hosted on itself.</strong> The web searches I have done haven't turned up such a simple scenario causing this error, so I'm wondering if I've stumbled into a beginner mistake. I have attached the source code to this post, so if someone could please take a look that would really help!<br>Block Diagram:<br><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_07_2015/post-53795-0-96854300-1437659630.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_07_2015/post-53795-0-96854300-1437659630.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10471" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-96854300-1437659630.jpg"></a><br>Result of running on computer (programmatic and shared variable node access both work):<br><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_07_2015/post-53795-0-92563900-1437659631.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_07_2015/post-53795-0-92563900-1437659631.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10472" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-92563900-1437659631.jpg"></a><br>Result of running on NI cRIO 9033 (<strong>programmatic shared variable access does not work</strong>, shared variable node access does work):<br><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_07_2015/post-53795-0-39160200-1437659632.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_07_2015/post-53795-0-39160200-1437659632.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10473" class="ipsImage ipsImage_thumbnailed" alt="post-53795-0-39160200-1437659632.jpg"></a></p>
<p><a href="https://lavag.org/applications/core/interface/file/attachment.php?id=10470" data-fileid="10470" rel="">Test Access to Shared Variable from cRIO.zip</a></p>
]]></description><guid isPermaLink="false">19118</guid><pubDate>Thu, 23 Jul 2015 13:55:09 +0000</pubDate></item><item><title>Synchronisation of instruments having different data rates</title><link>https://lavag.org/topic/19109-synchronisation-of-instruments-having-different-data-rates/</link><description><![CDATA[<p>Hi,</p>
<p> </p>
<p>I have faced the chalenge with setting values and synchronising measurement using multiple number of instruments. I use cRIO. The orginal application is a bigger but I will try to describe the main issue and my approach. I would like to listen to your feedback or better solution.</p>
<p> </p>
<p>Let's imagine:</p>
<p>- device A (comunication over CANOpen) controlling speed.</p>
<p>- device B (communication over RS232) controlling temperature</p>
<p>- device C (NI analog inputs module)</p>
<p> </p>
<p>The goal is to generate sequence of setpoints for temperature and speed and at the same time measuring current speed, temperature (using the same instruments) and measuring voltages using analog inputs.</p>
<p> </p>
<p>Setpoint for speed should be generated quite quickly (it depends on perspective what means 'quickly' but period is 10ms), setpoints for temperature can be generated slower (period 100ms or bigger).</p>
<p> </p>
<p>I can't wait for response from device B while I want to generate setpoints for device A (which is faster) so I decicde that I will divide these proceses.</p>
<p> </p>
<p>My solution:</p>
<p>I placed device A controller into Timed Loop where it does three operations in sequence: writes setpoint, read current value and gets command from queue ( Timeout is 0 so I am not waiting for element and it is used only to stop a loop or perform initialisation - non deterministic tasks). The device B is in a similar loop but have different time rate. I wanted to keep instruments and logic separate so I added a third 'Control' Timed Loop which is responsible for generation setpoints at higer rates (1ms). The third loop 'publish' setpoints to other loops using 'single process variable with one element fifo' (one variable per setpoint) - in this way processes doesn't have to wait. All Timed Loops are grouped and starts at the same time. Now, it is time for FPGA. In order to have every mearuement correlated ( corresponding to each other), values measured by instruments are sent to FPGA. On FPGA I acquire values measured by instruments along with analog inputs and send back to the host using FIFO. I am receiving these values in non derministic acquisition loop. Control loop is also responsible for triggering the acquisition.</p>
<p> </p>
<p>The problem seems to be common but described solution is the only one which I found to be correct and seems to be quite complicated (number of communication methods). Well, I hope I will get some advices to simplify it.</p>
]]></description><guid isPermaLink="false">19109</guid><pubDate>Thu, 16 Jul 2015 16:50:59 +0000</pubDate></item><item><title>synchronize EtherCAT Master with a third party slave</title><link>https://lavag.org/topic/19101-synchronize-ethercat-master-with-a-third-party-slave/</link><description><![CDATA[<p><span><span>Hello Experts</span><span>,</span></span></p>
<p><span><span>it is possible</span> <span>to synchronize</span> <span><span>the</span> <span>distributet</span> <span>clock </span></span><span>from a</span> <span>PXI</span> <span>RT</span> (<span><em>Phar Lap</em> ETS)</span> <span>EtherCAT Master</span> <span>with a</span> <span>third</span> <span>party</span> <span>slave <span><span>(</span><span>Beckhoff</span> <span>EL6692</span> <span>or</span> <span>el6695 <a href="http://www.beckhoff.de/default.asp?ethercat/el6695.htm" rel="external nofollow">http://www.beckhoff.de/default.asp?ethercat/el6695.htm</a></span><span>)</span></span></span><span>? </span></span></p>
<p> </p>
<p><span><span><span><span>Thanks in advance, Jim</span></span></span></span><br> </p>
]]></description><guid isPermaLink="false">19101</guid><pubDate>Mon, 13 Jul 2015 20:19:20 +0000</pubDate></item><item><title>Launching a VI dynamically inside RT</title><link>https://lavag.org/topic/19091-launching-a-vi-dynamically-inside-rt/</link><description><![CDATA[<p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">Hi all,</p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">I am trying to launch a vi dynamically inside RT. But I am unable to do it. It either throws up error 100 (VI not in compatible state for this operation) or just I get disconnected from the RT. I am not sure about the problem and I need help in this. How do I launch a VI dynamically inside RT. All its dependencies are downloaded to RT.</p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">The VIs I am trying to launch is a member of a class. </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">VIs property is set to be modal. (I want it to be front most when it gets launcheed. We are using LabVIEW Embedded UI for monitoring purposes). </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">I am able to get the reference of the VI porperly. The error occurs in invoke node which tries to run the VI. </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">Should the VI be reentrant for launching(a hunch of my own-but not sure why it should be)?</p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;"> </p>
<br><p style="color:rgb(0,0,0);font-family:Arial;font-size:12px;">Thanks in advance for your replies.</p>
<br>]]></description><guid isPermaLink="false">19091</guid><pubDate>Thu, 09 Jul 2015 06:09:55 +0000</pubDate></item><item><title>cRIO Sine wave</title><link>https://lavag.org/topic/19034-crio-sine-wave/</link><description><![CDATA[<p>See the attached screen shot. This crashes compilation.</p>
<p> </p>
<p><span style="color:#1f497d;"><span style="font-family:calibri, sans-serif;"><span style="font-size:11pt;">"some of the compilation steps were not executed. refer to the Xilinx logâ€</span></span></span></p>
<p>The xilinx log is what looks like hundreds of pages. I see many warnings, but nothing that looks like a critical failure.</p>
<p> </p>
<p>If I replace the sine wave with the square wave function, the code will run fine. </p>
<p> </p>
<p>I am running a cRIO-9067, with an NI-9269 module.</p>
<p> </p>
<p> </p>
<p>All I am looking for is a simple output sine wave VI. Freq and amp variable going in, and a waveform out of the RIO. </p>
<p>Any help would be greatly appreciated. </p>
<p>I have been using NI's examples (<a href="http://www.ni.com/white-paper/3780/en/#Example" rel="external nofollow">http://www.ni.com/white-paper/3780/en/#Example</a>, fig2) linking to my hardware. </p>
<p> </p>
<p>I suppose I'm looking for a few answers here:</p>
<p>1. Why does this fail compilation? </p>
<p>2. Does anyone have a VI that will just simply output a sine wave?</p>
<p> </p>
<p>Thanks again,</p>
<p>Chris</p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_06_2015/post-52576-0-85940900-1434036034.png" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_06_2015/post-52576-0-85940900-1434036034.png" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=10308" class="ipsImage ipsImage_thumbnailed" alt="post-52576-0-85940900-1434036034.png"></a></p>
]]></description><guid isPermaLink="false">19034</guid><pubDate>Thu, 11 Jun 2015 15:29:35 +0000</pubDate></item><item><title>Labview RealTime as EtherCAT slave</title><link>https://lavag.org/topic/19020-labview-realtime-as-ethercat-slave/</link><description><![CDATA[<p><span><span>Hello Experts</span><span>,</span><br><br><span>I would like to</span> <span>operate a</span> Labview RealTime <span>system</span> <span>(</span><span>PXI</span><span>)</span> <span>as</span> <span>EtherCAT Slave</span><span>.</span> <span>The</span> <span>master system</span> <span>should be a</span> <span>Beckhoff</span> <span>control</span><span>.</span> <span>Is it</span> <span>possible to operate</span> <span>the</span> Labview RealTime <span>system</span> <span>as EtherCAT</span> <span>slave</span><span>?</span><br><br><span>Thanks in advance</span><br> </span><br> </p>]]></description><guid isPermaLink="false">19020</guid><pubDate>Sun, 31 May 2015 15:55:11 +0000</pubDate></item><item><title>Removing buggy EtherCAT Slaves programmatically</title><link>https://lavag.org/topic/18946-removing-buggy-ethercat-slaves-programmatically/</link><description><![CDATA[<p>I am using an RT Target as the master of EtherCAT chain.  It has several different sorts of third party slaves in the chain.  All are correctly detected.  However some are buggy (they're in development) and prevent the Scan Engine from switching to Active mode.  If I remove the buggy slaves from under EtherCAT Master (but leave them plugged into the chain) in the project then the Scan Engine will switch to Active and the remaining targets are interogated correctly.</p>
<p> </p>
<p>However I want my RT app to be stand alone and adapt to different chains of slaves.  When I invoke the Refresh Modules method it finds all the available slaves including the buggy ones.  These then prevent the Scan Engine from switching to Active mode.  I have not been able to find a way to programmatically remove these buggy slaves as I can from the project - does it exist???</p>
<p> </p>
<p>Many thanks!</p>
<p> </p>
<p> </p>
]]></description><guid isPermaLink="false">18946</guid><pubDate>Tue, 21 Apr 2015 19:45:45 +0000</pubDate></item><item><title>TCP errors 56 and 66 on VxWork sbRIO</title><link>https://lavag.org/topic/18924-tcp-errors-56-and-66-on-vxwork-sbrio/</link><description><![CDATA[<p>I have a small <abbr title="LabVIEW">LV</abbr> code library that wraps the <a href="http://www.ni.com/white-paper/4095/en/" rel="external nofollow">STM</a> and VISA/TCP APIs to make a "network actor". My library dynamically launches a reentrant VI using the ACBR node that establishes a TCP connection as client or server, then uses the connection to poll for inbound messages and send outbound ones.</p>
<p> </p>
<p>When I try to establish a connection using my Windows 7 PC as the client and my sbRIO (VxWorks) as the server, it connects and pushes 100 messages from the client <em>if the server was listening first</em>. If the client spins up first, sometimes it works and sometimes I get error 56 from the "TCP Open Connection" primitive repeatedly. Other times I've seen error 66.</p>
<p> </p>
<p>When I try to make Windows act as the server, the sbRIO client connects without error, but it returns error 56 from "TCP Read" on the first call thereafter (inside "STM.lvlib:Read Meta Data (TCP Clst).vi"). This happens in whichever order I run them.</p>
<p> </p>
<p>This test, and all others I've written for the API, works just fine when both client and server are on the local machine.</p>
<p> </p>
<p>-------------------------------</p>
<p> </p>
<p>I'm tearing my hair out trying to get a reliable connection-establishment routine going. What don't I know? What am I missing? Is there a "standard" way to code the server and client so they'll establish a connection reliably between an RT and a non-RT peer?</p>
<p> </p>
]]></description><guid isPermaLink="false">18924</guid><pubDate>Tue, 07 Apr 2015 00:02:10 +0000</pubDate></item><item><title>3-floor Elevator</title><link>https://lavag.org/topic/18867-3-floor-elevator/</link><description><![CDATA[<p>Good day!</p>
<p>I'm planning to make a 3-floor miniature elevator (this is the prototype) and it will be controlled through LabVIEW. The LabVIEW interface will control what floor will it go up and down. But I have (super) major problems. First, which one is better to use for the interaction of prototype and labview, DAQ or Arduino? Next is that I don't have that much idea how to start the VI. I've seen some elevator VIs but I think I must read or research more. Also, is there a transfer function involved in the VI? </p>
<p> </p>
<p>All help will be greatly appreciated. Thank you. <img src="https://lavag.org/uploads/emoticons/default_smile.png" alt=":)"></p>
]]></description><guid isPermaLink="false">18867</guid><pubDate>Sat, 07 Mar 2015 19:02:54 +0000</pubDate></item><item><title>Moving averaging on FPGA</title><link>https://lavag.org/topic/18842-moving-averaging-on-fpga/</link><description><![CDATA[<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;">Hi All,</span></span></p>
<p> </p>
<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;"><span style="color:rgb(51,51,51);">I would like to do some moving averaging on my FPGA based on building the sum of the values to around 200/N data points and then removing the oldest value and adding the newest value that way I'm only needing to acquiring one new point once the data point have reached the 200 limit but I have 16 channels and FPGA does not support 2-D arrays and I can do it with 16 1-d arrays but I don't think there will be enough resources on the FPGA. Anyone have any ideas how i can do this. </span></span></span></p>
<p> </p>
<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;"><span style="color:rgb(51,51,51);">I guess the main challenge is having a way to continuously store the last 200 or N points so that I can subtract the oldest value other than a two d array or multiple 1-d arrays. I am trying to do it this way as well so that I don't need to wait each time and acquire 200 or N samples and then averages them each time for a new averaged value.</span></span></span></p>
<p> </p>
<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;"><span style="color:rgb(51,51,51);">Kindly let me know if any suggestion.</span></span></span></p>
<p> </p>
<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;"><span style="color:rgb(51,51,51);">Thanks in advance.</span></span></span></p>
<p><span style="font-size:14px;"><span style="font-family:arial, helvetica, sans-serif;"><span style="color:rgb(51,51,51);">Pravin</span></span></span></p>
]]></description><guid isPermaLink="false">18842</guid><pubDate>Thu, 26 Feb 2015 05:55:18 +0000</pubDate></item><item><title>RS232 on pxie-8100 RT</title><link>https://lavag.org/topic/18810-rs232-on-pxie-8100-rt/</link><description><![CDATA[<p>Hi,</p>
<p> </p>
<p>I'm designing RS232  using pxie-8100 RT.</p>
<p> </p>
<p>is the rs232 design and configuration is different between Labview RT and regular Labview ?</p>
<p> </p>
<p>cause the same rs232 design doesn't work on the RT labview...</p>
]]></description><guid isPermaLink="false">18810</guid><pubDate>Wed, 11 Feb 2015 11:54:49 +0000</pubDate></item><item><title>How to Implement first order filter in FPGA</title><link>https://lavag.org/topic/18752-how-to-implement-first-order-filter-in-fpga/</link><description><![CDATA[<p>Hello All,</p>
<p> </p>
<p>I have implemented first order filter in Real Time and trying to implement in FPGA.</p>
<p>Please attached code for your reference.</p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_01_2015/post-15324-0-32996500-1421668335.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_01_2015/post-15324-0-32996500-1421668335_thumb.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=9872" class="ipsImage ipsImage_thumbnailed" alt="post-15324-0-32996500-1421668335_thumb.j"></a></p>
]]></description><guid isPermaLink="false">18752</guid><pubDate>Mon, 19 Jan 2015 11:53:01 +0000</pubDate></item><item><title>Matrix Multiply slower on RT than PC?</title><link>https://lavag.org/topic/18635-matrix-multiply-slower-on-rt-than-pc/</link><description><![CDATA[<p>I was playing with large matrices and was testing execution speed on my laptop (the code is destined to run on RT). </p>
<p> </p>
<p>The code below tests using the Matrix Multiply function vs just straight array math.  Unsurprisingly the Matrix Multiply function executed faster.  Then when I ran it on RT both methods took the same amount of time? And Matrix Multiply (A x B.vi) takes LONGER on RT than PC?  Is there some windows-optimized code under the hood that is not available on RT?</p>
<p> </p>
<p>I was hoping it would be faster since my laptop is several years old and this is NI's super duper 8135 PXI controller. I did deploy this as a startup app to ensure running from the IDE did not affect timing when running on the RT.</p>
<p> </p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2014/post-6490-0-15466400-1416256375.png" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2014/post-6490-0-15466400-1416256375_thumb.png" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=9718" class="ipsImage ipsImage_thumbnailed" alt="post-6490-0-15466400-1416256375_thumb.pn"></a></p>
]]></description><guid isPermaLink="false">18635</guid><pubDate>Mon, 17 Nov 2014 20:40:44 +0000</pubDate></item><item><title>For-loop in case structure on FPGA</title><link>https://lavag.org/topic/18610-for-loop-in-case-structure-on-fpga/</link><description><![CDATA[<p>Hey,</p>
<p> </p>
<p>I have an application where I need to sample at a specific higher rate to calculate RMS values and feed some of my values over FPGA front panel objects to a fast loop on my RT and send the samples at a slower rate (triggered by a timer) over a DMA FIFO to slower loop.</p>
<p> </p>
<p>I Set the loop time to 10000 S/s and i'm filling up the DMA FIFO every 50 ms. The diagram looks something like this:</p>
<p> </p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_10_2014/post-27848-0-67466100-1414743936.png" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_10_2014/post-27848-0-67466100-1414743936_thumb.png" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=9678" class="ipsImage ipsImage_thumbnailed" alt="post-27848-0-67466100-1414743936_thumb.p"></a></p>
<p> </p>
<p>My question is: does the FPGA code execute the auto-indexed FOR-Loop like the Non-FPGA Diagram would, where the single Trigger bool from the timer remains true for all cycles of the for-loop, OR do I need to make sure the "Triggered" condition of the case structure is there for all FOR-Loop cycles? </p>
<p> </p>
<p>Thanks,</p>
<p> </p>
<p>Robert</p>
]]></description><guid isPermaLink="false">18610</guid><pubDate>Fri, 31 Oct 2014 08:26:54 +0000</pubDate></item><item><title>fundamental question about order of execution</title><link>https://lavag.org/topic/16535-fundamental-question-about-order-of-execution/</link><description><![CDATA[<p>Yeah, I thought that I had completely understood order of execution years ago.  It's not that hard right?  If something is wired into something else it goes first and things that are unwired happen first too.  Well you know what mean. </p>
<p> </p>
<p>Here's the situation I'm working with.  There's an existing cRIO based software that needed a quick fix.  In order to do so and report back to the Windows host a Network Shared Variable was added.  This variable is updated during the initialization, but is polled during an idle state in the RT code main process.  The NSV is not wired with error wires (currently) in this idle state.  No buffering or RT FIFO is enabled.  I have an intermittent problem where the NSV in that idle case is claiming that a part of the initialization failed though it hasn't (it's sole purpose is to monitor this).  Here's the question:  Is it possible that the NSV in the downstream loop and case structure is being populated before the initialization completes?  It is my understanding that a structure will act similarly to a subvi in that *nothing* inside it will execute until all the inputs to the structure are available.  However, this is the only sane explanation I can come up with to describe this behavior. </p>
]]></description><guid isPermaLink="false">16535</guid><pubDate>Fri, 08 Feb 2013 20:07:17 +0000</pubDate></item><item><title>What method should I use for transfer the latest value without polling?</title><link>https://lavag.org/topic/18496-what-method-should-i-use-for-transfer-the-latest-value-without-polling/</link><description><![CDATA[<p>Hi,</p>
<p>I would like to ask which method should I use for transferring latest data between determinism process. I don't want to use single process shared variable with RT FIFO enable since it will polling data. I don't want to use the RT FIFO function because I cannot send the latest value. Queue is not determinism. I am not sure if Notify is determinism or not. Anyone with experience about this?</p>
<p> </p>
<p>Regards,</p>
<p>Thang Nguyen</p>
]]></description><guid isPermaLink="false">18496</guid><pubDate>Wed, 10 Sep 2014 17:52:21 +0000</pubDate></item><item><title>How to manage RT code with FPGA refs that runs on Win/Linux/Mac</title><link>https://lavag.org/topic/18432-how-to-manage-rt-code-with-fpga-refs-that-runs-on-winlinuxmac/</link><description><![CDATA[<p>I have an RT app. A pretty big one. It does a lot of stuff.</p>
<p> </p>
<p>I have a Windows app that talks to my RT app. In the interest of dividing labor, creating automatic unit/subsystem tests, allowing multiple devs to build on their own machines, etc. I need to be able to simulate the RT program on Windows.</p>
<p> </p>
<p>So I abstracted all the calls to NI-RIO using Conditional Disable Structures and added a "Simulator" VI that wraps the entire application while hooking into some custom messages so it can display information to the user. When I need to run on Windows, the RIO calls don't execute and the Simulator panel ties into the network connections. When I need to run on RT, the Simulator panel isn't called and the RIO calls execute. It works great....except on machines that don't have the LVFPGA module installed (because they only develop the Windows app). Even though the ConDis structures prevent code from being called, it still gets statically linked into the app. This prevents a Windows-only system from building the Windows app: it throws errors while looking for FPGA Module components.</p>
<p> </p>
<p>What's the best way to abstract the FPGA reference wire from the code to work around this? I hate the idea of creating a class hierarchy for my IO calls and dynamically loading the class at runtime because dynamically launched code is nearly impossible to debug on LVRT.</p>
]]></description><guid isPermaLink="false">18432</guid><pubDate>Fri, 15 Aug 2014 20:06:33 +0000</pubDate></item><item><title>How to manage FPGA/RT code destined for multiple target types?</title><link>https://lavag.org/topic/16853-how-to-manage-fpgart-code-destined-for-multiple-target-types/</link><description><![CDATA[<p>I've been working on a cRIO-9074 project recently primarily via remote desktop into the customer site.  This morning I discovered my connection was down and there was nobody around to restart it.  I couldn't really do nothing all day, so I cloned my project, ported it to an sbRIO I had on hand, and continued working.</p>
<p> </p>
<p>I discovered I really like being able to easily shift between RT/FPGA targets.  It makes development so much easier and faster compared to remoting in to a client's site.  My question is what are some good ways to manage code so it can run on multiple target types?</p>
<p> </p>
<p>Currently I have two targets in my project, one sbRIO and one cRIO.  All the source code is listed under both targets.  It seems to work, but there's a lot of bookkeeping to track because many resources aren't shared between targets.  (FIFOs, registers, memory blocks, build specs, etc.)  It requires me to keep all the resource names synched and make sure the properties are identical.  I'm constantly worrying about screwing it up.  Is there a better way to do this?</p>
<p> </p>
<p>I noticed the sbRIO-9636 uses the Spartan 6 LX45 and the 9074 uses the Spartan 3 with 2M gates.  I assume I cannot use the bitfile from one for the other?</p>
<p> </p>
<p>I've been using conditional disable structures a bit and noticed there is a TARGET_CLASS symbol available when using it on an FPGA vi.  The help files don't give any information about that symbol.  Anyone know what it does?</p>
]]></description><guid isPermaLink="false">16853</guid><pubDate>Tue, 28 May 2013 06:49:55 +0000</pubDate></item><item><title>RT code that runs ok interactively but breaks as a built application</title><link>https://lavag.org/topic/18362-rt-code-that-runs-ok-interactively-but-breaks-as-a-built-application/</link><description><![CDATA[<p>I've just written about an <a href="http://forums.ni.com/t5/Real-Time-Measurement-and/RT-code-that-runs-ok-interactively-but-breaks-as-a-built/m-p/2925354" rel="external nofollow">interesting RT issue</a> I've experienced.  Perhaps keep the comments over there.</p>]]></description><guid isPermaLink="false">18362</guid><pubDate>Fri, 18 Jul 2014 03:41:21 +0000</pubDate></item><item><title>Timeout  of -1 Queue Performance on RT</title><link>https://lavag.org/topic/18298-timeout-of-1-queue-performance-on-rt/</link><description><![CDATA[<p>I'm having some weird behavior on RT on my softmotion application. Softmotion is throwing errors like it's not getting enough CPU to perform the needed tasks, but my CPU usage on the RIO is only in the 50% range.</p>
<p> </p>
<p>I have several(6-10) concurrent tasks going in my RT code, most of them are idle however, sitting on a dequeue with a -1 for the timeout. My communication manager loop is waiting for a message from the PC, and when it does it will enqueue a message to on of the concurrent tasks. The task will do a little casting as needed, then start executing a task that can take anywhere from 5 sec to 5 min. Some of these tasks involve time critical sub components. None of the time critical parts run for longer than 30 seconds.</p>
<p> </p>
<p>So as someone who's more experienced with desktop programming, all those dequeues look like 0% processor usage to me. And judging by the distributed system manager, the CRIO seems to agree. When there's nothing going on, my CPU usage drops down to the 15%-20% range. But I'm still getting weird softmotion errors (like -77055).</p>
<p> </p>
<p>So my question is: Does a dequeue with a -1 timeout tie up the CPU in RT, even though the usage doesn't seem to show it?</p>
]]></description><guid isPermaLink="false">18298</guid><pubDate>Thu, 19 Jun 2014 23:58:37 +0000</pubDate></item><item><title>Query USB Enumeration</title><link>https://lavag.org/topic/18258-query-usb-enumeration/</link><description><![CDATA[<p>I am working on an RT app and hardware that uses more than 50 USB devices connected via USB hubs to an NI rackmount computer.  After a hard reboot of the rack mount computer, the USB devices and hubs take more than 5 minutes to enumerate.  </p>
<p> </p>
<p>I am looking for a way to verify all the USB devices have enumerated.  Polling VISA Find Resources appears to cause the entire system to lockup if we start it immediately in RT app.  If we manually delay for 10 minutes or so in the application and then call VISA Find Resources, it appears to work OK as long as all of the devices have successfully enumerated.  A hard-coded 10 minute delay is not optimal because on soft reboots, the delay is unnecessary.  </p>
<p> </p>
<p>Are there any other ways to get the state of system USB enumeration other than VISA Find Resource?</p>
<p> </p>
<p>During reboots, the NI boot loader takes a minute or so to "Enumerate USB devices" but it appears it only enumerates each USB hub before it completes and moves on.</p>
<p> </p>
<p> </p>
<p> </p>
<p>PS. I know there are latency issues using USB on an RT system.  We chose to use the RT platform for stability (no windows updates, etc) vs determinism.  This may or may not be a good reason, but its what we have now.</p>
]]></description><guid isPermaLink="false">18258</guid><pubDate>Fri, 30 May 2014 11:57:11 +0000</pubDate></item><item><title>How do you write to the console in LV 2013?</title><link>https://lavag.org/topic/18152-how-do-you-write-to-the-console-in-lv-2013/</link><description><![CDATA[<p>I can't figure out where the VI to write to the console is. They deprecated the old RT Utilities API and Sys Config doesn't seem to have this function. I know I can watch a virtual console using the web admin interface, though. How do I write to the console from my application?</p>]]></description><guid isPermaLink="false">18152</guid><pubDate>Sat, 19 Apr 2014 23:50:48 +0000</pubDate></item><item><title><![CDATA[Error 53 &#34;Manager Call Not Supported&#34; for write PNG file VI on RT]]></title><link>https://lavag.org/topic/18066-error-53-manager-call-not-supported-for-write-png-file-vi-on-rt/</link><description><![CDATA[<p>I'm getting the "Manager Call Not Supported" when attempting to save a PNG file on an NI Phar Lap ETS target.  It's nice that the RTOS supports the "Get Image" method for control references, but being unable to save a PNG image makes that method pretty useless.  The "write BMP file" VI works just fine, but who wants to generate HTML with BMP images?  Is there a solution to the PNG vi, or has someone written an alternative?  Thanks.</p>]]></description><guid isPermaLink="false">18066</guid><pubDate>Mon, 10 Mar 2014 18:42:31 +0000</pubDate></item><item><title>Any way to get a type descriptor on RT?</title><link>https://lavag.org/topic/17997-any-way-to-get-a-type-descriptor-on-rt/</link><description><![CDATA[<p><a href="http://forums.ni.com/t5/LabVIEW/Variant-to-Flattened-String-prim-crashes-LVRT-2013-on-a-cRIO/m-p/2726419#M807156" rel="external nofollow">http://forums.ni.com/t5/LabVIEW/Variant-to-Flattened-String-prim-crashes-LVRT-2013-on-a-cRIO/m-p/2726419#M807156</a></p>
<p> </p>
<p>The Variant to Flattened String prim crashes an RT application in LV13. Does anybody know another way to get the type descriptor of a cluster?</p>
<br><br><p>Got it using VIs from <span style="font-family:courier, monospace;">vi.libUtilityVariantDataTypeVariantType.lvlib</span></p>
<p> </p>
<p>GetClusterInfo followed by a FOR loop with GetTypeInfo.</p>
]]></description><guid isPermaLink="false">17997</guid><pubDate>Mon, 10 Feb 2014 21:08:43 +0000</pubDate></item><item><title>Is it okay to use events in a Timed Loop?</title><link>https://lavag.org/topic/17861-is-it-okay-to-use-events-in-a-timed-loop/</link><description><![CDATA[<p>Any good reasons to avoid it? I intend to set the Event Structure's timeout to 0.</p>]]></description><guid isPermaLink="false">17861</guid><pubDate>Sun, 22 Dec 2013 23:08:29 +0000</pubDate></item><item><title>Custom Drivers for 3rd Party PCI cards in LVRT</title><link>https://lavag.org/topic/16691-custom-drivers-for-3rd-party-pci-cards-in-lvrt/</link><description><![CDATA[<p>Hey guys,</p>
<p> </p>
<p>I'm just beginning to feel out what would be required to write a driver for a 3rd party PCI card in LVRT. The outline is thus:</p>
<p>I have a laser interferometer card from Agilent, there are no drivers that I'm aware of for pulling information from the card directly into the RT system. My lab has been using a custom built hardware interface which taps off the hardware-out lines on the card when it is installed in a windows box, and reads the lines into an FPGA card in the RT box.</p>
<p> </p>
<p>This means we have to maintain two systems, a windows box to host the card, and an RT box where we're doing all our control. I'd like to simplify the system by doing whatever is necessary (driver?) to install the card direct into the LVRT box.</p>
<p> </p>
<p>My initial google has turned up resources for Veristand (I'm not familiar with it at all, and assume it isn't what I want), and not much else.</p>
<p><br>The install disc I have provides an API (headers with function declarations and register maps) but doesn't expose the functions themselves (they're in a compiled dll I think) There is also a pretty comprehensive manual about the register layout. My RT operating system is Pharlap, which can apparently call functions from a .dll (<a href="http://digital.ni.com/public.nsf/allkb/2EA49B05E67DDECF86256F9A006FB315" rel="external nofollow">linky</a>). The driver is a .sys file, could it be as simple as ftp'ing this into the right place along with the .dll and using "Call Library Function"? I couldn't find any information about what type of driver file Pharlap (and LVRT) expect, but I suspect it's not .sys (too good to be true).</p>
<p> </p>
<p>Anyway, I'm wondering if someone could point me in the right direction? Possibly with a link to any tuts/white papers about LVRT driver development?</p>
<p> </p>
<p>Many thanks for your time!</p>
<p>Kind regards,</p>
<p>Alex</p>
]]></description><guid isPermaLink="false">16691</guid><pubDate>Thu, 28 Mar 2013 00:36:37 +0000</pubDate></item><item><title>RT app needs system time from Windows PC</title><link>https://lavag.org/topic/17814-rt-app-needs-system-time-from-windows-pc/</link><description><![CDATA[<p>I have an RT PXI controller, and I am wondering the best way to get a networked PC's system time so I can periodically sync to it (in a controlled way, such as when RT system is idle).</p>
<p> </p>
<p>Obstacles:</p>
<p>The PC is not running any LabVIEW code, so no PC publishing time to network shared variable stuff</p>
<p>The code on the PC is legacy C# code that I cannot modify to include timestamp messaging between systems</p>
<p>The PC and attached RT PXI are network isolated, so no using a domain controller time service</p>
<p> </p>
<p> </p>
<p>My only solution to get the time from this generic windows PC (assume WinXP or newer) is to install an NTP time service on it that I can query via UDP from the RT application.  I have done this before, but it just feels unsatisfactory.</p>
<p> </p>
<p>Anyone else solve this problem before?</p>
]]></description><guid isPermaLink="false">17814</guid><pubDate>Thu, 05 Dec 2013 20:36:57 +0000</pubDate></item><item><title>cRio-9073 status led flashing 4 times</title><link>https://lavag.org/topic/17759-crio-9073-status-led-flashing-4-times/</link><description><![CDATA[<p>Hi guys,</p>
<p> </p>
<p>     I have a problem with the crio-9073 and a stepper driver 9512, the status led starts flashing 4 times, that according to the manual is a memory usage issue, but I don't think that's the problem since I haven't run any program on it, It starts when following the tutorial to use hybrid mode, I have I/O cards under an fpga program and the stepper module (9512) in scan mode, when everything it's deploy and try to switch the target to active mode it says that the NI Softmotion didn't detect the module, I restart the target and then when loading the module (when the leds of the 9512 start to come up) the status led starts to flash 4 times.</p>
<p> </p>
<p>     I format the crio, install all the software (NI rio, softmotion, fpga, picture attach) and do the same tutorial,</p>
<p> </p>
<p><a href="http://digital.ni.com/public.nsf/allkb/12287236ED86B789862576630059572C?OpenDocument" rel="external nofollow">http://digital.ni.com/public.nsf/allkb/12287236ED86B789862576630059572C?O</a><a href="http://digital.ni.com/public.nsf/allkb/12287236ED86B789862576630059572C?OpenDocument" rel="external nofollow">penDocument</a></p>
<p> </p>
<p>     and when the 9512 module leds start to pop up, the crio restarts and then the led status start to flash 4 times again.</p>
<p> </p>
<p>     I don't know if I'm doing something wrong here, but I really need your help with this.</p>
<p> </p>
<p> </p>
<p>Thanks in Advance</p>
<p>Javier Rocha</p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2013/post-46779-0-66298000-1385141320.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2013/post-46779-0-66298000-1385141320.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=8739" class="ipsImage ipsImage_thumbnailed" alt="post-46779-0-66298000-1385141320.jpg"></a></p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2013/post-46779-0-02761400-1385141356.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2013/post-46779-0-02761400-1385141356_thumb.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=8740" class="ipsImage ipsImage_thumbnailed" alt="post-46779-0-02761400-1385141356_thumb.j"></a></p>
]]></description><guid isPermaLink="false">17759</guid><pubDate>Fri, 22 Nov 2013 17:30:10 +0000</pubDate></item><item><title>Running RT project with dynamic IP</title><link>https://lavag.org/topic/17133-running-rt-project-with-dynamic-ip/</link><description><![CDATA[<p>I'm working with a contractor on a cRIO-based test system, and we are arranging a shared version control scheme so I can work on the code as well. One issue is that there are 2 different cRIO systems operating in completely different network environments, and there are currently 3 different locations where we have to change the IP address between environments:</p>
<p>1. RT controller properties in project</p>
<p>2. A front-panel control on a UI vi that connects to the RT controller</p>
<p>3. A constant in an RT Main vi to set the target for the FPGA BitFile</p>
<p> </p>
<p>I'd prefer to make this more portable and more easily maintainable in this shared satting under VCS, ideally just popping up a panel that offers controllers to connect to so the operator just clicks on a system to connect to. Desired features would be:</p>
<p>1. Dynamically identifies connected cRIO controllers</p>
<p>2. Offers choice of controller to connect with</p>
<p>3. Remembers last choice with ini file and automatically connects if there is only 1 possible target</p>
<p> </p>
<p>Thank you for any help.</p>
<p> </p>
<p>Ryan Rutledge</p>
]]></description><guid isPermaLink="false">17133</guid><pubDate>Wed, 18 Sep 2013 18:11:37 +0000</pubDate></item><item><title>basic question on softmotion module.</title><link>https://lavag.org/topic/17737-basic-question-on-softmotion-module/</link><description><![CDATA[<p>Hi guys,</p>
<p> </p>
<p>     I have a newbie question, I want to create an app that controls a stepper motor and some I/Os, I have read documentation that said that a hybrid mode is the best way to do it, so I installed all the "necessary" software to do it and only left me with very little memory that my code won't run, my problem is that this is my fist with cRio and I don't know if I'm using the correct software, I have attach a screen shot of the software that I have installed on the target and another with the target information.</p>
<p>     </p>
<p>     I'm using Lv2013 and NI-RIO 13.0, FPGA module and the softmotion module as well, is there another way or some NI knowledgebase that I missing, any help will be appreciated.</p>
<p> </p>
<p>     I don't know if I'm describing my problem correctly, so if you have any doubts please let me know, I just want to know if I can save more memory because I'm using the wrong package or if my code need to be more slim.</p>
<p> </p>
<p>Thanks in Advance</p>
<p> </p>
<p>     </p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2013/post-46779-0-82378100-1384822411.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2013/post-46779-0-82378100-1384822411.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=8716" class="ipsImage ipsImage_thumbnailed" alt="post-46779-0-82378100-1384822411.jpg"></a></p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_11_2013/post-46779-0-91803500-1384822412.jpg" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_11_2013/post-46779-0-91803500-1384822412.jpg" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=8717" class="ipsImage ipsImage_thumbnailed" alt="post-46779-0-91803500-1384822412.jpg"></a></p>
]]></description><guid isPermaLink="false">17737</guid><pubDate>Tue, 19 Nov 2013 01:04:21 +0000</pubDate></item><item><title>Design and add-on tools consideration</title><link>https://lavag.org/topic/17715-design-and-add-on-tools-consideration/</link><description><![CDATA[<p>I am looking to get some design consideration for developing a cRIO motion control application. My questions are</p>
<p>1. Is Softmotion advisable to be used for motion control where the data rate can is upto 20KHz? Not sure if SoftMotion only works with scan engine and according to cRIO developer guide, for rates &gt;500 Hz FPGA should be used and not scan engine. What are the limitations of using Softmotion?</p>
<p>2. In one application can FPGA be used to do I/O with one module and scan engine be used to do I/O with another module?</p>
<p>Just wondering how long does it take to develop a <abbr title="LabVIEW">LV</abbr> application with Softmotion if basic motion control is to be performed. Thanks.</p>
<p> </p>
]]></description><guid isPermaLink="false">17715</guid><pubDate>Sat, 09 Nov 2013 22:54:51 +0000</pubDate></item><item><title>saving a image of a graph to a file on a RT system</title><link>https://lavag.org/topic/17685-saving-a-image-of-a-graph-to-a-file-on-a-rt-system/</link><description><![CDATA[<p>Hi all,</p>
<p> </p>
<p>i've a project on a cRIO with some I/Os running under LabVIEW 2012.</p>
<p>Now i want to visible my results on a website with the cRIO webserver. So i wrote a web service witch show the content of some shared variables.</p>
<p>Because the default website show only a table with each name and content of the variables, i toke a string variable and save a html link to a picture in it (&lt;img src="myGraph.bmp"&gt;).</p>
<p>In my LabVIEW code i get the image of the graph using a property node and save it to an *.bmp file.</p>
<p>Code of the initalisation of the variable and saving an empty graph at start up:</p>
<p><a class="ipsAttachLink ipsAttachLink_image" href="https://lavag.org/uploads/monthly_10_2013/post-1099-0-57114700-1383118630.png" rel="external nofollow"><img src="https://lavag.org/uploads/monthly_10_2013/post-1099-0-57114700-1383118630.png" data-fileid="%7B___base_url___%7D/applications/core/interface/file/attachment.php?id=8648" class="ipsImage ipsImage_thumbnailed" alt="post-1099-0-57114700-1383118630.png"></a></p>
<p> </p>
<p>Now when i deployed my program the picture was saved and the website look like i want to.</p>
<p>But when i run my cRIO as a standalone it seemd that he didn't open the frontpanel and so he take an empty picture with.</p>
<p> </p>
<p>I checked if the frontpanel was removed by the build specifications and i try to set a invoke node to open the frontpanel first.</p>
<p>But both didn' help.</p>
<p> </p>
<p>I'm a native html but a good LabVIEW programmer. So i try to solve it in LabVIEW.</p>
<p>But perhaps there is an easier way in html. But up to now i don't know how to reference to the webservice variables from an html file.</p>
<p>I found an example for forms connecting to webservices. There i've to send the returned website with a LabVIEW build html string and i don't know how drawing an graph in html.</p>
<p> </p>
<p> </p>
<p>Now i'm thinking about drawing my own graph in a picture with LabVIEW and saving them...</p>
<p>So have anyone an idea how i get a graph easier to the website?</p>
<p> </p>
<p>thanks for help and sorry for my bad english grammar</p>
<p>Oliver</p>
]]></description><guid isPermaLink="false">17685</guid><pubDate>Wed, 30 Oct 2013 07:39:47 +0000</pubDate></item><item><title>Can Functional Globals be used to share data between VIs running on different targets?</title><link>https://lavag.org/topic/17093-can-functional-globals-be-used-to-share-data-between-vis-running-on-different-targets/</link><description><![CDATA[<p>The <a href="http://labviewwiki.org/Functional_global_variable" rel="external nofollow">LabVIEW wiki</a> page on Functional Global Variables (FGV) states that</p>
<blockquote data-ipsquote="" class="ipsQuote"><div>
<p></p><div style="margin-left:25px;">The primary use of Functional Globals is to provide data sharing across an entire project, both horizontally and vertically.</div>
<p></p>
</div></blockquote>
<p>In the past, I have successfully used FGVs to share data among VIs running <em>on the same target</em>. In my current project, which involves multiple targets (namely, a host PC and a cRIO), I now want to pass configuration data between a Host VI and an RT VI, and I thought an FGV would come in handy for that.</p>
<p> </p>
<p>However, it doesn't seem to work: I write to the FGV on the Host VI alright; but when I read data from the FGV in the RT VI, I only get default values, as if nothing had ever been written to the shift registers. Before you suggest it: yes, I have checked the VI properties of my FGV; its execution is set, as it should be, to <em>non-reentrant</em>.</p>
<p> </p>
<p>Can Functional Global Variables be used to share data between VIs running on different targets? Or is an FGV's scope limited to the target it runs on?</p>
<p>Unfortunately, I couldn't find any answers to those questions in the LabVIEW online help, or on any LabVIEW discussion board...</p>
]]></description><guid isPermaLink="false">17093</guid><pubDate>Thu, 29 Aug 2013 23:17:41 +0000</pubDate></item><item><title>LVRT Hung While Deploying</title><link>https://lavag.org/topic/17055-lvrt-hung-while-deploying/</link><description><![CDATA[<p>hi everyone here!</p>
<p> </p>
<p>recently i have come to a odd problem with lvrt(ets) and have no idea about how it goes. </p>
<p> </p>
<p>My project uses 10 or more dlls which were wrote by third party and had been put into the RT's C:ni-rtstartupdata  folder, and this path had been added to the system find path list. Each of the dlls may have several VI calls(each for different functions in the dll) in the project. And when i try to deploy the whole project, my RT hung with one of it's cpu went to 100% loads.</p>
<p> </p>
<p>And the odd thing is, when i try to disable one of the dll (means to disable all the vis that call the dll through the "call library function node"), the deploy goes with no error and my application can run as expected except the disabled parts! During the past one week's struggling with this deploy problem, once i can come to a particular configuration (by removing some no use modules in the RT or changing the dll call's  from "run in UI thread" to "run in any thread"), and under this situation ,i can deploy my project to rt, but when i run, a exception string appears on the RT's screen, which says "flushing disk cache" and something like "system error".</p>
<p> </p>
<p>Here i have two questions:</p>
<p>1,   does the ets os system have a max number of user defined dlls that can exist in memory at the same time?</p>
<p>2,   does anyone come to the "flushing disk cache" error before in the ets system? can you share some experience with me?</p>
<p> </p>
<p>any suggestions are welcome and will be appreciated.     i am looking forward to your share, many thanks in advance!</p>
]]></description><guid isPermaLink="false">17055</guid><pubDate>Fri, 16 Aug 2013 15:48:16 +0000</pubDate></item></channel></rss>
