完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
大家好,
我无法让示例应用程序在开发板上运行。 建立: 1. SPC56xxMB / XPC56xxMB(根据原理图相同) 2. SPC564AADPT324S / XPC564AADPT324S(根据原理图也相同) 问题: 1. LED不闪烁 2.使用BDM调试器(P& E Micro USB Multilink PPC Nexus)我可以看到SIU.PCR和eMIOS.CCR寄存器配置不正确。事实上,它们似乎具有默认值。我实际上在CodeWarrior下的这个板上运行了我自己的应用程序,所以我知道该板工作正常,SIU.PCR和eMIOS.CCR值应该是正确的。 观察: 我想知道问题是否在芯片配置中。我收到的电路板带有MPC5644A / SPC564A80B4。 (为了让它更加混乱,似乎飞思卡尔刚刚将部件号更改为SPC5644A!) 在platform.h中定义了_SPC564A70L7_,并且在application.ld中,对于564A80B4,MEMORY指令不正确。但是,将它们更改为564A80B4的值并没有帮助。 如果芯片配置是问题,我很乐意尝试纠正它,如果有人可以指出我,至少在一般方向,应该修改的文件。我仍然没有足够的经验与SPC5 Studio的做事方式自己找到一切。 当然它可能是其他所有东西:) 干杯 凯文 以上来自于谷歌翻译 以下为原文 Hi All, I am unable to get the sample application to run on the dev board. Setup: 1. SPC56xxMB/XPC56xxMB (they are identical according to the schematics) 2. SPC564AADPT324S/XPC564AADPT324S (they also are identical according to the schematics) Problem: 1. LEDs do not flash 2. Using the BDM debugger (P&E Micro USB Multilink PPC Nexus) I can see that the SIU.PCR and eMIOS.CCR registers are not configured correctly. In fact they appear to have the default values in them. I actually have my own app running on this board under CodeWarrior so I know that the board works and what the correct SIU.PCR and eMIOS.CCR values should be. Observations: I am wondering if the problem is in the chip configuration. The board I received came with a MPC5644A/SPC564A80B4. (To make it even more confusing, it seems that Freescale has just changed the part number on their part to SPC5644A!) In platform.h _SPC564A70L7_ is defined and in application.ld the MEMORY directive is incorrect for the 564A80B4. However, changing them to values for the 564A80B4 did not help. If the chip config is the problem I would be glad to try and correct it if someone can point me, at least in the general direction, of the files that should be modified. I am still just not experienced enough with the SPC5 Studio way of doing things to find everything by myself. Of course it may be something else all together:) Cheers Kevin |
|
相关推荐
10个回答
|
|
嗨,
我可以确认SPC564A70设备有问题。演示使用SPC560A80设备正常工作。该错误已在SPC5-HAL存储库中修复:https://sourceforge.net/projects/spc5-hal/ 如果要修补SPC4Studio 1.1安装,请在C: SPC5Studio eclipse plugins org.chibios.spc5.components.hal.platform.spc564axx _.... component lib src 下找到文件hal_lld.c 然后注释掉FLASH_B和XBAR的初始化如下: // FLASH_B.BIUCR.R = SPC5_FLASH_BIUCR | SPC5_FLASH_WS; // FLASH_B.BIUCR2.R = 0; // XBAR.MPR0.R = 0x34000021; // XBAR.MPR2.R = 0x34000021; 该问题将在SPC5Studio的下一个更新包(6月底)中修复。 乔瓦尼 以上来自于谷歌翻译 以下为原文 Hi, I can confirm that there is a problem with SPC564A70 devices. The demos work correctly using SPC560A80 devices. The bug has already been fixed on the SPC5-HAL repository: https://sourceforge.net/projects/spc5-hal/ If you want to patch your SPC4Studio 1.1 installation find the file hal_lld.c under C:SPC5Studioeclipsepluginsorg.chibios.spc5.components.hal.platform.spc564axx_....componentlibsrc then comment out the initialization of FLASH_B and XBAR as follow: // FLASH_B.BIUCR.R = SPC5_FLASH_BIUCR | SPC5_FLASH_WS; // FLASH_B.BIUCR2.R = 0; // XBAR.MPR0.R = 0x34000021; // XBAR.MPR2.R = 0x34000021; The problem will be fixed in the next update pack for SPC5Studio (end of June). Giovanni |
|
|
|
嗨Giovanni,
我评论了你推荐的那些行。 LED仍然不闪烁或发光。 我在代码中找不到SIU.PCR和eMIOS.CCR寄存器设置为点亮LED所需的值的任何地方。到目前为止,我唯一能找到的是pal_lld.c,其中在init期间,所有SIU.PCR寄存器都设置为默认值。我无法找到配置或设置eMIOS线路的任何地方。 根据56xxMB原理图,主板上的4个LED是eMIOS 9,10,11,12。这相当于SIU.PCR [188-191] .R。这些寄存器的正确值应为0x0600。 EMIOS.CH [9] .CCR.R = 0x00000001和EMIOS.CH [10] .CCR.R = 0x00000081打开LED并分别关闭LED。 你能告诉我哪些文件进行初始化并设置SIU和eMIOS模块的值? 以上来自于谷歌翻译 以下为原文 Hi Giovanni, I commented out the lines that you recommended. The LEDs still do not flash or light. I cannot find anywhere in the code where the SIU.PCR and eMIOS.CCR registers are set to the values necessary to light the LEDs. The only thing that I have been able to find so far is in pal_lld.c where during init all of the SIU.PCR registers are set to a default value. I have been unable to find anywhere that the eMIOS lines are configured or set. According to the 56xxMB schematics, the 4 LEDs on the motherboard are eMIOS 9,10, 11,12. This corresponds to SIU.PCR[188-191].R. The correct value of these registers should be 0x0600. EMIOS.CH[9].CCR.R = 0x00000001 and EMIOS.CH[10].CCR.R = 0x00000081 turns on the LEDs and turns off the LEDs respectively. Can you tell me which files do the initialization and set the values for the SIU and eMIOS modules? |
|
|
|
嗨凯文,
我只是在完成这些更改之后在SPC5Studio 1.1中重新测试了该应用程序并且它可以工作。您的电路板是否可能未配置为点亮LED?看看跳线组J7,那些都应该插入。 关于演示,LED闪烁不是使用EMIOS完成的,而是使用引脚的GPIO模式。引脚在Board Component中配置,默认值生成(来自Eclipse项目资源管理器)组件/ spc5_hal_spc564axx_hal_board_initialization_component / cfg / board.c 执行PCR初始化的代码是您已经找到的pal_lld.c中的函数,该函数读取board.c中生成的设置。 关于EMIOS,它将由版本1.2中的PWM和ICU驱动程序处理。 再见, 乔瓦尼 以上来自于谷歌翻译 以下为原文 Hi Kevin, I just re-tested the application in SPC5Studio 1.1 after doing those changes and it works. Is it possible that your board is not configured to light the LEDs? look at the jumpers group J7, those should all be inserted. About the demo, the LED flashing is not done using EMIOS but the GPIO mode of the pins. The pins are configured in the Board Component, the default values are generated into (from the Eclipse project explorer) components/spc5_hal_spc564axx_hal_board_initialization_component/cfg/board.c The code performing the PCR initialization is that function in pal_lld.c that you already found, that function reads the settings generated in board.c. About the EMIOS, it will be handled by the PWM and ICU drivers that will be present in version 1.2. ciao, Giovanni |
|
|
|
嗨Giovanni
首先,我要感谢你给予的所有帮助,我希望我的问题足够通用,可以帮助他人。 仍然无法使无操作系统的测试应用程序工作。在我编写的裸板应用程序中,LED正常亮起,所有电路板跳线配置都是出厂默认设置。 测试应用程序在启动序列中很早就失败了。使用内置的CodeWarrior调试器,我必须承认我完全不熟悉,我可以看到程序计数器(PC)停在0x42。这只是程序中的8或9条指令。当PC到达该点时,LC寄存器显示0x0badbad0。进一步强制PC,使用CW可以执行的操作会导致CTR和XER报告运行时错误。 似乎编译器没有为我的设置生成正确的代码。 几个问题; 1.测试应用程序是否使用VLE或BookE进行编译? 2.回想一下,我有MPC5644A / SPC564A80B4,而不是SPC564A70。这会导致问题吗? 3.由于我实际拥有MPC5644A,因此读取SIU.MIDR会将芯片报告为“MPC5644A掩模10”。这会导致问题吗? 再次感谢您的帮助,我真的很想开始运行,因为我非常渴望尝试使用ChibiOS。 以上来自于谷歌翻译 以下为原文 Hi Giovanni First, let me thank you for all the help you have given, I hope that my questions are generic enough to be of help to others. Still cannot get the OS-less test app to work. The LEDs light up properly in the bareboard application that I wrote and all of the board jumper configs are the factory defaults. The test app is failing very early in the boot sequence. Using the built-in CodeWarrior debugger, which I must confess I am completely unfamiliar with, I can see that the Program Counter (PC) stops at 0x42. This is only 8 or 9 instructions into the program. When the PC reaches that point, the LC register shows 0x0badbad0. Forcing the PC further, something that you can do with CW, causes CTR and XER to report runtime errors. It seems that the compiler is not producing the correct code for my setup. A few questions; 1. Is the test app compiling with VLE or BookE? 2. Recall that I have the MPC5644A/SPC564A80B4, not the SPC564A70. Could this be causing a problem? 3. Since I actually have the MPC5644A, reading SIU.MIDR will report back the chip as 'MPC5644A mask 10'. Could this be causing a problem? Thanks again for all your help, I really would like to get this up and running as I am quite anxious to try ChibiOS. |
|
|
|
嗨,
默认情况下,使用VLE编译应用程序。 如果您拥有A80,甚至不需要上述所有变通方法,那么应用程序应该按原样运行,还有其他东西阻止它工作。 你可以进入应用程序的配置并将设备更改为A80,然后“重新生成”并重新编译,以防问题与不同的内存大小有关。 在代码中没有任何地方检查器件的“ST-ness”,它也应该在FSL芯片上工作。 迷你模块是否具有外部存储器?我从未测试过那个,问题可能与此有关。 乔瓦尼 以上来自于谷歌翻译 以下为原文 Hi, The application is compiled using VLE by default. If you have the A80 the all the above workarounds are not even needed, the application should work as-is, there is something else preventing it to work. You could go under the configuration of the application and change the device to A80, then ''re-generate'' and recompile, just in case the problem is related to the different memory sizes. Nowhere in the code the ''ST-ness'' of the device is checked, it should work also on the FSL silicon. Is the mini-module you have the one with the external memory? I never tested that one, the problem could be related to that. Giovanni |
|
|
|
嗨Giovanni,
仍然无法让它工作,但我一直在仔细研究二进制文件。 我确实重新配置了应用程序以使用80B4部件。没有任何区别。 我确实有324针部分。它的迷你模块有2个外部存储器垫。闪存芯片的焊盘是空的。外部sram的焊盘填充1 MByte芯片。外部ram位于@ 0x20000000。这在理论上允许512 MB的外部存储器进入内部sram之前。原理图显示了地址线ADDR12-31和CS0,WE0和WE1也被使用。不知道这可能是一个问题。 用我的BDM查看内存,对于二进制文件在内存中的布局方式,似乎没有问题。在我进入这个过于无聊的细节之前,我想更多地探讨这个问题。你能把你的out.bin发布到这个论坛吗?我想把它与我的比较。 4.不知道是否对任何人感兴趣,但我修改了Makefile和rules.mk以输出除常规输出之外的Motorola srec(.mot)。这对我们摩托罗拉/飞思卡尔的人来说非常有用。如果你愿意,我可以在这里发布修改过的文件,或者你希望得到它们。 以上来自于谷歌翻译 以下为原文 Hi Giovanni, Still can't get it working but I have been taking a closer look at the binary. 1. I did reconfigure the application to use the 80B4 part. Did not make any difference. 2. I do have the 324 pin part. It's mini-module does have 2 pads for external memory. The pad for the flash chip is empty. The pad for the external sram is populated with a 1 MByte chip. The external ram is located @ 0x20000000. This in theory allows for 512 MBytes of external memory before it runs into the internal sram. The schematic shows address lines ADDR12-31 and CS0, WE0, and WE1 also being used. Don't know if this could be a problem or not. 3. Looking at memory with my BDM, something doesn't seem right with how the binary is layed out in memory. I would like to explore this more before I go into too much boring detail here. Could you post your out.bin to this forum? I would like to compare it to mine. 4. Don't know if is of interest to anyone but I modified the Makefile and rules.mk to output a Motorola srec (.mot) in addition to the regular outputs. This can be very useful for us Motorola/Freescale folks. If you like I could post the modified files here or however you would wish to get them. |
|
|
|
嗨,乔瓦尼,
如果您可以发布out.elf和out.bin的副本,那将非常有帮助。 提前致谢。 凯文 以上来自于谷歌翻译 以下为原文 Hi, Giovanni, If you could post a copy of your out.elf and out.bin it would be very helpful. Thanks in advance. Kevin |
|
|
|
嗨凯文,
我用BGA封装在SPC564A80上成功测试了应用程序。问题是默认演示是针对安装8MHz晶振的LQFP封装迷你模块配置的,BGA迷你模块具有40MHz晶振,因此初始化时演示失败。 您需要将电路板组件中的频率重新配置为40MHz,然后将驱动器组件中的FMPLL预分频器重新配置为10。 附上的No-OS应用程序已经重新配置和编译(内部的精灵和地图文件)。 请注意,我使用ST mini模块,因为BGA设备在ST和FSL之间有不同的球放置,请验证您的迷你模块频率。 再见, 乔瓦尼 以上来自于谷歌翻译 以下为原文 Hi Kevin, I successfully tested the application on the SPC564A80 with BGA package. The problem is that the default demo is configured for the LQFP package mini module which mounts an 8MHz crystal, the BGA mini module has a 40MHz crystal so the demo fails on initialization. You need to reconfigure the frequency in the board component to 40MHz and then the FMPLL pre-divider to 10 in the drivers component. Attached there is the No-OS application already reconfigured and compiled (elf and map files inside). Note that I used the ST mini module because BGA devices have different balls placement between ST and FSL, please verify your mini module frequencies. ciao, Giovanni |
|
|
|
嗨Giovanni,
成功! 无操作系统的演示效果很好。 一旦我在我的机器上重新编译项目并运行它,我立即构建了ChibiOS演示。它也很完美。 感谢您所有的帮助。我期待在我的下一个项目中使用ChibiOS。 凯文 以上来自于谷歌翻译 以下为原文 Hi Giovanni, Success! The OS-less demo works great. Once I had recompiled the project on my machine and had it running I immediately built the ChibiOS demo. It also works perfectly. Thanks for all of your help. I look forward to using ChibiOS in my next project. Kevin |
|
|
|
|
|
|
|
只有小组成员才能发言,加入小组>>
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
2648 浏览 1 评论
3213 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
1787 浏览 1 评论
3616 浏览 6 评论
5996 浏览 21 评论
944浏览 4评论
1318浏览 4评论
在Linux上安装Atollic TRUEStudio的步骤有哪些呢?
588浏览 3评论
使用DMA激活某些外设会以导致外设无法工作的方式生成代码是怎么回事
1307浏览 3评论
1367浏览 3评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-27 04:57 , Processed in 1.253854 second(s), Total 65, Slave 58 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号