Page 1 of 2 1 2 LastLast
Results 1 to 10 of 13

Thread: [WIP] BreadBoard

  
  1. #1
    MTN's Avatar
    MTN
    MTN is offline Programmer -Hacks Enthusiast
    Join Date
    Jan 2009
    Location
    Unknown
    Posts
    502
    Rep Power
    10

    Default [WIP] BreadBoard

    just wanted to say im about to make an app to simulate breadboard on psp ... it'll help me cheat in the lab , might help you too
    its something like vHDL or ISE ... later on i'll be adding breadboard->Circuit and Circuit-> breadboard
    any suggestions ?
    i need some help tho . its been a year and a half since i've written anything for psp , i need a make file . i need stdc++ and oslib but i dont have a single template :] help ?

    TODO :
    menu , check
    implement circuit|board system , check
    graphics and tools for drawing circuits <---
    get some sleep
    wake up
    goto line3


    -"OOh! sceGuClear?! Sounds exciting! I wanna stick my dick in it!" Stinkee2
    -DO NOT choose "install alongside other OS" when installing ubuntu 10.04 or higher

  2. #2
    hardhat is offline Programmer -Hacks Enthusiast
    Join Date
    May 2007
    Posts
    544
    Rep Power
    65

    Default

    Here is the makefile from my current C++ OSL game that I'm working on:

    Code:
    TARGET = leapingninjas
    OBJS = main.o map.o sprite.o falling.o
    
    INCDIR = 
    CFLAGS = -g -G4 -Wall -O2 
    CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti
    ASFLAGS = $(CFLAGS)
    PSP_FW_VERSION=200
    BUILD_PRX=1
    
    LIBDIR =LDFLAGS = -g
    STDLIBS= -L. -losl -lpng -lz -ljpeg \
                    -lpspsdk -lpspctrl -lpspumd -lpsprtc -lpsppower -lpspgu -lpspaudiolib -lpspaudio -lpspaudiocodec -lpspmpeg -lpsphprm -lm -lstdc++
    LIBS=$(STDLIBS)$(YOURLIBS)
    
    
    EXTRA_TARGETS = EBOOT.PBP
    PSP_EBOOT_TITLE = OSL Leaping Ninjas
    PSP_EBOOT_ICON = icon0.png
    #PSP_EBOOT_PIC1 = pic1.png
    
    PSPSDK=$(shell psp-config --pspsdk-path)
    include $(PSPSDK)/lib/build.mak
    It shouldn't have too much excess in it.

    I love sliced bread. But vHDL on the PSP? It might be a little tedious to type that up -- unless you intend for it to be more mouse based. Perhaps I could use it at work to help organize my thoughts as I lay out simple breadboarded circuits.

    Hmm...as for what to base it on, well, there is an open source schematic/layout program. I think a direct port would be inappropriate, but maybe it'll have libraries of parts that could be reused. Not sure. gEDA and KiCAD seem to have a bit of a following. Not sure what else is out there. Personally I use the closed source EAGLE so that's no help. It looks like TinyCAD might have potential too.

    My 2D homebrew | My 3D homebrew with Team Sushi. | My YouTube channel. | My Twitter
    Spoiler:

    hardhat: F1 == help on Windows
    J697: oh I have never used the help, so I wouldnt know
    hardhat: so that's why you're always lost. :-P

  3. #3
    MTN's Avatar
    MTN
    MTN is offline Programmer -Hacks Enthusiast
    Join Date
    Jan 2009
    Location
    Unknown
    Posts
    502
    Rep Power
    10

    Default

    thanks :] i'm not gonna port the whole thing ... just things that are better done on psp than pc ... i'll try to add a feature to save the files in a familiar format so you could use it on pc later
    it is gonna be mouse based ... otherwise it would be easier to do it on a paper or the board itself
    for now i'll just make a board with the ability to show what's connected to what then i'm gonna add compilability (wtf ?!) for wires, gates, dip. switch ,etc /w save|load . it would be stupid to do more than that
    as for the libraries ... obviously i need something open source but i don't think it'll be that hard to make my own . porting stuff is just a pain in the ass specially when you're a noob and don't know what the code does

    step 3

    -"OOh! sceGuClear?! Sounds exciting! I wanna stick my dick in it!" Stinkee2
    -DO NOT choose "install alongside other OS" when installing ubuntu 10.04 or higher

  4. #4
    hardhat is offline Programmer -Hacks Enthusiast
    Join Date
    May 2007
    Posts
    544
    Rep Power
    65

    Default

    Well a direct port probably wouldn't work due to memory limitations and of course the more limited screen/keyboard availability. So I support you in making something minimal to build on. Still it wouldn't be terrible to get OR gates and so on from some other project.

    My 2D homebrew | My 3D homebrew with Team Sushi. | My YouTube channel. | My Twitter
    Spoiler:

    hardhat: F1 == help on Windows
    J697: oh I have never used the help, so I wouldnt know
    hardhat: so that's why you're always lost. :-P

  5. #5
    MTN's Avatar
    MTN
    MTN is offline Programmer -Hacks Enthusiast
    Join Date
    Jan 2009
    Location
    Unknown
    Posts
    502
    Rep Power
    10

    Default

    By or gates you mean the different models (how they look ) ?
    Im gonna add a few then add a custom gate , where you can draw it and assign its pins ... This is gonna be harder than i thought :]
    EDIT : epic fail (crash'd) ... i don't know why it doesn't work .
    Code:
    #include <pspcallbacks.h>
    #include <oslib\oslib.h>
    #include "bread.h"
    // 480 x 272
    
    PSP_MODULE_INFO("Board", 0, 1, 1);
    PSP_MAIN_THREAD_ATTR(THREAD_ATTR_USER | THREAD_ATTR_VFPU);
    
    
    bool done=false;
    intraFont *menu_font;
    OSL_IMAGE *bkg;
    
    
    int main(int argc,char **argp)
    {
    	oslInit(0);
    	oslInitGfx(OSL_PF_8888,0);
    	oslDrawString(10,10,"1");
    
    	InitMenu();
    	oslDrawString(10,20,"2");
    	while(!done)
    	{
    		oslStartDrawing();
    		oslDrawString(10,30,"3");
    		DrawMenu();
    		oslDrawString(10,40,"4");
    		oslEndDrawing();
    		oslSyncFrame();
    	}	
    	oslEndGfx();
    	oslDrawString(10,50,"5");	
    	oslQuit();
    	return 0;
    }
    
    void InitMenu()
    {
    	intraFontInit();
    	menu_font =intraFontLoad("Data\\menu", INTRAFONT_CACHE_ASCII);
    	bkg = oslLoadImageFilePNG("Data\\bkg.png",OSL_IN_RAM,OSL_PF_8888);
    }
    void DrawMenu()
    {
    	oslDrawImage(bkg);
    	intraFontPrint(menu_font,10,10,"New Circuit");
    	intraFontPrint(menu_font,10,20,"New Circuit");
    	intraFontPrint(menu_font,10,30,"New Circuit");
    }

    -"OOh! sceGuClear?! Sounds exciting! I wanna stick my dick in it!" Stinkee2
    -DO NOT choose "install alongside other OS" when installing ubuntu 10.04 or higher

  6. #6
    hardhat is offline Programmer -Hacks Enthusiast
    Join Date
    May 2007
    Posts
    544
    Rep Power
    65

    Default

    By OR gate, I meant a 74ls32 or some sort of 7432 (Quad Input Or Gate).

    Well, you don't do any error checking, so maybe the problem is that your font file is misnamed (menu instead of menu.ttf) or any number of other potential problems. Have you tried getting the line where it crashes from psplink? Do you remember how to do that?

    My 2D homebrew | My 3D homebrew with Team Sushi. | My YouTube channel. | My Twitter
    Spoiler:

    hardhat: F1 == help on Windows
    J697: oh I have never used the help, so I wouldnt know
    hardhat: so that's why you're always lost. :-P

  7. #7
    MTN's Avatar
    MTN
    MTN is offline Programmer -Hacks Enthusiast
    Join Date
    Jan 2009
    Location
    Unknown
    Posts
    502
    Rep Power
    10

    Default

    :] i'll work on that.
    I tried renaming / removing custom font ,Dont know whats wrong ... ( i removed the extension)
    I never used psplink the only tool i used for debugging was this app i made for sending the eboot to psp and launching it
    edit : even a hello world doenst work :\ my psp has changed its mind about being a hacked device ...
    Spoiler:
    Code:
    int main(int argc,char **argp)
    {
    	oslInit(0);
    	oslInitGfx(OSL_PF_8888,0);
    	//InitMenu();
    	while(!osl_quit)
    	{
    		oslStartDrawing();
    		oslDrawString(10,40,"F U World!");
    		oslEndDrawing();
    		oslSyncFrame();
    	}	
    	oslEndGfx();
    	oslQuit();
    	return 0;
    }

    -.- fuck ! 4shared removed my account (for the second time) , i lost all the shit i needed
    edit2 : finaallyy ... the problem was PSP_FW_VERSION

    -"OOh! sceGuClear?! Sounds exciting! I wanna stick my dick in it!" Stinkee2
    -DO NOT choose "install alongside other OS" when installing ubuntu 10.04 or higher

  8. #8
    hardhat is offline Programmer -Hacks Enthusiast
    Join Date
    May 2007
    Posts
    544
    Rep Power
    65

    Default

    Are you saying that the PSP_FW_VERSION needs to be a larger number or a smaller number? Because that Makefile works fine for me for my samples.

    Using PSPlink is totally worth it. When I'm testing I live in psplink really. I've heard it said that psplink + psp-gdb is nicer than the debug tools for the official SDK, although I haven't tried it, so I couldn't say for sure.

    So if you compile with -g and link with -g, then you can use the handy psp-addr2line command line tool to convert from a crash address to the line number of the source program. Pretty useful.

    I'm sure that there is a tutorial around somewhere for that.

    My 2D homebrew | My 3D homebrew with Team Sushi. | My YouTube channel. | My Twitter
    Spoiler:

    hardhat: F1 == help on Windows
    J697: oh I have never used the help, so I wouldnt know
    hardhat: so that's why you're always lost. :-P

  9. #9
    MTN's Avatar
    MTN
    MTN is offline Programmer -Hacks Enthusiast
    Join Date
    Jan 2009
    Location
    Unknown
    Posts
    502
    Rep Power
    10

    Default

    I changed it from 200 to 550 (my cfw version) . I have a 2k
    There's a tut on minpspw' page . I heard psplink only works on 1ks , i'll give it a try anyway

    -"OOh! sceGuClear?! Sounds exciting! I wanna stick my dick in it!" Stinkee2
    -DO NOT choose "install alongside other OS" when installing ubuntu 10.04 or higher

  10. #10
    hardhat is offline Programmer -Hacks Enthusiast
    Join Date
    May 2007
    Posts
    544
    Rep Power
    65

    Default

    I don't think that that 200 or 550 number should really make a difference, but if you found it changed it for the better, I guess who am I to look a gift horse in the mouth?

    psplink works on any PSP with a CFW. I've heard of people using it with certain types of HEN but I'm not clear on the exact requirements. I haven't tried it but it would be interesting to know if it would work on OFW if all of the modules were signed properly. It seems to me that the code signing key for kernel PRXes is not yet available. I'm not sure about that though.

    My 2D homebrew | My 3D homebrew with Team Sushi. | My YouTube channel. | My Twitter
    Spoiler:

    hardhat: F1 == help on Windows
    J697: oh I have never used the help, so I wouldnt know
    hardhat: so that's why you're always lost. :-P

Page 1 of 2 1 2 LastLast

Tags for this Thread

Posting Permissions

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