ArkosTracker MSX playroutine, SDCC as-z80 syntax

Page 3/4
1 | 2 | | 4

By reidrac

Supporter (7)

reidrac's picture

21-10-2018, 07:54

ericb59 wrote:

Would be nice to have a C (SDCC) implementation of the TT Replayer

You only need to convert the ASM source to compile with SDCC assembler and add some entry points following C conventions. I ported the Arkos 2 lightweight player to SDCC and it took me a less than one hour.

By MsxKun

Paladin (865)

MsxKun's picture

21-10-2018, 13:34

JohnHassink wrote:

OPLL version is indeed still WIP, but the SCC version is pretty much done.
There's also two more versions of TT: one that's geared towards SMS chips, and one that's specially for dual PSG.

I saw those replayers on the folder, but the tracker is still the same?

JohnHassink wrote:

Note that it does require MSX-DOS 2.

Noted!

By ericb59

Paladin (744)

ericb59's picture

21-10-2018, 19:53

reidrac wrote:
ericb59 wrote:

Would be nice to have a C (SDCC) implementation of the TT Replayer

You only need to convert the ASM source to compile with SDCC assembler and add some entry points following C conventions. I ported the Arkos 2 lightweight player to SDCC and it took me a less than one hour.

So simple !
I'm not able to do such job oO

I only know C, not ASM.
Can you share you share your arkos 2 Player ? Does it work on MSX ?

By yzi

Champion (431)

yzi's picture

21-10-2018, 23:43

What are you trying to do, and how is whatever you have now not enough to do it?

By ericb59

Paladin (744)

ericb59's picture

22-10-2018, 09:41

yzi wrote:

What are you trying to do, and how is whatever you have now not enough to do it?

1- I'm building a complete SDCC C-Library for MSX, my purpose is to share this lib to every MSX user who want to program in C for MSX
2- I'm coding a game to demonstrate what this lib is able to do. Actual Game is Screen8 For MSX2 using MSXDOS. What I need now is libs for playing musics and sounds with C (Using SDCC) with and without MSX-DOS

By reidrac

Supporter (7)

reidrac's picture

22-10-2018, 13:08

ericb59 wrote:
yzi wrote:

What are you trying to do, and how is whatever you have now not enough to do it?

1- I'm building a complete SDCC C-Library for MSX, my purpose is to share this lib to every MSX user who want to program in C for MSX
2- I'm coding a game to demonstrate what this lib is able to do. Actual Game is Screen8 For MSX2 using MSXDOS. What I need now is libs for playing musics and sounds with C (Using SDCC) with and without MSX-DOS

IMHO you'll need some ASM to integrate things such as the player (btw, Arkos player uses self-modifying code, so it can't be used from ROM). For example: Arkos 2 doesn't support SDCC assembler neither comes with a C interface, so you'll have to convert it yourself and with any new Arkos release you'll have to port any changes to the SDCC version and/or adapt the C interface.

Then, when you sort all these issues, you'll have to deal with any bugs introduced by your changes!

This is where I am at the moment (I had done it already for the Amstrad CPC, experience counts). I will release things eventually, but I'm currently focusing on the game I'm making and I can't provide support or documentation.

I'm not saying it is impossible or that you should abandon your idea, but you'll need some knowledge to do it.

By Grauw

Enlighted (7466)

Grauw's picture

22-10-2018, 15:47

Don’t be discouraged by all the scary hubbub you tend to hear about assembly being difficult, it’s really not. In essence it’s all simple operations. It can just be a bit tedious, doing things that are more complicated.

By reidrac

Supporter (7)

reidrac's picture

22-10-2018, 15:50

Grauw wrote:

Don’t be discouraged by all the scary hubbub you tend to hear about assembly being difficult, it’s really not. In essence it’s all simple operations. It can just be a bit tedious, doing things that are more complicated.

Totally agree. Also is not like he needs to understand how to program the PSG. OK, there's some stuff to learn, but is not a lot.

By Wolverine_nl

Paladin (977)

Wolverine_nl's picture

22-10-2018, 16:59

Converting it to work with the SDCC assembler (SDA) can be done a few different ways. As a function with an inline assembly portion. so you can call the function when needed, or as a loose asm file, that you need to assemble, set in the commandline.
if you pre-defined a BIOS call, then you have to use a # before it, for instance: ld a, #CHPUT
and some things need to be changed like addresses, check the SDCC manual for the details, it is all explained.
I think it is doable.

By yzi

Champion (431)

yzi's picture

22-10-2018, 18:20

FWIW, we're still using the decade-old SDCC 2.9, because the 3.x series has been changed/broken so much that we haven't been motivated enough to port our old programs and libraries to it, and neither has anyone I know. Even though C is theoretically a high-level language, you still have to get your hands dirty with lower level stuff to survive making anything useful for 8-bit machines, particularly games.

Page 3/4
1 | 2 | | 4
My MSX profile