Forum Menu




 


Log in Problems?
New User? Sign Up!
AVR Freaks Forum Index

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
medium999
PostPosted: Jun 29, 2011 - 02:00 AM
Rookie


Joined: Jul 06, 2010
Posts: 23


I think my bootcmd or bootargs might be incorrect???????

This is the process i followed after building successfully building the kernal.

Set up the SD Card on the computer

Code:
sudo umount /dev/sdc
sudo /sbin/e2fsck /dev/sdc
sudo /sbin/mkfs ext2 /dev/sdc -I128


Copy files from computer -> SD Card

Code:
sudo dd if=/home/alastair/Desktop/buildroot-avr32-v3.0.0/output/images/rootfs.ext2 of=/dev/sdc
sudo dd if=/home/alastair/Desktop/buildroot-avr32-v3.0.0/output/images/u-boot.bin of=/dev/sdc
sudo dd if=/home/alastair/Desktop/buildroot-avr32-v3.0.0/output/images/uImage of=/dev/sdc


Uboot Parameters

Code:

baudrate=115200
ethaddr=00:04:25:1C:6A:D2
bootdelay=1
ethact=macb0
serverip=172.24.41.2
tftpip=172.24.41.2
eth1addr=00:04:25:1C:6A:D3
filesize=ded1f
env=askenv
bootargs=console=ttyS0 root=/dev/mtdblock1 rootfstype=ext2 rootwait rootdelay=1
bootcmd=mmcinit; ext2load mmcblk0p1 0x10400000 /uImage; bootm;

stdin=serial
stdout=serial
stderr=serial


Boot

Code:

U-Boot code: 00000000 -> 000144f7  data: 24000000 -> 24002d80
SDRAM: 32 MB at address 0x10000000
Testing SDRAM...OK
malloc: Using memory from 0x11fc0000 to 0x12000000
Flash:  8 MB at address 0x00000000
DRAM Configuration:
Bank #0:             10000000 32       MB
In:    serial
Out:   serial
Err:   serial
Net:   macb0, macb1
Press SPACE to abort autoboot in 1 seconds
Manufacturer ID:       1B
OEM/Application ID:    534D
Product name:          00000
Product Revision:      1.0
Product Serial Number: 2983805300
Manufacturing Date:    08/09
SD Card detected (RCA 2)
CSD data: 007fff32 5f5983ce 76dbdfff 924000b9
CSD structure version:   1.0
MMC System Spec version: 0
Card command classes:    5f5
Read block length:       512
Supports partial reads
Write block length:      512
Does not support partial writes
Supports group WP:      32
Card capacity:        1021837312 bytes
File format:            0/0
Write protection:       
.
** No boot file defined **
## Booting image at 10200000 ...
Bad Magic Number
 
 View user's profile Send private message  
Reply with quote Back to top
hce
PostPosted: Jun 29, 2011 - 07:09 AM
Raving lunatic


Joined: Jan 07, 2003
Posts: 4580
Location: Oslo, Norway

Quote:
## Booting image at 10200000 ...
Seems like your bootcmd is doing something else. You only need rootwait or rootdelay, not both. Rootfstype should autodetect with ext2, and you can NOT have an ext2 file system in raw flash devices. Use ubifs, or jffs2.

I would also recommend that you partition your SD-card, even if it just is to have one big partition.

Delete your filesize argument i U-Boot.

Arguments I use when booting a file system from SD-card:
Code:
set bootargs root=/dev/mmcblk0p1 rootwait
set bootcmd 'mmc init; ext2load mmc 0:1 0x10400000 /boot/uImage; bootm'
 
 View user's profile Send private message  
Reply with quote Back to top
medium999
PostPosted: Jul 06, 2011 - 01:12 PM
Rookie


Joined: Jul 06, 2010
Posts: 23


Still having some problems with this.

