[英]How would I get and show graph high frequency data point from PLC S7 with c#?
[英]I am reading floating point values from a PLC's 32 bit memory area as (they would be) Integer values. How can I convert this Integer to Single in C#?
它與 Eldar 的回答一樣有效。 如果您將 32 位浮點值讀取為位,則只需將其轉換為:再次感謝 Eldar :-)
var finalSingle=BitConverter.ToSingle(BitConverter.GetBytes(s7Int))
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.