Jump to content
IGNORED

coding


H.Hannig

Recommended Posts

Hi!

 

This is my first post here, so hello to all.

 

I've tried to persuade my brother Lars (Starcat) to do some PC coding beside Jag coding and in the end I've done some Jag coding beside PC coding :-)

 

It's nothing special but some kind of experiment about the "feeling" of the Jag from the coder's point of view. So these are just two quick "hello world" like hacks.

 

Since there aren't that much homebrew Demos for the Jag yet I decided to release them to the public.

 

 

Some general Information about usage:

 

- you can consider the binaries as PD

 

- since I don't own a jag I did the testing with Jaguar emulation (Project Tempest)

So don't expect them to run on a real Jag though I really hope they do

 

- If they don't run correct on a real Jag I will try my best to fix them when i have the time

 

- upload/start adress is 4000

 

something about my two mini progs:

 

JagPattern

Several years ago when I started VGA coding I accidently created this while I tried to code shadebobs. I liked it somehow and it became my 2D Bitmap graphics "hello world" later.

 

 

JagCube

I wanted to do something really small and simple in 3D on the Jag so I did this.

 

You can find the binaries at:

http://home.t-online.de/home/Holle.Hannig/

 

 

It's only small and simple stuff but I hope you like it

 

Regards,

Holger

Link to comment
Share on other sites

Since there aren't that much homebrew Demos for the Jag yet I decided to release them to the public.

Great to have another coder on board!

 

Please join jaguar-homebrew and create a directory archive there too!

 

Maybe you could add a web-page to your URL, with a couple of small

screen-shots, they don't have to be real screen-grabs, you can do the

same with a digital camera, but it would explain what they do to the

people who can't directly try them out.

 

As I already said, great to have another coder on board!

 

Cheers,

JustClaws.

Link to comment
Share on other sites

Hello!

 

- since I don't own a jag I did the testing with Jaguar emulation (Project Tempest)  

 So don't expect them to run on a real Jag though I really hope they do

 

- If they don't run correct on a real Jag I will try my best to fix them when  i have the time

 

Both programs work but share the same video-problem:

The program-screen starts in the fourth quarter of the monitor-screen.

Seems you are sharing some code with Lars because Lars' last demo had the same problem. ;-)

 

Regards

Matthias

Link to comment
Share on other sites

hi holger!

 

why don´t you team up with your brother - the community is eagerly awaiting eerivale and star alliance (personally i would put emphasis on star alliance, but oh well...) and it seems that it´s about time for a new, real jag release (all the betas coming out are only a substitute for what people really want: a complete game)........

 

cheers from münster, creekree

Link to comment
Share on other sites

Hi !

 

Matthias:

Yes, he used the same startup as I did. However it should be possible to fix this. Actually I am close to solving the problem in my code, however the Jag emu doesn't seem to like this fix. For some weird reason it will stop GPU processing after some time when I use the modified startup code. No idea why. On the real Jag it works. To make it work on the emu as well, it needs some more thinking or maybe just luck.

On my Jag the demo works fine though. I am still not sure why it works fine on some Jag and does not on others...

 

Is there a difference if you use RF or Scart ? (There shouldn't be any difference, right ?)

 

Creekree:

I don't think that a cooperation will help to speed things up that much. Afterall except for music code, most code in Eerievale is there.

So most of it is design work now.

And with Star Alliance, the main problem is, that my partner is very busy with work as well and thus has limited time for the project, so progress is quite slow on that. Most of the work on Star Alliance is design as well.

 

So a cooperation wouldn't speed things up that much.

Besides, I think Holger doesn't have that much time to spend on Jag coding anyway. ;)

 

However we often talk about Jag coding, exchange experiences and things like that. So even though it is no direct cooperation on a certain project, it helps solving problems.

 

Regards, Lars.

Link to comment
Share on other sites

Hello!

 

- since I don't own a jag I did the testing with Jaguar emulation (Project Tempest)  

 So don't expect them to run on a real Jag though I really hope they do

 

- If they don't run correct on a real Jag I will try my best to fix them when  i have the time

 

Both programs work but share the same video-problem:

The program-screen starts in the fourth quarter of the monitor-screen.

Seems you are sharing some code with Lars because Lars' last demo had the same problem. ;-)

 

Regards

Matthias

 

Hello Matthias,

 

As I said, these are fast hacks, so I didn't care too much with startup. I just took one from Lars, tweaked it slightly to my needs and got fast to the main code. Strange thing that it seems to run on Lars's Jag but not on yours. I hope to find a fix to this soon.

 

Regards,

Holger

Link to comment
Share on other sites

hi holger!

 

why don´t you team up with your brother - the community is eagerly awaiting eerivale and star alliance (personally i would put emphasis on star alliance, but oh well...) and it seems that it´s about time for a new, real jag release (all the betas coming out are only a substitute for what people really want: a complete game)........

 

Hi creekree,

we are teamed up in some form. When Lars started jag coding he kept asking me general coding questions and tried to adapt this to the jag. We often talk about coding since then and I've also done a few lines of code for his projects but those are his projects in the first line.

I prefer to keep the jag coding more like a small fun thing. To do some small homebrew hack is interesting to me but to do a whole game I would have to spent much more time on the jag than I have to spare.

 

cheers from münster, creekree

I used to go to school in Münster (Hans-Böckler) :-)

 

cheers from dortmund,

Holger

Link to comment
Share on other sites

Hello Holger!

 

As I said, these are fast hacks, so I didn't care too much with startup. I just took one from Lars, tweaked it slightly to my needs and got fast to the main code. Strange thing that it seems to run on Lars's Jag but not on yours. I hope to find a fix to this soon.  

 

I had understood you initial post in the way that you are now releasing

