Hi,
there is no method described in the manual. I guess many (most?) people interested in an open
hardware development device are using linux.
I hope there are any tools available and the documentation can be extended.
Thanks
Steffen
Hi,
there is no method described in the manual. I guess many (most?) people interested in an open
hardware development device are using linux.
I hope there are any tools available and the documentation can be extended.
Thanks
Steffen
Remember that the RIoT board is targeted specifically for Android development, not mainline linux.
It's also not a truly open hardware design as the actual CAD files are not provided. There are Gerbers available now which allow you to produce an exact copy, but the Mentor/KiCad/Eagle/whatever source files are not available so you can't easily modify it.
There are better choices if you want an open hardware board, for eaxmple the Olimex OLinuXino boards.
However, the user manual has section 5 on how to build linux kernel images and you'll find a linux download on this page RIoTboard
Thanks for the reply. You are right - it's maybe not that open.
I have seen the linux image. My problem is, that i don't see a way to upload it to the riotboards eMMc. The mfg tool is not
running on my linux desktop.
I think the attachment is ok u-boot.imx has 326656 bytes, here is the situation:
Hmm... like I said, I don't have the board here, so it's difficult to check switch settings. I'll do so later this afternoon and let you know.
file size looks correct, and the exact command I used to write it from the history was dd if=u-boot.imx of=/dev/sdb bs=1024 seek=1 using a usb SD adapter.
Unfortunately uploads here seem to be limited to 50MB, but maybe we just need to find a way to get you a straight copy of my uSD image to try.
I found this log in my terminals history showing what you should see, you should at least get the u-boot part with probably an error about missing /bootscript
U-Boot 2014.04-rc2-00094-g7d72f06-dirty (Mar 30 2014 - 18:20:25)
CPU: Freescale i.MX6SOLO rev1.1 at 792 MHz
Reset cause: POR
Board: RIoTboard
I2C: ready
DRAM: 1 GiB
MMC: FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
No panel detected: default to HDMI
Display: HDMI (1024x768)
In: serial
Out: serial
Err: serial
Net: FEC [PRIME]
Warning: Your board does not use generic board. Please read
doc/README.generic-board and take action. Boards not
upgraded by the late 2014 may break or be removed.
Hit any key to stop autoboot: 0
start
MMC: no card present
mmc0(part 0) is current device
load..
MMC: no card present
** Bad device mmc 0 **
mmc1 is current device
load..
473 bytes read in 29 ms (15.6 KiB/s)
import...
executing
2836792 bytes read in 192 ms (14.1 MiB/s)
kernel_loaded
33044 bytes read in 76 ms (423.8 KiB/s)
fdt_loaded
Kernel image @ 0x12000000 [ 0x000000 - 0x2b4938 ]
## Flattened Device Tree blob at 11000000
Booting using the fdt blob at 0x11000000
Using Device Tree in place at 11000000, end 1100b113
Starting kernel ...
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 3.14.0-imx (root@sl1) (gcc version 4.8.2 (GCC) ) #9 SMP Tue Apr 1 14:04:31 UTC 2014
[ 0.000000] CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] Machine model: RIoTboard i.MX6SDL
[ 0.000000] cma: CMA: reserved 16 MiB at 3e800000
[ 0.000000] Memory policy: Data cache writeback
[ 0.000000] CPU: All CPU(s) started in SVC mode.
[ 0.000000] PERCPU: Embedded 8 pages/cpu @edfce000 s8320 r8192 d16256 u32768
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 260624
[ 0.000000] Kernel command line: console=ttymxc1,115200n8 rootwait root=/dev/mmcblk0p1 enable_wait_mode=off
[ 0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes)
[ 0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
[ 0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
[ 0.000000] Memory: 1017160K/1048576K available (3802K kernel code, 169K rwdata, 1280K rodata, 196K init, 353K bss, 31416K reserved, 270336K highme)
[ 0.000000] Virtual kernel memory layout:
Matthias Schwartz wrote:
I think the attachment is ok u-boot.imx has 326656 bytes, here is the situation:
root@fubar01:~/riotboard# ls -l u-boot.imx
-rw-r--r-- 1 root root 326656 Mar 30 19:23 u-boot.imx
root@fubar01:~/riotboard# sha256sum u-boot.imx
36c4d61fa46203b8c4297c94ce5833739674a4bea92ea5766b631b5ab4a5b4ab u-boot.imx
Hopefully that can confirm the file you have is the same.
Yes the sha256sum is correct. I think the problem is not the u-boot.imx image. Either the dd call failed or the system needs additional information on the boot device, perhaps the u-boot parameters or some checksum. Or something on my board is corrupt.
I tried dd to /dev/mmcblk0 and /dev/mmcblk1 directly from ubuntu on the RIoT-board and dd to /dev/sda from an x86 linux system with USB to SD converter. Same effect with both. I checked the dip switches multiple times. Are there different board revisions with different switch settings?
When I'm using your u-boot in the serial download mode for BootStrap your UBoot-2014.04-rc2...dirty starts, first success
as far as I know, the only requirement is that the u-boot.imx file is written at 1K into the card.. it's obviously important that you don't create a filesystem at sector 63 as that would overwrite u-boot. Hence you create the first partition at 2048 blocks (1MByte) into the card.
The very same method works on the Wandboard and I've used it sucessfully there too.
Likewise, I've not seen anything to suggest there's more than one revision of the board. I suppose it's possible that one of the boot settings resistors from p18 of the schematics is missing, but it seems less likely if you're able to get the original images to boot.
If the serial download mode gets you something on the console then it seems it's likely to be switch settings, wrong SD card slot, failed write to the card, or maybe the boot rom is doing something your sd card doesn't like while trying to load u-boot..
Switch settings:
<html><head><title>Jive SBS</title></head>
<body><font face="arial,helvetica,sans-serif">
<b>Error</b><br><font size="-1">
An general error occurred while processing your request.
</font></font></body></html>
or maybe this is better with them highlighted?
uSD Card:
<html><head><title>Jive SBS</title></head>
<body><font face="arial,helvetica,sans-serif">
<b>Error</b><br><font size="-1">
An general error occurred while processing your request.
</font></font></body></html>
Card installed here:
<html><head><title>Jive SBS</title></head>
<body><font face="arial,helvetica,sans-serif">
<b>Error</b><br><font size="-1">
An general error occurred while processing your request.
</font></font></body></html>
# fdisk -l /dev/sdc
Disk /dev/sdc: 7948 MB, 7948206080 bytes
10 heads, 4 sectors/track, 388096 cylinders, total 15523840 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/dev/sdc1 2048 2099199 1048576 83 Linux
filesystem is ext2, but none of that should matter to get output from u-boot itself.
/bootscript sits in that ext2 partition and contains the following
fdt_high=0xffffffff initrd_high=0xffffffff kaddr=0x12000000 loadkernel=load ${dtype} ${disk}:1 ${loadaddr} /boot/zImage bargs=setenv bootargs console=ttymxc1,115200n8 rootwait root=/dev/mmcblk0p1 enable_wait_mode=off loadfdt=load ${dtype} ${disk}:1 0x11000000 /boot/${fdt_file} foobar=run bargs; if run loadkernel; then echo kernel_loaded ; if run loadfdt; then echo fdt_loaded; bootz ${loadaddr} - 0x11000000 ; else echo fail1; bootz ; fi ; fi ; echo failed to boot
and yes, that last line needs to be on a single line..
required kernel files go in /boot and are imx6s-riotboard.dtb & zImage, all three of which are attached..
sha256sums:
32d4b7d5ecc0b8838c8575e62cb689124fcaee6dc3babf0bbb76e975f9ad8ab8 bootscript
1e9f7ae6820a2febe71b8591d079995b36c7e07a80cc52dd3bf8c937aefddc5a imx6s-riotboard.dtb
5078d1023d49d62146826cd33af67789337aecd32240ff836d25fb9abf275ee4 zImage
Note that the kernel is quite minimal, there may not be enough in it to run a traditional distro like debian or ubuntu, but it's enough to prove booting works.
Matthias Schwartz wrote:
or the system needs additional information on the boot device, perhaps the u-boot parameters or some checksum.
That doesn't appear to be the case.. Mostly out of curosity to know if my build of u-boot would work on a full sized SD card, I completely zeroed a card, then wrote just that u-boot.imx at 1KB. Took out the uSD, put the full size SD in the other slot, swapped switches 7 & 8, turned it on and the u-boot prompt appears.. Not even a partition table on the card.
Thanks a lot for your detailed information!
Especially the kernel file and the dtb will be very useful to try.
At the moment I don't see what I've done wrong and suspecting some hidden misconfiguration of the board.
Another question. How do u-boot know which serial console and speed it should use for the output before the boot parameter of u-boot are set (setenv console...)? Perhaps everything is working except the console output.
Thanks a lot for your detailed information!
Especially the kernel file and the dtb will be very useful to try.
At the moment I don't see what I've done wrong and suspecting some hidden misconfiguration of the board.
Another question. How do u-boot know which serial console and speed it should use for the output before the boot parameter of u-boot are set (setenv console...)? Perhaps everything is working except the console output.
The console used is effectively hard-coded by the board config you build u-boot for. If you look in include/configs/embestmx6boards.h in the u-boot source, you'll find some lines near the top like
#define CONFIG_MXC_UART_BASE UART2_BASE #define CONFIG_CONSOLE_DEV "ttymxc0" #define CONFIG_MMCROOT "/dev/mmcblk1p2" #ifdef CONFIG_RIOTBOARD #define CONFIG_DEFAULT_FDT_FILE "imx6s-riotboard.dtb" #elif defined CONFIG_MARSBOARD #define CONFIG_DEFAULT_FDT_FILE "imx6q-marsboard.dtb" #else #error Please define a board (RIOTBOARD or MARSBOARD) #endif
CONFIG_CONSOLE_DEV gets used later for the default built-in environment, but I expect that it's really CONFIG_MXC_UART_BASE that sets what the console will be. I'm not 100% sure what gets used where though, or if you can fully override the u-boot console output by setting the var in the environment.