forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Preliminary Python port

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
fraca7



Joined: 03 Oct 2005
Posts: 21
Location: Paris

PostPosted: Mon Oct 03, 2005 1:17 am    Post subject: Preliminary Python port Reply with quote

Hello. I've just "released" a preliminary port of the Python programming language for the PSP, with bindings for the essential PSP APIs as well as part of pspgu.

More details on my blog: http://fraca7.free.fr/blog/

Feedback is welcome.
Back to top
View user's profile Send private message Visit poster's website
chaos



Joined: 10 Apr 2005
Posts: 135

PostPosted: Mon Oct 03, 2005 11:58 am    Post subject: Reply with quote

the screenshot looks promising.. have you implemented full 32-bit color?
_________________
Chaosmachine Studios: High Quality Homebrew.
Back to top
View user's profile Send private message
fraca7



Joined: 03 Oct 2005
Posts: 21
Location: Paris

PostPosted: Mon Oct 03, 2005 2:31 pm    Post subject: Reply with quote

Yes. The initial goal was to wrap enough of libpspgu to port one of the samples to Python, so the sceGuDrawArray function is part of it. Unfortunately, the API is not quite Pythonic; you have to do low-level stuff with the struct module. This will change soon.
Back to top
View user's profile Send private message Visit poster's website
Istari



Joined: 30 Sep 2005
Posts: 10

PostPosted: Mon Oct 03, 2005 8:37 pm    Post subject: Reply with quote

I have been trying to build, using the code from your repository. And I'm getting errors. The command I use is:
Code:
python-psp/PSP$ make


How do you fix the undefined reference to _stat?
It seems to me that you are using some voodoo to build, and haven't put all the nessecary code in svn. ;) (Please correct me if I'm wrong)

Is there any particular reason why you aren't using SWIG, or something similar, to wrap the SDK?
Back to top
View user's profile Send private message
nashdj



Joined: 27 Jan 2004
Posts: 3

PostPosted: Mon Oct 03, 2005 9:53 pm    Post subject: Reply with quote

Istari wrote:
I have been trying to build...


I just checked out and built revision 13 with no problems.
Back to top
View user's profile Send private message
fraca7



Joined: 03 Oct 2005
Posts: 21
Location: Paris

PostPosted: Mon Oct 03, 2005 9:57 pm    Post subject: Reply with quote

I also got the _stat problem using an older version of psptoolchain. Just update it and it will be OK.
Back to top
View user's profile Send private message Visit poster's website
fraca7



Joined: 03 Oct 2005
Posts: 21
Location: Paris

PostPosted: Tue Oct 04, 2005 3:13 am    Post subject: Reply with quote

Istari: About SWIG. Apart from the classic Bison/Flex pair, I don't trust a computer program to generate correct C code. Hell, I don't even trust most C programmers to generate correct C code, for that matter.

The Python/C API is so simple and elegant that I just use it directly. It may be kind of repetitive, but hey, it's C. It's always been.
Back to top
View user's profile Send private message Visit poster's website
Istari



Joined: 30 Sep 2005
Posts: 10

PostPosted: Tue Oct 04, 2005 4:17 am    Post subject: Reply with quote

OK. Fixed after I did a
Code:
svn update
in the toolchain directory (It would have helped to notice that particular line in the docs sooner), followed by a rebuild of the toolchain.

Thanks for the help, and thanks for porting my favorite language to the PSP.
Back to top
View user's profile Send private message
fraca7



Joined: 03 Oct 2005
Posts: 21
Location: Paris

PostPosted: Tue Oct 04, 2005 4:44 am    Post subject: Reply with quote

No sweat. It's also my favorite language :)

But there's still much to do. I've set up a simple Web page to keep track of evolutions, at the following URL:

http://fraca7.free.fr/pythonpsp/

If the project goes well, this will be enhanced later. Maybe moved to Sourceforge, or rather on the pspdev SVN repository. Who knows.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group