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 

_CLOCKS_PER_SEC_ problem

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



Joined: 02 Jul 2005
Posts: 41

PostPosted: Fri Jul 08, 2005 6:06 pm    Post subject: _CLOCKS_PER_SEC_ problem Reply with quote

I've used the clock() function from <time.h> and everything seems to run around 1000 times faster. It seems there is 1,000,000 clock ticks per second. But I checked the define _CLOCKS_PER_SEC_ and it is 1,000. Am I calculating the clock ticks wrong?

A smaller problem I'm having is that fopen() seem to always return null despite the existence of the file. Anyone have any ideas?
Back to top
View user's profile Send private message
Agoln



Joined: 08 Jun 2005
Posts: 326
Location: Fort Wayne, IN

PostPosted: Fri Jul 08, 2005 11:15 pm    Post subject: Re: _CLOCKS_PER_SEC_ problem Reply with quote

cooleyandy wrote:
A smaller problem I'm having is that fopen() seem to always return null despite the existence of the file. Anyone have any ideas?


Have you tried using the SCE functions? Here is a link to the IO functions: http://pspdev.ofcode.com/api.php?type=2&id=85
_________________
Lego of my Ago!
Back to top
View user's profile Send private message AIM Address
cooleyandy



Joined: 02 Jul 2005
Posts: 41

PostPosted: Sat Jul 09, 2005 6:56 am    Post subject: Reply with quote

Okay, just figured out about why fopen didn't work. Every filename needs a "ms0:/" to be prefixed to be read. Programming for the psp is such a learning experience. Is there any easy way to just read the files from the same directory the eboot.pbp is in?
Back to top
View user's profile Send private message
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