2004-10-08 20:23:15 +00:00
|
|
|
;
|
2018-04-10 18:37:10 +00:00
|
|
|
; Stefan Haubenthal, 2018-04-10
|
|
|
|
; Based on code by Mike
|
2004-10-08 20:23:15 +00:00
|
|
|
;
|
2012-03-04 13:08:54 +00:00
|
|
|
; unsigned char get_tv (void);
|
2004-10-08 20:23:15 +00:00
|
|
|
; /* Return the video mode the machine is using */
|
|
|
|
;
|
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
.include "get_tv.inc"
|
2004-10-08 20:23:15 +00:00
|
|
|
|
|
|
|
;--------------------------------------------------------------------------
|
|
|
|
; _get_tv
|
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
.proc _get_tv
|
2004-10-08 20:23:15 +00:00
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
; detect the system
|
|
|
|
lda #TV::NTSC
|
|
|
|
tax
|
2018-04-10 18:37:10 +00:00
|
|
|
ldy $EDE4 ; VIC init table
|
|
|
|
cpy #5
|
|
|
|
beq @L0
|
2013-05-09 11:56:54 +00:00
|
|
|
lda #TV::PAL
|
2018-04-10 18:37:10 +00:00
|
|
|
@L0: rts ; system detected: 0 for NTSC, 1 for PAL
|
2004-10-08 20:23:15 +00:00
|
|
|
|
|
|
|
.endproc
|