mirror of
https://codeberg.org/hkzlab/TK2048.git
synced 2026-01-04 03:29:19 +11:00
Begin with basic init
This commit is contained in:
parent
384d9b3fd1
commit
85ca4f19a2
5 changed files with 36 additions and 7 deletions
15
src/main.c
15
src/main.c
|
|
@ -9,9 +9,22 @@
|
|||
|
||||
#include "monitor_subroutines.h"
|
||||
|
||||
__task int main () {
|
||||
|
||||
// Low level initialization
|
||||
void __low_level_init(void) {
|
||||
POKE(P3_PWRDUP, 0); // Dirty the value checked by the reset vector
|
||||
PEEK(IO_ROMSEL); // Make sure the ROM is selected
|
||||
|
||||
PEEK(IO_DISPLAY_BW); // Disable colors
|
||||
PEEK(IO_DISPLAY_PAGE1); // Select the first display page
|
||||
|
||||
// Clear display memory
|
||||
memset((void*)DISPLAY_PAGE_1, 0, DISPLAY_PAGE_SIZE);
|
||||
memset((void*)DISPLAY_PAGE_2, 0, DISPLAY_PAGE_SIZE);
|
||||
}
|
||||
|
||||
__task int main(void) {
|
||||
|
||||
|
||||
while(1){
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue