计算 byte[] 转 int

modebus 指定位数 获取值 使用

SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。
                        if (bytetores.Length > 6)
                        {
                            int total = 0;
                            for (int i = 0; i < bytetores[3]; ++i)
                            {
                                total += bytetores[i + 3] * (256 ^ (bytetores[3] - i - 1));
                            }

                        }           

  

扫码关注我们
微信号:SRE实战
拒绝背锅 运筹帷幄