Olga99

Hi!

 

I am writing an installation program (in C#, VS2005)  which is installing CAB file using Active Synch manager  on the pocket pc device (Windows Mobile 2003 SE, Windows Mobile 5.0 and Windows CE 5.0). App has to install .Net CF 2.0 and SQL Server Compact Edition (Mobile) CABs on the device. I am using RAPI to communicate with device. In order to install appropriate CAB files, I have to detect device processor or Instruction Set ID as outlined in the ¡°Creating an MSI Package that Detects and Updates the .NET Compact Framework¡± article. But it seems that RAPI is not capable to do it. And it is very difficult on Windows Mobile and CE 5.0 (for security reasons) to run dll on the device.

 

Is it any other way I can detect processor type (especially for MIPS and SH processors)

As example ¨C for MIPS processor type for the SQL Server Mobile there are CAB files in ¡°mipsii¡±, ¡°mipsii_fp¡± and ¡°mipsiv¡± folders.

 

Help will be greatly appreciated.

(by the way - message text formatting does not work in Firefox...)

Olga



Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Ilya Tumanov

You probably don't need to worry about that because unless you specifically asked to develop for Windows CE (and given specific device to develop for) your application would never run on generic Windows CE. If you are asked to develop for specific device running CE you don¡¯t need detection either because application will only run on this specific device and nothing else.

One more reason not to worry about it: CE devices rarely support AS except for may be some ARM models with built in bar code scanners.






Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Olga99

Hi!

Thank you for a quick response.

Unfortunately we can¡¯t foresee what type of processor the end user will use¡­ But my app seems to be working fine on ARM processors, as for the other processor types ¨C we just will have to lead the user through install of individual CAB files.

It could be nice to add to RAPI functionality to detect processor type or/and instruction set ID (as outlined in the article).

Another question ¨C is there any tutorial on how to add provisional xml files to the Windows Mobile 5.0 and Windows CE 5.0 device to enable invoking native DLL on device (the same way as it can be done for Windows Mobile 2003 devices)

Olga





Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Ilya Tumanov

You absolutely can. Generic end users would never use CE, it's a custom platform designed for specific custom application running specific custom software.

Unless your application is designed for and tested on specific CE device with specific OS build there's no way to tell if it even would work as CE images are custom built with custom set of components. That is, whatever your application is using - it might not be available on particular CE. For example, many of these CE devices come without screens, don't have shell APIs and so on. That¡¯s why CE applications are always developed and tested on specific devices they would be deployed to, basically there's no general purpose software for CE.

If your application is designed for generic audience it's very safe to assume it would be WM only, no CE. In other case it needs to be tested on all CE devices it targets.

Provisioning and security is WM only feature. Generally there's no security on CE (though OEM can implement custom security) which means it would work just like on WM 2003 with DLLs. That¡¯s assuming CE device supports AS which is quite unlikely.






Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Olga99

Thank you for a quick reply.

I did father research - and it looks like most bar code scanner-enabled pocket pc most likely to use ARM processor. My desktop application communicates with connected via Active Synch pocket pc, installs prerequisites and my app (.Net CF 2.0 and SQL Server CE on the device, then install my asset management pocket pc app). I tested it on Symbol MC70 (with WM 5.0), MC3000 (WinCE) and Dolphin device with WM 2003. Customers with MIPS or SH processor types can install appropriate prerequisites CAB files.

I can pinvoke DLL on WM 2003, but it does not work on WM 5.0.

I hope in the future we will be able to detect processor type through RAPI.

Tahnk you again,

Olga





Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Ilya Tumanov

Few comments:

1. You supposed to sign all (or rather pay to signing authority for signing them for you) your binaries and CABs for Windows Mobile 5.0, in other case they won't run in certain circumstances and they might produce warnings in other cases.

2. You can query instruction set through RAPI using CeQueryInstructionSet() and/or through CeGetSystemInfo().

3. RAPI can be disabled on some WM 5.0 devices even though they might support AS and can install software through CeAppMgr.exe






Re: .NET Compact Framework Problem detecting mobile device processor type via RAPI

Olga99

Thank you for comments.

My problem is to install appropriate CABs for SQL Server CE remotly on the client's bar code scanner-enambled pocket pc. But as long as it works for the ARM-based processor, we should not worry about other processor types, looks like most bar code scanners have ARM-based processors. Soon we will release our app for community preview. Most of our customers are using Symbol devices, so it should work OK for them. I should support both, WM 2003 and 5.0, so I can't use RAPI 2. I will post here the results of community testing.

My apps CAB file is not sign and works OK on test machines. I think it will be working OK, as long as we can help customers to configure their devices.

Thank you for help,

Olga