Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Wed 01 Oct 2014, 04:22
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Projects
Need on-screen keyboard with mouse functions
Moderators: Flash, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 2 of 9 [134 Posts]   Goto page: Previous 1, 2, 3, 4, ..., 7, 8, 9 Next
Author Message
greengeek

Joined: 20 Jul 2010
Posts: 2558
Location: New Zealand

PostPosted: Sun 10 Mar 2013, 04:33    Post subject:  

Thats great - it would be useful to have someone familiar with xdotool to offer some advice.

I just had a tinker with xvkbd - it's quite good. I think it could be very useful, especially if it was also possible to write a program / script that is capable of moving the mouse pointer across the entire screen in a row by row scanning motion (over the top of any/all open windows).

If the mouse pointer could be made to scroll slowly across the top line of the screen, then step down 5mm and scroll back, then step down 5mm and scroll across again etc etc it would eventually cover the entire screen and allow a mouseclick to access all functions that xvkbd (or it's focused window) was presenting. (Very slow of course, but I'm just looking for a "proof of concept" idea at the moment. Something might be better than nothing...)

EDIT: xdotool does not seem to respond to WriteAid character depressions, but does respond to xvkbd character depressions. So, if a way could be found to automatically scroll through the xvkbd keys onscreen, it would be possible to program some of them to do special functions like File, save, file open, move mouse etc etc.
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Sun 10 Mar 2013, 12:49    Post subject: Delay  

Sorry for the delay in responding....I was dumb and didn't subscribe to my own thread, and I have 2 8 month old twins who have had the stomach bug.

The scanning function of gok/onboard allow the user to use a single action input to start "scanning" and logically determine which column, row, button they need.

So imagine the following....a person who has no control of arms/legs, and only a single range of motion in their neck. What we do now is put a spst momentary switch, let's say under their chin.

Currently, the only way to make the switch work now (in windows) is to buy a usb interface with a driver to recognize the switch as an input device.

What I did, was disassembled the keyboard to find the ic that runs let's say the pause/break key...a key that I doubt would come into conflict with normal internet surfing or email and connect the switch across the appropriate terminals to make essentially a "one button Keyboard"

Currently the interfaces are like $200, so for the price of a junk keyboard the solution works.

Now, I need that key to start the scanning process in something like GOK or Onboard.

The fundamental problem I found with GOK is that the original developers assigned all of the scanning functionality to any one of the mouse buttons.

This creates a conflict with the pointer, because every time you click to make it scan it also clicks wherever the pointer is.

Onboard appears to let you select another keyboard key as the scanning activator, but does not have mouse controls.

Its hard to imagine but I could post a video of someone using a very expensive paid application to show what I am talking about.

Thank you for your response, and sorry for the delay.

Will
Back to top
View user's profile Send private message 
greengeek

Joined: 20 Jul 2010
Posts: 2558
Location: New Zealand

PostPosted: Sun 10 Mar 2013, 14:05    Post subject: scanning  

standard7452 wrote:
Now, I need that key to start the scanning process in something like GOK or Onboard.

Would it be problematic if the scanning started automatically as soon as the PC booted?

Also - does this system have to be designed so that the single-switch user is the only person available to start the required processes, or is it likely that there will be another person available to boot and commence the necessary programmes?
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Sun 10 Mar 2013, 15:30    Post subject:  

Everyone thank you for your help.

I appreciate your time and patience while I try to explain this right because you guys are so close to solving this problem.

Its just so difficult to fully explain in one shot.

Onboard Onscreen Keyboard provides an option so that a keyboard key can be used to activate a scan of the keyboard layout. Here is a list of what happens for this:

