xboxscene.org forums

Pages: [1] 2

Author Topic: Openxdk  (Read 381 times)

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« on: August 02, 2006, 12:34:00 AM »

Procedure for installing clean and legal development environment for XBOX (OpenXDK) on Windows :
Logged

friedgold

  • Archived User
  • Sr. Member
  • *
  • Posts: 266
Openxdk
« Reply #1 on: August 02, 2006, 08:38:00 AM »

QUOTE(dcahrakos @ Aug 2 2006, 03:28 PM) View Post

cool thanks

although I already knew how to install it smile.gif
and im using dev-c++ so I dont need to do all that makefile stuff and compile with make, although its not hard seeing as I've used linux alot before, but meh.

just didnt see any input code for openxdk 0.7 and the cvs changes, but that looks good and understandable thanks!

The best documentation for using input with OpenXDK is the sample code.

An example using the XInput

An example using SDL

The recent CVS changes didn't change the Input API so any code which worked for OpenXDK 0.07 should work fine with the latest source.
Logged

dcahrakos

  • Archived User
  • Newbie
  • *
  • Posts: 8
Openxdk
« Reply #2 on: August 02, 2006, 09:35:00 AM »

hey, thanks alot, thats even better, I looked through the cvs samples but must have missed those.

also, will using XInput work with SDL, or do I have to use the SDL joystick code? (I cant see XInput not working, but I thought I would ask)
Logged

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« Reply #3 on: August 02, 2006, 11:01:00 PM »

XInput is the set of low level routines. Low level routines are in /hal directory (hardware abstraction layer).
SDL is a general purpose interface, interesting because it exists on other platforms and allows faster ports to xbox with openxdk. SDL is plugged above all others low level routines and use them.
Whatever functions you are calling, at the end it's the low level XInput routines that will be used.
Difference is that if you call SDL functions your final code will be bigger (but I don't think it will be slower).
Logged

mokda

  • Archived User
  • Newbie
  • *
  • Posts: 10
Openxdk
« Reply #4 on: August 04, 2006, 06:52:00 PM »

QUOTE(openxdkman @ Aug 1 2006, 11:41 PM) View Post

1) Be sure to have last version of cygwin (a free and legal unix-like environment for Windows)
Go on www.cygwin.com, click "install or update now!" in middle of page. The small setup program will offer you to download or update all components of cygwin (take them all). That can take all the day. Be patient.


Do we really need *all* of cygwin?

The reason I ask is that it might be the solution to the problem i'm having...

I followed your tutorial except for i just got the cygwin tools needed to make it do something when i told it make all install tongue.gif  This consisted of:
make
autoconf
automake
patch
and the rest of the things listed on the openxdk.org installation page.

So what happens when I compile the libraries, everything i code compiles nicely, but the .xbe I make crashes my xbox....

I'm 95% sure its something I'm doing wrong on my end because I took d0wnlab's wolf3d binaries that were compiled with the CVS openxdk libraries and that worked fine on my xbox.

So....is there anything obvious i'm missing? Or should i just bite the bullet and d/l all of cygwin?

Also, I would gladly give up trying to compile the CVS version if someone would release openxdk 0.8 with all these nice fancy changes smile.gif
Logged

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« Reply #5 on: August 04, 2006, 10:11:00 PM »

Happened to me too. My mistake was to call autogen and make all install BEFORE applying CVS changes.
Result was messy libraries not using last makefiles settings.
Try keeping your cygwin, but delete all OpenXDK directories (in /usr/home and /usr/local).
Then get source and apply all CVS changes, then AFTER, autogen and make all install as described.
If it doesn't work, then you will have to try to update/upgrade your cygwin a bit more. Taking all cygwin will only cost you time and disk space, not more. It's worth the effort.

Btw, I know a working ftp sample program (That includes a nForce packet driver and a tcp/ip stack) has been sent to owner of openxdk.org page (He wrote on his page he wanted help for network part. He got it). If you need valid libraries, ask for a version 0.08. If you badly need a network library badly just ask for a version 0.09. I know people involved in openxdk are over busy at the moment, but if you are a lot to beg for it, you should be able to obtain it.
Logged

mokda

  • Archived User
  • Newbie
  • *
  • Posts: 10
Openxdk
« Reply #6 on: August 15, 2006, 08:47:00 AM »

I give up!

I compiled the CVS openxdk libraries ok i think...Openxdkman's little snippet of code above doesn't crash my xbox and demonstrates controller stability.  The debug prints don't show though, and anything I do graphics wise crashes my xbox!

