2 ; Groepaz/Hitmen, 19.10.2015
4 ; high level implementation for the monochrome soft80 implementation
6 ; unsigned char __fastcall__ textcolor (unsigned char color);
7 ; unsigned char __fastcall__ bgcolor (unsigned char color);
10 .export soft80mono_textcolor, soft80mono_bgcolor
11 .import soft80mono_internal_cellcolor, soft80mono_internal_bgcolor
19 ldx CHARCOLOR ; get old value
20 stx tmp1 ; save old value
21 sta CHARCOLOR ; set new value
24 lda soft80mono_internal_bgcolor
30 sta soft80mono_internal_cellcolor ; text/bg combo for new chars
34 lda #$34 ; enable RAM under I/O
37 lda soft80mono_internal_cellcolor
42 sta soft80_vram+$100,x
43 sta soft80_vram+$200,x
44 sta soft80_vram+$2e8,x
51 lda tmp1 ; get old value
55 ldx soft80mono_internal_bgcolor ; get old value
56 stx tmp1 ; save old value
57 sta soft80mono_internal_bgcolor ; set new value
61 ;-------------------------------------------------------------------------------
62 ; force the init constructor to be imported
64 .import soft80mono_init
65 conio_init = soft80mono_init