Welcome Guest.   Make a donation to an author on the site July 28, 2014, 01:33:46 PM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
Read the Practical Guide to DonationCoder.com Forum Search Features
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1] 2 Next   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: DONE: Toggle mouse acceleration with a simple program  (Read 23928 times)
doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« on: September 03, 2009, 12:24:46 AM »

My annoyance is fairly straightforward, as well as (I would hope) its solution:

I want to toggle this with a hotkey:



THE STORY:

I bought a touchpad for my desktop to combat RSI. It's... ok, I guess. See, the driver that it comes with doesn't actually recognize the touchpad, which means that Windows sees it as a mouse. This isn't a huge problem; it works fine. Though without the driver, it lacks some customizable options, I can live with it. My mouse remains plugged in, since I will be swapping between the two devices based on the tasks I am doing.

The problem is that I now have two devices that run on the same control panel settings, and physically are two devices with different kinds of sensitivity.

The touchpad actually causes more strain without the "Enhance pointer precision," option enabled, since moving the pointer requires repeated 'scrubbing' with the fingers. With the feature enabled, I can move the pointer much more easily while retaining control.

However, this setting is far too sensitive for my mouse, which flies all over the screen like an out of control fighter plane.

To switch devices, I have to launch the Mouse applet, toggle the "Enhance pointer precision" setting manually, then resume using my input device. Without a helpful shortcut, I have to do this many times a day.

PROBLEM: Two pointing devices on one system, one that needs mouse acceleration, the other doesn't. Need an easy way to toggle the "Enhance pointer precision" setting to aid in switching between the two devices.

SOLUTION: A small program that launches, toggles the "Enhance pointer precision" setting from the Mouse control panel applet, and then closes itself. (If the setting is active, it deactivates it. If it's inactive, it activates it.)

Since this is an issue I've found with laptops I've used as well, this could be useful beyond my specific use case. I've often had to resort to touchpad on the go, and later dock, to find that my mouse is flying uncontrollably until I toggle this setting off.

Since I already use a decent hotkey manager, I don't need this to be a running program. Ideally, it would just execute, toggle the setting, and close. I can call upon the program when I need it.

BONUS: The ability to store actual mouse settings as profiles, and toggle in between them with user-configurable hotkeys. This is far beyond my own needs, of course, but this might be a more interesting challenge for some.

Thanks for your time, o programmers of tiny things.
« Last Edit: September 27, 2009, 07:58:25 AM by mouser » Logged
doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #1 on: September 03, 2009, 12:27:56 AM »

Darn, I think I may have posted in the wrong forum. Mods, can you please move my post to the correct place? I apologize for the mistake. tellme
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #2 on: September 03, 2009, 02:03:32 AM »

Try this:  Mat (Mouse Acceleration Toggler)

1) Unpack archive to a folder of your choice.

2) Run MouseAccelToggler.exe with one of the following switches:

    1) -on       This will turn mouse acceleration on.
    2) -off      This will turn mouse acceleration off.
    3) -toggle   This will toggle mouse acceleration from its current state.
« Last Edit: September 27, 2009, 10:35:21 PM by skwire » Logged

doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #3 on: September 03, 2009, 02:56:13 AM »

Perfect. Thank you!
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #4 on: September 03, 2009, 03:11:20 AM »

You're welcome.  May I assume it's working for you?  If so, we'll call it done.
Logged

Kamel
Honorary Member
**
Posts: 138


View Profile Give some DonationCredits to this forum member
« Reply #5 on: September 27, 2009, 01:16:37 PM »

And I thought I was the only one with these problems haha.

Thanks for this, I too will be using it. If you would like to improve it, I think it would be best improved by having mouse sensitivity and/or acceleration options, and store/load all of them according to which one you're using.

I actually switch between my touchpad and a gaming mouse, so the sensitivity difference is quite substantial. This little app will probably be all that I need to switch between the 2 easily though.
Logged

I'm the guy you yell at when your DSL goes down...
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #6 on: September 27, 2009, 02:34:30 PM »

If you would like to improve it, I think it would be best improved by having mouse sensitivity and/or acceleration options, and store/load all of them according to which one you're using.

Just to clarify, you would like to be able to set the pointer speed value, right?

Logged

doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #7 on: September 27, 2009, 04:52:58 PM »

If you would like to improve it, I think it would be best improved by having mouse sensitivity and/or acceleration options, and store/load all of them according to which one you're using.

Just to clarify, you would like to be able to set the pointer speed value, right?
 (see attachment in previous post)

Just a quick update: yes, this simple software has solved my problem. However, being able to toggle pointer speed settings would also be preferred, since in my specific case, mouse acceleration isn't quite enough to make the touchpad respond the way I'd like. Instead of simply toggling a single setting, the software would also have to retrieve, store, and apply two alternating speed settings.

I do realize that this would increase the scope of the software, so I choose to be happy with what I have right now, especially since I'm in a little financial difficulty at the moment and don't have a roll of quarters to drop in some kind programmer's bucket.  embarassed
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #8 on: September 27, 2009, 05:11:18 PM »

Just a quick update: yes, this simple software has solved my problem. However, being able to toggle pointer speed settings would also be preferred, since in my specific case, mouse acceleration isn't quite enough to make the touchpad respond the way I'd like. Instead of simply toggling a single setting, the software would also have to retrieve, store, and apply two alternating speed settings.

Adding the speed setting stuff is easy.  Give me a few minutes.

I do realize that this would increase the scope of the software, so I choose to be happy with what I have right now, especially since I'm in a little financial difficulty at the moment and don't have a roll of quarters to drop in some kind programmer's bucket.  embarassed

Please don't ever worry about stuff like this.  I'm happy to help.
Logged

skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #9 on: September 27, 2009, 06:14:39 PM »

v1.0.1 - 2009-09-27
    + Added ability to set mouse speed.
    * Changed up the parameter syntax.  Please adjust any of your scripts accordingly.

Website | Download

Run MouseAccelToggler.exe with one or both of the following parameters:

    accel=[on|off|toggle]  This will turn mouse acceleration on, off, or toggle its state.
    speed=[1-20]             This will set the mouse speed.
   
    Example:  c:\path\to\MouseAccelToggler.exe accel=on speed=8

Also...if you run the exe without any parameters, it will pop up a box showing your current speed setting.
« Last Edit: September 27, 2009, 09:40:36 PM by skwire » Logged

Kamel
Honorary Member
**
Posts: 138


View Profile Give some DonationCredits to this forum member
« Reply #10 on: September 27, 2009, 09:28:21 PM »

Thanks, works just fine cheesy

The popup box is a nice touch as well.

For clarity, you might want to do accel=[on|off|toggle] instead of mode, but not picking, it's perfectly fine as-is
Logged

I'm the guy you yell at when your DSL goes down...
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #11 on: September 27, 2009, 09:40:20 PM »

v1.0.2 - 2009-09-27
    * Changed "mode" to "accel" for more consistency.  (Thanks, Kamel)

Website | Download

« Last Edit: September 27, 2009, 09:42:50 PM by skwire » Logged

doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #12 on: September 28, 2009, 02:30:29 AM »

Now this was exactly what I needed. Thank you, Skwire!

For what it's worth, I blogged about it here: http://drfrog.wordpress.com/2009/09/28/mat/
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #13 on: September 28, 2009, 06:36:19 AM »

Thanks for the wonderful writeup and kind words about DC.  Much appreciated.  =]
Logged

skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #14 on: September 28, 2009, 06:43:59 AM »

BTW, I'm a blackbox user myself and downloaded plenty of your styles over the years.  =]
Logged

doctorfrog
Supporting Member
**
Posts: 134


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #15 on: October 01, 2009, 01:18:09 AM »

Cool, I'm actually just now updating to the latest 1.17 of bblean and creating a new suite of styles. I thought I had the latest 1.17, but I guess I've been using an RC of 1.17 for more than six months. Oh, the bugs that I've endured...

I've foregone the Windows shortcuts by now and now call Mat directly from Blackbox hotkeys. Ah, but it's a good time to be alive, and also a nerd.
Logged
nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #16 on: April 30, 2010, 06:30:07 AM »

