File operations help

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
pj1115
Posts: 23
Joined: Mon Jan 22, 2007 4:46 am

File operations help

Post by pj1115 »

Hey

I was just wondering if anyone here was willing to help me with some code samples.

What I wanted to do was:
- Be able to open up a file and cross-reference its contents (let's say 1 character, such as 1) with another (that reads 2) and then do something if it's lower.
- Download a complete file from wifi to the memory stick.

I've never worked with file I/O or wifi before so some help, or even better, some sample code would do me a world of good and help me to increase my currently less-than-fantastic coding skills.

Thanks.
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

The first is in the SDK docs. If you need more help on IO that the docs provide, you aren't ready to be programming the PSP. Take a few more computer classes.

http://psp.jim.sh/pspsdk-doc/

The second is in the old threads - just search on wget and curl. With those terms, you should be able to find the info yourself.

Rememeber, this site isn't here to help you increase your "less-than-fantastic coding skills," it's to get already "up-to-snuff" programmers going on PS2/PSP/PS3 programming.
adrahil
Posts: 274
Joined: Thu Mar 16, 2006 1:55 am

Post by adrahil »

I've never worked with file I/O
Wow, it's the first thing i learned to do with C....
pj1115
Posts: 23
Joined: Mon Jan 22, 2007 4:46 am

Post by pj1115 »

^^ You mean you never did a hello world? :p
shell
Posts: 7
Joined: Tue Apr 03, 2007 6:11 am
Location: NYC
Contact:

Post by shell »

cout IS a stream.... thats why its in iostream.h -.- lol
pj1115
Posts: 23
Joined: Mon Jan 22, 2007 4:46 am

Post by pj1115 »

^ Didn't understand that...
User avatar
dot_blank
Posts: 498
Joined: Wed Sep 28, 2005 8:47 am
Location: Brasil

Post by dot_blank »

this thread is going nowhere

pj: read multiple books on programming in C/C++
and please try everything you learn with a test simple command
shell app on windows or linux and just practice practice ...just like
the rest of us ...and read articles and ebooks and whatnot

this site is not here to hold your hand in the basics
10011011 00101010 11010111 10001001 10111010
jblaze2201
Posts: 3
Joined: Thu Apr 05, 2007 12:36 pm

Post by jblaze2201 »

also try doing the tutorials here. They show you how to open and read the contents of a file.

Youll then need to read up on arrays, and strings. I think if you open both files and read the contents into 2 arrays then compare them you will accomplish what ya need.
Post Reply