question on left and right soft key

Can I please have help on a support case I have?

From what I can see the Left and Right soft keys on the MT2000 are mapped to App1 and App2 respectively. I have been told that App1 and App2 map to the Operating System level as C1 and C2. Is there a way to redefine this value? Possibly through the registry?

I am not looking to remap App1 and App2 but instead change the value they are assigned to at the OS level.

Thank you,
Amy
Li Chen
There is a VS project in DCP

There is a VS project in DCP package that is called KBTool. It allows user to customize the keypad mapping.

For this particular case, say the customer wants to have F1 and F2 keys (hex 70 and 71) instead of hex C1 and C2 when left and right soft keys are pressed. They just need to change the SC_App1 and SC_app2 to SC_F1 and SC_F2 in MatrixKeyS.cpp and MatrixKeyR.cpp files. Build the project, whcih will generate a makebins.exe file. Run that file in a command line window. You will het three keypad mapping files, .mmt, .rmt and .sct files. Copy them onto the device under "Platform\Keyboard\" directory. Reboot the device. Now the left and right soft keys are mapped to F1 and F2 keys.
Vote: 
Vote up!
Vote down!

Points: 1

You voted ‘up’


Kenneth Ryan
Let me describe the exact

Let me describe the exact issue.

The customer is using the MSP Remote Control Agent.  This agent does not have the C1 and C2 keys in it.

Therefore when controlling MT2090 remotely they cant get the Left and Right Soft Menu Buttons to activate.

The though was the remap at the OS level the actual keys that trigger the Left and Right Soft Menu functions to different keys.  Not remap they hardware keys themselves to different values.

That way no matter what button I press that is mapped to F1, Left Soft Menu Button FUNCTIONALITY gets triggered.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
By remapping the left and

By remapping the left and right soft keys to F1 and F2, the app will never see C1 and C2 any more and the F1 and F2 are corresponding to the soft keys.

If I understand correctly, there is no simple way (such as a reg key change) to modify the remapping of the same scancode to different virtual key on the OS level. That involves the keypad driver change.
Vote: 
Vote up!
Vote down!

Points: 1

You voted ‘up’


Kenneth Ryan
So if I remap the Left Soft

So if I remap the Left Soft Key to SC_F1 from SC_App1, will pressing the Left Soft Key still bring up the Left Soft Key functionality in navigtor.exe?
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
How does Navigator.exe know

How does Navigator.exe know which key should bring up the left and right soft key functionality?  Does it do a RegisterHotKey()?
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
The other apps, which have

The other apps, which have already programmed to react on SC_App1 and SC_App2, won't recognize them as left and right softkeys.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
I am wondering if there is a

I am wondering if there is a way to make their app recognize the 0xC1 and 0xC2, since they are valid virtual keys...
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
Its not even there app.  This

Its not even there app.  This is a Motorola issue entirely.

They are using MSP to control the MT2090.  We make MSP.  Our Remote Control Agent is the one with the issue, but MSP team is at this time stating that F1 and F2 should work.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
The thing is that even if we

The thing is that even if we change the virtual key mapping in the OS level (which means changing the keypad driver), it will still break the other apps that are already programmed to work on SC_App1 and SC_App2.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
I dont see any explicit

I dont see any explicit mention in those apps like ScanItem and ScanInventory to C1 and C2.  They just mention using the Symbol.MT2000.UserInterface.SoftKey class.  Correct me if I am wrong but is that not managed at ScannerServices level?
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
I don't think ADCService

I don't think ADCService controls the virtual key mapping. Neither does Symbol.MT2000.UserInterface.SoftKeys class. ScanItem would break if the keycode it gets from CE changed.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
So what actually controls the

So what actually controls the Left Soft Key menu options being displayed?  I dont see any reference in any samples to the actual key.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
The UI code controls what it

The UI code controls what it does on the softkeys (for instance the LeftSoftKeyPressed function all over the classes in UI code). They do not control what softkey should be mapped to.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
Just to tie this off then,

Just to tie this off then, there is no way to remap the key that triggers the Left and Right Soft Key functionality from SC_App1 or C1 to F1 without a new keyboard driver?
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
Well, there is a remapping

Well, there is a remapping method without modifying the driver as I mentioned in the previous reply. Or, change the keypad driver to do the remapping in the OS level. The thing is that either way will change the behavior of the keypad. I am afraid we can not just make the change without worrying about the possible breaksown of other apps...

That's my opinion. Please correct me if I am wrong.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
If you could detail all

If you could detail all options with drawbacks I will provide to customer and see what they say.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Li Chen
The keypad driver change, in

The keypad driver change, in my opinion, is not really a good option. It has the same effect as doing the remapping via KBTool, which is designed for keypad remapping. But I believe the remapping of the keypad scancode to virtual key code has quite an impact on the behaior of the product, since it basically changes what keycode any app would get from CE.

In this particular case, if I understand correctly, the customer is trying to deploy the unit automatically with MSP. Is it possible to use the remapped the key map files during deployment, and after it is done, copy back the original key map files?

Also, would it be feasible to modify the MSP to accept 0xC1 and 0xC2?

Again, those are just my opinions. Anyone has a better idea or find that I have missed something, please let us know.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
Its not possible to get the

Its not possible to get the MSP Remote Control Agent to accept C1 and C2.

Think of the MSP Remote Control Agent like ActiveSync Remote Display.  Allows you to control device from remote PC with Windows Keyboard and Mouse.

The problem here is that the Windows Keyboard does not have an App1 or App2 key...the App1 and App2 (C1 and C2) keys are specific to Windows CE and Windows Mobile.

As such it cant do it.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Mike Faith
OK - Just to Recap: MSP can

OK - Just to Recap:

MSP can not remotely control the Left and Right soft keys on the device UI because it can not generate the VK_APP1 and VK_APP2 (0xC1 and 0xC2) keycodes that the UI is looking for.  It would be more convenient for MSP if the device UI were looking for VK_F1 and VK_F2 for the softkey codes  (0x70 and 0x71)

It works the way with ActiveSync Remote Display as well.  

Device keyboard mapping will not help. It can change the keycodes returned to the application for the softkeys but it does not remapp what keys the application is looking for.  The UI suite will still be looking for the old VK_APPx keycodes.

Just thinking out loud here:

- Does there exist a keyboard that supports the VK_APP key codes that can be used with MSP?

- Does there exist a key mapping tool for the PC that can map 2 keys to the 0xC1 and 0xC2 keys the UI is looking for?

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
Hi Mike, 1.  VK_App1 and VK

Hi Mike,

1.  VK_App1 and VK_App2 are Windows CE and Windows Mobile specific keys.  No windows key maps these on a PC.
2.  Not possible from what I can see.
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Kenneth Ryan
Any more thoughts regarding

Any more thoughts regarding this?
Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Log in to post comments