2272943826

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826  发布于  2016-06-29 09:11:52
采纳率 0%
24个问答
9482

[已解决]fastboot 烧写 spi

 
本帖最后由 2272943826 于 2017-7-6 12:44 编辑

我昨天 按照大神的烧写 spi flash,烧好啦。   如何检测呢?   


1 uboot-----u-boot-hi3516a.bin
2 kernel-----uImage_hi3516a
3 rootfilesystem------rootfs_hi3516a_64k.jffs2

我是新手,多多指教。 :P

我来回答
回答26个
时间排序
认可量排序

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 10:00:42
认可0
本帖最后由 ngswfx 于 2016-6-29 10:05 编辑

你这个刚吧uboot搞定,还没弄好kernel以及rootfs呢

////////////////////我估计你是没有配置对env,注意理解下面类似代码的意思:


setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashfs  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'
setenv bootcmd 'sf probe 0;sf read 0x81000000 0x30000 0x180000;sf read 0x82FF0000 0x1FF0000 0x10000;decjpg;setvobg 0 0x0;startvo 0 36 14;startgx 0 0x84fe0000 2048 0 0 1024 768;bootm 0x81000000'

////////////就是配置uboot接下来要到哪里去找kernel执行,然后flash的分区情况。

///////////你参考海思的文档,以及自己写kernel以及rootfs的地址,自己修改,改完后,在uboot环境下执行保存,重启就可以了。

///////////我上面是例子,我自己板子上的,你看海斯默认文档(应该在一个.txt文件介绍里面)里面怎么介绍的,在那个基础上修改。

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 10:04:35
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32757&ptid=11776]ngswfx 发表于 2016-6-29 10:00[/url]
你这个刚吧uboot搞定,还没弄好kernel以及rootfs呢[/quote]

我昨天在fastboot 里面
        1 u-boot image
        2 kernel image
        3 image of rootfile systems

烧写进入 开发板成功

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 10:10:20
认可0
本帖最后由 ngswfx 于 2016-6-29 10:12 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32762&ptid=11776]2272943826 发表于 2016-6-29 10:04[/url]
我昨天在fastboot 里面
        1 u-boot image
        2 kernel image
[/quote]

应该是成功了,只不过uboot不知道从哪里开始执行,

sf read 0x81000000 0x30000 0x180000
bootm 0x81000000

第一句意思是,从flash 的0x30000位置读取0x180000大小,到内存的0x8100000位置,
第二句意思是:从内存0x81000000位置开始执行。
//////按照你现在的配置,应该改为:
sf read 0x81000000 0x100000 0x800000
bootm 0x81000000
sa
///////////注意:3516内存地址,可不一定用0x81000000,你看看文档用多少,你改一下就可以了。
这样就能启动kernel了,通常执行后,会死在那里,重启后,ctrl+c,强制在uboot停下来,接着修改rootfs相关的bootargs配置。

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 10:26:55
认可0
本帖最后由 2272943826 于 2016-11-25 10:12 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32757&ptid=11776]ngswfx 发表于 2016-6-29 10:00[/url]
你这个刚吧uboot搞定,还没弄好kernel以及rootfs呢

////////////////////我估计你是没有配置对env,注意 ...[/quote]

我找到 .txt 文件啦
        我明白你的意思, 设置 kernel images 和 rootfs 的空间位置
        但是我不懂怎么设置,:'( :'( :'(

谢谢

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 10:42:07
认可0
本帖最后由 ngswfx 于 2016-6-29 10:43 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32767&ptid=11776]2272943826 发表于 2016-6-29 10:26[/url]
我找到 .txt 文件啦
        我明白你的意思, 设置 kernel images 和 rootfs 的空间位置
        但是我不懂怎么设 ...[/quote]

你发的这个是写的过程,pc上的工具已经做过这些动作了。

你现在就是要根据当时写的情况,把uboot启动的环境变量设置一下,应该在文档下面,

看有没有setenv bootargs以及setenv bootcmd,也可以从网上找些配置的介绍。

最好多试试,我要时把结果告诉你,你就没掌握呀。

多尝试,多折腾,才能知道为什么,错一个字节都不行的哦。

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 10:51:07
认可0
本帖最后由 2272943826 于 2016-11-25 10:12 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32768&ptid=11776]ngswfx 发表于 2016-6-29 10:42[/url]
你发的这个是写的过程,pc上的工具已经做过这些动作了。

