赛灵思
直播中

薛静斗

7年用户 194经验值
私信 关注
[问答]

怎么将.MCS转换为.hex或.bin

你好,
我有一个xilinx .msc,它包含位文件数据+ micorblaze C代码。
查看.mcs我可以看到微博代码和位文件数据之间有大约1meg的空白区域。我可以通过查看位于每个数据段之前的.mcs地址向量来判断。
但是,当使用promgen将.msc转换为.bin时,结果是一个文件,其中C代码在位文件数据之后立即启动。
这看起来像是promgen转换中的一个bug,或者是我做不对的东西:promgen -w -p bin -r file1.mcs -o file1.binHappy,听听是否有人有任何想法
阿米尔

以上来自于谷歌翻译


以下为原文

Hi there,

I have a xilinx .msc which contains bitfile data + micorblaze C code.
Looking at the .mcs I can see that there's around 1meg of empty space between the microblaze code and the bitfile data.
I can tell that by looking at the .mcs address vectors which are located before each data segment.

However, when using promgen to convert the .msc to .bin, the result is one file where the C code starts immediately after the bitfile data. This looks like a bug in the promgen conversion, or, something I don't do right:

promgen -w -p bin -r file1.mcs -o file1.bin

Happy to hear if anyone has any idea



Amir

回帖(3)

杨玲

2019-3-18 07:17:41
这听起来像个bug,我很容易看出它是如何发生的。
.bin或.hex文件中没有寻址信息,因此处理MCS文件中的间隙的唯一方法是用一些值填充数据(在位文件的末尾填写大约1M)
使用0或其他值开始代码)。
看起来文件转换器忽略了.mcs寻址中的间隙,只是将两个部分打包在一起。
你做这个文件转换的原因是什么?
即你需要.bin或.hex文件?
-  Gabor

以上来自于谷歌翻译


以下为原文

It sounds like a bug, and I can easily see how it happens.  a .bin or .hex file has no addressing info in it, so the only way to deal with the gap in the MCS file would be to pad the data with some value (fill in the approximately 1M between the end of the bit file and the start of the code using 0 or some other value).  It would seem that the file converter is ignoring the gap in the .mcs addressing and just packing the two sections together.
 
What's the reason you're doing this file conversion?  i.e. what do you need a .bin or .hex file for?
-- Gabor
举报

张颖

2019-3-18 07:26:28
请访问http://www.xilinx.com/support/answers/36210.html
_______________________________________________如果有助于解决您的查询,请将此帖子标记为“接受为解决方案”。
因此,它将有助于其他论坛用户直接参考答案。如果您认为该信息有用且面向答复,请给予此帖子称赞。

以上来自于谷歌翻译


以下为原文

Please check http://www.xilinx.com/support/answers/36210.html
________________________________________________

Please mark this post as an "Accept as solution" in case if it helped to resolve your query. So that it will help to other forum users to directly refer to the answer.

Give kudos to this post in case if you think the information is useful and reply oriented.
举报

李裕伦

2019-3-18 07:39:05
命令是正确的。
您使用的是哪个版本的工具?

以上来自于谷歌翻译


以下为原文

The command is correct.  Which version of tools are you using?
举报

更多回帖

发帖
×
20
完善资料,
赚取积分