Open StiNKzz opened 2 years ago
It's hard to understand what's the problem. According to forum, only you have this problem. So it's possible there is some specific setup causes this problem. I think you know that uboot.img laying in linux folder is not used for booting. You(or some script) need to execute updateboot which will flash uboot.img into special place of sd card. After that you can simply delete uboot.img - it's not needed.
It's not only him, I have put away my DE-10 after it stopped booting. Will no longer boot to GUI, only to prompt shown through serial. I have described this in the forum also. Mr. Fusion never gets to the second boot.
Coming from the thread at https://misterfpga.org/viewtopic.php?t=5292 I apologize if this isn't the best issue for it. There are so many repositories to choose from where to post, I'll gladly copypaste this somewhere else if you just tell me where.
For what it's worth, I tried the 20221224 release and have abysmal luck. This is installed by mr-fusion 2.9 (unlike what this repo's about, but isn't the resulting sd card the same anyway).
I also tried to downgrade to the 2021-08-29 release of uboot.img because I think that's the latest when people say 20210917 at https://misterfpga.org/viewtopic.php?t=3724 but it's not really better.
U-Boot 2017.03+ (Dec 24 2022 - 15:55:06 +0800)
Watchdog enabled
DRAM: 1 GiB
socfpga_bridges_reset: FPGA not ready, aborting.
MMC: dwmmc0@ff704000: 0
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
Autoboot in 0 seconds
reading menu.rbf
2484588 bytes read in 273 ms (8.7 MiB/s)
reading /linux/u-boot.txt
39 bytes read in 8 ms (3.9 KiB/s)
## Info: input data size = 1005 = 0x3ED
reading /linux/zImage_dtb
** Unable to read file /linux/zImage_dtb **
ERROR: Did not find a cmdline Flattened Device Tree
Could not find a valid device tree
=>
but when it works, it's like this
U-Boot 2017.03+ (Dec 24 2022 - 15:55:06 +0800)
Watchdog enabled
DRAM: 1 GiB
socfpga_bridges_reset: FPGA not ready, aborting.
MMC: dwmmc0@ff704000: 0
*** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
Autoboot in 0 seconds
reading menu.rbf
2484588 bytes read in 264 ms (9 MiB/s)
reading /linux/u-boot.txt
26 bytes read in 5 ms (4.9 KiB/s)
## Info: input data size = 1005 = 0x3ED
reading /linux/zImage_dtb
7378793 bytes read in 803 ms (8.8 MiB/s)
## Flattened Device Tree blob at 01704938
Booting using the fdt blob at 0x1704938
reserving fdt memory region: addr=0 size=1000
Loading Device Tree to 03ff8000, end 03fffe30 ... OK
Starting kernel ...
[ 1.223369] rtc-pcf8563 2-0051: pcf8563_write_block_data: err=-6 addr=0e, data=03
[ 1.230865] rtc-pcf8563 2-0051: pcf8563_probe: write error
[ 1.243374] rtc-m41t80 2-0068: Can't clear HT bit
Starting syslogd: OK
Starting klogd: OK
Populating /dev using udev:
Minimig by Dennis van Weeren
ARM Controller by Jakub Bednarski
MiSTer code by Sorgelig
Version 231018
Looking for root device...
FileOpenEx(open) File:/media/fat/config/device.bin, error: No such file or directory.
Using SD card as a root device
Identified 8BIT core*** SDRAM config not found
Core name is "MENU"
** altcfg: no cfg
INI_PARSER : Start INI parser for core "MENU"(MENU), video mode "0x0@0.0".
INI_PARSER : Opened file MiSTer.ini with size 14336 bytes.
I have tried two SD cards; one old one and the one that came with the FPGA. I don't think I've reinstalled this enough times to burn a hole in it, even though I did do that downgrade of uboot.img and update_boot
song and dance.
This is made more frustrating by the fact there's no real way to know if the device is about to come online or not. Except using a laptop and the usb uart. I was thinking there would be a small oled-type monitor that could read the serial data and display it, so I'd at least know if there's any point in jiggling the power switch, but I have it on good authority it's a non-trivial thing to build, as no over-the-counter solutions exist.
Is the DE10-Nano just a :hankey: that works by accident for enough people that the ones who don't get it going complain on the forums for a while until they stop trying? Or is there something fundamentally wrong in using mr-fusion as-is, and using mr-fusion with installing only some cores, and using mr-fusion and restoring a bigger backup of the conf files? I mean, the vanilla second boot essentially never works :man_shrugging: so I'd think it's not about the installation.
Where would I check my board version number, for example?
The post https://misterfpga.org/viewtopic.php?p=59472#p59472 seems like it would be best to build my own uboot.img, maybe that's in the future.
May be your DE10-nano is faulty. May be power supply circuit on your DE10-nano has problem and prevent it from booting. Every device may have problem including DE10-nano. If the problem you described was common then many people would complain. So it makes me think there is a problem with specific DE10-nano. But you may investigate further if you like. Source code for uboot is available.
Now I've conducted some more experiments, like in getting a 5V/5A PSU. I also built my kernel and bootloader and all that stuff.
The PSU is not proven to be relevant right now.
The DE10-nano doesn't boot 100% of the times, but it's as if there was some initial contact flaw and after one or two more attempts at booting, it starts up every time.
It should also be said that I have the MiSTress 500 daughterboard here, which I didn't think was pertinent information until I pulled the 10-pin GPIO1 bridge from between the DE10-nano and the mistress.
That seems to be the biggest single factor at play, so maybe some day I'll hotwire each of the pins, and/or try to measure the bridge with a multimeter, but this is too consistent to not be a lead.
Why it doesn't always boot might be a contact issue, as I routinely jiggle the MicroSD and everything when I mess with the system, so it could be that.
But what I'm currently seeing for errors, though I'm not certain this is a MiSTer issue per se anymore:
U-Boot SPL 2017.03-MiSTer-mjtorn+ (Dec 04 2023 - 12:00:53)
Trying to boot from MMC1
mmc_load_image_raw_sector: mmc block read error
mmc_load_image_raw_sector: mmc block read error
SPL: failed to boot from all boot devices
### ERROR ### Please RESET the board ###
I bought a brand new de 10 nano direct from Terasic in August. I have found the uboot image with the latest release (20220413) to boot unreliably, approximately 10% success rate.
However if I build my own uboot image from https://github.com/MiSTer-devel/u-boot_MiSTer and flash that directly on top of the sd cards uboot image, the boot is successful every time.
No additional boards, nor any sdram were attached, the nano was entirely by itself. Multiple sd cards of different brands and sizes were tested with this issue, they all produced the same results.
The uboot image bundled with the release may work with 99% of the nano boards out there, but my nano board appears to be 'special'. With that said, once I've flashed it with my own uboot image, my board works perfectly. I might also add the uboot image that Mr Fusion uses to start the installation process works fine as well.
This issue has been raised out of a discussion at https://misterfpga.org/viewtopic.php?t=5292
The UART output from a bad boot (uboot from release_20220413):
From a successful boot (uboot from release_20220413):