fantastic util - does more than i could have hoped for.
Logged
nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #17 on: April 30, 2010, 06:52:37 AM »

i've been playing about with the toggle function - works fine.

i'm just wondering (hoping) that maybe the app could be modified a little to provide a visual cue as to what mode the mouse speed/acceleration is in.

something blindly obvious like the cursor changing colour or shape depending on the mode.

e.g.
the mouse is acceleration ON = cursor is set to a blue cursor or a large cursor (or whatever).

the mouse is acceleration OFF = cursor is set to a white cursor or a standard/small cursor (or whatever).

maybe other cursors could be used for different speeds - maybe just a cursor with a tiny number next to it.

i'd be very happy to edit/design some cursors to include - if this is possible.

i'm just thinking that this visual cue would be extremely helpful (especially for me as i'll be swapping around the different modes and i'll forget what mode i'm in). having the cursor change appearance means it would also be instantly obvious what mode you are in, i.e. no need to look in the system tray for a mode change icon.
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #18 on: April 30, 2010, 07:48:50 AM »

i'd be very happy to edit/design some cursors to include - if this is possible.

Yes, this can be done so feel free to send me any test .ANI/.CUR files you want to use.  I like the idea of a standard cursor with small numbers the best.
« Last Edit: April 30, 2010, 07:52:40 AM by skwire » Logged

nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #19 on: April 30, 2010, 08:00:50 AM »

okay, i'll email something in a few minutes - just basic to see how things work.

would it be asking too much if the user could pick their own cursors to use. like yourself, some people will prefer a number to indicate speed - but i'd prefer a colour difference myself as it will be more immediate in recognising the difference - for acceleration on, at least (even if it's just a tiny red dot in the middle of the cursor). other people will have their own opinion of what is a good visual cue - giant cursor, coloured cursor, flashing (animated) cursor.
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #20 on: April 30, 2010, 09:07:38 AM »

would it be asking too much if the user could pick their own cursors to use.

I actually don't use this app myself but, yes, I plan to have this configurable on MAT's command-line since there is no real GUI to speak of. 
Logged

nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #21 on: April 30, 2010, 09:10:13 AM »

excellent. I've emailed you a few cursors to try.
Logged
nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #22 on: April 30, 2010, 02:33:54 PM »

not sure what's wrong but all Mouse Acceleration Toggler functions have stopped working here. i've not rebooted yet so will have to see what happens after that.

only thing i can see that is different with my system is that i've disabled all secondary monitors - everything seemed fine whilst i was using them earlier.
Logged
skwire
Moderator
*****
Posts: 4,018



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #23 on: May 01, 2010, 08:13:09 AM »

Here's a test version with your custom cursor request: http://skwire.dcmembers.c...er/MouseAccelToggler_.zip

Simply pass cursor="c:\path\to\some\cursor.cur"

You can also pass cursor="Default" to restore the normal cursor.  One caveat that I haven't been able to figure out yet is that, when using a custom cursor, it is used for all cursor functions i.e. no resizing cursors, no I-beam, etc.   huh  At any rate, let me know if it works for you.  I've tested it under Win2k and WinXP.  I don't have Vista or Win7.

not sure what's wrong but all Mouse Acceleration Toggler functions have stopped working here. i've not rebooted yet so will have to see what happens after that.

I haven't a clue.   embarassed
« Last Edit: May 01, 2010, 08:22:19 AM by skwire » Logged

nudone
Cody's Creator
Columnist
***
Posts: 4,116



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #24 on: May 01, 2010, 02:22:15 PM »

very good. i'll not be able to test it out until monday so i'll let you know then. that's unfortunate about the cursor dominating all other cursors. wish i could suggest something that you won't have already thought about.

i'm stil not sure why MAT seems to stop working sometimes. i think it has something to do with the logitech setpoint controls getting confused - not sure if that could really stop the exe with switches from working too when run on its own. there is definitely something strange with this setpoint stuff though - deleted settings keep coming back (so i need to figure out what's going on there).
Logged
Pages: [1] 2 Next   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.043s | Server load: 0.06 ]