Giter Club home page Giter Club logo

Comments (10)

bztsrc avatar bztsrc commented on July 27, 2024

Hello,

Debugging boot procedure on a real hardware is not easy, requires a deep knowledge of the process and a big deal of experience.

I'd suggest to check these:

  1. is the partitioning table MBR (and not GPT) with partition type 0xC? How big is your partition? I've found that not all partition sizes are supported by the fw. (In short, can the fw find the files at all?)
  2. try to download the other firmware files too, most notably fixup.dat
  3. if you use a different kernel image, does it work? (so narrow the problem to either GPU booting (bootcode.bin, start.elf) or ARM (kernelX.img; a led blinker kernel7.img will do))
  4. are you sure your board supports AArch64? (so is it RPi3 and not RPi2B+ by any chance?)
  5. if you have a config.txt on the SD card, remove it, as my tutorials were intended to boot with default configuration. They won't work if you have some special set up, like kernel_old.

This is not a complete list, just a few thoughts what you should check. The most important thing is to narrow down whether the problem is with your card (partition unreadable by the fw), with the GPU boot stage, or with executing the ARM kernel. Also you could try to download a raspbian lite image and replace the kernel in it (with that you can rule out the first two possibilities for sure).

I strongly suggest to start with a known to be working image (like raspbian), remove kernel*.img and config.txt and build your testing environment up from there.

Good luck!
bzt

from raspi3-tutorial.

milanvidakovic avatar milanvidakovic commented on July 27, 2024

Hello,
Thank you for your detailed answer. I have purchased a new 16GB Kingston class 10 sd card and I have installed raspbian. It booted without problems. Then I have deleted almost everything, leaving bootcode.bin and start.elf. Then I have copied your simple uart echo example as kernel8.img, placed the sd card into the RPI3 (yes I do have RPI3) and everything was OK.

Now I need one more thing (for now) - I would like to use the your raspbootin64 image to reduce sd card wear and send executables via serial cable. However, my development environment is Windows. You have left a link to a windows-based raspbootin-server.c. This information is rather foggy to me. What can I do with that file? To me it doesn't appear as a client-side program, which could be used to send executable files via serial connection to your raspbootin64.
Github dwelch67 user has created similar environment as yours, but it uses xmodem protocol to accept files to be executed. On Windows, I can find several xmodem clients which I could use to send files via serial cable. Could you help regarding this matter?
Best regards,
Milan

from raspi3-tutorial.

milanvidakovic avatar milanvidakovic commented on July 27, 2024

Hello,
let me reply to my own question. Now that I can boot from any kernel8.img file, I have decided to write a Java client for your Raspbootin loader.
I have written an application in Java which sends arbitrary kernel file to the your Raspbootin loader. I am getting all the right answers from the loader, including the 'OK' at the end, but it seems that the loaded kernel file is not working.
Just to check: your Raspbootin expects a kernel8.img file from the examples to be sent?
Raspbootin64Client.zip

from raspi3-tutorial.

bztsrc avatar bztsrc commented on July 27, 2024

Hi,
That windows code was not written by me, and I have never tried it. But you should be able to compile it on win and use it to send your kernel just like with the original rasbootcom utility. If you have written another app, that's great!
Yes, the kernel file should be the same kernel8.img you would load from sd card if you were using sd card and not serial.
Please give me a few days, somebody else has reported problems with the loader, although I was unable to reproduce the error so far. I'll do more through tests and get back to you.

from raspi3-tutorial.

bztsrc avatar bztsrc commented on July 27, 2024

I've tested it, now works for me. Please check it out.

from raspi3-tutorial.

milanvidakovic avatar milanvidakovic commented on July 27, 2024

Edit: I have written the comment below before I realized that you have also written a comment. I will check it up and inform you soon.

Hi,
Thank you. I am waiting for your response :)
In a meantime, just to inform you how far I have reached: loader receives the kernel8.img via serial and then jumps to the 0x80000 address. That is the point where uploaded program fails. I don't know what happens there, because that step should be straight forward. Unfortunately, nothing happens at that moment, so I don't know if the uploaded image gets corrupted during upload, or something else fails.
Best regards,
Milan

from raspi3-tutorial.

bztsrc avatar bztsrc commented on July 27, 2024

Yeah, I agree, that step should be straight forward, but it's not. I suppose it's a gcc bug, because it does not jump to the address 0x80000 as one would expect. First I've wanted to use a relocation calculated by hand, but that seemed way too ugly. So instead I've decided to use a fake function return to jump to the absolute address of the new kernel, which is 4 bytes longer, but at least works :-)

from raspi3-tutorial.

milanvidakovic avatar milanvidakovic commented on July 27, 2024

Hello,
It works! :) Thank you!
Now I will go through all the examples.
I have changed the Java client so it works a bit more stable. I plan to put the source to my github repository, but in any case, if you don't mind, here is the whole Eclipse project. Works on Windows, and should work on any OS with Java.
Best regards,
Milan
Raspbootin64Client.zip

from raspi3-tutorial.

bztsrc avatar bztsrc commented on July 27, 2024

Good to hear!
Please let me know when you've created a github repo for your Java kernel sender, I'd like to link it if you don't mind.

Cheers,
bzt

from raspi3-tutorial.

milanvidakovic avatar milanvidakovic commented on July 27, 2024

Hello,
I have created a repo on the github:
https://github.com/milanvidakovic/Raspbootin64Client

Thanks again for the great software!
Best regards,
Milan

from raspi3-tutorial.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.