[Done v2.0.0a3 + a4] Add some extra commands to songtoaky

What is Arkos Tracker? Forums Arkos Tracker forum Feature requests [Done v2.0.0a3 + a4] Add some extra commands to songtoaky

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #872
    ggn
    Participant

    Hi,

    In an effort to export and include source easier for ST, I’d like to start using songtoaky instead of exporting from the player. However I’m missing a couple of features present in the editor, and not only:

    – No colon to separate 2 db/dw/etc instructions. Write each instruction in its own line
    – Labels postfix option. Necessary as some assemblers require a label to end in a colon
    – Make all song offsets relative to 0. For now I’m using a sed command to simply insert a ‘-song_start’ at each file (like https://github.com/ggnkua/Arkos-Tracker-2-ST/blob/master/tunes/Interleave%20THIS!%20014.s#L4179), would be great if this could happen during export.

    For the last item it could be argued that I could simply assemble the exported source to binary blob at absolute address 0 but that would remove some of its usability. For example XiA asked me if it would be possible to manipulate the linker data directly at runtime. It’d be super trivial to do if the source of the tune is assembled with the code, less trivial with a binary blob.

    #879

    I was also looking at the portability of the song asm file generated. It’s customizable now under FILE->SETUP->SOURCE_PROFILES which will solve post-colon for labels and using different directives for db and dw.

    I’m not sure I understand the need for song offsets relative to 0 in an asm file. You set the org to 0, assemble it and it’s done, unless I misunderstand?

    #880

    (EDIT button for posts does not work btw)

    Just adding: I would second removal of colon separate statements since that’s not too common among assemblers. I haven’t seen that myself though.

    #881
    Targhan
    Keymaster

    (yeah, edit does not work. It’s just a forum, I’m not really going to debug this :)).

    Point 1 & 2: the next version include all the mnemonic override from command line, so everything you can make in the Source Profile will be doable from CLI.
    Point 3: still not sure it would be a good idea, but we’ll see in a close future.

    Also, the next version will allow you to have only one different type of instruction in the same line.

    I should really finish this alpha3 version. I’ll try to finish it within a week or two, please be patient and stop harassing me with bug fixes and feature requests :).

    #882
    ggn
    Participant

    “I’m not sure I understand the need for song offsets relative to 0 in an asm file. You set the org to 0, assemble it and it’s done, unless I misunderstand?”

    Let me try to summarise the reasons very quickly:

    a) The ST by default runs programs that are position independent (unless you’re making boot demos or games)
    b) Because of this, you can’t create a standard ST prg and have “org” in your source anywhere
    c) The only way to make something like that would be to create a different binary and assemble it using “org” 0, then including it as binary on the main source
    d) But (c) means that then you lose the song’s labels. I had a discussion where the musician would like to change the order of patterns during runtime, very simple if you have the labels inside the main source

    This is what the ST player assumes for now. Worst case I can keep the awful sed commands as a post process step when exporting a tune or do some extra init at runtime to get all song labels relative to song start.

    #910
    Admin
    Keymaster

    Ok, now that the Alpha3 is released, I’ll check on that relative feature you want. So to be sure to get this right, I need to subtract the beginning of the song to ALL the reference to the addresses, is it right?

    #929
    ggn
    Participant

    Yes! something like:

    dc.w 128 ;Duration in frames.
    dc.w Main_Subsong0_Track_6-Main_Subsong0
    dc.w Main_Subsong0_Track_13-Main_Subsong0
    dc.w Main_Subsong0_Track_14-Main_Subsong0

    (a full example here: https://github.com/ggnkua/Arkos-Tracker-2-ST/blob/master/tunes/Interleave%20THIS!%20014.s)

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.