News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

cpcwiki logo rom for plus

Started by arnoldemu, 14:21, 12 October 12

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

arnoldemu

Here is a ROM i wrote for Plus. (It's written in C using SDCC and my "PlusLib").
You may find it annoying after a while. ;)

I hope the attachment works. First time I've attached something to a post.

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

robcfg

How should I set it up for it to work?

Gryzor

Ah damn, I got all excited, but I don't know what to do with it, either!

Terje_Norway

Hi,


I tried it in WinAPE, and it works like a dream  8)


So what did I do :
1.) Rename the file from .BIN to .ROM
2.) Start WinAPE in 6128 plus mode
3.) Install the .ROM and restart the software.


Working 100 %. Really nice picture and clear colors. Usefulness unknown  :-\


To those of You that haven't tried it, it works like putting a sticker with the CPCWiki logo on Your screen. It stays there all the time, even when running different software (at least it's there with the programs I have tried)


So thanks for a nice little program.


Yours

Terje Grind
NORWAY




robcfg

Could you be a little more specific in which parameters do I have to set up to which values?


I get either a black screen or the cartridge (Basic or Burnin Rubber)...

Terje_Norway

Hi,


This is perhaps going to be a bit to detailed, but if it can help it's probably worth it.


1.) Start WinAPE as usual.
2.) Go to SETTINGS and choose GENERAL, then You get to the WinAPE Setup.
3.) In GENERAL I have selected CRTC Type : 3-CPC + ASIC
4.) In Memory I have selected 128K - Enable Cartridge File : cpc_plus.cpr
5.) ROM is loaded into : Upper 8
6.) Reset WinAPE.


That should do the trick.


Yours

Terje Grind
NORWAY




Kris

I confirm it works on Winape as described above; and works also on real CPC+ :)
Could have been better with a CLS before display the hardsprite :)

Gryzor

Hahaha! This is fantastic!


I did try choosing it as a ROM initially, but I didn't rename it and WinAPE complained it's not a valid ROM file...


Interestingly, it works the same in mode 2, too!!
[attachimg=1]



TFM

Yeah! That's the magic of sprites ;)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

robcfg


TotO

#10
10/13/2012, CPC users discover CPC+ "iSprite"... It's a revolution. :-\
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

robcfg

Well, even almost all of the cpc+ catalogue doesn't use the plus features, so yeah, for most of us it's quite a surprise.


I think we should give the CPC+ some love  ;)

Gryzor

Well, yes, had no idea this could be done. Someone care to explain how? :)



tastefulmrship

#13
Quote from: Gryzor on 08:42, 14 October 12
Well, yes, had no idea this could be done. Someone care to explain how? :)
It's all to do with da magics!


Related infoz;
The not-so-loved Zeeloxyl demo has a nice CPC+ Cacodemon sprite as its last page.
http://www.pouet.net/prod.php?which=58115

A number of CPC+/GX4K games have MODE 1 sprites over MODE 0 backgrounds. That tennis game and the Rick Dangerous remake are two off the top of my head.

Gryzor

Hm, imagine that. Not that it explains how, but cool, will check the examples out.

How many colours are there?

SyX

Well, you can consider in the cpc+ there is two planes, one is the background and has the lower priority (the cpc only has this kind); and the other plane is where the sprites live, this plane has higher priority and because that is always printed over the background.

Of course, those planes can have different features, for example, different resolutions, and that is because you can mix a background in mode 2 with sprites in mode 0. Simply like that ;)

arnoldemu

Quote from: Gryzor on 10:22, 14 October 12
Hm, imagine that. Not that it explains how, but cool, will check the examples out.

How many colours are there?
15 colours.

I took the original image, I rescaled it with gimp, so that it would fit into 16 sprites.

Reduced colours to 16, one of which is the background.

It uses 15 sprites, in a 5x3 arrangement.

I used my own tools and my own library to make it.
I will publish my plus library, makefiles and source soon.

it's a bit of fun.

But what was not so fun was working out a way I could detect plus features in the upper ROM and without using any other ram.

On the CPC, out &7fb8 will switch out the upper rom!!!

