Forum: Open Source & Homebrew Jailbreak - If you are looking for news and helpful information on PS3 topics like open source and homebrew jailbreak solutions then PSX-Scene should be your first stop. You can stay up to date on topics such as PSGroove and PSFreedom plus much more.


The above video goes away if you are a member and logged in, so log in now!




 
Would you like to get all the new info from
PSX-Scene in your email each day?




Want to learn more about the team keeping you up to date with the latest scene news?

Read about them now!

Check out our Developer bios, too!

 


User Tag List

Thread: Trouble compiling PSGrooPIC
  

Results 1 to 9 of 9
  1. #1 Exclamation Trouble compiling PSGrooPIC 
    CptAJ is offline Registered User
    Join Date
    Nov 2010
    Posts
    4
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    I'm trying to compile the latest PSGrooPIC for my DIY board. Its a PIC4550 8mhz NoBTL for 3.41FW. I'm using the PCWHD 4.110 compiler and I keep getting around a hundred errors related to usb.h when trying to compile.

    I tried using the command script provided in the source and it tries a bunch of times and fails at all of them. So I proceeded to trim the script to leave the error report and only try compiling the version I need. Here's the pertinent command:
    Code:
    ccsc +FH +Y9 -L -A -E -M -P -J -D +GFW341="true" +GLEDG=PIN_B4 +GLEDR=PIN_B4 +GDEFPL="true" main.c

    and I get this error:

    Code:
    Error[27]   C:\J1M-PSGrooPIC-87c5f0b\usb.h 105 : Expression must evaluate to a constant
          1 Errors,  0 Warnings.
    When compiling from the PCWHD IDE I get a more extensive error report which you can see here: RAW OUTPUT 1pcQfghY

    I realize that I need to modify the source to support the 8mhz crystal but I'm trying to compile the untouched version first to make sure I'm not the one causing the problem by modifying the source.

    At any rate, here's the modification I plan on doing for future reference (NOTE: I HAVEN'T done this part yet, what I'm talking about above is using the virgin source code from git):
    Code:
    #include <18F4550.h>
    #fuses HSPLL,NOWDT,NOPROTECT,NODEBUG,NOBROWNOUT,USBDIV,PLL2,CPUDIV1,VREGEN,PUT,MCLR,NOLVP
    #use delay(clock=8000000)

    Could I get some help with the compiling process? I don't know what I'm doing wrong.
    Also, if there's anything wrong with the modification I plan on doing after I figure out the first problem, feel free to point it out as well.

    Thanks
    Last edited by CptAJ; 11-09-2010 at 04:26 PM.
    Reply With Quote  

  2. #2  
    RolF2 is offline Registered User
    Join Date
    Sep 2010
    Posts
    27
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    CCS usb stack is patched ?
    Reply With Quote  

  3. #3  
    jaekid's Avatar
    jaekid is offline Teensy++ 2.0 User
    Join Date
    Sep 2010
    Posts
    792
    Downloads
    1
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    kindly post your usb.h file for analysis.
    Reply With Quote  

  4. #4  
    CptAJ is offline Registered User
    Join Date
    Nov 2010
    Posts
    4
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    usb.h
    http://pastebin.com/bd7atCYn

    usb_desc.h
    http://pastebin.com/mwmuBk0p

    I've made no changes and applied no patches. I just downloaded from github here:
    https://github.com/J1M/PSGrooPIC
    Reply With Quote  

  5. #5  
    RolF2 is offline Registered User
    Join Date
    Sep 2010
    Posts
    27
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    Code:
    Build:
    Fist, you need to convert the usb descriptor format to a big array as required by CCS compiler (doesn't support 
    pointers to ROM), to do so just copy descriptor.h and psgroove.c to the source directory, and build GenDescriptors. 
    To do so, you'll need a windows C compiler (VC++ or Mingw).
    
    	with VC++: 
    	cl gendescriptors.c
    
    	or with mingw:
    	gcc gendescriptors.c -o gendescriptors
    
    If you get some error, you are missing some files.
    
    Now, to build the descriptors, run
    	gendescriptors > usb_desc.h
    
    Now you need to modify the CCS usb stack. CCS stack distribution not allowed outside licensed users, so you'll need
    to patch the one from your ccs installation:
    copy usb.c,usb.h, pic18_usb.c and pic18_usb.h (they are in the Drivers folder in CCS) to your source directory and run:
    	patch -p1 < stack.diff
    
    Now you can compile the source to a .hex with

    R.
    Reply With Quote  

  6. #6  
    CptAJ is offline Registered User
    Join Date
    Nov 2010
    Posts
    4
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    So where do I find this gendescriptor.c file? I've seen several sites quoting this but not one mentions where to get the file.

    I have the descriptor.h and psgroove.c file from the psgroove source. But from there it jumps to building gendescriptor.c which I don't know where to find

    Wish this was a little more documented =(
    Reply With Quote  

  7. #7  
    RolF2 is offline Registered User
    Join Date
    Sep 2010
    Posts
    27
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    i atach it here , and you can try iLLNESS source in his own thread with all patched files included already ...
    Attached Files
    Reply With Quote  

  8. #8  
    iLLNESS is offline Member
    Join Date
    Dec 2002
    Location
    Ontario
    Posts
    923
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    1
    my sources are here http://psx-scene.com/forums/546952-post5.html (iLLNESS's PSGrooPIC Hexes and Information Thread)

    they may be harder to follow but they are current as of now so you dont need to mess with compiling pl3.

    you should just need to comment out any bootloader related stuff in my source for it to work.
    PIC based jailbreakers please visit my thread below and please READ. I have spent a few hours now trying to explain everythign as best I can here. You will also find my latest HEX releases there as well.

    http://psx-scene.com/forums/showthre...946#post546946
    Reply With Quote  

  9. #9  
    CptAJ is offline Registered User
    Join Date
    Nov 2010
    Posts
    4
    Downloads
    0
    Uploads
    0
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Likes Given
    0
    Likes Received
    0
    Ok, I gave your source a try and it compiled fine. I made a few changes to support my DIY board.

    Here are the fuses and clock lines.
    Code:
    #fuses HSPLL,NOWDT,NOPROTECT,NOLVP,NODEBUG,NOBROWNOUT,USBDIV,PLL2,CPUDIV1,VREGEN,PUT,NOMCLR
    #use delay(clock=8000000)
    I defined PSGROOPIC as the board...
    Code:
    #define PSGROOPIC
    And commented out this whole section:

    Code:
    ///////////////////////////////////////////////////////////////////////////
    // NON BOOTLOADER USERS COMMENT ALL DATA FROM ABOVE ////// TO BELOW //////
    // IF NOT USING BOOTLOADER PLEASE MAKE SURE TO SET #FUSES ACCORDINGLY TO MATCH YOUR BOARD!!!!!!!
    // BOOTLOADER SCRIPT
    /*
    #ifdef BTL_USBHID
       #define BOOTLOADER USBHID
       #define CODE_START 0x1000
       #export (HEX, FILE=BOARD-VERSION_STRING-FIRMWARE-PLTYPE-PL3_COMMIT-BOOTLOADER.hex)
    #elif defined (BTL_PICDEM)
       #define BOOTLOADER PICDEM
       #define CODE_START 0x0800
       #export (HEX, FILE=BOARD-VERSION_STRING-FIRMWARE-PLTYPE-PL3_COMMIT-BOOTLOADER)
    #else
       #error Bootloader not defined
    #endif
    #build(reset=CODE_START, interrupt=CODE_START+0x08)
    #org 0, CODE_START-1 {}
    */
    ///////////////////////////////////////////////////////////////////////////
    And finally, I changed the led for my board on the psgroopic header file like so:
    Code:
    #define LEDR PIN_B4
    Then I hit compile on PCWHD and everything went great. I loaded the hex onto my device and tried it... but it DIDN'T WORK.

    The led flashes a bit then it stops and then it just stays flashing non-stop. The PS3 boots on with no positive results.

    I've checked my device and everything seems fine but here's an EXACT drawing of it, did I make any mistakes?



    Note: The led and resistor ARE in series to the ground line. I just didn't draw it in an obvious manner.

    Any ideas? I'm stuck here
    Reply With Quote  

Tags for this Thread

View Tag Cloud

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