Key stroking simulation in Windows Mobile Dev
Let's talk the topic directly. keybd_event() can send key board events, which is available in WinCE 1.0 and later. The Win32 version of the function is also available in win9x/nt3.1, so it's toooold. You can also use PostKeybdMessage available after WinCE 2.0.
keybd_event taks four parameters.
VOID keybd_event(
BYTE bVk,
BYTE bScan,
DWORD dwFlags,
DWORD dwExtraInfo
);bVk
- [in] Specifies a virtual-key code. The code must be a value in the range 1 to 254. For a list of virtual-key codes, see Virtual-Key Codes.
- bScan
- [in] Specifies a hardware scan code for the key.
- dwFlags
- [in] Specifies various aspects of function operation. An application can use any combination of the following predefined constant values to set the flags.
Value
DescriptionKEYEVENTF_EXTENDEDKEY
If specified, the scan code will be treated as an extended key by giving it a prefix byte having the value 0xE0 (224).KEYEVENTF_KEYUP
If specified, the key is being released. If not specified, the key is being pressed.KEYEVENTF_SILENT
If specified, a keystroke is simulated, but no clicking sound is made.- dwExtraInfo
- [in] Specifies an additional 32-bit value associated with the keystroke.
In most conditions, you may only need the first and third parameters.
Virtual-key code:
VK_0 thru VK_9 are the same as ASCII '0' thru '9' (0x30 - 0x39)
VK_A thru VK_Z are the same as ASCII 'A' thru 'Z' (0x41 - 0x5A)You can get others from MSDN
So, this is an simle example of send 'F' key press event:
const byte VK_F = 0x46;
keybd_event(VK_F, 0, 0, 0); // key pressed
keybd_event(VK_F, 0, KEYEVENTF_KEYUP, 0); // key released
see also: MSDN: keybd_event()
CE 6.0 – why the codename “Yamazaki” ?
CE 6.0 - why the codename "Yamazaki" ?
CE 6.0 - why the codename "Yamazaki" ?
I've been asked why we used the name "Yamazaki" as a codename for CE 6.0 - There's some history behind the naming of Windows CE versions, here's the short version...
Before the Windows CE product was released we had an internal set of tools known as the Oem Adaptation Kit also known as the OAK - an OAK of course is a type of tree.
The initial releases of Windows CE were therefore named after trees, as follows.
Windows CE 1.0 - Alder (Nov 1996)
Windows CE 2.0 - Birch (Nov 1997)
Windows CE 3.0 - Cedar (Apr 2000)
Interestingly, there was a second team within the Windows CE group that worked on the tools, I guess you could consider tools to be something that makes a job easier, or cuts the job down to size - therefore the tools releases were named after things that cut down trees - as follows...
Windows CE 1.0 - Alder - Tools: Axe
Windows CE 2.0 - Birch - Tools: Buzzsaw
Windows CE 3.0 - Cedar - Tools: Chainsaw
For Windows CE 4.0 the original plan was to call the O/S DougFir (DouglasFir), the thing that cuts down DougFir trees was going to be Dozer (BullDozer) - interestingly, at Windows CE 4.0 the o/s team and tools teams merged together to form a new, combined team - the codenames for the operating system and tools also changed at this time from trees/tools to
Windows CE 4.0 - Talisker (Jan 2002)
Windows CE 4.1 - Jameson (Jun 2002)
Windows CE 4.2 - McKendric (Apr 2003)
Windows CE 5.0 - Macallan (Aug 2004)
Windows CE 5.0 Network Device Feature Pack - Tomatin (Apr 2006)
Windows CE 6.0 - Yamazaki (Sep 2006)
Don
*originally posted on Mike Hall's Weblog
WIN CE Platform Builder 6.0 Evaluation Offline Download
在网上找到的WINCE PB 6文件列表。
存成dl.txt,然后wget -i dl.txt,睡一觉起来就可以看到接近4G的文件了。
运行Windows Embedded CE 6.0.msi进行离线安装。
试用key的获取












