1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2024-12-11 02:49:22 +00:00
8bitworkshop/presets/astrocade/skeleton.sdcc

35 lines
692 B
Plaintext
Raw Normal View History

2018-08-29 01:41:51 +00:00
2019-06-02 02:09:45 +00:00
//#resource "astrocade.inc"
#include "aclib.h"
//#link "aclib.s"
2019-05-29 01:05:19 +00:00
#include "acbios.h"
//#link "acbios.s"
2019-06-02 02:09:45 +00:00
//#link "hdr_autostart.s"
2018-08-29 01:41:51 +00:00
#include <stdlib.h>
2018-08-29 01:41:51 +00:00
#include <string.h>
2019-05-29 01:05:19 +00:00
/*{pal:"astrocade",layout:"astrocade"}*/
const byte palette[8] = {
0x77, 0xD4, 0x35, 0x01,
0x07, 0xD4, 0x35, 0x01,
};
2019-05-29 01:05:19 +00:00
void main(void) {
// setup palette
set_palette(palette);
// set screen height
// set horizontal color split (position / 4)
// set interrupt status
SYS_SETOUT(89*2, 23, 0);
2019-06-02 02:09:45 +00:00
// clear screen
SYS_FILL(0x4000, 89*40, 0);
2019-05-29 01:05:19 +00:00
// display standard characters
display_string(2, 2, OPT_ON(1), "HELLO, WORLD!!");
// infinite loop
2019-05-29 01:05:19 +00:00
activate_interrupts();
while (1) {
2019-05-29 01:05:19 +00:00
sleep(1);
}
2018-08-29 01:41:51 +00:00
}