So I used the stack. I wrote a small program (15 bytes) into the stack, executed it, and got my results.

:)

The plus lib can be used by others to make plus games/demos and now roms ;)
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TFM

Quote from: arnoldemu on 09:45, 15 October 12
On the CPC, out &7fb8 will switch out the upper rom!!!

Are you sure??? My FutureOS for the Plus does that without a problem (running in ROM), the ROM state seems not to be altered to me when using that OUT.
Ok, you do have to activate the Plus features first. But else this out would not make sense at all.
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

arnoldemu

#18
Quote from: TFM/FS on 19:55, 15 October 12
Are you sure??? My FutureOS for the Plus does that without a problem (running in ROM), the ROM state seems not to be altered to me when using that OUT.
Ok, you do have to activate the Plus features first. But else this out would not make sense at all.
Try it on a normal CPC. The ROM is compatible with CPC and Plus. It does nothing on the CPC, but also it doesn't crash.
7FB8 on a normal CPC is:

mode 0, lower rom enable, upper rom disable, raster interrupt clear. ;)
I enable the plus features, I open the ram page, and do a write to detect it exists. On a CPC, it will not work from upper rom.
With a plus it works fine ;)
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TFM

Oh, you talked about a CPC old Generation. Well I was talking about the Plus.

So why don't you just check if the machine is a Plus or not? That's more easy than to put a program in the stack (and maybe screw it, if the stack suffers heavy usage).

TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

arnoldemu

Quote from: TFM/FS on 15:37, 16 October 12
Oh, you talked about a CPC old Generation. Well I was talking about the Plus.

So why don't you just check if the machine is a Plus or not? That's more easy than to put a program in the stack (and maybe screw it, if the stack suffers heavy usage).

I am talking about both.

The ROM can be used on CPC and Plus. On CPC it does nothing, so it's useless here.
On Plus we see the result I wanted.

Now the ROM unlocks the ASIC and tests if there are plus features by enabling the plus ram, writing a value to the sprite pixel data and reading the result back.

It is this testing code that will not work from ROM if you have a CPC. It would crash on a CPC, and I didn't want that. I wanted it to do nothing.

So, I had to decide where to put this test code, and the best place, because I will not overwrite any other data and I will not use any more ram, is to put it onto the stack. I put the small code here (15 bytes) and execute it. It is ok, because the stack is not used much before this little test. So the code is only for testing to see if a plus exists.

The idea is that my pluslib can be used to make games that run in ram/rom/cart if you want with features for plus if it is detected.
So the code must be able to detect plus safely.

My aim is a rom based game (this is a project for next year). I plan to use 4 roms (1 background, 3 extension), and have the game run on cpc and plus. If plus is found it will activate plus features. I want it to run from ROM and use the RAM for screens and things.
It is a fun experiment I want to try.





My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TFM

Just check a byte of the ROM and you know if it is a Plus or not. Or you can check the cassette-read bit of the PIO.
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

tastefulmrship

#22
I'll try to find the post I got this from... I use this for all my CPC+ image conversions.

          ld    bc,&f782
          out    (c),c
          dec    b
          ld    a,&f
          out    (c),a
          inc    b
          out    (c),c
          dec    b
          in    c,(c)
          cp    c
          jr    z,CPC_Plus_Found
.CPC_Normal_Found


EDIT: The code above was sent to me by redbox via PM.

arnoldemu

Quote from: TFM/FS on 18:12, 16 October 12
Just check a byte of the ROM and you know if it is a Plus or not.
patched roms?

Quote from: TFM/FS on 18:12, 16 October 12
Or you can check the cassette-read bit of the PIO.
464 plus???
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TFM

Ok, any kind of test can be masked by a special modification.

But who uses a patched lower ROM on the Plus? 5-10.


Hmmm... finally you could check some CRTC registers, they should deliver clear results. And probably nobody will have a mod there.

But that's just a theoretical discussion. Your system works well, so why to change it. Nice conversion of the GFX btw. Good colors, not too big, not too small  :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

Powered by SMFPacks Menu Editor Mod