你现在就是要根据当时写的情况,把uboot启 ...[/quote]

非常感谢

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 10:55:07
认可0
改这2句:
setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashfs  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'
setenv bootcmd 'sf probe 0;sf read 0x81000000 0x30000 0x180000;sf read 0x82FF0000 0x1FF0000 0x10000;decjpg;setvobg 0 0x0;startvo 0 36 14;startgx 0 0x84fe0000 2048 0 0 1024 768;bootm 0x81000000'

然后执行

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 11:04:18
认可0
本帖最后由 2272943826 于 2016-6-29 11:32 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32773&ptid=11776]ngswfx 发表于 2016-6-29 10:55[/url]
改这2句:
setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstyp ...[/quote]

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashfs  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'
setenv bootcmd 'sf probe 0;sf read 0x81000000 0x100000 0x800000;sf read 0x82FF0000 0x1FF0000 0x10000;decjpg;setvobg 0 0x0;startvo 0 36 14;startgx 0 0x84fe0000 2048 0 0 1024 768;bootm 0x81000000'

sa
这是我的想法,准备在putty 输入 上面的 command,对吗?

我在 putty command 里面 输入
setenv sf read 0x81000000 0x100000 0x800000
setenv bootm 0x81000000
sa

restart the target board and putty.  putty still can‘t find the ls command

Wrong image format for bootm command
ERROR: can't get kernel image!


ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 11:25:45
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32775&ptid=11776]2272943826 发表于 2016-6-29 11:04[/url]
setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashf ...[/quote]

就是在putty上输入命令,然后这些环境信息会保存到flash上,再次启动后,会按照配置执行命令,就不用你每次都输入了。

sa是缩写,uboot环境支持的命令很少,支持缩写实际上是saveenv命令

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 12:01:21
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32782&ptid=11776]ngswfx 发表于 2016-6-29 11:25[/url]
就是在putty上输入命令,然后这些环境信息会保存到flash上,再次启动后,会按照配置执行命令,就不用你每 ...[/quote]

restart the target board, still can't find the kernel image! Wrong Image Format for bootm command

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 12:28:08
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32773&ptid=11776]ngswfx 发表于 2016-6-29 10:55[/url]
改这2句:
setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstyp ...[/quote]

我在 putty 输入下面的 command:

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashfs  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'
setenv bootcmd 'sf probe 0;sf read 0x81000000 0x100000 0x800000;sf read 0x82FF0000 0x1FF0000 0x10000;decjpg;setvobg 0 0x0;startvo 0 36 14;startgx 0 0x84fe0000 2048 0 0 1024 768;bootm 0x81000000'
sa

No filesystem could mount root , tried: squashfs
Kernel panic -not sysncing: VFS: Unable to mount root fs on unknown-block (31,3)

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 13:01:08
认可0
本帖最后由 ngswfx 于 2016-6-29 13:03 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32795&ptid=11776]2272943826 发表于 2016-6-29 12:28[/url]
我在 putty 输入下面的 command:

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 roo ...[/quote]

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squashfs  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)

上面的每一句都有意义的,和你的环境对不上,你先查查各方面的资料,学着修改

kernel已经OK了,下面就是配置分区,让整个流程能识别你写入的rootfs分区8M-16M

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 13:35:18
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32797&ptid=11776]ngswfx 发表于 2016-6-29 13:01[/url]
setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=squas ...[/quote]

my rootfs system memory from 9 to 16 M

:P :$

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 13:42:55
认可0
本帖最后由 ngswfx 于 2016-6-29 13:44 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32800&ptid=11776]2272943826 发表于 2016-6-29 13:35[/url]
my rootfs system memory from 9 to 16 M[/quote]

你有3各 分区,1024K(uboot),7168K(kernel),7168K(rootfs)
rootfs开始的位置,好像没有接着kernel

1024K(uboot),7168K(kernel),1024K(NULL),7168K(rootfs)

这样启动时候的,rootfs就是root=/dev/mtdblock3   (从0开始算)

压缩格式,估计你的是jfffs2  rootfstype=jffs2

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 13:51:04
认可0
本帖最后由 2272943826 于 2016-7-21 15:47 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32801&ptid=11776]ngswfx 发表于 2016-6-29 13:42[/url]
你有3各 分区,1024K(uboot),7168K(kernel),7168K(rootfs)
rootfs开始的位置,好像没有接着kernel