1. The user presses a predefined keyboard button on the physical keyboard once and lets off.
2. The entire first row of the onscreen keyboard is selected so lets say the number row (` through =), meaning that if the user wants a key in that row they need to press the predefined button a second time.
3. From there, each key is selected from left to right. The user must press the predefined key again to make their final selection.
4. The process starts over for the next character or function the user needs.

With Onboard this part already exists, but there is no way to use the mouse.

Now think of "Mouse Keys" for windows or the use numberpad to control the mouse in Ubuntu.

if you hold the 8, the mouse cursor moves up relative to its position, 4 goes left, 6 goes right and 2 goes down.

if I could add six buttons to any onscreen keyboard that has the scanning feature mentioned above that ran a script for xdotool to move the mouse in a direction until the user hits the predefined physical keyboard button again. and also have a button for right, left and doubleclicks that would be it.

so like buttons on xvkbd that ran something like xdotool mousemove 0,5 on a loop until the user hit the predefined keyboard button.

hope this makes sense, if not I can make a video to explain it.

sorry and thanks!

Will Best
Back to top
View user's profile Send private message 
greengeek

Joined: 20 Jul 2010
Posts: 2558
Location: New Zealand

PostPosted: Sun 10 Mar 2013, 16:41    Post subject:  

standard7452 wrote:
if I could add six buttons to any onscreen keyboard that has the scanning feature mentioned above that ran a script for xdotool to move the mouse in a direction until the user hits the predefined physical keyboard button again. and also have a button for right, left and doubleclicks that would be it.

So is this similar to what you mean?

Programmatically assign the following keys with the attached functions as shown:
F4 = "slowly scroll left till user hits switch"
F5 = "slowly scroll up till user hits switch"
F6 = "slowly scroll down till user hits switch"
F7 = "slowly scroll right till user hits switch"
Back to top
View user's profile Send private message 
Ted Dog


Joined: 13 Sep 2005
Posts: 2339
Location: Heart of Texas

PostPosted: Sun 10 Mar 2013, 18:15    Post subject:  

Ah, you got around the expensive switch, I'd like to see a video setup.

Also do you know if you keep a lazer mouse still and just move the pad its the same and moving the mouse, would a upside down mouse and a padded semi ridged chin strip made of mousepad work. Also the mouse buttons are easier to reuse over a keyboard.
Just a thought.

I asked my local chapter of the MDA if there was any interest in a project like this... She was not expecting this type of topic so she will get back with me in a few weeks, after the Shamrock for MDA fund drive is over. Wink

While on the topic, MDA fund drive is underway, please donate,
MDA saved my life, I was going down hill with a form of MD that is very rare. Normal doctors where unable to classify or treat my condition for 12 yrs. When I visited the MDA clinic they where able to id the problem and I had a workable prescription before I left, also since it was rare they had me stay the rest of the day and be seen by everybody in the department and a few students.
If I was seen by that many doctors and had all the expensive tests run it would have easily been 10,000 dollars, my cost $86 rest covered my MDA.
Back to top
View user's profile Send private message 
starhawk

Joined: 22 Nov 2010
Posts: 2879
Location: Everybody knows this is nowhere...

PostPosted: Sun 10 Mar 2013, 20:37    Post subject:  

A thought that occurs to me --

Could these people manipulate a directional-pad sort of setup, like on a Game Boy? If so, a special switch (not expensive!), an Arduino Leonardo chip (the whole board is not necessary), and a PS/2 cable is all you'd need.

But they'd need to be able to set their chin on the switch actuator and then move the chin slightly to make the circuit do its thing. They'd also need to be able to move to a second and third switch for left- and right-click.

Directional switch like this --> http://www.sparkfun.com/products/10063
Other two switches as needed, maybe like this? --> http://www.sparkfun.com/products/9337
Arduino chip --> http://www.sparkfun.com/products/10524
28pin DIP socket (for the chip) --> http://www.sparkfun.com/products/7942
...as a note, that is an utterly atrocious price. Mouser Electronics sells those for less than $0.25! (But the added shipping cost isn't worth it.)

The Arduino would need to be programmed, using the ps2dev library here as a starting point --> http://playground.arduino.cc/componentLib/Ps2mouse

A further note -- the switch I mention is going to be a real doozy to solder, simply because it's surface-mount. Probably the best way to deal with this would be to use this "breakout board" that puts things into through-hole friendly form. You would not need to buy the switch separately -- the "breakout" board includes everything needed here. There is an additional "select" output on that switch which would not be used -- that can be implemented in other buttons. (This is likely to be far, far less frustrating than "press the button and push, but don't push too hard or you'll click on something!")

So, per device, you'd be looking at a cost of $12.50 plus shipping, labor, and whatever sort of PCB you'd want it mounted on -- Radio Shack actually has a pretty nifty "perfboard" selection (perfboard is a PCB with plated holes spaced at 0.1" intervals, primarily for prototyping and for hobbyists who can't afford custom PCBs)... I'd recommend their Catalog # 276-158 board, at about 2.8"x3.7". See here --> http://www.radioshack.com/product/index.jsp?productId=2103798

I daresay that, given some experimentation and such, I could quite likely build one of these myself as a prototype. I don't think you'd want me building a lot of them for you (I've got motivation issues, among other things) but I'd be happy to assemble a prototype if I can scrape together the money...

_________________
Loving X-Slacko 2.1!
Custom Build: HP MOCA-AR + Core2Duo T7200 + 4gb RAM + 256gb SSD
...just needs a pretty case Wink
Back to top
View user's profile Send private message 
starhawk

Joined: 22 Nov 2010
Posts: 2879
Location: Everybody knows this is nowhere...

PostPosted: Mon 11 Mar 2013, 01:45    Post subject:  

I have a much better design for this. Let me know if you're interested, and if so, I'll send you the plans.

Total cost should be under $30 including all parts and shipping. (Labor is extra.) It is 100% workable, with all off-the-shelf components, and can be assembled by an experienced maker in probably about an hour. (That means it'll take me two hours at least!)

I still have to write the programming to make it work -- but it WILL work!

What's more -- if the system this is used on has an integrated keyboard (i.e. is a laptop), there is no need for any other input device so long as an onscreen keyboard is readily available! That is -- this can REPLACE the single-button keyboards entirely.

For systems that will not boot up without a keyboard present -- simply find a PS/2 keyboard, open it up, and pull out the electronics inside. You only need the PCB and PS/2 cable to remain intact -- discard the rest. Wrap it up tight with electrical tape, hook it up, and stash it somewhere. Presto! One keyboard that will never experience another keypress, but fool the computer into thinking all is well. Simple and brutal, but remarkably effective.

_________________
Loving X-Slacko 2.1!
Custom Build: HP MOCA-AR + Core2Duo T7200 + 4gb RAM + 256gb SSD
...just needs a pretty case Wink
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Tue 12 Mar 2013, 11:46    Post subject:  

greengeek wrote:
standard7452 wrote:
if I could add six buttons to any onscreen keyboard that has the scanning feature mentioned above that ran a script for xdotool to move the mouse in a direction until the user hits the predefined physical keyboard button again. and also have a button for right, left and doubleclicks that would be it.

So is this similar to what you mean?

Programmatically assign the following keys with the attached functions as shown:
F4 = "slowly scroll left till user hits switch"
F5 = "slowly scroll up till user hits switch"
F6 = "slowly scroll down till user hits switch"
F7 = "slowly scroll right till user hits switch"


Yes! But, the keyboard has to be "scannable" as well so that the person can first select the f4 key using row, column deduction, and then the mouse would start, and then the mouse would stop when they hit the switch again.

Functionally, this is exactly what it would be with 3 other keys, left click, right click, and double click.

When I am back at work tomorrow (I got the stomach bug my kids got), I will take a video of someone using a super expensive solution just so you guys see what the end functionality is.

Thank you again for your help!

I will post the video tomorrow which I think will clear up the details of what I am looking to do (obviously with much help, ty)

Will
Back to top
View user's profile Send private message 
greengeek

Joined: 20 Jul 2010
Posts: 2558
Location: New Zealand

PostPosted: Tue 12 Mar 2013, 13:25    Post subject: Re: Delay  

standard7452 wrote:
The fundamental problem I found with GOK is that the original developers assigned all of the scanning functionality to any one of the mouse buttons. This creates a conflict with the pointer, because every time you click to make it scan it also clicks wherever the pointer is.

I would just like to clarify this if possible - is the conflict caused because the pointer MOVES when you click the mouse button (because of the mechanical pressure on the mouse), or do you mean that the conflict is that you cannot trigger the scanning unless the mousepointer is in one correct place only? (and you want the mouse to be elsewhere at the moment you trigger scanning...)
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Tue 12 Mar 2013, 14:40    Post subject: Re: Delay  

greengeek wrote:
standard7452 wrote:
The fundamental problem I found with GOK is that the original developers assigned all of the scanning functionality to any one of the mouse buttons. This creates a conflict with the pointer, because every time you click to make it scan it also clicks wherever the pointer is.

I would just like to clarify this if possible - is the conflict caused because the pointer MOVES when you click the mouse button (because of the mechanical pressure on the mouse), or do you mean that the conflict is that you cannot trigger the scanning unless the mousepointer is in one correct place only? (and you want the mouse to be elsewhere at the moment you trigger scanning...)


http://m.youtube.com/#/watch?v=Mn-HLmEPI_s&desktop_uri=%2Fwatch%3Fv%3DMn-HLmEPI_s

This is a video of what I mean by "scanning" that uses the win7 OSK.

In the first part he uses the "Point and Click" method where he selects the character or key he wishes to use with the mouse pointer. In the second part he uses the "Scanning" mode to allow him to press a predefined button like "space" to get a row selected, and then three characters, then the final character the user wants.

GOK has a keyboard layout that included mouse functionality like you we're talking about with xdotool. There is buttons (like enter, space, letters, buttons), except they are for mouse up (xdotool mousemove_realtive 0,5 on some sort of loop) and mouse down, etc. these buttons allow for the user to access both the keyboard and mouse using a single switch and the deductive logic part.

GOK's conflict lies in the fact that they used a mouse button exclusively to initiate this scanning process. So if you want to move the mouse using the OSK with GOK, every time you want to change direction or open a context menu or whatever, the core pointer itself clicks.

[/url]
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Tue 12 Mar 2013, 14:47    Post subject:  

starhawk wrote:
A thought that occurs to me --

Could these people manipulate a directional-pad sort of setup, like on a Game Boy? If so, a special switch (not expensive!), an Arduino Leonardo chip (the whole board is not necessary), and a PS/2 cable is all you'd need.

But they'd need to be able to set their chin on the switch actuator and then move the chin slightly to make the circuit do its thing. They'd also need to be able to move to a second and third switch for left- and right-click.

Directional switch like this --> http://www.sparkfun.com/products/10063
Other two switches as needed, maybe like this? --> http://www.sparkfun.com/products/9337
Arduino chip --> http://www.sparkfun.com/products/10524
28pin DIP socket (for the chip) --> http://www.sparkfun.com/products/7942
...as a note, that is an utterly atrocious price. Mouser Electronics sells those for less than $0.25! (But the added shipping cost isn't worth it.)

The Arduino would need to be programmed, using the ps2dev library here as a starting point --> http://playground.arduino.cc/componentLib/Ps2mouse

A further note -- the switch I mention is going to be a real doozy to solder, simply because it's surface-mount. Probably the best way to deal with this would be to use this "breakout board" that puts things into through-hole friendly form. You would not need to buy the switch separately -- the "breakout" board includes everything needed here. There is an additional "select" output on that switch which would not be used -- that can be implemented in other buttons. (This is likely to be far, far less frustrating than "press the button and push, but don't push too hard or you'll click on something!")

So, per device, you'd be looking at a cost of $12.50 plus shipping, labor, and whatever sort of PCB you'd want it mounted on -- Radio Shack actually has a pretty nifty "perfboard" selection (perfboard is a PCB with plated holes spaced at 0.1" intervals, primarily for prototyping and for hobbyists who can't afford custom PCBs)... I'd recommend their Catalog # 276-158 board, at about 2.8"x3.7". See here --> http://www.radioshack.com/product/index.jsp?productId=2103798

I daresay that, given some experimentation and such, I could quite likely build one of these myself as a prototype. I don't think you'd want me building a lot of them for you (I've got motivation issues, among other things) but I'd be happy to assemble a prototype if I can scrape together the money...


This sounds interesting! I need to take a video of how they access so that you could look...as far as prototypes I would fund it, but first take a look to at the vid to see if it is applicable....I should have it n tomorrow,
Back to top
View user's profile Send private message 
starhawk

Joined: 22 Nov 2010
Posts: 2879
Location: Everybody knows this is nowhere...

PostPosted: Tue 12 Mar 2013, 16:58    Post subject:  

I eagerly await your video... Wink

Minus the programming part (which will be hard for me, but I think I can do it) the entire design is basically done. It uses parts from Mouser Electronics (www.mouser.com) and Radio Shack. There will be one part that must be scrounged (the PS/2 cable) but that's not a terribly big deal IMO. Nearly anyone should be able to build it in an afternoon -- so it doesn't need factories and mass-production, it can be built by hobbyists and makers the world over! (This also lowers the cost of things dramatically.)

I have a couple of things I'd want to talk to you about, to get the design spot-on, but at this point I'm just doing fine-tuning.

The problem with the programming is that I'm used to a very old programming language that the world has largely moved on from -- QuickBASIC -- and the Arduino uses a subset of C/C++, which is completely different. I'll have some learning to do!

I would like to open-source this design if at all possible... I'll be glad to assemble one or two for you, and we can figure out how to tweak them, but as I said above -- if you can hold a drill, and if you can solder, then you can build this thing yourself.

I will also mention -- if you need to use a USB-to-PS/2 adapter with this, for computers that do not have PS/2 ports, you need to steer clear of these two styles of adapter --
Passive, wires-only adapters, like this one.
Active but super-cheap adapters like this one.

The one in the first link won't work, and it could damage things. Those rely on the mouse being able to detect what kind of port it's attached to, and switch by itself. This device can't do that!

The one in the second link will "sort of" work -- those have HORRIBLE filtering (if any at all) in them -- I had one and it was so jittery that I just got rid of it. The mouse cursor dances a jig even when the mouse ISN'T moving, and when it is moving the dancing gets worse. By the way, these come in both beige and black -- so don't be fooled, lol.

I can't speak to how well the following adapters work, but money provided I'll gladly test them --
http://www.ebay.com/itm/280775192717
http://www.ebay.com/itm/111011014372

_________________
Loving X-Slacko 2.1!
Custom Build: HP MOCA-AR + Core2Duo T7200 + 4gb RAM + 256gb SSD
...just needs a pretty case Wink
Back to top
View user's profile Send private message 
standard7452

Joined: 25 Feb 2013
Posts: 15

PostPosted: Wed 13 Mar 2013, 19:01    Post subject:  

I made a couple of videos to explain what the project entails...


...I apologize if I seem sassy on the video, I had to do it in the early morning, and I am not a morning person.

I just went over the basics, not because I think anyone is dumb, it just is such a weird thing to explain to folks....

Plus this is the first time I have ever made a vid like this so I didn't want to look too stupid....

Thanks for your help!

part one - http://www.youtube.com/watch?v=BaKmdhGexVk

part two - http://www.youtube.com/watch?v=6b857d5G2Qs
Back to top
View user's profile Send private message 
Ted Dog


Joined: 13 Sep 2005
Posts: 2339
Location: Heart of Texas

PostPosted: Wed 13 Mar 2013, 19:12    Post subject:  

Thanks, DL them now, internet is slow for me.... Sad
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 2 of 9 [134 Posts]   Goto page: Previous 1, 2, 3, 4, ..., 7, 8, 9 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Puppy Projects
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
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1270s ][ Queries: 13 (0.0076s) ][ GZIP on ]