.import zerobss, pushax
.import _main, __filetab, getfd
.import __CODE_LOAD__, __BSS_LOAD__
+.ifdef DYNAMIC_DD
+ .import __getdefdev
+.endif
.include "zeropage.inc"
.include "atari.inc"
; Call module constructors
jsr initlib
+.ifdef DYNAMIC_DD
+ jsr __getdefdev
+.endif
; set left margin to 0
.ifdef DEFAULT_DEVICE
.importzp tmp2
+.ifdef DYNAMIC_DD
+ .import __defdev
+.endif
.endif
.importzp tmp3,ptr4,sp
.import _strupr,subysp
lda #':'
sta (sp),y ; insert ':'
dey
- lda #'0' + DEFAULT_DEVICE
+.ifdef DYNAMIC_DD
+ lda __defdev+1
+.else
+ lda #'0'+DEFAULT_DEVICE
+.endif
sta (sp),y ; insert device number
dey
lda #'D'