完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
芯片的端口和引脚PA0..7,PB0..7,..之间的关系
以上来自于谷歌翻译 以下为原文 relationship between the ports and pins PA0..7, PB0..7,.. of chip |
|
相关推荐
3个回答
|
|
你好
我用的是ST7FMC2。 我们必须选择一个包装。 (44,64,80针) 1.引脚名称PA0,..与数据寄存器端口A之间是否存在关系? 2.我看到64和80引脚之间的差异是引脚PH0-7,PG0-7。 44到64之间有什么增加? (我看到44针中有PA3,PA5,但没有PA0,1,2,4,6,7。可以吗?) 3.如何在特定引脚的不同功能之间进行选择? 例如,在64引脚中,引脚PA5也是ARTIC1和AIN1,所以如果我不使用PWM-ART和ADC那么PA5是免费的吗? 4.如果上面的答案是肯定的,那么因为每个Px0..Px7与备用功能相结合,而对于电机控制我们使用PWM,MTC,ADC,然后没有GPIO保持空闲。不是吗? 5.所以正确的工作方式是坐在平底锅和纸上,标记我使用的所有引脚,看看剩下的是什么,然后才设置PDDR,POR寄存器? 如果引脚用于PWM而不用于PA5,我是否还必须设置输入/输出方向? 你能帮我吗 ? 非常感谢 奥伦 以上来自于谷歌翻译 以下为原文 Hello I use ST7FMC2. We have to choose a packadge. (44, 64,80 pins) 1. Is there a relationship between the pin name PA0,.. to data register Port A ? 2. I saw that the different between 64 and 80 pins is pins PH0-7, PG0-7. What is the additions between 44 to 64 ? (I saw that there is PA3,PA5 in the 44 pins, but there isn't PA0,1,2,4,6,7. Can it be ?) 3. How do I choose between different functions of a specific pin ? for example in 64 pins, pin PA5 is also ARTIC1 and AIN1, so if I don't use the PWM-ART and the ADC then PA5 is free ? 4. if the answer above is yes, then because each Px0..Px7 is combined with alternate function, and for motor control we use PWM, MTC, ADC, then no GPIO left free. Isn't it ? 5. So the correct way to work is to sit with pan and paper, mark all the pin that I use, see what left, and only then set the PDDR, POR registers ? Do I have to set also the in/out direction also if the pin use for PWM and not for PA5 for example ? Can you help ? Thanks a lot Oren |
|
|
|
Ciao Omatza,
请花点时间阅读问题的答案: 1.引脚名称PA0,..与数据寄存器端口A之间是否存在关系? 答: 端口A数据寄存器称为“PADR”,PADR [7:0]分别与引脚PA7,... PA0相关。 2.我看到64和80引脚之间的差异是引脚PH0-7,PG0-7。 44到64之间有什么增加? (我看到44针中有PA3,PA5,但没有PA0,1,2,4,6,7。可以吗?) 回答: 是的,它可以。数据表中的内容是您可以在ST7FMC设备产品上检索的正确信息。 3.如何在特定引脚的不同功能之间进行选择? 例如,在64引脚中,引脚PA5也是ARTIC1和AIN1,所以如果我不使用PWM-ART和ADC那么PA5是免费的吗? 回答: 只要相关外设使能(ART,ADC,......),就会验证引脚的备用功能 在您的示例中,PA5是免费的,因为数字I / O都禁用了外设。 4.如果上面的答案是肯定的,那么因为每个Px0..Px7与备用功能相结合,而对于电机控制,我们使用PWM,MTC,ADC,然后没有GPIO保持空闲。不是吗? 回答: 电机控制操作不需要附加PWM(定时器A和定时器B)。在这种情况下,您可以使用PORT D引脚,即ADC未使用的引脚。 5.所以正确的工作方式是坐在平底锅和纸上,标记我使用的所有引脚,看看剩下的是什么,然后才设置PDDR,POR寄存器? 回答: 对,就是这样。 最好的祝福, Tanio 以上来自于谷歌翻译 以下为原文 Ciao Omatza, please, take your time for reading the answers to your questions: 1. Is there a relationship between the pin name PA0,.. to data register Port A ? Ans: The Port A data register is called 'PADR' and PADR[7:0] is related on pins PA7,..PA0 respectively. 2. I saw that the different between 64 and 80 pins is pins PH0-7, PG0-7. What is the additions between 44 to 64 ? (I saw that there is PA3,PA5 in the 44 pins, but there isn't PA0,1,2,4,6,7. Can it be ?) Ans.: Yes, it can. What is written in the datasheet is the correct info you can retrieve on ST7FMC device product. 3. How do I choose between different functions of a specific pin ? for example in 64 pins, pin PA5 is also ARTIC1 and AIN1, so if I don't use the PWM-ART and the ADC then PA5 is free ? Ans.: The alternate function for a pin is validated as soon as the relative peripheral is enabled (ART, ADC,...) In your example, PA5 is free as digital I/O is both peripherals are disabled. 4.if the answer above is yes, then because each Px0..Px7 is combined with alternate function, and for motor control we use PWM, MTC, ADC, then no GPIO left free. Isn't it ? Ans.: Additional PWM (Timer A and Timer B) is not necessary for Motor Control operations. In that case you can use PORT D pins, the ones not used by ADC. 5. So the correct way to work is to sit with pan and paper, mark all the pin that I use, see what left, and only then set the PDDR, POR registers ? Ans.: Yes, exactly. Best regards, Tanio |
|
|
|
你好Tanio
谢谢你的优秀(!)答案。 你的 奥伦 以上来自于谷歌翻译 以下为原文 Hello Tanio Thanks for your excellent (!) answer. Yours Oren |
|
|
|
只有小组成员才能发言,加入小组>>
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
2742 浏览 1 评论
3244 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
1813 浏览 1 评论
3655 浏览 6 评论
6044 浏览 21 评论
1342浏览 4评论
203浏览 3评论
对H747I-DISCO写程序时将CN2的st-link复用为usart1,再次烧录时无法检测到stlink怎么解决?
356浏览 2评论
STM32G474RE芯片只是串口发个数据就发烫严重是怎么回事?
446浏览 2评论
STM32处理增量式编码器Z信号如何判断中断是正转的还是反向转的?
275浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-28 00:11 , Processed in 1.226434 second(s), Total 80, Slave 64 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号