完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
我有一个应用处理器,它通过内存控制器连接到CyPress FX3芯片。我的工作是通过孔进入s-port,配置并执行R / W型连接到sib0 SD卡。我已经成功地初始化了卡片。所以我知道SD命令接口正在工作。现在我要从/到SD卡进行块R / W,我被困在这里,因为s-port不支持任何FIFO接口(如果我错了请指正)。我看了看参考代码和代码中,我看到s-port与DMA接口。请注意,在我的情况下,做DMA将复杂且效率很低因为数据缓冲区(读或写)存储在应用程序处理器不能直接传递到FX3S。因此,如果我有什么写的SD卡的DMA,我首先将要复制的布从应用处理器提供的FX3S内存后再发起写DMA。请注意这是非常低效的。另一件事,我能做的是传输的数据字节的字节通过cmd52接口。除了是缓慢的和不可取的,它不允许转让超过16字节时,需要为每一个字节传送一个新的命令。应用处理器和FX3S没有共享内存,因此上述机制是唯一可能的。回到最初的问题:我如果s-port具有FIFO读/写登记摆脱这一切。这样,我可以触发CMD53和登记,根据某些条件进行连续的R / W。这将使我的实现更加简单和快捷。参考手册中,我没有看到任何该等登记但参考手册似乎是不完整的所以我认为最好的如果我问这个问题的论坛。希望我很快就能回答这个问题。
以上来自于百度翻译 以下为原文 I have an application processor which is interfaced to the Cypress FX3 chip via memory controller. My job is to access the S-Port via the P-Port, configure it and perform R/W to an SD card connected to the SIB0. I have been able to initialize the card successfully. So I know that the SD command interface is working. Now I have to perform block R/W from/to the SD card, and I'm stuck here because the S-Port does not support any FIFO interface(please correct me if I'm wrong). I've looked at the reference code and in that code, I see that the S-Port is interfaced with the DMA. Please note that in my case, doing DMA will be complicated and very inefficient because the data buffer(read or write) is stored in the application processor and cannot be passed directly to the FX3s. Therefore, if I have something to write to the SD card via DMA, I will firstly have to copy the buffer from the application processor to the FX3s internal memory and then initiate a write via DMA. Please note that this is very inefficient. Another thing that I can do is transfer data byte by byte via the CMD52 interface. Apart from being slow and undesirable, it does not allow to transfer more than 16 bytes at a time and requires a new command for every byte transfer. The Application processor and the FX3s don't have any shared memory and therefore the above mentioned mechanisms are the only possible. Back to the original question: I can get rid of all this if the S-Port has a FIFO R/W register. With that, I can trigger a CMD53 and continuously perform R/W on that register based on some condition. That would make my implementation simpler and faster. In the reference manual, I do not see any such register but the reference manual seems to be not complete anyway so I think its best if I ask this question on the forum. Hopefully I'll have answer to this question very soon. |
|
相关推荐
3个回答
|
|
嗨,比拉尔,
在s-port.are你指的是cyfx_pmmc比如登记模式是不可能的吗? 如果是这样,请注意,不是dma_manual通道使用,你也可以使用自动或auto_signal渠道。这是更快,不必等待DMA回调提交数据从AP到s-port。 当做, - Madhu Sudhan 以上来自于百度翻译 以下为原文 Hi Bilal, Such register mode is not possible in S-port.Are you referring to the cyfx_pmmc example? If so,please note that instead of DMA_MANUAL channel used there, you can also use AUTO or auto_signal channels. These are more faster and don't have to wait for DMA callbacks to commit the data from AP to S-port. Regards, - Madhu Sudhan |
|
|
|
dfzvzs 发表于 2018-9-24 09:55 嗨,Madhu,我没有使用柏树的例子。相反,我正在创建一个基于RTOS的自己的应用程序。所以我的问题不是从这个背景出发的。而且,我现在不在应用程序层面工作。可以说,我在创造我自己的同胞司机。让我来解释一下这是如何简单地工作的。我们有一个应用处理器,可以通过P-端口访问FX3。我们在Sb0的应用处理器上有一个驱动程序(SIB寄存器访问通过P-端口工作)。这个驱动程序正在工作,因为我看到命令接口工作,也就是说,当我发送命令时,我会收到一个响应。现在的问题是,在应用程序处理器上有大量数据,需要通过SIB0驱动程序传输到SD卡。这对我们造成了一个问题,因为要传输的缓冲器在应用处理器的外部DRAM中(FX3S不能看到这一点)。因此,如果我们要使用DMA进行批量传输,我们必须在FX3S内部存储器空间中复制数据,然后进行读或写。请注意,该机制涉及两步过程,因此将非常缓慢。因此,我正在寻找替代品。如果我找不到一个,我会继续执行上面提到的两个步骤(非常不受欢迎)。最简单的选择是SIB0寄存器集有一个FIFO寄存器。这不仅可以消除两步过程,而且会使我的实现更加简单。如果有,请告诉我。如果不是,我认为这是SIB外围IP设计中的一个缺陷。正如你到处提到的,FX3S用来与外部存储器和P-端口接口,以访问设备的内存映射空间。但是我们不能有效地做到这一点,因为我们必须遵循这两个步骤。你同意这个说法吗?由于FX3S被用作IO扩展桥,例如,我们有一个SD卡连接到SIB0,它通过应用处理器来控制。考虑到系统和界面暴露出来,我认为我们永远也无法从SD卡中提取合理的R/W速度。你对此有什么看法?问候,比拉尔 以上来自于百度翻译 以下为原文 Hi Madhu, I'm not using any of cypress examples. Rather I'm creating my own application based on an RTOS. So my question is not from that context. Also, I'm not working at the application level right now. Instead I'm creating my own SIB driver so to speak. Let me explain to you how this works very briefly. We have an application processor which has access to the FX3 VIA P-Port. We have a driver on the application processor for the SIB0(the SIB register access works via p-port). This driver is working because I see the command interface working, i.e. when I send a command, I receive a response for it. Now the problem is that I have bulk data on the application processor that needs to be transferred via the SIB0 driver to the SD card. This creates a problem for us because the buffer that is to be transferred is in the external DRAM of the application processor(the FX3s cannot see this). Therefore if we are to use DMA for bulk transfers, we have to copy the data in the FX3s internal memory space and then do the read or write. Please note that this mechanism involves two-step procedure and therefore would be very slow. Therefore I'm looking for alternatives. If I'm unable to find one, I will go ahead and implement the above mentioned two-step process(highly undesirable). The easiest alternative would be that the SIB0 register set has a FIFO register. That will not only get rid of the two-step procedure but it would make my implementation much simpler. Please let me know if there is. If not, I think that this is a flaw in the design of the SIB peripheral IP. As you mention everywhere, the FX3s is used to be interfaced with the external memory and p-port to access the memory-mapped space of the device. But we are unable to do this effectively because we have to follow this two-step procedure. Would you agree with this ? As the FX3s is used as an IO expansion bridge, consider for example that we have an SD-card attached to the SIB0 which is controlled via the application processor. Considering the system and the interface exposed, I don't think that we would ever be able to extract reasonable R/W speeds from the SD card. What do you think about this ? Regards, Bilal |
|
|
|
wqqty 发表于 2018-9-24 10:15 你好,比拉尔, 你可以检查“cyfxgpiftostorage“固件的例子在下面的路径: C: Program Files(x86) Cypress公司EZ-USB FX3固件 gpif_examples 1.3 SDK 这个例子使用邮箱注册的孔,却能把8字节的数据在一个时间和更低的延迟端口的。 希望这对你有帮助!! 感谢和问候 阿比纳夫 以上来自于百度翻译 以下为原文 Hello Bilal, You can check "cyfxgpiftostorage" firmware example in the following path: C:Program Files (x86)CypressEZ-USB FX3 SDK1.3firmwaregpif_examples This example makes use of mailbox registers of P-port that can actually send the 8 bytes of data at a time to S -Port with less latency. Hope this may help you !! Thanks & Regards Abhinav |
|
|
|
只有小组成员才能发言,加入小组>>
754个成员聚集在这个小组
加入小组2105 浏览 1 评论
1851 浏览 1 评论
3669 浏览 1 评论
请问可以直接使用来自FX2LP固件的端点向主机FIFO写入数据吗?
1786 浏览 6 评论
1536 浏览 1 评论
CY8C4025LQI在程序中调用函数,通过示波器观察SCL引脚波形,无法将pin0.4(SCL)下拉是什么原因导致?
570浏览 2评论
CYUSB3065焊接到USB3.0 TYPE-B口的焊接触点就无法使用是什么原因导致的?
423浏览 2评论
CX3连接Camera修改分辨率之后,播放器无法播出camera的画面怎么解决?
437浏览 2评论
384浏览 2评论
使用stm32+cyw43438 wifi驱动whd,WHD驱动固件加载失败的原因?
915浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-23 19:37 , Processed in 1.206477 second(s), Total 81, Slave 65 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号