完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
本帖最后由 lm12041204a 于 2019-12-4 15:54 编辑 The NI Scan Engine is not running. Please verify that the project is configured to start the scan engine on deploy operations. Also, make sure that the LabVIEW and all associated I/O drivers are properly installed. NI扫描引擎未运行。 请验证项目已配置为在部署操作时启动扫描引擎。 另外,请确保正确安装了LabVIEW和所有相关的I/O驱动程序。 字面说的很明白,扫描引擎没有启动。 1. 关闭360,卸载、重新安装,看能否正常; 2. 看右下角托盘里是有NI相关图标; 3. 我的电脑 - 管理 -服务和应用程序 - 服务, 或 开始菜单 - 管理工具 - 服务 进去查找有无“NI”、“NI Scan Engine”之类的服务; 如果有则检查是否已经启动了,否则就启动它。
最佳答案
|
|
1 条评论
|
|
看一下NI Scan Engine是以什么方式运行的,一般进程,还是系统服务方式;
如果卸载重新安装都解决不了问题,看看是不是防护软件把NI Scan Engine进程或服务给禁止了,关闭相关防护软件在试试。 |
|
1 条评论
|
|
Using the NI Scan Engine (ETS, VxWorks, Windows)
Table of Contents LabVIEW 2011 Help Edition Date: June 2011 Part Number: 371361H-01 »View Product Info Download Help (Windows Only) The NI Scan Engine enables efficient single-point access to sets of data channels, such as I/O channels, using a scan that stores data in a global memory map and updates all values at a single rate, known as the scan period. The NI Scan Engine installs on LabVIEW for Windows by default. You also can install the NI Scan Engine on supported LabVIEW targets, such as RT Series PXI and CompactRIO targets. Refer to the specific hardware device documentation for information about NI Scan Engine support. (Real-Time Module) By default, the NI Scan Engine runs in a thread above time-critical priority on RT targets, although LabVIEW includes the scan thread in the time-critical category when reporting CPU usage statistics. When running the NI Scan Engine at above time-critical priority, you must synchronize the deterministic sections of the application with the scan period to ensure that the scan thread does not affect the determinism of the application. For applications in which I/O is not the highest-priority task, you also can configure the priority of the scan engine to fall between time-critical and Timed Structure priority. If you do not plan to use I/O variables on a target, do not install the NI Scan Engine on the target. If the NI Scan Engine is already installed on the target, you can use the NI Measurement & Automation Explorer (MAX) to uninstall the NI Scan Engine. Note (Windows) The only NI Scan Engine priority available on Windows is normal priority. Because of the non-deterministic nature of the Windows operating system, the timing of the NI Scan Engine is not guaranteed when running on Windows. 使用NI扫描引擎(ETS,VxWorks,Windows) 目录 LabVIEW 2011帮助 版本日期:2011年6月 零件编号:371361H-01 »查看产品信息 下载帮助(仅限Windows) NI扫描引擎使用一种将数据存储在全局内存映射中并以单一速率(即扫描周期)更新所有值的扫描,来实现对I / O通道等数据通道集的高效单点访问。 NI扫描引擎默认安装在LabVIEW for Windows上。您还可以在支持的LabVIEW目标(例如RT Series PXI和CompactRIO目标)上安装NI扫描引擎。有关NI扫描引擎支持的信息,请参阅特定的硬件设备文档。 (实时模块)默认情况下,尽管LabVIEW在报告CPU使用情况统计信息时将扫描线程包括在时间紧迫类别中,但NI扫描引擎默认在RT目标上的时间紧迫优先级的线程中运行。以高于时间要求的优先级运行NI扫描引擎时,必须将应用程序的确定性部分与扫描周期同步,以确保扫描线程不会影响应用程序的确定性。对于I / O不是最高优先级任务的应用程序,您还可以将扫描引擎的优先级配置为介于时间关键和定时结构优先级之间。如果您不打算在目标上使用I / O变量,请不要在目标上安装NI Scan Engine。如果目标已经安装了NI扫描引擎,则可以使用NI Measurement&Automation Explorer(MAX)卸载NI扫描引擎。 注意(Windows)Windows上唯一可用的NI Scan Engine优先级是普通优先级。由于Windows操作系统的不确定性,在Windows上运行时,不能保证NI扫描引擎的计时。 Configuring NI Scan Engine Settings Use the Scan Engine page to configure scan engine settings including the scan period, network-publishing rate, and priority level of the NI Scan Engine. Use the NI Distributed System Manager to monitor and manage scan engine faults and modes. Select Tools»Distributed System Manager to display the NI Distributed System Manager. You also can use the NI Scan Engine VIs to view and configure scan engine settings programmatically. Deploying and Running the NI Scan Engine After you configure NI Scan Engine settings in the Project Explorer window, you must deploy a project item that uses the NI Scan Engine, such as My Computer or an RT target, for the settings to take effect. (Windows) The NI Scan Engine starts running the first time you deploy the target and stops running when you close the project. To automatically deploy the NI Scan Engine and I/O variables when a built application runs, you must enable the Include hardware configuration files checkbox on the Advanced page of the Application Properties dialog box before building the application. (Real-Time Module) When running on an RT target, the NI Scan Engine starts automatically when you boot the target and runs continuously until you shut down the target. A single computer can run only a single instance of the NI Scan Engine at a time. For example, if you create a Windows built application that uses the NI Scan Engine, you must close the project from which you built the application before you can run the application on the same computer. Although you can configure multiple instances of the NI Scan Engine in multiple LabVIEW projects, deployment of subsequent projects using the NI Scan Engine fails if an instance of the NI Scan Engine is running. To run a different instance of the NI Scan Engine, you first must stop the current instance. 配置NI扫描引擎设置 使用“扫描引擎”页面可配置扫描引擎设置,包括扫描周期,网络发布速率和NI扫描引擎的优先级。 使用NI分布式系统管理器来监视和管理扫描引擎的故障和模式。选择工具»分布式系统管理器以显示NI分布式系统管理器。您也可以使用NI扫描引擎VI以编程方式查看和配置扫描引擎设置。 部署和运行NI扫描引擎 在“项目资源管理器”窗口中配置NI扫描引擎设置后,必须部署使用NI扫描引擎的项目项(例如“我的电脑”或RT目标)才能使设置生效。 (Windows)NI Scan Engine在您首次部署目标时开始运行,并在关闭项目时停止运行。要在生成的应用程序运行时自动部署NI Scan Engine和I / O变量,必须在构建应用程序之前启用“应用程序属性”对话框“高级”页面上的“包括硬件配置文件”复选框。 (实时模块)在RT目标上运行时,NI扫描引擎在启动目标时自动启动,并持续运行直到关闭目标。 一台计算机一次只能运行一个NI扫描引擎实例。例如,如果创建使用NI扫描引擎的Windows构建的应用程序,则必须关闭构建应用程序的项目,然后才能在同一台计算机上运行该应用程序。尽管您可以在多个LabVIEW项目中配置NI扫描引擎的多个实例,但是如果正在运行NI扫描引擎的实例,则使用NI扫描引擎进行后续项目的部署将失败。要运行NI扫描引擎的其他实例,首先必须停止当前实例。 Scan Engine Timing The NI Scan Engine executes at regular intervals determined by the Scan Period you specify on the Scan Engine page. Choose a period long enough to accommodate both the scan itself and the application logic, as shown in the following illustration. Note The length of the scan depends on the number and type of I/O items deployed to the target. To maximize scan engine performance, undeploy any I/O items that you do not plan to use in the application. Use the Get Scan Engine Period VI to read the scan period programmatically. Use the Set Scan Engine Period VI to set the scan period programmatically. Note (Real-Time Module) Real-time loops generally need one or two warm-up iterations to begin executing deterministically. Before checking to ensure that an application meets timing requirements, you should allow each time-critical loop to execute warm-up iterations. Synchronizing to the Scan Engine (Real-Time Module) Unless you configure the NI Scan Engine to run below time-critical priority, you must synchronize time-critical code to the scan period to avoid collisions that could affect the determinism of the application. Use the Synchronize to Scan Engine timing source to synchronize timed structure execution to the scan engine. If you do not want to use a timed structure, you can use the Synchronize to Scan Engine VI to synchronize to the scan engine. Both synchronization methods trigger execution at the time labeled End of Scan in the previous illustration. To use I/O variables as a coherent data set, ensure that the synchronized code finishes executing before the next scan iteration. However, you can skip scan iterations if the code does not depend on a coherent data set. Note If synchronized code does not finish executing before the next scan iteration, the information reported by the error cluster of an I/O variable might lose synchronization with the I/O value. Note When you click the Abort button on a VI that involves synchronization to the NI Scan Engine, the VI does not abort until the current scan iteration completes, so the VI might appear to hang temporarily if the scan period is sufficiently long. 扫描引擎定时 NI扫描引擎会定期执行,该间隔由您在“扫描引擎”页面上指定的扫描周期确定。选择一个足够长的时间来容纳扫描本身和应用程序逻辑,如下图所示。 注意扫描的长度取决于部署到目标的I / O项目的数量和类型。为了最大化扫描引擎的性能,请取消部署您不打算在应用程序中使用的所有I / O项目。 使用“获取扫描引擎周期” VI可通过编程方式读取扫描周期。使用设置扫描引擎周期VI可通过编程方式设置扫描周期。 注意(实时模块)实时循环通常需要一两次预热迭代才能确定地开始执行。在检查以确保应用程序满足时序要求之前,应允许每个对时间要求严格的循环执行预热迭代。 同步到扫描引擎 (实时模块)除非您将NI扫描引擎配置为在时间要求严格的优先级以下运行,否则必须将时间要求严格的代码同步到扫描周期,以避免可能影响应用程序确定性的冲突。 使用“同步到扫描引擎”定时源将定时结构的执行同步到扫描引擎。如果不想使用定时结构,可以使用“同步到扫描引擎” VI来同步到扫描引擎。两种同步方法均在上图中标记为“扫描结束”的时间触发执行。要将I / O变量用作一致的数据集,请确保在下一次扫描迭代之前完成同步代码的执行。但是,如果代码不依赖于一致的数据集,则可以跳过扫描迭代。 注意如果同步代码在下一次扫描迭代之前未完成执行,则I / O变量的错误群集报告的信息可能会失去与I / O值的同步。 注意当您在涉及与NI扫描引擎同步的VI上单击“中止”按钮时,VI不会中止,直到当前的扫描迭代完成为止,因此,如果扫描周期足够长,VI可能会暂时挂起。 NI Scan Engine Modes Note Only certain targets and devices use NI Scan Engine modes. CompactRIO targets with local I/O modules do not use NI Scan Engine modes. Refer to the I/O hardware documentation for information about hardware-specific mode behavior. LabVIEW defines four NI Scan Engine modes: Initialization Mode Occurs only briefly during startup. Configuration Mode The required mode when configuring scan engine settings on hardware that uses NI Scan Engine modes. Active Mode The mode in which the scan engine runs and updates values. Fault Mode The mode triggered when a major or unrecoverable fault occurs. Note Fault mode behavior varies by target. Refer to the specific target hardware documentation for information about fault mode behavior. Use the NI Distributed System Manager to view and configure the scan engine mode. Use the Get Scan Engine Mode VI to read the scan engine mode programmatically. Use the Set Scan Engine Mode VI to set the scan engine mode programmatically. NI扫描引擎模式 注:仅某些目标设备和设备使用NI扫描引擎模式。带有本地I / O模块的CompactRIO目标不使用NI扫描引擎模式。有关特定于硬件的模式行为的信息,请参考I / O硬件文档。 LabVIEW定义了四种NI扫描引擎模式: 初始化模式仅在启动期间短暂出现。 配置模式在使用NI扫描引擎模式的硬件上配置扫描引擎设置时需要的模式。 活动模式扫描引擎运行和更新值的模式。 故障模式发生重大或不可恢复的故障时触发的模式。 注意故障模式的行为因目标而异。有关故障模式行为的信息,请参考特定的目标硬件文档。 使用NI分布式系统管理器查看和配置扫描引擎模式。使用“获取扫描引擎模式” VI以编程方式读取扫描引擎模式。使用设置扫描引擎模式VI可通过编程方式设置扫描引擎模式。 机器翻译,将就看吧。 |
|
|
|
本帖最后由 lm12041204a 于 2019-12-4 16:08 编辑
NI Scan Engine Performance Publish Date: 二月 14, 2018 | 4 评级 | 3.75 out of 5 | Print Overview The NI Scan Engine enables efficient single-point access to sets of data channels, such as I/O channels, using a scan that stores data in a global memory map and updates all values at a single rate, known as the scan period. The scan period must include the time for the scan itself, as well as the time for the application logic. It is valuable to understand how the scan engine performs its scans and the factors outside application logic that can affect performance. This document provides key considerations when analyzing the performance of CompactRIO hardware with the NI Scan Engine installed, and introduce the Real-Time Execution Trace Toolkit as a method for estimating NI Scan Engine cost in a CompactRIO system. NI扫描引擎性能 发布日期:二月14,2018 | 4评分| 5中的3.75 | 打印 总览 NI扫描引擎使用一种将数据存储在全局内存映射中并以单一速率(即扫描周期)更新所有值的扫描,来实现对I / O通道等数据通道集的高效单点访问。 扫描周期必须包括扫描本身的时间以及应用程序逻辑的时间。 了解扫描引擎如何执行其扫描以及应用程序逻辑外部可能影响性能的因素非常有价值。 本文档提供了在分析安装了NI Scan Engine的CompactRIO硬件性能时的主要注意事项,并介绍了实时执行跟踪工具包,作为估算CompactRIO系统中NI Scan Engine成本的一种方法。 Table of Contents Understanding NI Scan Engine Performance I/O Scan Thread I/O Variable Nodes CPU Usage Considerations When Using Scan Mode Estimating NI Scan Engine Cost For Your System Related Resources 1. Understanding NI Scan Engine Performance NI Scan Engine performance is primarily determined by two key elements. The first element is the I/O Scan Thread: this is tied to hardware resources and is affected by the type and number of C Series Modules used, if timestamps are acquired, and other factors. The second element is the I/O Variable node. This is tied to software resources and is affected by the number of nodes in a LabVIEW VI, how nodes are accessed, and other factors. The next two sections will cover these topics in more detail. Note: The benchmarks provided in this document (CPU and execution time) were run on a legacy CompactRIO 9012 controller. While useful to illustrate the effects of certain variables on NI Scan Engine performance, they should not be used to predict performance for newer CompactRIO controllers. 2. I/O Scan Thread I/O Scan Time is the first major consideration when understanding NI Scan Engine performance. The main factor that controls I/O Scan execution time is the type and number of C Series Modules used in a CompactRIO system. Figure 3 compares the I/O scan execution times of a selected set of NI-RIO digital (NI-94xx) and analog (NI-92xx) I/O modules. All I/O modules, except NI-9264, used in this test support 32 I/O channels. Figure 1. I/O Scan thread cost for different I/O module types (Above Time-Critical Priority) Based on this data, we can make the following assumptions when trying to understand the I/O Scan time for a given hardware setup: Digital modules (NI-94xx) consume less I/O Scan time than analog modules (NI-92xx). This is because digital modules don’t require any scaling or calibration. Input-only modules for a given data type (NI-9205 voltage input module) take less time than output modules of the same data type (NI-9264 voltage output module), as there is no processing needed to write output data. Depending on the type and number of modules used, the total execution time of the I/O Scan thread generally ranges from 200 to 500 μs. Figure 3 shows ~60 μs of overhead with no I/O modules in use. This represents the fixed I/O Scan thread overhead. If you are not using any of the Scan Mode features, NI recommends that you uninstall Scan Mode software from the real-time target to avoid this fixed cost. Another key element that affects the I/O Scan Time is timestamping. Each I/O variable allows you to enable or disable the timestamp feature. Enabling timestamps on any I/O variable under a module adds overhead to the I/O Scan time for that module. Figure 2 shows the difference in I/O Scan time for NI 9205 modules with and without timestamp enabled. Figure 2. I/O Scan time for NI 9205 with timestamp feature enabled/disabled The timestamp cost varies by module. In general, enabling timestamps can add 10-15% overhead to the I/O scan time of a given module. The timestamp feature is disabled by default. 目录 了解NI扫描引擎性能 I / O扫描线程 I / O变量节点 使用扫描模式时的CPU使用注意事项 估算系统的NI扫描引擎成本 相关资源 1.了解NI扫描引擎性能 NI Scan Engine的性能主要由两个关键要素决定。第一个元素是I / O扫描线程:它与硬件资源相关,并且受所使用的C系列模块的类型和数量,是否获取时间戳以及其他因素的影响。第二个元素是“ I / O变量”节点。这与软件资源有关,并受LabVIEW VI中节点数,节点访问方式以及其他因素的影响。接下来的两个部分将更详细地介绍这些主题。 注意:本文档中提供的基准(CPU和执行时间)在旧式CompactRIO 9012控制器上运行。尽管有助于说明某些变量对NI Scan Engine性能的影响,但不应将其用于预测新型CompactRIO控制器的性能。 2. I / O扫描线程 了解NI Scan Engine性能时,I / O扫描时间是首要考虑因素。控制I / O扫描执行时间的主要因素是CompactRIO系统中使用的C系列模块的类型和数量。图3比较了一组选定的NI-RIO数字(NI-94xx)和模拟(NI-92xx)I / O模块的I / O扫描执行时间。本测试中使用的所有I / O模块(NI-9264除外)均支持32个I / O通道。 图1.不同I / O模块类型的I / O扫描线程成本(时间优先级以上) 基于此数据,在尝试了解给定硬件设置的I / O扫描时间时,我们可以做出以下假设: 数字模块(NI-94xx)消耗的I / O扫描时间少于模拟模块(NI-92xx)。这是因为数字模块不需要任何缩放或校准。 给定数据类型的仅输入模块(NI-9205电压输入模块)比相同数据类型的输出模块(NI-9264电压输出模块)花费的时间更少,因为无需执行任何处理即可写入输出数据。 根据所用模块的类型和数量,I / O扫描线程的总执行时间通常为200到500μs。 图3显示了大约60μs的开销,没有使用I / O模块。这表示固定的I / O扫描线程开销。如果您没有使用任何扫描模式功能,NI建议您从实时目标中卸载扫描模式软件,以避免固定费用。 影响I / O扫描时间的另一个关键因素是时间戳。每个I / O变量都允许您启用或禁用时间戳功能。在模块下的任何I / O变量上启用时间戳会增加该模块的I / O扫描时间的开销。图2显示了启用和不启用时间戳的NI 9205模块的I / O扫描时间的差异。 图2.启用/禁用时间戳功能的NI 9205的I / O扫描时间 时间戳成本因模块而异。通常,启用时间戳会给给定模块的I / O扫描时间增加10-15%的开销。默认情况下,时间戳功能是禁用的。 3. I/O Variable Nodes In addition to the execution time of the I/O Scan thread, each evaluation of an I/O variable node in a LabVIEW VI takes time to execute. Figure 3 shows the total execution time of Boolean and Double I/O variable nodes for both read and write operations. The trend for the total I/O variable node access time is clearly linear. Figure 3. Total execution time of I/O Variable nodes Figure 4 shows the average execution time of each I/O variable node for the same setup used to collect data for figure 3. As shown below, the execution time per node varies from 7 μs to 9 μs, with the average execution time around 8 μs. This data is an approximation of the average execution time per I/O variable node as the number of nodes on the block diagram increases. This data is based on averages collected over several thousand iterations and is adjusted to account for system jitter and benchmarking overhead. In general, 10 μs per I/O variable node is a reasonable estimate of execution time using scanned access mode. Figure 4. Average execution time per I/O variable node As the number of Variable Nodes increases, the execution time slightly increases. I/O variable nodes execute faster using scanned access mode than direct access mode. When you access an I/O variable using direct access mode, LabVIEW must traverse the software stack all the way down to the hardware driver, whereas scanned access simply involves accessing local memory. Figure 5 below compares scanned versus direct mode execution times for I/O variable nodes of the Double data type. Figure 5. Average I/O variable execution time for scanned versus direct access mode Use scanned access mode for synchronous access to a group of I/O channels. Use direct access mode to access an I/O channel asynchronously from the I/O scan. Although the execution time of direct access mode is slower than that of scanned access mode, you can take advantage of the asynchronous quality of direct access mode to access individual I/O channels at either a faster or a slower rate than the I/O scan. 3. I / O变量节点 除了I / O扫描线程的执行时间外,LabVIEW VI中对I / O变量节点的每次评估还需要花费一些时间来执行。图3显示了布尔和双I / O变量节点的读写操作总时间。 I / O变量节点总访问时间的趋势显然是线性的。 图3. I / O变量节点的总执行时间 图4显示了用于与图3收集数据相同的设置的每个I / O变量节点的平均执行时间。如下所示,每个节点的执行时间从7μs到9μs不等,平均执行时间约为8 s。微秒随着框图上节点数量的增加,该数据近似于每个I / O变量节点的平均执行时间。此数据基于数千次迭代收集的平均值,并进行了调整以考虑系统抖动和基准测试开销。通常,使用扫描访问模式,每个I / O变量节点10μs是执行时间的合理估计。 图4.每个I / O变量节点的平均执行时间 随着变量节点数量的增加,执行时间会稍微增加。 与直接访问模式相比,使用扫描访问模式的I / O变量节点执行速度更快。当您使用直接访问模式访问I / O变量时,LabVIEW必须一直遍历软件堆栈直至硬件驱动程序,而扫描访问仅涉及访问本地内存。下面的图5比较了Double数据类型的I / O变量节点的扫描时间与直接模式执行时间。 图5.扫描和直接访问模式下平均I / O变量执行时间 使用扫描访问模式来同步访问一组I / O通道。使用直接访问模式从I / O扫描异步访问I / O通道。尽管直接访问模式的执行时间比扫描访问模式的执行时间慢,但是您可以利用直接访问模式的异步质量以比I / O扫描更快或更慢的速率访问单个I / O通道。 4. CPU Usage Considerations When Using Scan Mode CPU usage is an important metric of system performance, and certain factors can have a big impact on scan engine performance, without much application logic. Table 1 below details a simple PID loop run on a legacy CompactRIO 9012 Controller. As the number of channels used increases, the CPU usage increases. This effect is compounded as the controller's Scan Rate is increased. At 1000Hz, the CompactRIO 9012 was not able to read/write to more than 16 AI/AO pairs without reaching maximum CPU usage. Note: More modern CompactRIO Controllers will not have this problem - these benchmarks are provided to show the effect that increasing channel counts and sample rates have on CPU usage. Number of Channels (AI/AO pair) 100 Hz 500 Hz 1000 Hz 1 10% 32% 55% 16 16% 47% 95% 32 18% 67% n/a 64 27% 96% n/a 80 29% n/a n/a Table 1. CPU usage for Scan Mode PID application at various scan rates Another key factor affecting CPU usage is network publishing of data. I/O variables support network publishing for remote data access and monitoring, but using this network publishing can have significant CPU overhead, based on the publishing period selected. Figure 6 compares the system CPU usage for various network publishing rates. Figure 6. Network publishing overhead for analog I/O variables at various publishing rates The test setup used for the network publishing benchmarks included continuously changing analog input data from NI 9205 modules. The test used NI Distributed System Manager probes to monitor the input data on all the I/O modules and to record the total CPU usage for each scenario. The results reflect the total CPU usage with the I/O scan running at the default period of 10 ms and network publishing either disabled for all I/O variables or enabled at various network publishing rates. Network publishing overhead is typically negligible if no remote client is connected to the target or if the I/O data is not changing quickly. But as figure 8 shows, the CPU usage can become significant when monitoring a large number of continuously changing analog I/O channels. Network publishing is enabled by default for I/O variables. However, you can disable network publishing for the individual I/O variables using the Shared Variable Properties dialog box. You also can disable network publishing for multiple I/O variables at once using the Multiple Variable Editor. The “Publishing Disabled” series in figure 8 represents the baseline CPU usage of the system with only the I/O scan running and network publishing disabled for all I/O variables. To optimize your system’s CPU usage, you can either slow down the network publishing rate by adjusting the Network Publishing Period on the Scan Engine page of the RT Target Properties dialog box, disabling network publishing for I/O variables that you are not monitoring remotely, or making sure you don’t have a remote client connected to any I/O module unless it is using the I/O data for remote access or monitoring. 4.使用扫描模式时的CPU使用注意事项 CPU使用率是衡量系统性能的重要指标,并且在没有太多应用程序逻辑的情况下,某些因素可能会对扫描引擎性能产生重大影响。下表1详细说明了在旧版CompactRIO 9012控制器上运行的简单PID回路。随着使用的通道数增加,CPU使用率增加。随着控制器的“扫描速率”的增加,这种影响更加严重。在1000Hz频率下,CompactRIO 9012不能读取/写入超过16个AI / AO对,而未达到最大CPU使用率。 注意:更现代的CompactRIO控制器将不会出现此问题-提供这些基准测试是为了显示增加通道数和采样率对CPU使用率的影响。 通道数(AI / AO对)100 Hz 500 Hz 1000 Hz 1 10%32%55% 16 16%47%95% 32 18%67%不适用 64 27%96%不适用 80 29%不适用不适用 表1.各种扫描速率下的扫描模式PID应用程序的CPU使用率 影响CPU使用率的另一个关键因素是数据的网络发布。 I / O变量支持用于远程数据访问和监视的网络发布,但是根据所选的发布时间,使用此网络发布会产生大量的CPU开销。图6比较了各种网络发布速率下的系统CPU使用率。 图6.不同发布速率下模拟I / O变量的网络发布开销 用于网络发布基准测试的测试设置包括不断更改NI 9205模块的模拟输入数据。该测试使用NI Distributed System Manager探针监视所有I / O模块上的输入数据,并记录每种情况下的CPU使用总量。结果反映了I / O扫描在默认时间段10毫秒运行并且对所有I / O变量禁用了网络发布或以各种网络发布速率启用了网络发布时的总CPU使用率。 如果没有远程客户端连接到目标或I / O数据没有快速更改,则网络发布开销通常可以忽略不计。但是如图8所示,当监视大量不断变化的模拟I / O通道时,CPU使用率可能会变得很高。默认情况下,I / O变量启用网络发布。但是,可以使用“共享变量属性”对话框为单个I / O变量禁用网络发布。您也可以使用“多变量编辑器”同时禁用多个I / O变量的网络发布。图8中的“发布已禁用”系列表示仅运行I / O扫描并且已禁用所有I / O变量的网络发布的系统的基准CPU使用率。 为了优化系统的CPU使用率,您可以通过调整“ RT Target属性”对话框的“扫描引擎”页面上的“网络发布时间”来降低网络发布速度,从而对不进行远程监视的I / O变量禁用网络发布,或确保您没有将远程客户端连接到任何I / O模块,除非该客户端正在使用I / O数据进行远程访问或监视。 5. Estimating NI Scan Engine Cost For Your System As noted in the previous sections, I/O Scan thread overhead depends on the number and type of I/O modules used in your system. An I/O variable node itself can take around 10 μs or less of execution time. The total cost of I/O variable nodes depends on the number of nodes present in your application and the rates of the loops containing the nodes. You can use the Real-Time Execution Trace Toolkit to estimate the total execution time of the I/O Scan thread for you system. See figure 8 for an example trace session showing the I/O Scan running at Above Time Critical priority. The data shown in figure 3 and figure 4 is an average of several iterations of the data collected from similar traces and is adjusted to account for system jitter and benchmarking overhead. Figure 7. I/O Scan Execution trace for a system with eight NI-9205 modules 6. Related Resources C Series Modules Supported by CompactRIO Scan Mode Using NI CompactRIO Scan Mode with NI LabVIEW Software Recommended Practices for Using the LabVIEW I/O Variable and NI Scan Engine The RIO Scan Interface Under the Hood 5.估算系统的NI扫描引擎成本 如前几节所述,“ I / O扫描”线程的开销取决于系统中使用的I / O模块的数量和类型。 I / O变量节点本身可以花费大约10μs或更短的执行时间。 I / O变量节点的总成本取决于应用程序中存在的节点数以及包含这些节点的循环的速率。 您可以使用实时执行跟踪工具包来估计系统的I / O扫描线程的总执行时间。请参阅图8,以获取示例跟踪会话,该会话显示以“高于时间上限”优先级运行的I / O扫描。图3和图4中显示的数据是从类似迹线收集的数据的几次迭代的平均值,并进行了调整以考虑系统抖动和基准测试开销。 图7.具有八个NI-9205模块的系统的I / O扫描执行轨迹 6.相关资源 CompactRIO扫描模式支持的C系列模块 通过NI LabVIEW软件使用NI CompactRIO扫描模式 使用LabVIEW I / O变量和NI扫描引擎的推荐实践 引擎盖下的RIO扫描界面 继续将就看。 |
|
|
|
你正在撰写答案
如果你是对答案或其他答案精选点评或询问,请使用“评论”功能。
用udl里的字符串信息在局域网内其他电脑连接sql数据库为什么为出现连接失败拒绝访问?
1632 浏览 2 评论
为什么同一个队列引用的全局变量,运行在两个子vi中发现队列数据丢失了
1241 浏览 0 评论
1452 浏览 0 评论
关于labview2024版本的lvanlys.dll出错的问题
2648 浏览 2 评论
1387 浏览 2 评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-20 12:29 , Processed in 1.103997 second(s), Total 118, Slave 86 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号