From 11:00 PM CDT Friday, Nov 8 - 2:30 PM CDT Saturday, Nov 9, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From 11:00 PM CDT Friday, Nov 8 - 2:30 PM CDT Saturday, Nov 9, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
|
我创建了一个CVI DLL来动态地给一维双精度浮点数数组分配LabVIEW内存。当我在LabVIEW中调用该DLL时,LabVIEW崩溃了。它对单精度数据工作正常,但对双精度数据却出现问题。
LabWindows/CVI默认以4字节为单位对齐,但为了让LabVIEW数据结构保持它们的结构,你必须强制CVI向最近的字节对齐而非最近的4字节处。方法如下:
在定义任何LabVIEW数据结构前放置
并在这些定义之后放置
详情请参见文件cvilvsb.h,它位于<LabVIEW>\cintools目录下。想了解更多关于结构填充的信息,请参考CVI在线帮助,链接见下文。
|