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 

need help adding a new IR keyboard.
Goto page 1, 2  Next
 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 4:55 am    Post subject: need help adding a new IR keyboard. Reply with quote

I have 0 programming experience besides a little bit of LUA, but i dont really count that.

Im trying to program a driver and a keymap for the old PALM Wireless
Keyboard (P10946-P)(yes its an IR keyboard).

Ive come to understand that I need a program for the psp called irDAcapture to get all the keys from my ir keyboard to my psp. Ive downloaded it, and whenever I press a key on the keyboard, a bunch of unidentified characters show up on my psp screen. I pressed every character on my keyboard (left to right starting with the first row of keys) and then pressed start. I got a file on the root of my MS called irdacapture. this fle has no extension. when i open it with notepad i get this:

*^"" m
"_** N :
+< =>(? 98M9:\222fflpxuxuGGbjVjVݦ""T\3\3υDXPpPpEaaFJBSBSGBBVCCWBJRJRX.ؽؽFFdd,-
.8 /)LxMi͑N[

H4><<Y<?44:n*^"" m
"_** N :
+< =>(? 98M9:\222fflpxuxuGGbjVjVݦ""T\3\3υDXPpPpEaaFJBSBSGBBVCCWBJRJRX.ؽؽFFdd,-
.8 /)LxMi͑͑N[

H4><<Y<?44:nO0|88#gg"h`v`vFNN7DL1L1$^VVQt|7|7RSfnnP&&


I also have come to understand that I need something called pspirkeyb. I downloaded the latest version but have no idea how to work it or anything.

please bear with me, I baught this keyboard specifically to use with my psp, and I dont want it to just be a waste of money... I dont care how long it takes for me to get it working, But a guide, or even better, some hand on hand help would be BEYOND greatly appreciated.

Can someone please tell me where to go from here??
Back to top
View user's profile Send private message AIM Address
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Fri Sep 12, 2008 6:27 am    Post subject: Reply with quote

Use IRDAMon instead and post the hex codes for each key. I can add it to pspirkeyb no problem.

Generally speaking, IR keyboards work this way -

You get a data packet for each press and release of a key. A data packet generally looks like:

Optional packet start byte. The most common value is 0xC0.
Optional key group code.
Key code. A key up is most often just the same value as key down + 0x80.
Optional key validate code. Most often just the inverse of the keycode.
Optional packet end byte. Most often value is 0xC1.

So a packet can be as simple as 0x11 for a key down and 0x91 for key up, or it may be more complicated with the above optional bytes, like 0xC0 0x20 0x11 0xEE 0xC1 for key down.

The current line of Palm keyboards not only have all the optional bytes mentioned above, but also have a secondary keycode for compatibility with a different line of keyboards.
Back to top
View user's profile Send private message AIM Address
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 9:11 am    Post subject: Reply with quote

ok, when i hit a key in irDAmon i get 18 sets of characters(36 characters).

each set of 2 characters is seperated by a space.

is this right? if so, is there a way to capture all this text, or am I going to have to manually write it all down?
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Fri Sep 12, 2008 10:30 am    Post subject: Reply with quote

Legacyxero wrote:
ok, when i hit a key in irDAmon i get 18 sets of characters(36 characters).

each set of 2 characters is seperated by a space.

is this right? if so, is there a way to capture all this text, or am I going to have to manually write it all down?


Look for what is in common about the data... generally, only one or two bytes of the packet changes. Mark down the entire packet for one key, then only what changes for everything else.

Sometimes, some of the data doesn't matter at all. For example, the Targus keyboard inserts a random number of 0xFF bytes at the front and tail of each data packet. All of them can be ignored (and are - the driver only looks for the 0xC0 start of packet byte).
Back to top
View user's profile Send private message AIM Address
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 10:44 am    Post subject: Reply with quote

here they are if i was right, chillywilly.

First row of keys


Second row of keys


third row of keys


fourth row of keys


I'de also like to say that I cant thank you enough dude!
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 10:46 am    Post subject: Reply with quote

oh and, J.F... do you think you could get on aim?

im: legacyxero
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Fri Sep 12, 2008 1:03 pm    Post subject: Reply with quote

I'm not one for IMing. Email is fine... you can PM me for that if you want.

How's about a picture of the keyboard? No idea how the keys look. "First Row" means nothing. I can work from the screenshots, just need to know what the key layout is.
:)
Back to top
View user's profile Send private message AIM Address
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 1:11 pm    Post subject: Reply with quote

Its quite a big picture, but i had to keep it big so you could see all the keys.

heres the direct link:

http://i56.photobucket.com/albums/g184/legacyxero/Picture001.jpg
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Fri Sep 12, 2008 7:40 pm    Post subject: Reply with quote

Okay, I've started on the code... it's late so I'll finish it up later tomorrow. So you should have something to try tomorrow evening.

Just in case you have suggestions on mapping, here's my first thoughts on it:

Not pressing BlueFn or GreenFn just gives the main character marked, except for the arrow keys, which are considered main characters in my book. That means the '?' marked key is really UP arrow. That makes more sense... '?' should just be shift+/ like a normal keyboard.

Pressing BlueFn gives the blue marked characters except for ? and the arrows, which become the same as the green marks (PgUp, etc).

Pressing GreenFn doesn't give the green marked characters for anything other the the arrows (which become PgUp, Home, PgDn, End). Instead, the Numbers become F1 to F10, and [ becomes F11, ] becomes F12, and ` becomes ESC. Also, left cmd/alt/ctl become right cmd/alt/ctl.

EDIT: Okay, I got an initial compile of the latest pspirkeyb with support for your keyboard. NOW I'm going off to bed. :)

http://www.mediafire.com/download.php?ytmsxmqni3w

The keyboard type for the new keyboard is 23. You'll need to add it to the ini file and copy the appropriate files to the proper place. Then you can try the sample apps. I updated the sample apps to be 3.xx/4.xx prx apps, and they load irda.prx if you're on 3.80 or newer cfw.
Back to top
View user's profile Send private message AIM Address
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Fri Sep 12, 2008 9:41 pm    Post subject: Reply with quote

THANK YOU SOOOO MUCH

sorry for the newb Q, but how do i install all this new data on my PSP? Its just a bunch of folders.
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 1:54 am    Post subject: Reply with quote

Ahh! J.F. why didn't you PM me? Remember that I need all those for piKey too! lol

I'm the only person who has the LATEST version of the PSPIRKeyB!

It appears you didn't add it to the latest version of the PSPIRKeyB lib. The latest version is a lot tidier and has the Belkin driver.

That said... you've updated all the sample files... I'll just work on re-adding adding the Belkin driver. *Sighs.*

In future J.F, please inform me the next time something IRDA related pops up. School doesn't always allow me to check this place daily.

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
jean



Joined: 05 Jan 2008
Posts: 489

PostPosted: Sat Sep 13, 2008 2:35 am    Post subject: Reply with quote

...then why didn't you ask for a commit???
Are you the ONLY person on planet having the latest pikey, too?? Because i'm quite improving it.... and this improvement should include a dynamic link with pspirkeyb with no longer need to recompile everything.
Back to top
View user's profile Send private message
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 4:31 am    Post subject: Reply with quote

Argh...

As you know Jean, piKey depends on the PSPIRKeyB. You need to "make install" the PSPIRKeyB first to your environment, then "make" piKey and you have the latest version.

I added a driver a while back and forgot about releasing the PSPIRKeyB to the svn due to school work. I think maybe J.F forgot to update his version.

The version that's in the svn now is quite old. I'll update it when I get a chance with all the drivers and the 4.XX kernel update with IRDA calls.

As for the latest version of piKey. I think it's only me that has the latest version, however there are 3 people working on it. (Me, you and Jube.)

To my understanding, Jube and yourself are mainly focusing on SIO, whilst I'm working on IR.

At the moment, I'm too caught up with school work to think about piKey, but when I get a chance I need to update everything, create an Unofficial piKey 0.5 checkpoint and confirm with everybody, that is working on the application, the future of piKey.

I've seen sources from you and, Jean, and both of you look like you've been working on differant things.

Maybe some day we should combien them all together and release Unofficial 0.5 together.

I'm going to PM you my the changelog so far...

You might want to PM me about piKey's progress...

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sat Sep 13, 2008 5:19 am    Post subject: Reply with quote

angelo wrote:
Ahh! J.F. why didn't you PM me? Remember that I need all those for piKey too! lol

I'm the only person who has the LATEST version of the PSPIRKeyB!

It appears you didn't add it to the latest version of the PSPIRKeyB lib. The latest version is a lot tidier and has the Belkin driver.

That said... you've updated all the sample files... I'll just work on re-adding adding the Belkin driver. *Sighs.*

In future J.F, please inform me the next time something IRDA related pops up. School doesn't always allow me to check this place daily.

Angelo


I thought I was working from the latest. If you start making changes, you should have let me know. The only changes I knew of that you made were to the repeat variables, which doesn't affect this. If you have indeed been making changes, add the new palm-one stuff from my files to it and post it again.

And yes, this REALLY needs to get committed. There are lots of devs out there with REALLY old versions of pspirkeyb (cough zx81 cough). The main problem is getting someone with write access to actually do so. Have my changes for SDL and PSPGL been committed yet? I posted a patch file months back that someone said they wanted to check out before committing, and I've not heard a peep since.
Back to top
View user's profile Send private message AIM Address
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 7:04 am    Post subject: Reply with quote

The last change was the Belkin driver... remember? I was decoding HEX values like an autistic demon child!

I tried to submit the lib to Harold Fielker... no reply.

When I find spare time (school is REALLY busy now), I'll make an Unofficial piKey 0.5 checkpoint and get all libs and samples up to date.

I'll zip it all up and inform the PSPDev comunity. I keep bugging ZX81 about the PSPIRKeyB. I don't think he cares!

Who does have access to the SVN?
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Sat Sep 13, 2008 7:46 am    Post subject: JH! Reply with quote

I have no idea how to install this onto pikey! please help me!
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sat Sep 13, 2008 8:16 am    Post subject: Re: JH! Reply with quote

Legacyxero wrote:
I have no idea how to install this onto pikey! please help me!


Pikey has to be recompiled with the changed pspirkeyb to get any new changes. Better just wait for angelo to integrate the changes with his own changes to pikey. You're just slightly unlucky that both are in a state of flux preceding the next version of the software. If you can't compile these things yourself, you'll just have to be patient.
Back to top
View user's profile Send private message AIM Address
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 8:43 am    Post subject: Reply with quote

Ill get him outta his misery. I'll provide him with a IR_IN.PRX with the correct driver.

He's shown initiative, so why not put effort and give him a small gift!

But first... school work! *Sighs*
Back to top
View user's profile Send private message Send e-mail MSN Messenger
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 8:44 am    Post subject: Reply with quote

@Jean

What major changes have you made in piKey. Can we mix are ideas together?

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sat Sep 13, 2008 9:07 am    Post subject: Reply with quote

angelo wrote:
@Jean

What major changes have you made in piKey. Can we mix are ideas together?

Angelo


Yeah, we should pull everything together and try to get the repo updated. Hopefully then folks will start using a relatively new version for a change. :)
Back to top
View user's profile Send private message AIM Address
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 9:20 am    Post subject: Reply with quote