I compiled the sdlvideo.c file straight out of the Sample section, and that crashes my xbox (where it didn't before in openxdk 0.07).

I wonder if someone could host their nicely compiled openxdk libraries somewhere?
Logged

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« Reply #7 on: August 16, 2006, 01:48:00 AM »

Ok, let's hunt the bug... With these, I don't have any crash in sdlvideo

http://home.tele2.fr...august_2006.zip
http://home.tele2.fr...august_2006.zip
http://home.tele2.fr...august_2006.zip

If it still crashes, I'm interested to know the value (in hexadecimal) returned by
the function XVideoGetEncoderSettings(), on your XBOX.
Lower byte is adapter, next upper byte is TV standard.
That will allow to detect if you belong to a rare category of users (not tested yet).
Logged

Eskema

  • Archived User
  • Newbie
  • *
  • Posts: 8
Openxdk
« Reply #8 on: August 16, 2006, 11:36:00 AM »

I wanna ask something, with all those new patches, ¿is there any news on sdl_mixer? ¿what kind of music i can use in my games, ogg,mp3, mod...?
Logged

friedgold

  • Archived User
  • Sr. Member
  • *
  • Posts: 266
Openxdk
« Reply #9 on: August 16, 2006, 03:16:00 PM »

QUOTE(Eskema @ Aug 16 2006, 06:43 PM) View Post

I wanna ask something, with all those new patches, ¿is there any news on sdl_mixer? ¿what kind of music i can use in my games, ogg,mp3, mod...?

It looks like SDL_mixer is built with support for wav, voc and aiff files and mod files (.MOD .S3M .IT .XM). No ogg or mp3 (they require additional libraries). I haven't tried using it though so I'm not 100% sure.
Logged

Eskema

  • Archived User
  • Newbie
  • *
  • Posts: 8
Openxdk
« Reply #10 on: August 16, 2006, 10:41:00 PM »

Thanks, i hope in next releases they include ogg support or mp3 smile.gif
Logged

Carcharius

  • Archived User
  • Sr. Member
  • *
  • Posts: 304
Openxdk
« Reply #11 on: August 16, 2006, 10:44:00 PM »

mod works fine.

ogg and mp3 have issues. Both the SMPEG lib and the standard ogg libs crash the xbox under OpenXDK.

Ogg can be made to work using the Tremor lib, but to use that SDL_mixer needs some changes - examples of which can be seen in the PSP port of SDL_mixer if anyone is interested.
Logged

mokda

  • Archived User
  • Newbie
  • *
  • Posts: 10
Openxdk
« Reply #12 on: August 16, 2006, 10:50:00 PM »

QUOTE(openxdkman @ Aug 16 2006, 12:55 AM) View Post

Ok, let's hunt the bug... With these, I don't have any crash in sdlvideo

If it still crashes, I'm interested to know the value (in hexadecimal) returned by
the function XVideoGetEncoderSettings(), on your XBOX.
Lower byte is adapter, next upper byte is TV standard.
That will allow to detect if you belong to a rare category of users (not tested yet).


Here is my code:
CODE

void XBoxStartup()
{
               FILE *fp;

    int bpp = 32;
    DWORD retVal=0;
    fp = fopen("e:/blah.txt", "a+");
    if (fp == NULL)
       XReboot();
    SDL_Init(SDL_INIT_VIDEO);
    retVal = (DWORD)XVideoGetEncoderSettings();
    fprintf(fp," %d",retVal);
    fclose(fp);
    XSleep(5000);
    XReboot();
}


It returns 4194563.  Turned to hex is 0x400103.  Does this make sense at all?

I tried your libraries and it produced the same crashing results sad.gif
Logged

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« Reply #13 on: August 17, 2006, 01:02:00 AM »

In fact, if I were you, I would stick to a small sample in which debugPrint doesn't work.
Since it's not crashing, it's good and we can try to obtain debug traces and find out why
debugPrint isn't working (I'm sure if we find the reason we will find what's going on)

First thing is to see if frame buffer address is correct when debugPrint is printing...
Logged

openxdkman

  • Archived User
  • Hero Member
  • *
  • Posts: 550
Openxdk
« Reply #14 on: August 17, 2006, 05:27:00 AM »

If my xbe doesn't crash on your xbox, a smart thing to do for you, is to use my libraries and sample source to create the sdlVideo sample xbe file that crashes on your xbox and put it online so I can retrieve it.
Then I will use IDA Pro to disassemble my xbe and your xbe and I will compare. That will give clues.

If my xbe crashes on your xbox, a nice way will be to make the smallest program having different behaviour on your xbox and mine, and we you can slowly find out at wich step something odd occurs.
Logged
Pages: [1] 2