Author Topic: cpctelera arkos 2 conversion problem  (Read 3405 times)

0 Members and 1 Guest are viewing this topic.

Offline Targhan

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.217
  • Country: fr
  • Liked: 1181
  • Likes Given: 172
Re: cpctelera arkos 2 conversion problem
« Reply #25 on: 12:16, 25 November 20 »
Mmmh, I don't know cpctelera or the scripts you're using, but why do you use the "spbyte" "spword" on export? Export the song normally, and use Disark to convert the source properly into a format understood by SDCC.
Targhan/Arkos

Arkos Tracker 2.0.0 now released! - Follow the news on Twitter!
Disark - A cross-platform Z80 disassembler/source converter
FDC Tool 1.1 - Read Amsdos files without the system

Imperial Mahjong
Orion Prime

Offline cperezgrin

  • CPC464
  • **
  • Posts: 30
  • Country: es
  • Liked: 15
  • Likes Given: 5
Re: cpctelera arkos 2 conversion problem
« Reply #26 on: 15:33, 25 November 20 »
Hi, because I don't really know what I'm doing  :picard: . My knowledge about ASM, binary, ... is very short. I saw a way to convert aks files to LightWeight that works in cpctelera. So, I thought converting it to AKG could be in a similar way.
Also, I don't know how to use Disark to convert the .asm genereted from SongToAkg.exe into a file that would read cpctelera. I'm used to Arkos1 songs, where I only need to write a line in a cfg file.

Offline Targhan

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.217
  • Country: fr
  • Liked: 1181
  • Likes Given: 172
Re: cpctelera arkos 2 conversion problem
« Reply #27 on: 15:57, 25 November 20 »
We've got a tutorial about all that that is being currently proofreading, so don't worry too much. I'll notify as soon as it is up.
Targhan/Arkos

Arkos Tracker 2.0.0 now released! - Follow the news on Twitter!
Disark - A cross-platform Z80 disassembler/source converter
FDC Tool 1.1 - Read Amsdos files without the system

Imperial Mahjong
Orion Prime

Offline Targhan

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.217
  • Country: fr
  • Liked: 1181
  • Likes Given: 172
Re: cpctelera arkos 2 conversion problem
« Reply #28 on: 16:00, 25 November 20 »
In the meantime, everything about Disark is explained here:
http://www.julien-nevo.com/arkostracker/index.php/using-a-song-in-production-using-any-assembler/

That, plus the various files above in this thread, and you might be able to sort this out on your own.. Or ask for help or wait for the tutorial :).
Targhan/Arkos

Arkos Tracker 2.0.0 now released! - Follow the news on Twitter!
Disark - A cross-platform Z80 disassembler/source converter
FDC Tool 1.1 - Read Amsdos files without the system

Imperial Mahjong
Orion Prime

Offline prototano

  • CPC464
  • **
  • Posts: 10
  • Country: es
  • Liked: 27
  • Likes Given: 6
Re: cpctelera arkos 2 conversion problem
« Reply #29 on: 17:34, 25 November 20 »
@cperezgrin I have attach a working project with AKG, But it's including de arkostraker2 tools and rasm compiled for linux. If you are using windows you will have to replace them for their corresponding version and maybe some minor changes on cfg/music_conversion.mk.

De makefile rules that I made will generate the following commands:

#Generates a intermediate folder

mkdir -p obj/__aks2

touch obj/__aks2/.folder

#Converts the song

arkostraker2utils/SongToAkg assets/sound/music.aks obj/__aks2/music1.asm --exportPlayerConfig --labelPrefix

music1_arkostraker2utils/rasm obj/__aks2/music1.asm -o obj/__aks2/music1 -s -sl -sq

arkostraker2utils/Disark obj/__aks2/music1.bin src/assets/sound/music1.s --symbolFile obj/__aks2/music1.sym --sourceProfile sdcc

# Converts the sfx