Me Jean Jube... 3 versions. 2 versions too many!
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Sat Sep 13, 2008 9:41 am    Post subject: Reply with quote

thanks alot dude.

could you just post the link in here after you finnish your work?
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
jean



Joined: 05 Jan 2008
Posts: 489

PostPosted: Sat Sep 13, 2008 6:51 pm    Post subject: Reply with quote

@Angelo
Seems to be quite OT here, but....here we are. As i just finished writing in reply to your PM, fortunately the greatest part of my work is on plugins side; only thing required for my works to behave correctly is to fix or remove at all SIO messing code from PiK. I'm really busy now, too, but when i've time (and when i reach a good point in development) i'll surely let you know.
Back to top
View user's profile Send private message
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 7:08 pm    Post subject: Reply with quote

ok guys... all seems fair!

Looks like we're all pretty busy and that we have higher priorities. lol

I'll have to agree with you. I'll PM you when piKey is almost complete.

Thanks

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 8:52 pm    Post subject: Reply with quote

OK, I fixed and cleared up the PSPIRKeyB lib now! Here's the IR keyboard compatibility list:

Code:
#  0  - No IR Keyboard
#  1  - Compaq / HP Foldable IR Keyboard
#  2  - Snap'n'Type IR Keyboard
#  3  - Belkin F8U1500 IR Keyboard
#  5  - HP Slim IR Keyboard
#  8  - Belkin IR Keyboard (not IrDA)
#  9  - Flexis FX-100 IR Keyboardeyboard
#  10 - Benq G250 IR Gamepad
#  12 - Micro Innovations Foldaway IR Keyboard
#  13 - Micro Innovations IR Datapad
#  14 - Compaq IR Micro Keyboard
#  15 - Targus Universal IR Wireless Keyboard
#  18 - Freedom IR Keyboard
#  19 - NOVAETS - KIS2 - IR Keyboard
#  20 - Palm Universal Wireless IR Keyboard
#  21 - Hama Palm IR Keyboard
#  22 - Sprint PDA Keyboard
#  23 - Palm P10946-P


