Electronic Engineer Discuss

View: 12428|Reply: 5
Print Prev. thread Next thread

HT6022BE虚拟示波器第二次开发问题

[Copy link]

105

Threads

356

Posts

528

Credits

超级版主

Rank: 8Rank: 8

Credits
528
1#
Post time 2020-11-23 14:33:13 | Show all posts



1. 开发示例没有C#
2. 转换公式:电压 = data * 8 * 通道电压档位 / 255
3. 频率(也包括其他属性)是对获取的波形数据进行计算得出。

105

Threads

356

Posts

528

Credits

超级版主

Rank: 8Rank: 8

Credits
528
2#
Post time 2020-11-26 11:49:45 | Show all posts
luyongmaokf replied at 2020-11-24 10:34
换算电压有点不对,请指点一下

        //转换公式:电压 = data * 8 * 通道电压档位 / 255

int temp = (int)pCH1Data * 8 * m_nCH1VoltDIV / 255;

m_nCH1VoltDIV是电压档位索引值,不是电压档位电压值,要换成电压值(例如1.0V/DIV,取1.0这个值),公式直接使用float或double计算,不要int转换。
You have to log in before you can reply Login | Register

Points Rules

Dark room|Mobile|Archiver|Electronic Engineer Discuss

2024-5-4 00:46 GMT+8 , Processed in 0.180859 second(s), 19 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

Quick Reply To Top Return to the list