arkostraker2utils/SongToSoundEffects assets/sound/soundEffects.aks obj/__aks2/sfx.asm --exportPlayerConfig --labelPrefix sfx_

arkostraker2utils/rasm obj/__aks2/sfx.asm -o obj/__aks2/sfx -s -sl -sq

arkostraker2utils/Disark obj/__aks2/sfx.bin src/assets/sound/sfx.s --symbolFile obj/__aks2/sfx.sym --sourceProfile sdcc

# Converts the player

cp arkostraker2utils/players/PlayerAkg.asm obj/__aks2/PlayerAkg.asm

cp arkostraker2utils/players/PlayerAkg_SoundEffects.asm obj/__aks2/PlayerAkg_SoundEffects.asm

touch obj/__aks2/PlayerHead.asm

echo ""                                                          > obj/__aks2/PlayerHead.asm

echo 'PLY_AKG_HARDWARE_CPC = 1'                  >> obj/__aks2/PlayerHead.asm

echo 'PLY_AKG_MANAGE_SOUND_EFFECTS = 1'          >> obj/__aks2/PlayerHead.asm

echo 'include "music1_playerconfig.asm"' >> obj/__aks2/PlayerHead.asm ;

echo 'include "sfx_playerconfig.asm"'  >> obj/__aks2/PlayerHead.asm ;

echo 'include "PlayerAkg.asm"'                                   >> obj/__aks2/PlayerHead.asm

arkostraker2utils/rasm obj/__aks2/PlayerHead.asm -o obj/__aks2/PlayerAkg -s -sl -sq

arkostraker2utils/Disark obj/__aks2/PlayerAkg.bin src/assets/sound/PlayerAkg.s --symbolFile obj/__aks2/PlayerAkg.sym --sourceProfile sdcc
« Last Edit: 17:38, 25 November 20 by prototano »

Offline cperezgrin

  • CPC464
  • **
  • Posts: 30
  • Country: es
  • Liked: 15
  • Likes Given: 5
Re: cpctelera arkos 2 conversion problem
« Reply #30 on: 19:45, 25 November 20 »
Man, you really deserve a beer or whatever you want. What a great help to me!!
 Not only I have managed to make it play with a main.c (I can't code in ASM yet) but also I have integrated this into my current project very easy, with a few changes.
@ronaldo, if you have time (I know you haven't), take a look at prototano's code. He has integrate arkos2 in a very similar way as arkos1 is now. This should be easy to make cpctelera v1.6 compatible with arkos2. I haven't try sfx yet, but music plays ok!

Offline prototano

  • CPC464
  • **
  • Posts: 10
  • Country: es
  • Liked: 27
  • Likes Given: 6
Re: cpctelera arkos 2 conversion problem
« Reply #31 on: 23:22, 25 November 20 »
Man, you really deserve a beer or whatever you want. What a great help to me!!
 Not only I have managed to make it play with a main.c (I can't code in ASM yet) but also I have integrated this into my current project very easy, with a few changes.
@ronaldo, if you have time (I know you haven't), take a look at prototano's code. He has integrate arkos2 in a very similar way as arkos1 is now. This should be easy to make cpctelera v1.6 compatible with arkos2. I haven't try sfx yet, but music plays ok!
Thank you  :D
I already have integrated arkostracker2 on my cpctelera's fork (only with AKM player) and with C bindings that don't need any assembly code.
https://github.com/cmp102/cpctelera/tree/arkostracker2

But I think the way as I implemented it don't fit very well on the mainline cpctelera. The way to generate the songs and the player is a bit messy.


Offline cperezgrin

  • CPC464
  • **
  • Posts: 30
  • Country: es
  • Liked: 15
  • Likes Given: 5
Re: cpctelera arkos 2 conversion problem
« Reply #32 on: 09:40, 26 November 20 »
Messy, but functional in a very easy way. That's all I'm asking for :D
Thanks again