I also fixed the key repeat values so they are now perfect. Here's the latest PSPIRKey_B lib with the latest drivers and the samples moved to 4.XX kernel with IRDA calls. (Thanks J.F!)

http://piKey.Kloplop321.com/Release/PSPIRKeyB_Lib.zip

And here are the modules compiled using the latest PSPIRKey_B. I compiled Unofficial piKey 0.4 and stripped it down to the PRX modules and the configs. I haven't tested it.

If any help/support is needed, please go to http://forums.noobz.eu/. You'll find help there and I always check the forums and my PM there. I don't want to fill this forum with clutter.

Here's Unofficial piKey 0.4:

http://piKey.Kloplop321.com/Release/piKey_0.4_with_added_Palm.zip

@J.F + Jean + Jube + ZX81 and any other IRDA / piKey dev. Can somebody please post the latest PSPIRKeyB_Lib to the SVN please. It's about time it got revamped!

Anyway... I'm off to do my schoolwork now! *Sighs*.

Have a good day guys!

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
zx-81



Joined: 07 Apr 2006
Posts: 11
Location: France

PostPosted: Sat Sep 13, 2008 9:51 pm    Post subject: Reply with quote

I've asked for a write access to subversion ps2dev server in Nov 14, 2007 ... and i've never had any chance to get it.

