OS kernel can be written in Pascal !! lazarus / 62-General ---------------------------------------------------------------------- Mussel · 2022-01-07 21:45 Well, I have just proved it !! With reference to https://wiki.osdev.org/Pascal_Bare_Bones, although not 100% following his examples. Is this a good news? ---------------------------------------------------------------------- Thaddy · 2022-01-08 09:35 There are more examples. E.g. for Raspberry Pi there is Ultibo to build kernels and aa long time ago a pascal flavor was used for many micro Os's. FreePascal has good support for barebone/kernel programming. It is always nice to write your own OS. ---------------------------------------------------------------------- PascalDragon · 2022-01-08 10:42 Quote from: Mussel on January 07, 2022, 10:45:07 pmWith reference to https://wiki.osdev.org/Pascal_Bare_Bones, although not 100% following his examples. That article essentially abuses the Linux target for this. However for barebones development FPC has the Embedded target (most might associate it with micro controllers, but in essence it means “without an OS”). ---------------------------------------------------------------------- MarkMLl · 2022-01-08 12:12 Quote from: Mussel on January 07, 2022, 10:45:07 pmWell, I have just proved it !! I'd hardly call something which is in effect a "Hello, World!" an operating system, and it includes various assembler etc. I have managed to write a bare-metal microkernel in Modula-2 (Wirth's next language), which relied heavily on the language's built-in coroutine support to switch between threads. Also it used an external binder to fudge descriptor tables etc. I'm not sure that it's possible to write a useful OS from scratch in a high-level language unless you either * Embed processor-specific assembler or * Have extensions to the language which might be great from the POV of the OS writer, but are definitely not the sort of thing that you'd allow most application programmers to get their hands on or * Have a specialist OS-builder to handle binary generation MarkMLl ---------------------------------------------------------------------- Leledumbo · 2022-01-08 12:34 Quote from: Mussel on January 07, 2022, 10:45:07 pmIs this a good news? Yes, but you're about 10++ years too late. Feel free to take a look at all previous attempts. I wrote the first entry when I was in college, then I graduated and had no more time to develop. Among all listed, Ultibo to me is the most advanced and featureful. I don't mean to put you down, but take a look at it to see what can be done in Pascal with regard to OS development. It's not the language, it's the programmer, as always. If you go to OSDev forum, there are still people making 16-bit OSes using Turbo Pascal for whatever reason. ---------------------------------------------------------------------- Mussel · 2022-01-10 16:23 Thank you Thaddy, PascalDragon and MarkMLI for the insights. Quote from: Leledumbo on January 08, 2022, 01:34:20 pmYes, but you're about 10++ years too late. Wow, I just found out your are one of maintainer of FPOS on GitHub. It is certainly encouraging to see what FPOS can do, especially the command prompt!! I will not copy anything from FPOS. ---- For update on my OSFP, check out github.com/fliermatex/osfp PS/2 keyboard support has just been added (but without caps lock support).