Balena not booting on Intel Edison

I just flashed balena-cloud-xxxxxx-intel-edison-2.15.1+rev1-v7.16.6 to my intel Edison.
It doesn’t boot. From console this is all I can read:
Error reading from serial device
** Bad device :7 0x100000 **
Error: Invalid Boot Flag (found 0xffef, expected 0xaa55)

Kernel loading failed …

zboot - Boot bzImage

Usage:
zboot [addr] [size] [initrd addr] [initrd size]
addr - The optional starting address of the bzimage.
If not set it defaults to the environment
variable “fileaddr”.
size - The optional size of the bzimage. Defaults to
zero.
initrd addr - The address of the initrd image to use, if any.
initrd size - The size of the initrd image to use, if any.

Unknown boot mode: boot
Saving Environment to MMC…
Writing to MMC(0)… done
Resetting to default boot mode and reboot…
resetting …


PSH KERNEL VERSION: b0182929
WR: 20104000


SCU IPC: 0x800000d0 0xfffce92c

PSH miaHOB version: TNG.B0.VVBD.0000000c

microkernel built 10:14:01 Jan 13 2015

******* PSH loader *******
PCM page cache size = 192 KB
Cache Constraint = 0 Pages
Arming IPC driver …
Adding page store pool …
PagestoreAddr(IMR Start Address) = 0x04899000
pageStoreSize(IMR Size) = 0x00080000

*** Ready to receive application ***

U-Boot 2015.10 (Jul 25 2018 - 15:38:47 +0000)

CPU: x86_64, vendor Intel, device 406a8h
Watchdog enabled
DRAM: 980.6 MiB
MMC: tangier_sdhci: 0, tangier_sdhci: 1
Using default environment

In: serial
Out: serial
Err: serial
Net: Net Initialization Skipped
No ethernet found.
Hit any key to stop autoboot: 0
Target:blank
Partitioning already done…
Flashing already done…
Probing DFU…
Saving Environment to MMC…
Writing to redundant MMC(0)… done
** Bad device :7 0x100000 **
Error: Invalid Boot Flag (found 0xffef, expected 0xaa55)

Kernel loading failed …

zboot - Boot bzImage

Usage:
zboot [addr] [size] [initrd addr] [initrd size]
addr - The optional starting address of the bzimage.
If not set it defaults to the environment
variable “fileaddr”.
size - The optional size of the bzimage. Defaults to
zero.
initrd addr - The address of the initrd image to use, if any.
initrd size - The size of the initrd image to use, if any.

Unknown boot mode: boot
Saving Environment to MMC…
Writing to MMC(0)… done
Resetting to default boot mode and reboot…
resetting …


PSH KERNEL VERSION: b0182929
WR: 20104000


SCU IPC: 0x800000d0 0xfffce92c

PSH miaHOB version: TNG.B0.VVBD.0000000c

microkernel built 10:14:01 Jan 13 2015

******* PSH loader *******
PCM page cache size = 192 KB
Cache Constraint = 0 Pages
Arming IPC driver …
Adding page store pool …
PagestoreAddr(IMR Start Address) = 0x04899000
pageStoreSize(IMR Size) = 0x00080000

*** Ready to receive application ***

U-Boot 2015.10 (Jul 25 2018 - 15:38:47 +0000)


Solved flashing with Intel’s Flash Tool.
The script has a bug

I got the same error and I can’t figure out how to flash with Intel’s Flash Tool. The device only shows up for a few secends in the flash tool and becomes disconnected.

Can we fix the script so that depencency on the flash tool is not needed?

I managed to use Intel’s flash tool to flash the device but it still doesn’t work. Can we get someone from Balena to take a look?

Thanks!

Hi
Can you confirm that you got the 100% done progress bar in the flash tool? If possible, can you also share the logs that you can see in the Flash Tool?

Also, do check our docs for some common issues. I think the below part is relevant here -

Once your Edison has reached 100% on the progress bar, the flashing process has completed, but the device still needs to reboot. Let your Edison sit for about 2 minutes.

1 Like

https://gist.github.com/aifreedom/223acca21ff1840ae4e751700c0db511 is the flash.log from the flashall.bat. I think I’ve waited long enough using the flash tool. But again, I’m not sure why the device only shows up temporarily when it is starting. It seems that after the kernel is loaded, the device appears disconnected in the tool.

I’m also sure that the hardware is working. Below shows that if I can login in as root if I flash Intel’s Yocto Poky Linux.

The error message I got from the serial port of Edison is the same as @cyanpablo.

** Bad device :7 0x100000 **
Error: Invalid Boot Flag (found 0xffef, expected 0xaa55)

Hi @aifreedom I think I have an edison lying around here, I will try reproduce my side and see if I can get it working. One thing to note is that since Intel has completely discontinued the Edison and doesn’t support much of its software anymore, its becoming harder for balena to justify maintaining and supporting this device type. Which OS version have you tested to flash, have you tested any of the older ones?

1 Like

Yes, I get the idea that it’s discontinued by Intel in 2017. I got this board from a raffle on Hackster.io. And just want to see if I can make use of the board to do something cool. I appreciate your effort and time trying to fix the issue. Totally understandable if Balena decides to stop supporting it too.

I was flashing the latest OS version 2.31.5+rev1 as it was “recommended” in the “Add new device” flow. Will try to flash the oldest in the list 2.15.1+rev1 and see if that works.

Oh no, the intel flash tool for MacOS link is broken and the installer doesn’t seem to exist, might need to try find an ubuntu machine to try run this from :?

I downloaded from this github project https://github.com/projectceladon/tools

I am currently flashing it from an Ubuntu 19.10 laptop with dfu-util 0.9 and it seems to be working correctly, but will know for sure in about 10 minutes, so one workaround might be to flash it using a virtual machine running ubuntu, but I will be able to say for sure in a few.

Flashing using dfu-util and the bat included in the zip on Windows 10 seems to succeed for me without a problem. Not sure if the issue is from the flashing because I can flash the official image in a similar way without problem.

okay, so just provisioned a balenaOS 2.31.5+rev1 “development” version on my edison and it popped up in my dashboard correctly, so the dfu-util flash script for linux definitely is working correctly. Did you flash a development image? if you did, you should be able to connect up a serial cable to your board on the console micro usb and see the boot logs, that would tell us if the flash is working correctly and if the perhaps is another issue, it could be that you are trying to connect to a 5Ghz network and the edison only supports 2.4GHz or some other wifi related issue

I flashed the development image. The boot logs I got is almost identical to what @cyanpablo posted above that it complains about invalid boot flag and kernel loading failed. It has failed before trying to connect to the internet.

Let me try to flash from Linux or maybe install dfu-util on Mac.

@shaunmulligan thank you for looking into it!

no problem, let us know if it works correctly from Linux or mac. Its really a pity Intel stopped working on the edison, its really quite a great little device.

1 Like

Flashed it on Mac with dfu-util installed from Homebrew and it worked!

You probably can give users a warning message on the UI that the flashall.bat doesn’t work in Windows 10 and it’s recommended to flash in Mac and Linux.

Awesome! thanks for letting us know. I have already pinged the docs team to help clean up the edison docs a bit and set expectations a bit, so people don’t have to hit this again. thanks for helping us work it out!