Windows Embedded CE and Windows Mobile (June 24, 2008)
Chat Topic: Windows Embedded CE and Windows Mobile
Date: Tuesday, June 24, 2008
Sue Loh [MS] (Moderator):
Welcome to today’s public chat. Our chat today covers the topic of Windows Embedded CE and Windows Mobile!
Sue Loh [MS] (Moderator):
We are pleased to welcome our Experts for today’s chat. I will have them introduce themselves now.
Introductions:**
Travis Hobrla [MS] (Expert):
Hello, my name is Travis Hobrla and I'm a developer on the Windows CE Embedded BSP team.
russellk_MSFT (Expert):
Hi, I'm Russ Keldorph. I work on the native C++ compilers and runtime libraries.
Ryan Ward [MSFT] (Expert):
Hello, I'm Ryan Ward and I am a SDET on the Platform Builder IDE team.
Sue Loh [MS] (Moderator):
Hi, I’m Sue Loh, a developer in the Windows Devices Core team at Microsoft. I work on the remote tools team, and have previous experience with the kernel and file system. I’m also moderating today’s chat. I hope we can answer some questions for you today!
Peter Nowak (Expert):
Hi. My name is Peter Nowak and I'm a german Device Application Development MVP.
Michael_MSFT (Expert):
Hello, I am Michael Malueg, lead PM in the Windows Embedded CE group focusing on Portable Navigation
GLanger_MS (Expert):
Hi, I am Glen Langer, lead program manager for BSPs.
Sue Loh [MS] (Moderator):
Let’s begin the chat!
Start of chat:*
Mikethom [MS] (Expert):
Q: What is the restriction of an unlicensed Windows CE Image?
A: Huhu are you asking about what you can do with an image you build with PB without an OEM runtime license? If that is the case then the license.rtf file or EULA describes what you can do with an image in a non-commercial release that would not have an attached OEM runtime license.
Mikethom [MS] (Expert):
Q: I have license stickers but forgotten to stamp the image
A: So it looks like you have a COA for the device that must be displayed on the device and you where also given a PID that you were suppose to use stampbin.exe on to stamp your image. The Image will continue to run without the image stamp but you should go back to your requirements and determine what you should do next.
Sue Loh [MS] (Moderator):
Q: Will you cover Compact Framework questions here as well?
A: We can try but no guarantees we know the answer. What's your question?
Peter Nowak (Expert):
Q: When using the CF's class Bitmap to load images, I've noticed that it fails to load if the image is too large. When I reflect on the Bitmap type, I see that it calls into AGL, which is either in the CLR or a wrapper for some unmanaged bitmap class. Yet when I use the unmanaged Imaging API, I can load any image of any size. Any reason why the limitation in the Bitmap class?
A: Chris Tacke did some research on this topic in August 2006. It has to do something with Device Dependent and Device Independent Bitmaps. Please take a look at his blogpost over here (https://blog.opennetcf.com/ctacke/PermaLink,guid,987041fc-2e13-4bab-930a-f79021225b74.aspx).
Sue Loh [MS] (Moderator):
Q: Are there any managed wrappers for remote debugging and monitoring tools?
A: There aren't any wrappers for the tools you see in the remote tools menu. There are some sample apps to plug in and consume some of the data, for example kernel tracker has a little data consumer sample, but those are all native. The closest we come is the Remote Tools Framework, which was new in PB6-SP1, which you can use to develop your own managed remote tools. But still there are no wrappers for those tools either. What are you looking for?
Sue Loh [MS] (Moderator):
Q: Sue, I'm looking for connectivity mechanisms to do things like instrumentation during debugging: collecting code coverage data, etc.
A: Okay, well if it's just connectivity, the Remote Tools Framework is our recommended platform for building any connected tools. It's pretty simple to pass data back and forth with a Remote Tools Framework tool. However it doesn't specifically get you any data from the other tools -- your device side is basically just an app so you can call any device-side API. If you are looking to plug in to our existing code coverage tool I don't know how to do that, or even if there is a way to do that.
Sue Loh [MS] (Moderator):
Q: Does Windows CE 5.0 support debugging tools such as Post mortem debugger other than platform builder?
A: I'm not sure if I understood your question correctly, but there is a post mortem debugger and I'm fairly sure it was supported in CE 5.0. What kind of tools are you looking for?
Sue Loh [MS] (Moderator):
Q: Hi sue. Thanks. But I am in search for tool which can be used to analyse real time crashes when KITL is not connected. I guess Post mortem debugger can analyse the .KDUMP files and reproduce the crash screnarios without target being connected.
A: Are you looking for something which "automatically" analyzes the crashes for you on the device side? Or a tool other than PB to look at crashes? Or I wonder, maybe what you're really after is the "passive KITL" option, where KITL does not connect until a crash happens? With passive KITL you can run the device without a KITL connection, then hook it up to a PC to debug over KITL after the device hits a crash.
Sue Loh [MS] (Moderator):
Q: yes. I am in search of any such tool which can analyse crash when there is no KITL connected either in passive or active mode. One of the tool which I know is CeDebugX which can show call stack info when KITL is in passivr mode. Is there any other tool?
A: I am sorry but I still don't understand you. What do you mean by "the tool can analyze" - do you just want a dump like Post Mortem debugging gets, or do you want automatic analysis? I really don't think what you are looking for exists, but maybe I'm just not understanding. What is insufficient about the post mortem debugging dump, what features is it missing that you are looking for?
Mikethom [MS] (Expert):
Q: I'm a long time Windows programmer, back to release of Win 32 and c/c++. Just starting work with a company developing a device with ARM9 processor. Best development transition suggestions?
A: Doug Boling has a pretty good book that covers everything and there is training from him and others that can get people up to speed quickly. There should be some resources up on https://www.microsoft.com/embedded
Mikethom [MS] (Expert):
Q: Are there any plans to revamp Pocket Outlook and other common applications that ship with Windows CE, to be more touch-friendly, instead of using tiny scrollbars, menu buttons, etc., that almost require the use of a stylus? Any changes in the shell 4 ths?
A: We are looking at changes in the future that will help in this area but nothing more to report at this time.
John Spaith [MS] (Expert):
Q: Is there a generic navigation API that I can access instead of vendor-specific GPS APIs?
A: No, there is not such a generic navi API I'm afraid. Currently all that MS currently provides you is position of where you are.
John Spaith [MS] (Expert):
Q: Is there any work being done to come up with generic APIs for common devices like WiFi, barcode scanners, RFID readers, GPS, etc., and have vendors plug in device drivers to map the generic APIs to their specific implementations? (This is very important.)
A: Currently the closest thing we have is a Location Framework (https://msdn.microsoft.com/en-us/library/aa917993.aspx) which abstracts out location specific hardware information; so lat/long, 802.11 nearby wifi spots, etc. It's not anywhere near as ambitious a sensor framework as what you're proposing. I can't comment officially on future releases in a public forum, but it's safe to assume that no, we won't have something like that in immediate future either.
TomGet [MSFT] (Expert):
Q: Standard APIs for common devices, yes... but for an extra processor, there are all kinds of neat things you could use it for. :)
A: Agreed, but unfortunately, we can't help you.
Mikethom [MS] (Expert):
Q: In windows CE 5.0 activesync support is not there on RNDIS profile .Whether windows CE 6.0 supports active sync over RNDIS profile?
A: I believe that 5/6 share the same AS profiles.
TomGet [MSFT] (Expert):
Q: When do we get alpha channel support for bitmaps in CE? :) I am doing some alpha blending work, and supplying my own alpha value for each pixel in a bitmap is a pain.
A: Unfortunately, we can't talk about the timing of any particular features. But, I'd appreciate hearing what you feel is missing. What APIs would you expect to support Alpha?
TomGet [MSFT] (Expert):
Q: And in general, do Device Independent Bitmaps support an alpha channel on Windows CE?
A: Unfortunately, not very well. There is some support, but it's rather spotty and not well tested.
TomGet [MSFT] (Expert):
Q: This is a problem I have with alpha values. Wondering if the problem is in .NET or in the DIB structure, or somewhere in CE?
Bitmap bmp = new Bitmap(100, 100);
Color c = Color.FromArgb(83941635);
int IntendedAlpha = c.A; // 5
bmp.SetPixel(0, 0, c);
Color c2 = bmp.GetPixel(0, 0); int alpha = c2.A; // 255, wrong value
A: My graphics experts tell me GDI should work correctly, so this is likely an issue with the .Net CF implementation.
TomGet [MSFT] (Expert):
Q: Some new WinMobile devices are coming out with graphics processors. How do we detect these and take advantage of them?
A: There are two ways to access the graphics processors today. One way is D3DM, which is the programming model for Windows Mobile 6. Another way is OpenGL ES - but, the implementation may vary between devices.
TomGet [MSFT] (Expert):
Q: So I can use one of these graphics libraries to make use of the graphics processor, but there are no other, more direct ways? Couldn't this processor be tapped for non-graphics related tasks?
A: I thought you were looking for standardized APIs. If you want direct access to the hardware, the only way is to work with the hardware provider to get the details you need.
Peter Nowak (Expert):
Q: We are looking for a Microsoft solution for graphics and game development for Windows CE 5.0 and the Compact Framework; we prefer Managed Code. We’ve tried some things, but have not been successful yet. Is Managed DirectX an option? Will XNA work for ou
A: I think in this case Managed Direct 3D Mobile is the only feasible possibility you have, if you want to go that way, as no XNA Framework version is available for Windows Mobile / Windows CE. Why haven't you been successful? What has been there problem?
Peter Nowak (Expert):
Q: Thanks Peter. We have tried Microsoft.WindowsMobile.DirectX but we didn’t get it working. An error was thrown “Unsupported system exception”; and we did not determine why or what we needed to do to get things working.
A: There are some official samples (https://msdn.microsoft.com/en-us/library/ms181014(VS.85).aspx) and a good tutorial (https://channel9.msdn.com/posts/scobleizer/Chris-Muench-writing-managed-3D-app-for-mobile-devices/) available. have you tried any of these?
Peter Nowak (Expert):
Q: Peter: Is https://msdn.microsoft.com/en-us/library/ms181014(VS.85).aspx the same as https://msdn.microsoft.com/en-us/library/ms181014.aspx? It seems to be and our programer looked at these samples.
A: Sorry. Actually I'm not a Direct 3D Programmer, whether managed or unmanaged. I've been requested those links several times in the past and I never heard any feedback on any problems with them.
Peter Nowak (Expert):
Q: Anyway, he tried a couple of samples from https://msdn.microsoft.com/en-us/library/bb278108.aspx (Casual Game Development with Managed Direct X); were these appropriate?
A: Sorry, but those are samples for the .NET Framework and not the .NET Compact Framework. They can't work on Windows Mobile. That's the main error here. ;-)
Peter Nowak (Expert):
A: Sorry - an error on my site. I've misread the page. I haven't seen this samples in the past, so I can't say anything on them whether they work or not. The ones I mentioned have worked in the past. Please give them a try.
Peter Nowak (Expert):
Q: I notice there is a C++ sample for Direct Show (to capture video from the device's camera) in the WM6 SDK, is there a C# version of this code available?
A: As far as I know there is no managed variant of this sample available.
TomGet [MSFT] (Expert):
Q: Is there a way to know the currently running fitergraph of WMP 10.x mobile in Windows Mobile? something similar to the PIMG log
A: Not really. Why would you want to know this?
Peter Nowak (Expert):
Q: I would be interested in configuring a WPA or WPA2 wireless connection on a Windows Mobile 5 or 6 device. Is the easiest way to do this via provisioning XML? If so, are there any examples of XML to use to achieve this?
A: Please take a look at this post (https://www.windowsmobiletraining.com/connection/forums/t/441.aspx). It shows you how to use a CSP for provisioning. I actually don't know, if there is another possibility available.
Sue Loh [MS] (Moderator):
Q: Hi, My name is Milind. I am working on WindowsCE 5.0. I have question about USB mass storage class driver support. I want to know how expose selective partition to host machine?
A: This isn't a full answer, but maybe it will help:
I guess they are talking about USB function mass storage. My limited knowledge tells me that there isn’t a way to associate USBFN Mass storage to a partition, the only way right now is to specify the disk by given the “DSKn:” in the corresponding registry. So if customer knows the mapped disk name for the desired partition, then he or she can setup the registry. Unfortunately that mapping must be fixed.
I am still waiting on further answers from other experts.
Mikethom [MS] (Expert):
Q: Is there any way to disable thread preemption in the Windows Embedded CE and its variant OSes for cooperative synchronization, something similar to TaskLock and TaskUnlock in other RTOSes
A: You can prevent other thread from running if you are set to the highest priority and your thread quatum is set to 0. This will have the kernel only schedule your thread to run. During this time interrupts could occur which will stall your thread somewhat. So if you want to prevent that from happening as well then you need to disable interrupts while you are doing something. You can over use these models and cause your platform to not function correctly so you need to be very careful.
Sue Loh [MS] (Moderator):
Q: Is there any way to disable thread preemption in the Windows Embedded CE and its variant OSes for cooperative synchronization, something similar to TaskLock and TaskUnlock in other RTOSes
A: Sorry, I'm not familiar with TaskLock and TaskUnlock. But I'm guessing the preemption you want to disable is purely preemption by other threads at the same priority? In other words, you want the threads to run entirely to completion instead of switching between each other? In that case would SetThreadQuantum (to infinity) do what you want?
Travis Hobrla [MS] (Expert):
Q: Thanks for answering. This involves 4 (before and after CS) system calls CeSetThreadPriority and CeSetThreadQuantum to protect the CS and this defeats the purpose of cooperative sync
A: If that doesn't help you, can you describe in more detail exactly what you're trying to achieve from a synchronization standpoint?
Travis Hobrla [MS] (Expert):
Q: i want to disable preemption by all threads (in the same priority or high priority). Actually we require this as part of OSAL (OS Adaptation Layer) for a custom low-level multimedia framework
A: As far as same priority, you'd have to change the thread quantum to disable preemption. When you say higher priority, do you mean higher priority from the CeThreadPriority numerical scale? If you just want to disable _pre-emption_ then you will need to turn interrupts off completely. If you want to disable rescheduling then setting the thread quantum will do that, but it won't save you from threads with lower priority (on the CeThreadPriority numerical scale). That's why you'd need to bump your thread to priority 0.
Mikethom [MS] (Expert):
Q: Are there going to be any future developments that allow multiple devices to be accessed from a single desktop machine via active sync?
A: This was not designed with that scenario in mind. Maybe there is a better protocol for what you are trying to do? Private message me with some details
GLanger_MS (Expert):
Q: Is it possible to recharge a Windows Mobile device using hand power (hand crank etc.) with a small hand powered electric generator that can be carried in your pocket? Say, with 10-20 minutes of winding on the bus, in nature parks, etc.?
A: Yes, it's possible. But it depends on the phone and the hand-powered generator. I have a hand-powered flashlight that says it can charge phones. No one on the WinMobile team has actively looked at this to my knowledge. I'll pass along the suggestion.
Sue Loh [MS] (Moderator):
Q: Should I be able to use Standard SDK 5.0 with VS2008?
A: Yes, I believe so, though I do not have first hand experience with that. Are you having a problem?
Sue Loh [MS] (Moderator):
Q: VS2008 does not see Standard SDK 5.0 as an option. I'm curious if there is a compatibility issue with this.
A: Hmm, I've seen a similar problem if VS was running during the SDK install. If you make sure VS is not running, and do a "repair" on the install, then restart VS, that might clear up the problem.
Sue Loh [MS] (Moderator):
Q: In my case SDK 5.0 was installed first. I will remove and re-install. This should be documented somewhere.
A: Hmm I don't think that's the same issue then. You can try a "repair" but maybe there really is an issue.
Travis Hobrla [MS] (Expert):
Q: Any plans to implement a wear leveling layer for NAND flash?
A: The FAL (Flash Abstraction Layer) already does wear-leveling. Are you talking about a separate public layer for wear-leveling?
Travis Hobrla [MS] (Expert):
Q: 37: yes a seperate layer
A: Don't believe there are plans for this currently. Are you interested in having the FAL exposed or just want to plug in your own wear-leveling?
Sue Loh [MS] (Moderator):
Q: We are migrating a platform from VxWorks to WinCE 6.0. We have run perfalyzer traces against the platform and we are seeing that 27% of our time is in DoWaitForObjects. Is there a way to see what objects we are waiting on?
A: Yeah, the best tool to figure out why threads are waiting is CeLog - and the Kernel Tracker UI for visualizing the CeLog traces. If you check out my blog (https://blogs.msdn.com/sloh) and my team blog (https://blogs.msdn.com/ce_base) you'll find posts I wrote about these tools.
Sue Loh [MS] (Moderator):
Hello everyone, we are just about out of time.
Thank you for joining us today for our Windows Embedded CE 6.0 chat today! A special thank you to the product group members for coming out.
The transcript of today’s chat will be posted online soon, to https://msdn.microsoft.com/chats/transcripts/default.aspx. We’ll see you again for another chat next month. Please check https://msdn.microsoft.com/chats for the list of upcoming chats.
If you still have unanswered questions, let me suggest that you post them on one of our newsgroups, such as Microsoft.public.windowsce.platbuilder.