[/quote]

对对的,我的是rootfs是jffs2

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 13:56:30
认可0
[quote][url=forum.php?mod=redirect&goto=findpost&pid=32802&ptid=11776]2272943826 发表于 2016-6-29 13:51[/url]
对对的,我的是 rootfs 是 jffs2

但是我的 putty 一直停在那里, 我按 Ctrl+C 也停不下来,该怎么办 ...[/quote]

重启呀,只要停住都只能重启,然后uboot ,ctrl+c,到Uboot控制台,重新配置

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 14:05:49
认可0
本帖最后由 2272943826 于 2016-6-29 14:09 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32801&ptid=11776]ngswfx 发表于 2016-6-29 13:42[/url]
你有3各 分区,1024K(uboot),7168K(kernel),7168K(rootfs)
rootfs开始的位置,好像没有接着kernel

[/quote]

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=jffs2  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'
setenv bootcmd 'sf probe 0;sf read 0x81000000 0x100000 0x800000;sf read 0x82FF0000 0x1FF0000 0x10000;decjpg;setvobg 0 0x0;startvo 0 36 14;startgx 0 0x84fe0000 2048 0 0 1024 768;bootm 0x81000000'
sa


jffs2 settle already.    kernel panic -not syncing : No init found. Try passing init = option to kernel. See linux Documentation/init.txt for guidance.

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 14:15:15
认可0
本帖最后由 2272943826 于 2016-11-25 10:14 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32803&ptid=11776]ngswfx 发表于 2016-6-29 13:56[/url]
重启呀,只要停住都只能重启,然后uboot ,ctrl+c,到Uboot控制台,重新配置[/quote]

我进去啦Uboot 控制台

ngswfx

1个粉丝

55

问答

1

专栏

40

资料

ngswfx 2016-06-29 14:51:03
认可0
本帖最后由 ngswfx 于 2016-6-29 14:54 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32805&ptid=11776]2272943826 发表于 2016-6-29 14:15[/url]
我进去啦 Uboot 控制台, 重新配置啦
                但是 kernel panic ,not init found  我不知道该怎么办?

[/quote]

他这个是PC,你的是arm,不是一回事

看着你怪费劲的:

setenv bootargs 'mem=96M lpj=5996544 console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=jffs2  mtdparts=hi_sfc:128K(boot),64K(UB_ENV),1536K(kernel),8640K(rootfs),21824K(APP),512K(Config),64K(LOGO)'

修改为
setenv bootargs 'mem=64M console=ttyAMA0,115200 root=/dev/mtdblock3 rootfstype=jffs2  mtdparts=hi_sfc:1024K(boot),7168K(kernel),1024K(Config),7168K(rootfs)'

试试在uboot里面执行这个,然后保存重启。

2272943826

0个粉丝

24

问答

0

专栏

8

资料

2272943826 2016-06-29 14:53:33
认可0
本帖最后由 2272943826 于 2016-7-21 15:48 编辑

[quote][url=forum.php?mod=redirect&goto=findpost&pid=32810&ptid=11776]ngswfx 发表于 2016-6-29 14:51[/url]
他这个是PC,你的是arm,不是一回事[/quote]

谢谢您的指导
加载中···
或将文件直接拖到这里
悬赏:
E币
网盘
* 网盘链接:
* 提取码:
悬赏:
E币

Markdown 语法

  • 加粗**内容**
  • 斜体*内容*
  • 删除线~~内容~~
  • 引用> 引用内容
  • 代码`代码`
  • 代码块```编程语言↵代码```
  • 链接[链接标题](url)
  • 无序列表- 内容
  • 有序列表1. 内容
  • 缩进内容
  • 图片![alt](url)
+ 添加网盘链接/附件

Markdown 语法

  • 加粗**内容**
  • 斜体*内容*
  • 删除线~~内容~~
  • 引用> 引用内容
  • 代码`代码`
  • 代码块```编程语言↵代码```
  • 链接[链接标题](url)
  • 无序列表- 内容
  • 有序列表1. 内容
  • 缩进内容
  • 图片![alt](url)
举报反馈

举报类型

  • 内容涉黄/赌/毒
  • 内容侵权/抄袭
  • 政治相关
  • 涉嫌广告
  • 侮辱谩骂
  • 其他

详细说明

易百纳技术社区