что поделать когда trdos, мягко говоря, не идеален... :)
Вид для печати
well.. replace it with something better? I would suggest to fork and fix it, but it's not open IIRC, the license is prohibitive... which brings me back to my lamenting about people using the most painful options available, causing harm to themselves and still even touting it as best/only option. Situations like this learned me to pick up my SW carefully and pay attention to licenses and source availability, and to value this strongly even over some neat features. Those help in short-term, but in long-term the closed stuff is just pain in ass, I definitely replace it whenever possible with more open options, even if I have to somewhat fix them (looking at you sjasmplus, costing me year+ of my life, instead of writing some ZXNext games ... sigh)
- - - Updated - - -
Ok, now back to those two TRD files... the first disk contains the "80 AA 01 00" autostart bytes after the 250th byte of BASIC.
So changing your:
toКод:ORG $C000, 7 ; "page 7"
incbin "TRD/boot.B"
SAVETRD "my_test.trd","boot.B",$C000,$100,$1
*should* work... ... I'm going to try myself and edit this post if I fail... but I don't see any reason why it would not work.Код:ORG $C000, 7 ; "page 7"
incbin "TRD/boot.B"
SAVETRD "my_test.trd","boot.B",$C000,250,$1
EDIT:
so your original trd (with three letter extensions and autostart) on my disk is "orig.trd" (I renamed it to keep track which is which), and your sjasmplus produced is "sjasmplus.trd" ... I can assemble the two disc together (with current git master) with this code:
This is the result:Код:DEVICE ZXSPECTRUM1024
EMPTYTRD "ped.trd"
ORG 0 : INCTRD "orig.trd", "boot.B"
SAVETRD "ped.trd", "boot.B", 0, 250, 1
ORG 0 : INCTRD "sjasmplus.trd", "my_test.C"
SAVETRD "ped.trd", "my_test.bin", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "pent.C"
SAVETRD "ped.trd", "pent.scr", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy00.C"
SAVETRD "ped.trd", "dizzy00.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy01.C"
SAVETRD "ped.trd", "dizzy_0.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy02.C"
SAVETRD "ped.trd", "dizzy_1.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy03.C"
SAVETRD "ped.trd", "dizzy_2.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy04.C"
SAVETRD "ped.trd", "dizzy_3.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "dizzy05.C"
SAVETRD "ped.trd", "dizzy04.pak", 0, $ ; ok
ORG 0 : INCTRD "sjasmplus.trd", "press.C"
SAVETRD "ped.trd", "press.scr", 0, $ ; ok
Вложение 73034
Please try if it works... it is different in four bytes, the disc label in original has extra two spaces (sjasmplus keeps it only 8 chars long, not 10), and the two bytes in boot.B sector after the auto-start mark are also "00 00" from assembler, but your original disc has "35 36" there ... should be just garbage, not affecting anything, as far as I know.
BTW, why I do use INCTRD over both trd files to create this example? Because INCTRD in sjasmplus does not support 3-letter extensions, so I can't easily include the original files...
:D :D :D ... irony..
Ok, that's maybe one more thing to fix before v1.15.1 release...
это звучит как
"выкинуть zx spectrum 128 toast rack
и купить вместо ibm pc with core i9"
+tr dos прошит в ПЗУ
и не каждый его вообще может как либо обновить
на реальном железе
приходиться использовать то что есть
менять что либо уже поздно
некоторые вообще продолжают упорно пытаться писать только под 48к
несмотря ни на что...
...а результат как правило плохой...
- - - Добавлено - - -
теперь я тоже поддерживаю 3-х буквенные расширения :v2_dizzy_indy:
https://jpegshare.net/images/57/6b/5...47c9f9fd75.png
- - - Добавлено - - -
у меня 54 версии программы
для этого нужно будет 54 rules.txt :v2_dizzy_facepalm:
нужен препроцессор который сам будет запускать 54 раза sjasm
по одному правилу
+ не которые варианты не всегда собираются (тк может не хватать памяти)
и нужно рассматривать и вникать в сообщения
а как внешний препроцессор заменит что либо во всех условно подключаемых include-ах ?
никак...
And INCTRD refactored too, now it supports the unofficial 3-letter extensions just like SAVETRD
I guess today (+-5 days) the v1.15.1 will be released, depends how z00m has time to build the binaries and verify the packages.
(but if no more problems appear, what is current last commit in git will become v1.15.1)
Да, ваш пример работает верно, как задумывал аффтор :) Это же чисто для проверки, если по нажатию клавиш 1-7 на экране рисуются различные картинки из Диззи - значит файлы в образе расположены в правильном порядке. Это я учусь распихивать файлы по различным банкам памяти :v2_dizzy_indy:
Чтото средствами sjasm, что-то скриптами и внешними программами.
Ну можно например сохранять логи в отдельных файлах или попытаться отслеживать "Pass 3 complete" и "Errors: 0,".
Как запрограммируешь так и заменит.
https://github.com/z00m128/sjasmplus...es/tag/v1.15.1
- mostly TRD related changes
новая версия выдает 100500 предупреждений на adp
adp.asm(417): warning: When lua script emits machine code bytes, use "ALLPASS" m
odifier
https://jpegshare.net/images/b3/87/b...655552cc4a.png
- - - Добавлено - - -
можно подробней про то
когда выдается такое предупреждение?
вариант делать allpass по моему не приемлемый
по моему я эксперементальным путем подбирал номера проходов чтоб все работало
чисто на вид полученный код работает
я уже совершенно не помню как это все работает :v2_dizzy_vodka:
и почему
Код:;FAST TAB macro pg00
;по окончанию PASS2 уже установлен новый org!
macro fasttab_allocate_macro_pg00 _fasttab_alloc_page_for_table_pg00?, _fasttab_alloc_table_haddr_pg00?, _fasttab_alloc_procedure_number_pg00?
@__fasttab_allocate_page_for_table_pg00 = _fasttab_alloc_page_for_table_pg00?
@__fasttab_allocate_table_haddr_pg00 = _fasttab_alloc_table_haddr_pg00?
@__fasttab_allocate_procedure_number_pg00 = _fasttab_alloc_procedure_number_pg00?
@__fasttab_allocate_macro_current_addr_pg00 = $ ;бекап адреса
;display "fasttab_allocate_macro_current_addr_pg00 ",@__fasttab_allocate_macro_current_addr_pg00
;чтение состояния слотов
org $0000
@__fasttab_allocate_macro_current_slot0_pg00 = $$
;display "fasttab_allocate_macro_current_slot0_pg00 ",@__fasttab_allocate_macro_current_slot0_pg00
org $4000
@__fasttab_allocate_macro_current_slot1_pg00 = $$
;display "fasttab_allocate_macro_current_slot1_pg00 ",@__fasttab_allocate_macro_current_slot1_pg00
org $8000
@__fasttab_allocate_macro_current_slot2_pg00 = $$
;display "fasttab_allocate_macro_current_slot2_pg00 ",@__fasttab_allocate_macro_current_slot2_pg00
org $C000
@__fasttab_allocate_macro_current_slot3_pg00 = $$
;display "fasttab_allocate_macro_current_slot3_pg00 ",@__fasttab_allocate_macro_current_slot3_pg00
;
; ;востановление адреса
org @__fasttab_allocate_macro_current_addr_pg00
; display "current addr check ",$
lua pass1
lua_fasttab_allocate_procedure_start_addr_pg00[(_c("__fasttab_allocate_table_haddr_pg00"))][(_c("__fasttab_allocate_procedure_number_pg00"))] = _c("$")
endlua
lua allpass
lua_function_fasttab_allocate_pg00((_c("__fasttab_allocate_table_haddr_pg00")),(_c("__fasttab_allocate_procedure_number_pg00")))
endlua
lua pass2 ;copy
if lua_fasttab_allocator_page_finded_pg00 == 1 then
_pc("slot 0")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 1")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 2")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 3")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc(string.format("org $%04x", _c("__fasttab_allocate_table_haddr_pg00 * 256") + (_c("__fasttab_allocate_procedure_number_pg00"))))
_pc(string.format("defb $%02x", lua_fasttab_allocator_new_h_org_pg00))
_pc("slot 0")
_pc("page @__fasttab_allocate_macro_current_slot0_pg00")
_pc("slot 1")
_pc("page @__fasttab_allocate_macro_current_slot1_pg00")
_pc("slot 2")
_pc("page @__fasttab_allocate_macro_current_slot2_pg00")
_pc("slot 3")
_pc("page @__fasttab_allocate_macro_current_slot3_pg00")
_pc(string.format("org $%04x", lua_fasttab_allocator_new_h_org_pg00*256 + (_c("__fasttab_allocate_procedure_number_pg00"))))
end
endlua
lua pass3 ;
if lua_fasttab_allocator_page_finded_pg00 == 1 then
_pc("slot 0")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 1")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 2")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc("slot 3")
_pc("page @__fasttab_allocate_page_for_table_pg00 ")
_pc(string.format("org $%04x", _c("__fasttab_allocate_table_haddr_pg00 * 256") + (_c("__fasttab_allocate_procedure_number_pg00"))))
_pc(string.format("defb $%02x", lua_fasttab_allocator_new_h_org_pg00))
_pc("slot 0")
_pc("page @__fasttab_allocate_macro_current_slot0_pg00")
_pc("slot 1")
_pc("page @__fasttab_allocate_macro_current_slot1_pg00")
_pc("slot 2")
_pc("page @__fasttab_allocate_macro_current_slot2_pg00")
_pc("slot 3")
_pc("page @__fasttab_allocate_macro_current_slot3_pg00")
_pc(string.format("org $%04x", lua_fasttab_allocator_new_h_org_pg00*256 + (_c("__fasttab_allocate_procedure_number_pg00"))))
end
endlua
endm
в принципе если это предупреждение представляет какую либо? ценность
и его можно будет убрать например так
lua pass1 ;ok
lua pass2 ;ok
lua pass3 ;ok
то можно будет заменить все авто заменой
hmm... yeah, I guess you are very special case, when the warning is actually wrong, and your precise pass1/allpass is used as designed and correctly.
(usually missing "allpass" with machine code emitted is just simple bug, but your code is lot more complicated case).
I was trying to add "suppress warning" mechanics on the "endlua" area, but I failed there miserably (not so easy), so that's why the warning can't be suppressed in v1.15.1.
I will explore your idea of suppressing it at the beginning `lua` line, that may be possible.
meanwhile, if you have this construct in separate module, consider to switch off warnings globally by `--msg=err` level, producing only errors, or to use v1.15.0 for the moment. Sorry for the inconvenience, but I didn't think about such complex case, while the warning did help me to catch many common cases, where just add "allpass" is solution.