Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 35

Thread: FPC4NDS: devkitPro's 2D examples

  1. #21

    FPC4NDS: devkitPro's 2D examples

    Does anyone in the community use SDL on DS?

    At the moment the engine is hooking into SDL for window management and 2D rendering. Actually Dean gave me a JEDI-SDL patch for DS. I hope it also works with SDL_mixer as that is what I am using for sound.
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  2. #22

    FPC4NDS: devkitPro's 2D examples

    OK I downloaded and installed the GBA and NDS FreePascal files, they are timestamped 10/05/2007 ( European Date ).

    Do these include the latest memory manager?

    Also what emulators do you guys use for GBA/NDS dev? I downloaded DeSmuME, is it any good?

    Now I have to work out how to get SDL working on it.
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  3. #23

    FPC4NDS: devkitPro's 2D examples

    The last version is the 2.2.0, released on september, but the new memory manager is in the trunk 2.3.x and there isn't a snapshot yet (I hope to release it next week-end, when I'll get some spare free time). However you can grab the daily source snapshot (24 megs) and try to recompile it. In the case, I can help in this task, so let me know
    [size=9px](EDIT: I have a batch file that does the "dirty" job. ASAP I'll post it here)[/size]

    The emulator of choice is no$gba (that despite its name, it is for ds too), but you can try iDeaS, that comes with a small debugger.
    For the gba, you can use no$gba or visualboy advance.
    Get your fpc4gba copy now!
    Get your fpc4nds copy now!

  4. #24
    Co-Founder / PGD Elder WILL's Avatar
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    6,107
    Blog Entries
    25

    FPC4NDS: devkitPro's 2D examples

    The only game/demo that I know of for the DS written in Pascal is the x-mas demo that Francesco and I wrote just last year. I can't recall if any SDL was used for graphics, but then again what was used to play the FastTracker2(.XM) module then?

    I think the source was posed a few months ago.... as for the link... uh, Francesco?
    Jason McMillen
    Pascal Game Development
    Co-Founder





  5. #25

    FPC4NDS: devkitPro's 2D examples

    Is the memory management fix in 2.2.1? It would be nice to have the 2.2.2 release with the fix.

  6. #26

    FPC4NDS: devkitPro's 2D examples

    @Jason: No SDL was used in the XMas demo, we used libnds only; about the XM, we converted it to wav, because the lack of mod libraries for ds. The sources are in the fpc4nds' "examples" directory.

    @Dani?īl: I have removed the old hack for ds and gba, so now (I mean in 2.3.x trunk) gba and ds use the standard memory manager shipped with free pascal. Is it merged in the 2.2 fix branch now?

    @Dominique: as promised, my batch file ^_^

    Code:
    rem This batch script is a little utility to make your fpc4nds in an easy way.
    rem Make sure to install all stuff required and set the dirs accordingly.
    rem For more infos feel free to contact me at francky74 AT gmail DOT com
    
    @echo off
    
    rem !!WARNING!! Set right directories!
    rem     FPC_INST_DIR&#58; The folder where you want your fpc4nds installed
    rem     FPC_SRC_DIR&#58; The folder where you have unpacked fpc sources
    rem     BINUTILS_DIR&#58; The folder where you have unpacked arm-nds binutils
    rem     FPC_BIN_DIR&#58; The folder where is fpc compiler used for build
    
    set FPC_INST_DIR=C&#58;\fpc4nds
    set FPC_SRC_DIR=C&#58;\fpc_sources
    set BINUTILS_DIR=C&#58;\arm-nds-binutils
    set FPC_BIN_DIR=C&#58;\fpc\2.2.0\bin\i386-win32
    
    cls
    
    echo ------------------------------------------------------------------------
    echo                 FreePascal arm-nds installation script                 
    echo ------------------------------------------------------------------------
    echo You need to prepare the following stuff&#58;
    echo 1. Install the arm-nds binutils into %BINUTILS_DIR%
    echo    http&#58;//itaprogaming.free.fr/download/arm-nds-binutils.zip
    echo 2. Install the latest FreePascal snapshot into %FPC_SRC_DIR%
    echo    ftp&#58;//ftp.freepascal.org/pub/fpc/snapshot/v21/source/fpc.zip
    echo. 
    echo According with this batch file, your fpc4nds will be installed in
    echo %FPC_INST_DIR% from the fpc sources located at %FPC_SRC_DIR%
    echo by using the Binutils located at %BINUTILS_DIR%.
    echo.
    echo At the end of this batch script, you could delete %FPC_SRC_DIR%/*.*
    echo and %BINUTILS_DIR%/*.*. 
    echo Please, remember to add %FPC_INST_DIR% to your search path too!
    echo ------------------------------------------------------------------------
    
    if NOT EXIST %BINUTILS_DIR%\arm-nds-ld.exe goto errorarmmissing
    if NOT EXIST %FPC_SRC_DIR%\compiler\cclasses.pas goto errorfpcmissing
    if EXIST %FPC_INST_DIR%\ goto makefpc4nds
    
    echo ------------------------------------------------------------------------
    echo Creating the freepascal dir ...
    echo ------------------------------------------------------------------------
    mkdir %FPC_INST_DIR%\bin\arm-nds
    
    &#58;makefpc4nds
    pause
    echo ------------------------------------------------------------------------
    echo The necessary files were found, you may now continue.
    echo ------------------------------------------------------------------------
    pause
    
    rem Creating cross compiler
    rem ---------------------------
    
    echo ------------------------------------------------------------------------
    echo Cross compiler will now be created...
    echo ------------------------------------------------------------------------
    
    cd %FPC_SRC_DIR%\compiler
    set path=%BINUTILS_DIR%;%PATH%;%FPC_BIN_DIR%
    fpcmake -r -w -Tall
    make distclean
    make PPC_TARGET=arm
    echo ------------------------------------------------------------------------
    echo If you don't see any error messages, you may now continue.
    echo ------------------------------------------------------------------------
    pause
    echo ------------------------------------------------------------------------
    echo Creating the folder %FPC_INST_DIR%\bin\arm-nds ...
    echo ------------------------------------------------------------------------
    mkdir %FPC_INST_DIR%\bin\arm-nds
    echo ------------------------------------------------------------------------
    echo Copying %FPC_SRC_DIR%\compiler\ppcarm.exe
    echo      to %FPC_INST_DIR%\bin\arm-nds\ ...
    echo ------------------------------------------------------------------------
    
    rem Renamed to avoid conflicts with other fpc arm compilers &#40;like fpc4gba&#41;
    copy %FPC_SRC_DIR%\compiler\ppcarm.exe %FPC_INST_DIR%\bin\arm-nds\ppcarmnds.exe
    echo ------------------------------------------------------------------------
    echo Copying %BINUTILS_DIR%\*.*
    echo      to %FPC_INST_DIR%\bin\arm-nds\ ...
    echo ------------------------------------------------------------------------
    copy %BINUTILS_DIR%\*.* %FPC_INST_DIR%\bin\arm-nds\
    echo ------------------------------------------------------------------------
    echo Creating the folder %FPC_INST_DIR%\msg ...
    echo ------------------------------------------------------------------------
    mkdir %FPC_INST_DIR%\msg
    echo ------------------------------------------------------------------------
    echo Copying %FPC_SRC_DIR%\compiler\msg\*.*
    echo      to %FPC_INST_DIR%\msg\ ...
    echo ------------------------------------------------------------------------
    copy %FPC_SRC_DIR%\compiler\msg\*.* %FPC_INST_DIR%\msg\
    pause
    echo ------------------------------------------------------------------------
    echo The crosscompiler is created and installed. You may now build the RTL.
    echo ------------------------------------------------------------------------
    pause
    
    rem Compiling rtl
    rem -----------------
    
    echo ------------------------------------------------------------------------
    echo The rtl will now be compiled...
    echo ------------------------------------------------------------------------
    cd %FPC_SRC_DIR%\rtl\nds
    fpcmake -r -w -Tall
    make clean
    make CPU_TARGET=arm OS_TARGET=nds PP="%FPC_INST_DIR%\bin\arm-nds\ppcarmnds" OPT="-Tnds -CX" 
    echo ------------------------------------------------------------------------
    echo If you don't see any error messages, you may now continue.
    echo ------------------------------------------------------------------------
    pause
    echo ------------------------------------------------------------------------
    echo Creating the folder %FPC_INST_DIR%\units\arm-nds ...
    echo ------------------------------------------------------------------------
    mkdir %FPC_INST_DIR%\units\arm-nds
    echo ------------------------------------------------------------------------
    echo Copying %FPC_SRC_DIR%\rtl\units\arm-nds\*.*
    echo      to %FPC_INST_DIR%\units\arm-nds\ ...
    echo ------------------------------------------------------------------------
    copy %FPC_SRC_DIR%\rtl\units\arm-nds\*.* %FPC_INST_DIR%\units\arm-nds\
    
    
    echo ------------------------------------------------------------------------
    echo Creating %FPC_INST_DIR%\bin\arm-nds\fpc.cfg ...
    echo ------------------------------------------------------------------------
    echo -Tnds > %FPC_INST_DIR%\bin\arm-nds\fpc.cfg
    echo -Fu%FPC_INST_DIR%\units\arm-nds >> %FPC_INST_DIR%\bin\arm-nds\fpc.cfg
    echo -XParm-nds- >> %FPC_INST_DIR%\bin\arm-nds\fpc.cfg
    echo -FD%FPC_INST_DIR% >> %FPC_INST_DIR%\bin\arm-nds\fpc.cfg
    echo -FD%FPC_INST_DIR%\bin\arm-nds >> %FPC_INST_DIR%\bin\arm-nds\fpc.cfg
    
    
    echo ------------------------------------------------------------------------
    echo Creating some useful shortcuts ...
    echo ------------------------------------------------------------------------
    echo &#91;InternetShortcut&#93; > %FPC_INST_DIR%\freepascal.url
    echo URL=http&#58;//www.freepascal.org/ >> %FPC_INST_DIR%\freepascal.url
    echo &#91;InternetShortcut&#93; > %FPC_INST_DIR%\fpc4nds.url
    echo URL=http&#58;//itaprogaming.free.fr/ >> %FPC_INST_DIR%\fpc4nds.url
    
    
    
    echo ------------------------------------------------------------------------
    echo Congratulations! Your fpc4nds is now correctly installed.
    echo Remember to add %FPC_INST_DIR% to your search path. If you want, you 
    echo can delete %FPC_SRC_DIR%/*.* and %BINUTILS_DIR%/*.* now. 
    echo ------------------------------------------------------------------------
    goto EOF
    ;
    
    &#58;errorarmmissing
    echo ------------------------------------------------------------------------
    echo The ARM files are missing in %BINUTILS_DIR%!
    echo Please install them, then restart this batch file.
    echo. 
    echo You can download these files from
    echo http&#58;//itarogaming.free.fr/download/arm-nds-binutils.zip
    echo. 
    echo If you want to use different paths, please open this file in notepad
    echo and change the first few lines according to your wishes.
    echo ------------------------------------------------------------------------
    pause
    goto &#58;EOF
    ;
    
    &#58;errorfpcmissing
    echo ------------------------------------------------------------------------
    echo The FPC files are missing in %FPC_SRC_DIR%\!
    echo Please install them, then restart this batch file.
    echo. 
    echo You can download these files from
    echo ftp&#58;//ftp.freepascal.org/pub/fpc/snapshot/v21/source/fpc.zip
    echo.
    echo If you want to use different paths, please open this file in notepad
    echo and change the first few lines according to your wishes.
    echo ------------------------------------------------------------------------
    pause
    goto &#58;EOF
    ;
    
    &#58;EOF
    cd %FPC_INST_DIR%
    set FPC_INST_DIR=
    set FPC_SRC_DIR=
    set BINUTILS_DIR=
    set FPC_BIN_DIR=
    
    pause
    Hope it helps
    Get your fpc4gba copy now!
    Get your fpc4nds copy now!

  7. #27

    FPC4NDS: devkitPro's 2D examples

    Quote Originally Posted by Legolas
    The last version is the 2.2.0, released on september, but the new memory manager is in the trunk 2.3.x and there isn't a snapshot yet (I hope to release it next week-end, when I'll get some spare free time). However you can grab the daily source snapshot (24 megs) and try to recompile it. In the case, I can help in this task, so let me know
    [size=9px](EDIT: I have a batch file that does the "dirty" job. ASAP I'll post it here)[/size]
    Ok I've download no$gba as well now. Btw, I normally get my overnight snapshots from http://www.hu.freepascal.org/lazarus/, is this the same as your URL, but from a different location?

    Thanks for the batchfile, I've added it to my arsenal.
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  8. #28

    FPC4NDS: devkitPro's 2D examples

    Quote Originally Posted by savage
    Ok I've download no$gba as well now. Btw, I normally get my overnight snapshots from http://www.hu.freepascal.org/lazarus/, is this the same as your URL, but from a different location?

    Thanks for the batchfile, I've added it to my arsenal.
    You're welcome

    About the sources, from my url you will get the development snapshot (2.3.x), from yours the fixes snapshot (2.2.x), that does not have my last fixes for nds/gba
    Get your fpc4gba copy now!
    Get your fpc4nds copy now!

  9. #29

    FPC4NDS: devkitPro's 2D examples

    Hi Legolas,
    I tried recompiling things from source, but just got a load of error messages and then it said it had compiled correctly. I'll have to try out the exe to see if it really was built correctly.

    I forgot about this thread, where Dean did some work with SDL and NDS ( http://www.pascalgamedevelopment.com...pic.php?t=3949 )
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  10. #30

    FPC4NDS: devkitPro's 2D examples

    Uhm... You should just get a lot of warnings :scratch:

    I'm trying to make a complete rebuild now, and if it works fine I'll upload it somewhere
    Get your fpc4gba copy now!
    Get your fpc4nds copy now!

Page 3 of 4 FirstFirst 1234 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •