Sony PSP OSK

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

Moderators: cheriff, TyRaNiD

Post Reply
McZonk
Posts: 35
Joined: Thu Jul 14, 2005 10:42 pm
Location: Germany
Contact:

Sony PSP OSK

Post by McZonk »

After some testing I can init the internal osk.

I have not idea about the most fields but it works. You can improve it and add to the sdk.

Image

http://zcom.sytes.net/tee/tutorials/psposk/psposk.zip
weltall
Posts: 310
Joined: Fri Feb 20, 2004 1:56 am
Contact:

Post by weltall »

wow i was waiting for this :P
thanks
Danny769
Posts: 55
Joined: Wed Feb 01, 2006 12:29 pm

Post by Danny769 »

wow!!!

Nice work
klump
Posts: 7
Joined: Sun Feb 05, 2006 12:23 pm

Post by klump »

johnmph
Posts: 119
Joined: Sat Jul 23, 2005 11:48 pm

Post by johnmph »

Thanks, it's very useful.

But i have found some bugs with osk :

- If the thread that calls osk functions is kernel thread, this doesn't work, you must call it with user thread.

- If the flash1 is assigned as read only, the osk is showed but the messages aren't showed.

And here some fields found :

typedef struct PspOskData_s {
int unk_00;
int unk_04;
int language;
int unk_12;
int unk_16; // This is charset type (0 = all, 1 = number, ...)
int lines;
int unk_24;
unsigned short* desc;
unsigned short* intext;
int outtextlength;
unsigned short* outtext;
int rc;
int outtextlimit;
} PspOskData;

typedef struct PspOsk_s {
unsigned int size;
int language;
int buttonswap;
int unk_12; // set 17
int unk_16; // set 19
int unk_20; // set 18
int unk_24; // set 16
int rc;
int unk_32;
int unk_36;
int unk_40;
int unk_44;
int unk_48; // Number of datas
PspOskData* data; // Array of data

int unk_56;
int unk_60;
} PspOsk;
sg57
Posts: 144
Joined: Fri Oct 14, 2005 2:26 pm

Post by sg57 »

hmmmm.....This is sweet and all, but the example shown I dislike very much (lol). Not the best commenting and its hard to edit certain things ex: make the out put of the text go from unsigned short into a buffer (but my trusty friend sprintf).

'I' cannot relaly see whats going on but it works, so I just change and delete and add things here and there to see what happens

ALSO, where you said

data.language = 2; // english

that is the language output and ONLY KEYPAD buttons are english, where

osk.language = 1; // originally 2

is the actual OSK language (the help button and enter buttons are in english), when 2, its spanish, 1 =english, 0 = japenese, etc.

osk.buttonswap = 1; // originally 0

When 1, the O adn X are swapped, and since the PSP was made in japan (yes?) they thought X as enter was opposite so buttons swapped is 'true' or '1' so it makes sense.

Hope that helps anyone who had issues with what I did, hope some one makes a better and easy to understand example where it is fully documented. (no offense to the example made by McZonk as it is pretty sweet having this keyboard)
reefbarman
Posts: 87
Joined: Mon Jan 08, 2007 12:16 pm
Location: Australia

Post by reefbarman »

i would really love to see this work in my program but i dont really have a clue how to set it all up,

i have these in so far

Code: Select all

#include <psputility_osk.h>
SceUtilityOskParams * myKeyboard;
SceUtilityOskData * myKeyboardData;
SceOskState keyboardState;
now my problem is how do i use all this
i want a function called keyboard() that displays this keyboard, makes it work and then stores the entered text in a char * array, then shuts the keyboard down allowing my program to return to it previous place

thanks in advance
Post Reply