diff --git a/docs/html/_r_e_a_d_m_e_8md.html b/docs/html/_r_e_a_d_m_e_8md.html new file mode 100644 index 0000000..1f49fcb --- /dev/null +++ b/docs/html/_r_e_a_d_m_e_8md.html @@ -0,0 +1,113 @@ + + +
+ + + + +|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
| Cdateval | |
| CFormat_State | Stores the current numeric value and formatting flags |
| Ctimeval |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
#include "printf.h"Go to the source code of this file.
++Functions | |
| void | clear (void) |
| Clears the terminal screen and moves the cursor to the home position. | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
Go to the source code of this file.
++Functions | |
| void | clear (void) |
| Clears the terminal screen and moves the cursor to the home position. | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
Go to the source code of this file.
++Macros | |
| #define | RTCDR (*(volatile uint32_t *)0x101e8000) |
| #define | SECONDS_IN_YEAR 31556926 |
| #define | SECONDS_IN_MONTH 2629743 |
| #define | SECONDS_IN_DAY 86400 |
| #define | LEAP_YEARS_BEFORE_1970 477 |
+Functions | |
| uint32_t | getdate (dateval *date_struct) |
| uint32_t | gettime (timeval *time_struct) |
| #define LEAP_YEARS_BEFORE_1970 477 | +
Definition at line 13 of file datetime.c.
+ +| #define RTCDR (*(volatile uint32_t *)0x101e8000) | +
Definition at line 8 of file datetime.c.
+ +| #define SECONDS_IN_DAY 86400 | +
Definition at line 12 of file datetime.c.
+ +| #define SECONDS_IN_MONTH 2629743 | +
Definition at line 11 of file datetime.c.
+ +| #define SECONDS_IN_YEAR 31556926 | +
Definition at line 10 of file datetime.c.
+ +| uint32_t getdate | +( | +dateval * | date_struct | ) | ++ |
Definition at line 15 of file datetime.c.
+| uint32_t gettime | +( | +timeval * | time_struct | ) | ++ |
Definition at line 49 of file datetime.c.
+|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
#include <stdint.h>Go to the source code of this file.
++Classes | |
| struct | timeval |
| struct | dateval |
+Functions | |
| uint32_t | getdate (dateval *date) |
| uint32_t | gettime (timeval *time_struct) |
| uint32_t getdate | +( | +dateval * | date | ) | ++ |
Definition at line 15 of file datetime.c.
+| uint32_t gettime | +( | +timeval * | time_struct | ) | ++ |
Definition at line 49 of file datetime.c.
+|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
| File in user | Includes file in include |
|---|---|
| clear.c | printf.h |
| datetime.c | datetime.h |
| printf.c | printf.h |
| string.c | string.h |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
| File in src/user | Includes file in include |
|---|---|
| clear.c | printf.h |
| datetime.c | datetime.h |
| printf.c | panic.h |
| printf.c | printf.h |
| string.c | string.h |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Files | |
| clear.c | |
| datetime.c | |
| printf.c | |
| string.c | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Directories | |
| pages | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Files | |
| clear.c | |
| datetime.c | |
| printf.c | |
| UART-backed minimal printf implementation for a freestanding kernel. | |
| string.c | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Files | |
| interrupt.c | |
| kernel.c | |
| memory.c | |
| panic.c | |
| start.s | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Directories | |
| lib | |
+Files | |
| clear.h | |
| datetime.h | |
| interrupt.h | |
| memory.h | |
| panic.h | |
| Kernel panic and halt routines. | |
| printf.h | |
| Minimal kernel printf/puts/getlines interface for freestanding systems. | |
| string.h | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
+Files | |
| interrupt.c | |
| kernel.c | |
| memory.c | |
| panic.c | |
| start.s | |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
| docs | |
| pages | |
| include | |
| lib | |
| math.h | |
| clear.h | |
| datetime.h | |
| interrupt.h | |
| memory.h | |
| panic.h | Kernel panic and halt routines |
| printf.h | Minimal kernel printf/puts/getlines interface for freestanding systems |
| string.h | |
| src | |
| kernel | |
| interrupt.c | |
| kernel.c | |
| memory.c | |
| panic.c | |
| start.s | |
| user | |
| clear.c | |
| datetime.c | |
| printf.c | UART-backed minimal printf implementation for a freestanding kernel |
| string.c |
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
This page explains how to interpret the graphs that are generated by doxygen.
+Consider the following example:
This will result in the following graph:
+The boxes in the above graph have the following meaning:
+The arrows have the following meaning:
+|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
AstraKernel is a minimal experimental kernel written in modern C and ARM assembly, designed to run on QEMU’s Versatile AB/PB board with a Cortex‑A8 CPU override (-cpu cortex-a8). This setup keeps the simple Versatile peripheral map while enabling ARMv7‑A features for experimentation. The purpose is educational, showing the fundamental steps of bringing up a bare-metal system, from low-level bootstrapping to higher-level interactive features to explore kernel development concepts.
+Later, the kernel may relocate vectors using VBAR once the MMU is enabled.
+Make sure you have an ARM cross-compiler installed (e.g., arm-none-eabi-gcc) and qemu-system-arm.
+Developers also have the option to run the kernel with custom flags, such as:
If you have Docker installed, you can also run AstraKernel through a Docker container:
+For more details about this kernel, refer to the AstraKernel Documentation.
+AstraKernel is an educational project created to demonstrate operating system concepts. It is currently in version and should be considered experimental software.
By using AstraKernel, you acknowledge that you understand these limitations.
+This project is licensed under the GNU General Public License. See the [LICENSE](LICENSE) file for details.
+|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
Go to the source code of this file.
++Functions | |
| void | interrupts_init_timer0 (uint32_t tick_hz, uint32_t timer_clk_hz) |
| VersatilePB SP804 timer clock is typically 1 MHz (can be overridden) | |
| void | irq_handler (void) |
| C-level IRQ handler called from assembly stub in start.s Must clear the source interrupt and (for VIC) write VIC_VECTADDR to ack end of interrupt. | |
| void | irq_disable (void) |
| void | irq_enable (void) |
+Variables | |
| volatile uint64_t | systicks = 0 |
| void interrupts_init_timer0 | +( | +uint32_t | tick_hz, | +
| + | + | uint32_t | timer_clk_hz ) | +
VersatilePB SP804 timer clock is typically 1 MHz (can be overridden)
+| tick_hz | desired tick frequency (e.g., 100) |
| timer_clk_hz | input clock to the SP804 (e.g., 1000000) |
Definition at line 14 of file interrupt.c.
+
+
|
+ +inline | +
Definition at line 53 of file interrupt.c.
+
+
|
+ +inline | +
Definition at line 58 of file interrupt.c.
+| void irq_handler | +( | +void | ) | ++ |
C-level IRQ handler called from assembly stub in start.s Must clear the source interrupt and (for VIC) write VIC_VECTADDR to ack end of interrupt.
+ +Definition at line 40 of file interrupt.c.
+ +| volatile uint64_t systicks = 0 | +
Definition at line 6 of file interrupt.c.
+ +|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+
#include <stdint.h>Go to the source code of this file.
++Macros | |
| #define | VIC_BASE 0x10140000u |
| #define | VIC_INTSELECT (*(volatile uint32_t *)(VIC_BASE + 0x00C)) |
| #define | VIC_INTENABLE (*(volatile uint32_t *)(VIC_BASE + 0x010)) |
| #define | VIC_INTENCLR (*(volatile utin32_t *)(VIC_BASE + 0x014)) |
| #define | VIC_SOFT_INT (*(volatile uint32_t *)(VIC_BASE + 0x018)) |
| #define | VIC_SOFT_INTCLR (*(volatile uint32_t *)(VIC_BASE + 0x01C)) |
| #define | VIC_IRQSTATUS (*(volatile uint32_t *)(VIC_BASE + 0x000)) |
| #define | VIC_VECTADDR (*(volatile uint32_t *)(VIC_BASE + 0x030)) |
| #define | VIC_DEFVECTADDR (*(volatile uint32_t *)(VIC_BASE + 0x034)) |
| #define | T01_BASE 0x101E2000u |
| #define | T0_LOAD (*(volatile uint32_t *)(T01_BASE + 0x00)) |
| #define | T0_VALUE (*(volatile uint32_t *)(T01_BASE + 0x04)) |
| #define | T0_CONTROL (*(volatile uint32_t *)(T01_BASE + 0x08)) |
| #define | T0_INTCLR (*(volatile uint32_t *)(T01_BASE + 0x0C)) |
| #define | T0_MIS (*(volatile uint32_t *)(T01_BASE + 0x14)) |
| #define | TCTRL_ENABLE (1u << 7) |
| #define | TCTRL_PERIODIC (1u << 6) |
| #define | TCTRL_INTEN (1u << 5) |
| #define | TCTRL_32BIT (1u << 1) |
| #define | IRQ_TIMER01 4 |
+Functions | |
| void | irq_handler (void) |
| C-level IRQ handler called from assembly stub in start.s Must clear the source interrupt and (for VIC) write VIC_VECTADDR to ack end of interrupt. | |
| void | irq_enable (void) |
| void | irq_disable (void) |
| void | interrupts_init_timer0 (uint32_t tick_hz, uint32_t timer_clk_hz) |
| VersatilePB SP804 timer clock is typically 1 MHz (can be overridden) | |
| static void | timer0_start_periodic (uint32_t load) |
| static void | vic_enable_timer01_irq (void) |
| #define IRQ_TIMER01 4 | +
Definition at line 40 of file interrupt.h.
+ +| #define T01_BASE 0x101E2000u | +
Definition at line 25 of file interrupt.h.
+ +| #define T0_CONTROL (*(volatile uint32_t *)(T01_BASE + 0x08)) | +
Definition at line 28 of file interrupt.h.
+ +| #define T0_INTCLR (*(volatile uint32_t *)(T01_BASE + 0x0C)) | +
Definition at line 29 of file interrupt.h.
+ +| #define T0_LOAD (*(volatile uint32_t *)(T01_BASE + 0x00)) | +
Definition at line 26 of file interrupt.h.
+ +| #define T0_MIS (*(volatile uint32_t *)(T01_BASE + 0x14)) | +
Definition at line 30 of file interrupt.h.
+ +| #define T0_VALUE (*(volatile uint32_t *)(T01_BASE + 0x04)) | +
Definition at line 27 of file interrupt.h.
+ +| #define TCTRL_32BIT (1u << 1) | +
Definition at line 37 of file interrupt.h.
+ +| #define TCTRL_ENABLE (1u << 7) | +
Definition at line 34 of file interrupt.h.
+ +| #define TCTRL_INTEN (1u << 5) | +
Definition at line 36 of file interrupt.h.
+ +| #define TCTRL_PERIODIC (1u << 6) | +
Definition at line 35 of file interrupt.h.
+ +| #define VIC_BASE 0x10140000u | +
Definition at line 12 of file interrupt.h.
+ +| #define VIC_DEFVECTADDR (*(volatile uint32_t *)(VIC_BASE + 0x034)) | +
Definition at line 21 of file interrupt.h.
+ +| #define VIC_INTENABLE (*(volatile uint32_t *)(VIC_BASE + 0x010)) | +
Definition at line 14 of file interrupt.h.
+ +| #define VIC_INTENCLR (*(volatile utin32_t *)(VIC_BASE + 0x014)) | +
Definition at line 15 of file interrupt.h.
+ +| #define VIC_INTSELECT (*(volatile uint32_t *)(VIC_BASE + 0x00C)) | +
Definition at line 13 of file interrupt.h.
+ +| #define VIC_IRQSTATUS (*(volatile uint32_t *)(VIC_BASE + 0x000)) | +
Definition at line 19 of file interrupt.h.
+ +| #define VIC_SOFT_INT (*(volatile uint32_t *)(VIC_BASE + 0x018)) | +
Definition at line 16 of file interrupt.h.
+ +| #define VIC_SOFT_INTCLR (*(volatile uint32_t *)(VIC_BASE + 0x01C)) | +
Definition at line 17 of file interrupt.h.
+ +| #define VIC_VECTADDR (*(volatile uint32_t *)(VIC_BASE + 0x030)) | +
Definition at line 20 of file interrupt.h.
+ +| void interrupts_init_timer0 | +( | +uint32_t | tick_hz, | +
| + | + | uint32_t | timer_clk_hz ) | +
VersatilePB SP804 timer clock is typically 1 MHz (can be overridden)
+| tick_hz | desired tick frequency (e.g., 100) |
| timer_clk_hz | input clock to the SP804 (e.g., 1000000) |
Definition at line 14 of file interrupt.c.
+
+
|
+ +inline | +
Definition at line 53 of file interrupt.c.
+
+
|
+ +inline | +
Definition at line 58 of file interrupt.c.
+| void irq_handler | +( | +void | ) | ++ |
C-level IRQ handler called from assembly stub in start.s Must clear the source interrupt and (for VIC) write VIC_VECTADDR to ack end of interrupt.
+ +Definition at line 40 of file interrupt.c.
+ +
+
|
+ +inlinestatic | +
Definition at line 48 of file interrupt.h.
+
+
|
+ +inlinestatic | +
Definition at line 56 of file interrupt.h.
+|
+ AstraKernel v0.1.0
+
+ A minimalist experimental ARM kernel
+ |
+