I think there might have been a problem with my buildroot so i have downloaded the binaries directly. I am now using an EVKLCD101 so i have downloaded the binarys for that from here - http://www.atmel.no/buildroot/binaries/ ... evklcd100/

I have copied the jffs2-root and jffs2-usr files to the SD card using sudo dd if=**file path** of=/dev/sdc

Previously i was using files labelled as rootfs.ext2 so not sure if i can still use
Quote:
bootcmd 'mmc init; ext2load mmc 0:1 0x10400000
now that the files are labeled as jffs2. Does the bootcmd or bootargs change due to this?
 
 View user's profile Send private message  
Reply with quote Back to top
medium999
PostPosted: Jul 09, 2011 - 04:09 AM
Rookie


Joined: Jul 06, 2010
Posts: 23


bump
 
 View user's profile Send private message  
Reply with quote Back to top
nedwed
PostPosted: Jul 22, 2011 - 06:08 AM
Newbie


Joined: Feb 23, 2009
Posts: 16
Location: Poland

Hi,
are your bootargs and bootcmd correct? as far as I remember root path should be root=/dev/mmcblk0p1

my ngw100 uses:
Code:

bootargs=console=ttyS0 root=/dev/mmcblk0p1 rootwait
bootcmd=mmcinit; ext2load mmc 0:1 0x10400000 /boot/uImage; bootm 0x10400000
[/code]
 
 View user's profile Send private message  
Reply with quote Back to top
medium999
PostPosted: Aug 01, 2011 - 05:27 AM
Rookie


Joined: Jul 06, 2010
Posts: 23


Thanks for your post

With those bootargs/cmd i get an error saying
Quote:
** Unable to read "/boot/uImage" from mmc 0:1" **
## Booting image at 10400000
Bad Majic Number

I have checked the SD card and the file system looks like it copied perfectly.

Whats the story with Uboot, do newer versions of the buildroot need newer versions of Uboot? If so what the clearest most up to date guide as to how to update Uboot?
 
 View user's profile Send private message  
Reply with quote Back to top
medium999
PostPosted: Aug 12, 2011 - 03:12 AM
Rookie


Joined: Jul 06, 2010
Posts: 23


Resolution:

Contacted Atmel. Upgraded Uboot using the Uboot file found in http://www.atmel.no/buildroot/binaries/ ... gw100mkii/

I used the AVRATJTAGICE_MKII to do this by first installing AVR32Studio on my PC then

open command prompt and cd into the following directory

program files\Atmel\Plugins\com.atmel.avr.utilities.win32.x86_3.0.0.201012011602\os\win32\x86\bin

make sure the u-boot.bin file is in this directory. Plug the AVRATJTAGICE_MKII into your computer and automatically install (driver is part of AVR32Studio)

Plug into your device, make sure you get the JGTAG pins round the right way

Erase flash

avr32program erase -fcfi@0 ;

Program new uboot

avr32program program -F bin -vfcfi@0 u-boot.bin;

Use the EVKLCD101 Linux binary from http://www.atmel.no/buildroot/binaries/ ... evklcd101/

Put on your SD card (will post a good article on howw to do this here)

set bootcmd to mmc init; ext2load mmc 0:1 0x10400000 /boot/uImage; bootm 0x10400000

set bootargs to console=ttyS0 root=/dev/mmcblk0p1 fbmem=600k rootwait

WORKS
 
 View user's profile Send private message  
Reply with quote Back to top
monimi529
PostPosted: Aug 26, 2012 - 02:36 AM
Newbie


Joined: Aug 21, 2012
Posts: 9


Hi,is just that i dont know why my boot folder is not visible in the SD card, i can see it if i plug it into the PC (the SD card) but when i plug it into the atngw100 board there is no boot folder and no uImage, i don't understand why, and because of that problem, my board isn't booting, i already changed my SD card, i was first using a terasic SD card (256 MB) and now i'm using a kingston micro SD card (1 GB). please help. thanks in advanced.
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT + 1 Hour
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2006 The PNphpBB Group
Credits