完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
我是一个初学者的汇编语言。这个问题如下所示,要求使用PIC16877 A,并使用MPLAB进行上传。所以,我可能需要你们所有人的帮助。(当第一个开关(RB0)预设时,LED 1点亮1s。(001)。(RB5灯亮)LED 1和LED 2将在2S(011)亮起来。(RB5,RB6亮)LED 1,LED 2和LED 3将点亮3s。(111)(RB5,RB6和RB7亮)之后,第二开关(RB1)被预设。LED 3将点亮1s(100)。(RB7点亮)LED 3和LED 2将在2S(110)点亮。(RB7,RB6亮)LED 3,LED 2和LED 1将点亮在3S(111)。(RB7、RB6和RB5亮起)
以上来自于百度翻译 以下为原文 I am a begineer for the assembly language. Well, the question was as shown below which is requested to use PIC16877A and upload using MpLAB. So, i may need help from all of you. :( when first switch (RB0) is pressed. LED 1 will light up at 1s.(001). (RB5 light up) LED 1 and LED 2 will light up at 2s(011).(RB5,RB6 light up) LED 1, LED 2 and LED 3 will light up at 3s.(111).(RB5,RB6 and RB7 light up) After, second switch(RB1) is pressed. LED 3 will light up at 1s(100). (RB7 light up) LED 3 and LED 2 will light up at 2s(110). (RB7, RB6 light up) LED 3, LED 2 and LED 1 will light up at 3s (111). (RB7,RB6, and RB5 light up) |
|
相关推荐
3个回答
|
|
你没有说问题是什么,只是程序做了什么。
以上来自于百度翻译 以下为原文 You have not said what the problem was, only what the program does. |
|
|
|
我建议你从一些简单的教程开始阅读按钮,创建一个时间延迟,并点燃一个LED。阅读以下内容:HTTP://www. McCHIP.COM/FUMMS/M64 2525.ASPXBASE教程是免费的,其他大约是15美元:HTTP://www-GooLuMun.com A/PIC-教程,这看起来像是家庭作业,它的目的是让你思考一个问题,至少提出一个解决方案,然后在HAV之后寻求帮助。我们投入了这一努力。
以上来自于百度翻译 以下为原文 I suggest you start with some simple tutorials on reading a pushbutton, creating a time delay, and lighting an LED. Read the following: http://www.microchip.com/forums/m642525.aspx Baseline tutorials are free, others are about $15: http://www.gooligum.com.au/PIC-tutorials This seems like homework, and its purpose is to make you think about a problem and at least propose a solution, and then ask for help once you have put in this effort. |
|
|
|
在这里,和大多数其他技术论坛一样,我们希望你在展示一个学术练习时帮助你展示你的作品——是的,即使伪装得很重也很容易发现。项目规范是不完整的——这在现实生活中是常见的。但是为了你自己的理智,你应该总是这样。试着在开始编码之前先把说明书整理好。你必须考虑的事情是:它暗示当任一个按钮被按下时,所有的LED最初都会关闭。在按下任何按钮之前,LED应该做什么?如果你按下按钮前三秒的按钮,会发生什么?幸运的是,这两个按钮不能控制独立的LED组,所以你不必担心并发性,并且可以通过写一个顺序动作循环来编写一个简单的过程程序。因此,您只需要一个固定的一秒延迟子程序。接下来,我建议规划一个算法来实现规范。根据你以前的编码经验,绘制一个流程图或编写类似于你熟悉的编程语言的代码可能会有帮助。尝试* * *陷入陷入细节,特别是避免提到任何特定的PIC寄存器,因为转换AlgRITIM到代码是一个后面的步骤。理想情况下,您希望每一行的代码或流程图块可以在一个PIC汇编程序中进行编码。如果你在编写算法时每次只写一行或两行汇编程序。
以上来自于百度翻译 以下为原文 Here as in most other technical forums, we expect you to show your work so far when asking for help with an academic exercise - and yes they are easy to spot even if heavily disguised. The project specification is incomplete - which is common in real life - but for your own sanity, you should always attempt to firm up the specification before starting to code. Things you have to consider:
One of the other keys to note is that there is one second between steps in both the LED sequences, so you only need one fixed one second delay subroutine. Next, I'd suggest planning an algorithm to implement the specification. Depending on your previous coding experience, drawing a flow-chart or writing psuedocode resembling a programming language you are familiar with may be helpful. Try *NOT* to get bogged down in the details, especially avoid mentioning any specific PIC registers, as converting the algoritm to code is a later step. Ideally you want each line of psuedocode or flowchart block to be codeable in up to a screenful of PIC assembler. If you are only writing one or two lines of assembler every time you were too detailed when planning the algorithm. |
|
|
|
只有小组成员才能发言,加入小组>>
5146 浏览 9 评论
1993 浏览 8 评论
1921 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3162 浏览 3 评论
请问电源和晶体值之间有什么关系吗?PIC在正常条件下运行4MHz需要多少电压?
2218 浏览 5 评论
714浏览 1评论
601浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
484浏览 1评论
PIC Kit3出现目标设备ID(00000000)与预期的设备ID(02c20000)不匹配。是什么原因
613浏览 0评论
513浏览 0评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-12 00:41 , Processed in 1.230824 second(s), Total 80, Slave 64 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号