极客工坊

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9715|回复: 2

有一个例子是UED下实现的,我现在想拿到UNO上使用,大家看看可行否?

[复制链接]
发表于 2014-3-26 12:02:33 | 显示全部楼层 |阅读模式
这是例子的页面:

http://blog.sina.com.cn/s/blog_6f72ff900101k8dc.html

我把这个电路和代码拿到UNO上来编译的时候,程序报错:

error: 'analogWriteResolution' was not declared in this scope


出错代码行的内容:
analogWriteResolution(12);  // set the analog output resolution to 12 bit (4096 levels)
analogReadResolution(12);   // set the analog input resolution to 12 bit


请问,这个出错的函数在UNO下有没有相对应的?


回复

使用道具 举报

发表于 2014-3-26 12:42:22 | 显示全部楼层
本帖最后由 shihaipeng04 于 2014-3-26 12:44 编辑

due的采样分辨率更高,用uno的话analogRead一样的,只是分辨率变低了而已。当然度数也要相应的处理一下。。从 1024 *4 要不后面程序就乱了
回复 支持 反对

使用道具 举报

 楼主| 发表于 2014-3-26 13:19:46 | 显示全部楼层
shihaipeng04 发表于 2014-3-26 12:42
due的采样分辨率更高,用uno的话analogRead一样的,只是分辨率变低了而已。当然度数也要相应的处理一下。。 ...

实际上,我正要做一个低采样的波形   多谢~~
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|联系我们|极客工坊

GMT+8, 2026-6-9 21:13 , Processed in 0.033299 second(s), 18 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表