-3

I would like to completely erase the EEPROM and then shutdown the RaspBerry Pi 4 that I bought. When you then insert a USB-stick with your own bootloader, it should search for it and automatically install the bootloader you have either compiled or downloaded, so you can run your own operating system.

I am a qualified Computer Science engineer and I need a simple workstation to build my own operating system, but the Raspberry Pi doesn't allow me to program or install anything of my own. This is a problem.

Has anyone been able to install a different OS? The processor is a RISC processor and the basic instruction set hasn't changed, it has only been expanded, so if you make use of the basic instruction set it will still work.

5
  • It is possible to install many different operating systems on a pi (try a noobs card). What is it you want to do that cannot be accommodated by adding your own operating system to noobs? Jul 11, 2023 at 11:39
  • Welcome, but: "Has anyone been able to install a different OS? [...] the Raspberry Pi doesn't allow me to program or install anything of my own" This must be an assumption based on some flawed reasoning, because I don't believe there is any piece of legit information anywhere that implies this. If that assumption is based on the official Raspberry Pi imager, you don't need to use that either. I've been playing with Pis for a little over a decade, and I've never even seen it beyond online screenshots. In any case, you have it very wrong, dunno if chatGPT or something is behind that.
    – goldilocks
    Jul 11, 2023 at 13:04
  • You might find wiki.netbsd.org/ports/evbarm/raspberry_pi interesting . Jul 12, 2023 at 13:57
  • I want to install DOS 6.22 with QBASIC for programming my assembler. I checked with MicroSoft. They agree that the basic instruction set upto and including 32-bit hasn't changed for RISC processors, only the extended instruction set for systems higher than 32-bit. DOS 6.22 doesn't make use of the extended instruction sets. As such it should run just fine and allow me to develop my own operating system. Erasing the EEPROM didn't allow me to upload a different bootloader, only the default, which suggests there's an EEPROM behind the EEPROM that I erased that I need to erase. How do I do this? Jul 13, 2023 at 15:49
  • @EmileMichelHobovanOranje I think you’ve misunderstood the situation. The CPU on which the RPi is based is a completely different architecture than that which ran MS-DOS. Neither one would be able to directly run an OS or other software written for the other one.
    – Sneftel
    Dec 30, 2023 at 15:35

2 Answers 2

2

You don't need to do anything with the EEPROM nor any bootloader. The entire OS is stored on your boot device eg micro sd card or SSD

Download PiImager and select 'CHOOSE OS' to see a selection of other OS's.

https://www.raspberrypi.com/software/

2
  • I want to design my own bootloader. I'm a computer science engineer. It's a part of my trade. I do have to do this. I have very specific intended purposes that the offered operating systems and also bootloaders prohibit. Jul 13, 2023 at 16:59
  • I am not too sure that a Raspberry Pi is a great choice for this, but if so, get a 3B+ instead of a 4B (no EEPROM -- but that won't get you out of the proprietary issues mentioned in my other comment). Note that you can add a third stage bootloader, people use u-boot that way: apriorit.com/dev-blog/66-develop-boot-loader This correlates to a conventional second stage bootloader.
    – goldilocks
    Jul 13, 2023 at 19:21
1

As per other comments, you don't need to worry about the bootloader if what you want to do is code an OS or whatever bare metal based thing; lots of people do this. The OS is loaded from a file on the boot partition, which is configurable and can be anything you like. Conventionally, this is the linux kernel which then does its own thing loading the userland etc.

https://www.raspberrypi.com/documentation/computers/config_txt.html#kernel

Probably reading some of the actual documentation is a good idea WRT planning your project.

5
  • I also want to code my own smaller than 64k bootloader that might also act as a basic OS. Jul 13, 2023 at 17:00
  • I think what is partially at issue is the Rpi is not open hardware, and some of the bootloader/firmware is proprietary as is the parts of the hardware it controls/initializes. There is a second stage bootloader that's not in the EEPROM, start.elf, which the first stage bootloader loads from storage (ie. the SD card).
    – goldilocks
    Jul 13, 2023 at 19:18
  • It's not your fault, but I paid for it, so it's my computer. There's no such thing as proprietary hardware. As soon as I have it, as long as I don't rebrand it and sell it as my own, for instance by reverse engineering it, I can use it whatever way I like. They aren't allowed to use forced packaging deals. Those have been deemed illegal a long time ago. Jul 14, 2023 at 6:07
  • Of course you can do whatever you like with your own property, my point is the impediments you are running into aren't an accident, and if you are looking for public information on those proprietary bits, you won't find any because (ostensibly) there isn't any. You can still reverse engineer the bootloader and put your own thing on the EEPROM, you just need the means and the wherewithal. I doubt that you are going to get much help with that here though, probably our big sibling site Electrical Engineering is a better starting point.
    – goldilocks
    Jul 14, 2023 at 13:08
  • I think the documentation is just off in that the RaspBerry Pi has the usual 64kB bootloader and an onboard SSD of probably 256MB. I remember articles on the RaspBerry Pi describing conflicts with the original creator who had the intent of people actually doing exactly what I want to do. Maybe it's possible to put "erase_eeprom=0,1" in the config.txt file to delete both the bootloader and the SSD. Jul 14, 2023 at 17:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.