Angelo, may be we can share code using code.google.com account ?
_________________
The only good is knowledge and the only evil is ignorance.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sat Sep 13, 2008 10:21 pm    Post subject: Reply with quote

Quote:
I've asked for a write access to subversion ps2dev server in Nov 14, 2007 ... and i've never had any chance to get it.


Gee... they're slow!

Quote:
Angelo, may be we can share code using code.google.com account?


Well it's always going to stay on the server one of my team members have ftp://ftp.kloplop321.com/ but do what you want with it. Nothing is really my work, I just manage it. :)

Angelo
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Legacyxero



Joined: 12 Sep 2008
Posts: 23

PostPosted: Sun Sep 14, 2008 1:30 am    Post subject: Reply with quote

YES, its almost perfect. All i need now is the keymap from JF.
_________________
[IMG]http://img115.exs.cx/img115/638/Sephiroth3.jpg[/IMS]
Back to top
View user's profile Send private message AIM Address
angelo



Joined: 29 Aug 2007
Posts: 168

PostPosted: Sun Sep 14, 2008 1:42 am    Post subject: Reply with quote

Don't bother J.F for the keymap mate. He's a busy man and he also doesn't have the keyboard. Making a perfect keymap will be pretty difficault.

Make the keymap yourself. It's dead easy! Download Unofficial pikey 0.4 and read the piKey's Guide to keymaps. Then, basing it on the "Qwerty.ini" map, you can build your own! It's dead easy!

You need to get the piKey I sent you working though and a fixed version of the piKey Sample to write the keymap.

Did piKey work well on your PSP... except from the incorrect OSK characters?

I can help you make it if you want... but over MSN. Not email! I'll post a link of the working piKey Sample. I'm kinda busy now...

Angelo

EDIT: IF piKey is properly installed, then this should work just fine. Copy the "piKey_Sample" folder to ms0:\PSP\Game.

Link: http://piKey.Kloplop321.com/Release/Sample.zip
Back to top
View user's profile Send private message Send e-mail MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sun Sep 14, 2008 5:17 am    Post subject: Reply with quote

Legacyxero wrote:
YES, its almost perfect. All i need now is the keymap from JF.


Well, I'm not sure if the keys are all correct as I don't have that particular keyboard. I told you the layout in my post above:

Not BlueFn or GreenFn: Key is as marked with the exception of the arrow keys. I think the arrow keys are important, so I made them the primary mapping of those keys.

BlueFn: Key is as marked with the exception of the arrow keys again. Since the arrows were made primary, BlueFn + arrow is the same as the green marking (PgUp, Home, PgDn, End). Note that most of the green markings can be had by BlueFn+Shift. That makes more sense than GreeFn (e.g., @ = shift + 2 which is shift+ (BlueFn + W)).

GreenFn: Virtually none of the green marked keys are used with GreenFn... that didn't make sense. Instead, I use GreenFn for yet more of the missing keys. GreenFn + Number gives a F1 to F10. GreenFn + [ = F11, and GreenFn + ] = F12 (that makes the top row just like the top row of a regular keyboard - the only thing missing is Esc, which I made GreenFn + `). GreenFn + CMD/ALT/CTL = right CMD/ALT/CTL.

If you find a key that is wrong (like A is not A), then let me or angelo know so we can correct the maps.
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Goto page 1, 2  Next
Page 1 of 2

 
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