something which you have written long ago, so it could have been that

Lars had fixed that problem meanwhile for his current projects.

 

The difference between my Jaguar and Lars' is that i am using BJL

and Lars the Alpine-board, so the Jaguar has a different video-setup

before you upload a program to it.

It is not PAL/NTSC-related.

 

Regards

Matthias

Link to comment
Share on other sites

Hello Holger!

 

I had understood you initial post in the way that you are now releasing

something which you have written long ago, so it could have been that

Lars had fixed that problem meanwhile for his current projects.

 

No, these two are relative new. I should have written "... and in the end I've done some Jag coding beside PC coding now" in my first post.

I've played with the thought of giving the jag a try before but never realized it till now.

 

The difference between my Jaguar and Lars' is that i am using BJL

and Lars the Alpine-board, so the Jaguar has a different video-setup

before you upload a program to it.  

It is not PAL/NTSC-related.

 

Regards

Matthias

 

I'm pretty much green on the jag but am I guessing right that in the startup I used some settings are missing?

 

 

Reagrds,

Holger

Link to comment
Share on other sites

Hi!

 

The difference between my Jaguar and Lars' is that i am using BJL

and Lars the Alpine-board, so the Jaguar has a different video-setup

before you upload a program to it.  

It is not PAL/NTSC-related.

 

Regards

Matthias

 

I'm pretty much green on the jag but am I guessing right that in the startup I used some settings are missing?

 

 

We would need to compare the sources.

Lars said in one of his messages above he would use the GPU to set up video? That's soemthing i do with the 68k at the program-start, only later the GPU is used to rebuild the object-lists, but's something different.

 

I think the STUB/Alpine combination is more close in it's video-setup to the later video-setup of the loaded program than the BJL-video-setup,

so it might be that something is "missing" in your routines which overrules something the BJL-videosetup has set differently or not at all.

 

And of course i had often the same problem the other way round:

Programs which worked fine on BJL/JagServer-Jaguars showing only blank screens on Alpines or stock (=unmodified) Jaguars.

 

Regards

Matthias

Link to comment
Share on other sites

Hi Matthias !

 

No. The GPU is not used to set up video.

The only thing I said about GPU was, that the code doesn't run on the emulator properly.

 

However it turned out that this new startup is not suitable for him work anyway.

 

So the startup code that he uses still needs to be fixed to run on PAL BJL systems.

 

Regards, Lars.

Link to comment
Share on other sites

We would need to compare the sources.

Lars said in one of his messages above he would use the GPU to set up video? That's soemthing i do with the 68k at the program-start, only later the GPU is used to rebuild the object-lists, but's something different.

Hi Matthias!

The startup code I used is also pure 68k code.

Another startup Lars sent me uses GPU code to do the first OLP setting. But I discarded it because this code seems not to work properly on the jag emu according to him.

Although I'm just a jag coding beginner I don't think it really matters if it's pure 68k code or some kind of mix.

I think it's something missing or going wrong. I will upload the used startup code soon in the same folder where the binaries are so you can do a quick check if you like.

 

One thing I noticed before is that the startup I used doesn't first disable video interrupts like the other. I didn't care much and took it "as is" but when I think of it now after you mentioned bjl I would guess that this can cause quite chaos on jags first running the bjl code and then my binary.

 

 

Regards

Holger

Link to comment
Share on other sites

Another startup Lars sent me uses GPU code to do the first OLP setting. But I discarded it because this code seems not to work properly on the jag emu according to him.

GSetOLP is a very useful bit of code, because if the 68k, which only has a 16 bit bus, gets interupted by the OP in the middle of its pair of writes to the OLP register (which is 32 bit, and all 32 bit 68k writes are done as 2 16 bit writes one after the other), then the value in the register will be nonsense and the op will start reading from (and writing to) some random area of ram, potentially causing all kinds of chaos and some VERY random and un-traceable errors. If the emu's complain, and I dont know why they would since it should be used in all published games (Atari wouldnt encrypt games not using the official startup code), the easy solution is to not use an emu, but if you must, just .org the block of gpu code and copy it to gpu ram before running it.

Link to comment
Share on other sites

simple solution to setting the OP list register address is to do it during a VBL, when you can gurantee that the OP is not using it.  nice simple quick fix :)

 

Hi LinkoVitch!

That's the way I go in the main code but what's about the startup?

Do you really need to use GPU code when you disable the VI?

Regards

Holger

Link to comment
Share on other sites

I wouldn't fdisable the VBI if I were you, it's just such a handy interupt to use to ensure that you are in sync with the screen. At startup I would probably go with a very basic list that just contains a stop object and then you only need to set the address once and can leave it there (I think, as the stop object isn't changed by the OP)

Link to comment
Share on other sites

Hi Linkvitch!

I wouldn't fdisable the VBI if I were you, it's just such a handy interupt to use to ensure that you are in sync with the screen.  

I wasn't talking about main code but just about the startup code.

(prevent the OP interrupting the startup code, do startup stuff and turn on)

Later both of my programs use the vbl interrupt to do OL fixing and timing.

At startup I would probably go with a very basic list that just contains a stop object and then you only need to set the address once and can leave it there (I think, as the stop object isn't changed by the OP)

I coded the jag in a framebuffer approach so a predefined list should work if I'm correct ?

 

Regards

Holger

Link to comment
Share on other sites

If your list has anything like a bitmap in, the OP will corrupt the data, it updates things like position and start address within the OP list each pass. So you either have to rebuild or copy the old list back each frame.

 

But as a stop doesn't have either of these I think you may be able to get away with simply slapping a list containing a stop in there which should keep the op happy till you get ready to use it.. I haven't tried this tho, just an idea I have had

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...