21ic电子技术开发论坛

标题: AVR128DB48测评之环境搭建及例程测试 [打印本页]

作者: 飞天鸣人    时间: 2022-2-22 19:45
标题: AVR128DB48测评之环境搭建及例程测试
本帖最后由 飞天鸣人 于 2022-2-25 19:43 编辑

#申请原创#  @21小跑堂

很幸运中了一块 AVR128DB48 CURIOSITYNANO EVALUATION KIT 开发板,借此机会来学习一下microchip 8位单片机开发,并实现一个电机控制项目,接下来先来学习开发环境的搭建和例程测试
官网https://www.microchip.com/en-us/development-tool/EV35L43A
[attach]1839952[/attach]
在页面下方文档区可以找到资料:
[attach]1839954[/attach]

根据文档我选择用MPLAB®X IDE加 MPLAB®XC C Compiler这个软件平台学习,
首先是MPLAB®X IDE的下载:https://www.microchip.com/en-us/tools-resources/develop/mplab-x-ide
然后是MPLAB®XC C Compiler的下载:https://www.microchip.com/en-us/tools-resources/develop/mplab-xc-compilers
MPLAB®XC C Compiler需要licence,暂时不急先安装软件。
MPLAB®X ID的安装:
[attach]1839950[/attach]

习惯装英文版
[attach]1839958[/attach]

更改安装目录:
[attach]1839960[/attach]

选择需要安装的组件:
[attach]1839962[/attach]
[attach]1839964[/attach]

MPLAB®XC C Compiler的安装:
[attach]1839966[/attach]
[attach]1839968[/attach]

更改安装目录:
[attach]1839970[/attach]
[attach]1839972[/attach]

点击Next安装完成后获取60天的licence:
[attach]1839974[/attach]
[attach]1839976[/attach]
[attach]1839978[/attach]

运行一下.bat文件,可以看到licence安装到C盘的路径下了:
[attach]1839980[/attach]

打开MPLAB X IDE 在工具菜单下可以看到license的状态:
[attach]1839982[/attach]
[attach]1839984[/attach]

这样MPLAB XC8就安装完成了:
[attach]1839986[/attach]

然后找到github上编译好的例程:https://github.com/microchip-pic-avr-examples/avr128db48-cnano-opamp-demo-fw-mplab
[attach]1839988[/attach]
[attach]1839990[/attach]

然后在MPLAB X IDE中打开工程:
[attach]1839992[/attach]

选择pro 模式
[attach]1839994[/attach]

然后编译成功后
[attach]1839996[/attach]

连接开发板和电脑软件会自动连接到板子,并在Kit Window页显示相关内容
[attach]1839998[/attach]

然后program单片机:
[attach]1840000[/attach]

编程完成后我们来看看这个demo实现的是什么功能,在github页面上有详细介绍,实现的是通过pc4-pc6这几个管脚状态组合来调用单片机的三个OPAMP组合成不同模式的运放电路。并且通过按键可以从led的状态反应当前的模式,后面小视频展示一下:
[attach]1840002[/attach]

配置为仪表放大器:按下按键后led会闪6次,配置如下图:
[attach]1840004[/attach]

演示如下图:
[attach]1840006[/attach]






      
作者: pzsh    时间: 2022-2-25 19:09
谢谢, 非常详细
作者: lcczg    时间: 2022-2-28 14:55
这里有AVR DB马达控制的示例https://github.com/microchip-pic ... ntrol-pim-mplab-mcc
作者: 飞天鸣人    时间: 2022-2-28 16:21
lcczg 发表于 2022-2-28 14:55
这里有AVR DB马达控制的示例https://github.com/microchip-pic-avr-examples/avrdx-motor-control-pim-mpla ...

谢谢!
作者: i1mcu    时间: 2022-3-4 14:04
AVR128支持arduino吗
作者: chenci2013    时间: 2022-3-4 14:12
可以图形化开发吗?
作者: yangxiaor520    时间: 2022-3-4 18:47
这篇**详细
作者: wangdezhi    时间: 2022-3-5 22:38
AVR128价格多少钱了。   
作者: xiaoyaodz    时间: 2022-3-5 23:10
描述的非常详细的测评了。   
作者: soodesyt    时间: 2022-3-6 13:09
这个是官网的开发板吗   
作者: mollylawrence    时间: 2022-3-6 15:11
这个支持arduino的开发吗   
作者: dspmana    时间: 2022-3-6 17:08
AVR128DB48是不是也涨钱了
作者: chenci2013    时间: 2022-3-6 17:45
例程是在哪下载的呢  
作者: 飞天鸣人    时间: 2022-3-7 17:28
i1mcu 发表于 2022-3-4 14:04
AVR128支持arduino吗

好像不支持,我只看到两个平台支持一个是 MPLAB®X IDE,一个是Atmel Studio 7
作者: 飞天鸣人    时间: 2022-3-7 17:31
wangdezhi 发表于 2022-3-5 22:38
AVR128价格多少钱了。

这个你直接上官网找销售问吧,我也不知道,应该不贵吧

作者: 飞天鸣人    时间: 2022-3-7 17:33
chenci2013 发表于 2022-3-6 17:45
例程是在哪下载的呢

github上有的 https://github.com/microchip-pic-avr-examples/avr128db48-cnano-opamp-demo-fw-mplab

作者: burgessmaggie    时间: 2022-4-1 12:36
pic的单片机是性能比较好的吧  
作者: wwppd    时间: 2022-4-1 16:45
8位单片机效果怎么样
作者: updownq    时间: 2022-4-11 15:49
支持arduino吗
作者: jimmhu    时间: 2022-4-11 17:45
AVR128DB48性能怎么样
作者: pl202    时间: 2022-4-11 19:43
licence在哪里下载?
作者: typeof    时间: 2022-4-11 20:26
MPLAB需要**吗
作者: hellosdc    时间: 2022-4-11 21:20
现在还可以申请开发板的吗
作者: ulystronglll    时间: 2022-5-26 17:47
AVR128DB48性能怎么样  
作者: 51xlf    时间: 2022-5-26 20:10
Atmega128?  
作者: lzmm    时间: 2022-5-26 21:21
谢谢楼主分享的AVR128教程。   
作者: fentianyou    时间: 2022-5-26 22:40
AVR128教程   
作者: pzsh    时间: 2022-5-31 15:17
mollylawrence 发表于 2022-3-6 15:11
这个支持arduino的开发吗

支持的,新的AVR全部支持




欢迎光临 21ic电子技术开发论坛 (https://bbs.21ic.com/) Powered by Discuz! X3.5