Creativsion support added to cc65

Talk about programming CreatiVision (except games programming). Projects of homebrew hardware are also welcome.
sannyx
Posts: 10
Joined: Tue Feb 07, 2017 2:06 pm

Creativsion support added to cc65

Post by sannyx » Wed Feb 22, 2017 12:15 pm

Hi,

since last week cc65 supports the CV "out of the box".

Compile with -t creativsion, like "cl65 -t creativision -o rom.bin prog.c".

The joystick driver still needs some work, currently it doesn't detect combined directions (e.g. left/up or right/down).

Many thanks to cvemu (I think that's @username@ over here) for the inital port.

regards,
chris
User avatar
MADrigal
Site Admin
Posts: 952
Joined: Sun Sep 15, 2013 1:00 pm
Contact:

Re: Creativsion support added to cc65

Post by MADrigal » Thu Feb 23, 2017 11:24 am

Good stuff!!!!
sannyx
Posts: 10
Joined: Tue Feb 07, 2017 2:06 pm

Re: Creativsion support added to cc65

Post by sannyx » Wed Mar 08, 2017 12:52 pm

Joystick driver is fixed in latest cc65 git version or tomorrow's snapshot.

Note that https://sourceforge.net/projects/creativisionemulator uses wrong values for diagonal joystick movement, so there still only left/right/up/down work, and no combination of them.

I works on a real CV console.
User avatar
Scouter3d
Posts: 265
Joined: Mon Jun 28, 2010 7:02 am
Location: Wien
Contact:

Re: Creativsion support added to cc65

Post by Scouter3d » Wed Mar 08, 2017 3:20 pm

Hi,

I hope you are aware, that the CV Joystick has 16 directions... 8 directions and their combinations...
like UP, UP-DIAG_RIGHT, DIAG_RIGHT, DIAG_RIGHT-RIGHT, RIGHT...
Games become very hard to steer if the "inbetweens" are not considered...

Greetings, TOM:0)
User avatar
Scouter3d
Posts: 265
Joined: Mon Jun 28, 2010 7:02 am
Location: Wien
Contact:

Re: Creativsion support added to cc65

Post by Scouter3d » Wed Mar 08, 2017 3:32 pm

Hi again,

I would love to see the cc65 for the Creativision grow into an even easier toolset for the CV (Easy Graphic libraries, Sprite libraries, Sound, maybe even Scrolling?) So that it would be "easy" to program (small) games in C without the need of Assembly Code (i can´t come to grips with assembly since 1984, but then again i haven´t tried very hard ;0))

TOM:0) dreaming of being able to program his own games for the CV ;0)
sannyx
Posts: 10
Joined: Tue Feb 07, 2017 2:06 pm

Re: Creativsion support added to cc65

Post by sannyx » Wed Mar 08, 2017 5:55 pm

Scouter3d wrote: I hope you are aware, that the CV Joystick has 16 directions... 8 directions and their combinations...
like UP, UP-DIAG_RIGHT, DIAG_RIGHT, DIAG_RIGHT-RIGHT, RIGHT...
Games become very hard to steer if the "inbetweens" are not considered...

Yes, I'm aware of that. And that is fully supported by the cc65 joystick driver.

I'm just noticed that on creativisonemulator, e.g. address at $11 (direction of left joystick) contains "wrong" values for diagonal positions.

These are the possible values, found out with the zpvars-test-new.rom program from the other thread:

Code: Select all

; port values: (compass points)
; N      -  $49 - %01001001
; NNE    -  $48 - %01001000
; NE     -  $47 - %01000111
; ENE    -  $46 - %01000110
; E      -  $45 - %01000101
; ESE    -  $44 - %01000100
; SE     -  $43 - %01000011
; SSE    -  $42 - %01000010
; S      -  $41 - %01000001
; SSW    -  $40 - %01000000
; SW     -  $4F - %01001111
; WSW    -  $4E - %01001110
; W      -  $4D - %01001101
; WNW    -  $4C - %01001100
; NW     -  $4B - %01001011
; NNW    -  $4A - %01001010
; center -  $00 - %00000000
But diagonal postions in creativisionemulator have the MSB set, so values in the $80 range.

regards,
chris
sannyx
Posts: 10
Joined: Tue Feb 07, 2017 2:06 pm

Re: Creativsion support added to cc65

Post by sannyx » Wed Mar 08, 2017 5:58 pm

Scouter3d wrote: I would love to see the cc65 for the Creativision grow into an even easier toolset for the CV (Easy Graphic libraries, Sprite libraries, Sound, maybe even Scrolling?)

Yes. But if the functions are too special they might not become part of the cc65 runtime lib. But we always could create a separate addon lib.

regards,
chris
Fabrizio Caruso
Posts: 14
Joined: Mon Feb 05, 2018 9:23 am
Contact:

Re: Creativsion support added to cc65

Post by Fabrizio Caruso » Mon Feb 05, 2018 2:27 pm

Has anyone here figured out how compile a 16k rom with CC65?
I am only able to create 8k roms with code in $A000-$BFFF.
Anything different will generate a non-functional rom.
Remark: I know the memory map. I know $8000-$BFFF should be possible but CC65 will create a rom file that won't even start
if I set $8000-$BFFF.
sannyx
Posts: 10
Joined: Tue Feb 07, 2017 2:06 pm

Re: Creativsion support added to cc65

Post by sannyx » Wed Feb 07, 2018 1:36 pm

Fabrizio Caruso wrote:Has anyone here figured out how compile a 16k rom with CC65?
I am only able to create 8k roms with code in $A000-$BFFF.
Anything different will generate a non-functional rom.
Remark: I know the memory map. I know $8000-$BFFF should be possible but CC65 will create a rom file that won't even start
if I set $8000-$BFFF.
Look at the XMas-Demo source code at http://www.madrigaldesign.it/creativemu/roms.php .
I appears that the 8K banks are reversed, so A000-BFFF at the beginning, and 8000-9FFF at the end.

Don't know if and how that would work on real hardware. Does anybody know?
User avatar
MADrigal
Site Admin
Posts: 952
Joined: Sun Sep 15, 2013 1:00 pm
Contact:

Re: Creativsion support added to cc65

Post by MADrigal » Thu Feb 08, 2018 9:02 am

The 16K roms available for download on the CreatiVEmu website are made to work on the FunnyMu emulator and yes, they have the 8K banks reversed. This was done to follow the format of the 10K and 12K roms, that are also reversed, and this reflects how the eproms fit in the cartridges.

The Xmas demo (as far as I know) was not done with CC65, it was coded in pure ASM.
Post Reply