annotate kernel/kernel.c3 @ 350:2b02bd286fe9

Fixed A9 hello worle
author Windel Bouwman
date Sat, 08 Mar 2014 16:29:03 +0100
parents c7cc54c0dfdf
children 899ae3aea803
rev   line source
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
1 module kernel;
292
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
2
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
3 import memory;
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
4 import process;
292
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
5 import scheduler;
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
6 import arch;
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
7
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
8 // Main entry point of the kernel:
293
6aa721e7b10b Try to improve build sequence
Windel Bouwman
parents: 292
diff changeset
9 function void start()
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
10 {
340
c7cc54c0dfdf Test featurebranch
Windel Bouwman
parents: 308
diff changeset
11 var int* UART0DR;
c7cc54c0dfdf Test featurebranch
Windel Bouwman
parents: 308
diff changeset
12 UART0DR = cast<int*>(0x10009000); // UART0 Data register
c7cc54c0dfdf Test featurebranch
Windel Bouwman
parents: 308
diff changeset
13 *UART0DR = 72;
c7cc54c0dfdf Test featurebranch
Windel Bouwman
parents: 308
diff changeset
14
308
2e7f55319858 Merged analyse into codegenerator
Windel Bouwman
parents: 301
diff changeset
15 process.init();
301
6753763d3bec merge codegen into ppci package
Windel Bouwman
parents: 296
diff changeset
16 //memory:init();
292
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
17
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
18
296
9417caea2eb3 Directorized some backend files
Windel Bouwman
parents: 295
diff changeset
19 //Process proc = new process:Process();
292
534b94b40aa8 Fixup reorganize
Windel Bouwman
parents: 283
diff changeset
20
296
9417caea2eb3 Directorized some backend files
Windel Bouwman
parents: 295
diff changeset
21 //scheduler:queue(proc);
340
c7cc54c0dfdf Test featurebranch
Windel Bouwman
parents: 308
diff changeset
22 while(true) {}
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
23 }
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
24
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
25
293
6aa721e7b10b Try to improve build sequence
Windel Bouwman
parents: 292
diff changeset
26 function void panic()
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
27 {
308
2e7f55319858 Merged analyse into codegenerator
Windel Bouwman
parents: 301
diff changeset
28 arch.halt();
283
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
29 }
c9781c73e7e2 Added first kernel files
Windel Bouwman
parents:
diff changeset
30