Where’s my RAM?


So you just bought a brand new WM5 device.  The box says it’s got 64M of RAM.  You go digging through control panels on the device and find one that says it’s only got 50M.  Is something wrong?  Should you be worried about this?  The short answers are “No” and “No.”  This blog entry will explain why.


First though, please make sure you’ve read my earlier “RAM, ROM, NAND, NOR–that’s a lot of capital letters…” entry.  I’m assuming here that you understand what I described there.



It’s all about control
The primary source of this confusion stems from the fact that the control panel which shows your RAM usage only counts RAM that you have any control over.  That is to say, it only shows running applications.  There are other uses for RAM, and such things are hidden from you.  As end users, there’s nothing you can do about them, so why display them in the panel?  Now you could make the argument that you’d still like to see a listing of the RAM you can’t directly use.  The WM5 designers disagree.  I personally don’t have a strong opinion on the matter one way or the other. 


You might also make the argument that you don’t really have control of everything listed in the control panel, since there’s application RAM used at boot time and there’s no easy way to close things to free it up.  I don’t have a good answer for this, other than to say that the RAM is being used for things that we’re pretty sure you want running–the phone dialer, the PIM, the drivers that make the hardware work, etc. 


Some of that code comes from Microsoft, and we’re interested in feedback on things you don’t want to be running by default.  If we shut off the dialer, you wouldn’t receive phone calls.  If we shut down the PIM, you wouldn’t be able to see your next appointment from the home/today screen.  Etc.  If there are apps that you don’t think should be running, let us know.  The more specific and constructive you are, the better.  You’ll get more traction with, “I never use this app, so I wish it wasn’t using RAM all the time,” than “Stupid Microsoft, all you can ever do is bloat stuff.” 


Some of that code, however, comes from the Mobile Operator who sold you the device, and some comes from the OEM who manufactured it.  It’s sometimes hard to tell which is MS code and which is MO code.  But giving similar feedback to the place where you bought the device is a good thing to do.  “I really never use add-on app X.  Please have it stop using my RAM.”



So what’s this stuff I can’t control?
Where did the those 14 megs go?  This will vary from device to device, so I can’t give exact numbers.  But I can tell you the kinds of things that tend to use RAM outside the scope of running applications.  There are five main sources.


The Page Pool
Applications use RAM in two ways.  There is code that runs, and there is data that is created while it is running.  On a NOR device, the code can run directly from the ROM and not be loaded into RAM first.  This process is called XIP (eXecute In Place).  NAND devices can’t XIP, so their code is loaded into RAM and executed from there.  If you don’t have a Page Pool, this code is loaded into normal RAM.  The Page Pool is a mechanism to limit how much code is loaded into normal RAM.  With a Page Pool, we can unload code that hasn’t been used in a while and reload it later if we need to.  We can’t do that without a Page Pool. 


On a typical NAND-based WM5 device, the Page Pool is 4.5M.


The Radio Stack
Devices with a Cellular Radio have a complicated bunch of code to make their radios talk to cell towers.  On some devices, the radio is a self-contained module with its own RAM and ROM.  On others, the radio code is stored in the normal system flash.  If so, it either needs to XIP, or it needs to be run in RAM.  If it’s run in RAM, that RAM is taken away from the system.


A typical radio stack takes 4M.


DMA Buffers
Some hardware can write directly into RAM without using the CPU to do it.  This is called “Direct Memory Access” or DMA.  DMA is very efficient and lets you get a lot more data transferred in the same amount of time, usually for less power.  But it’s best to set aside your DMA buffers before the system boots.  This guarantees that they’re there when you need them.  PocketPCs have been doing this for a decade.  But, back in the old days, the main use for DMA was audio capture.  Audio data is small, so the DMA buffers are also small.  Video, on the other hand, is big.  More data requires bigger DMA buffers.


An OEM will tune the size of the pre-allocated DMA buffers based on what the device is intended to do.  If the main goal is still photos, you can use a much smaller buffer.  If the goal is recording video, it needs a much larger buffer.  If the goal is video conferencing, it needs a bigger buffer still.


DMA buffers range in size between 300K and 6M.  For a video capture device, it’s likely to use around 4M.


XIPKernel
There are portions of the deepest parts of the OS that have to XIP.  If you’re on NOR, that code just XIPs like everything else.  Not so on NAND.  For a NAND system to boot, it needs to load this code into RAM first and then run it from there.  When the system is running, it can’t really tell if it’s running from RAM or ROM, so it assumes it’s running from ROM and doesn’t count this space.


The XIPKernel region tends to be between 1.5 and 2M.


The Frame Buffer
There is a chunk of RAM set aside to hold everything that’s on the screen.  (If you want to know more about it, read this.)  On most devices, every dot on the screen needs two bytes.  A typical Pocket PC has 240×320 dots.  That would be 300K.  If you have a 640×480 screen, it’s 600K.  Sometimes, for performance reasons, devices will have two frame buffers.  So this could take up to 1.2M. 



But you said 32M was enough!
You obviously can’t have a 32M device if 14M are gone before you start loading applications.  What’s important to understand is that all of the big ticket items above are dependent on the hardware used.  If a device was NOR based and XIPed, it would use a smaller Page Pool (or none at all).  It would likely XIP the XIPKernel region.  It might be able to XIP the Radio Stack as well.  If it was tuned for taking pictures instead of video conferencing, it could use a smaller DMA buffer.  If the device was 240×240 instead of 640×480, its frame buffer would be 1/6th the size.  Etc.


The important thing to understand is that these are all knobs that the OEM can adjust to tune their particular piece of hardware.  The OEM makes conscious decisions on trading off speed and abilities vs. loading a bunch of applications.  You could say, “I don’t trust them to make those decisions” but that would be silly.  You trust them to design the hardware and write the drivers.  That stuff is far more difficult to get right than the relative tuning of DMA buffer sizes.


Mike Calligaro


Comments (85)

  1. Dan S says:

    I understand there is important stuff that has to run to make the device work. However, why wasn’t this "stuff" so important in WM2003? My VGA IPAQ 4700 would use about 13 MB of prorgram memory after a soft reset – however my i-mate JasJar VGA device — has 14 MB reserved (as mentioned above) AND still uses 20 MB of other RAM after a soft reset. This is after I removed the OEM installed AV program.

    Didn’t WM2003SE have to load all of the same stuff as WM5.0? If not, why were the decisions made to do so in WM5.0 – these still are portable devices and it’d difficult to understand how the OS can now take up more than TWICE as much RAM after a reset. You may say it’s not "bloatware", but as a user it sure looks that way. Of our 64 MB of RAM more than half is being used by the OS even before we run one program, this wasn’t the case in WM2003SE. Something fishy is happeing with RAM, it’s almost like the developers said "well we don’t have to worry about users wanting to use RAM to store programs so we’ll just use it all up for the OS – I’m tired of out of my device locking up because it’s run out of memory!

    On a somewhat related note – why does Active Sync feel the need to run and occupy valuable RAM, even when I’m not connected to a PC, syncing? It starts up on it’s own and you can’t stop it.

  2. JD says:

    Looks like 64MB of RAM is all we can hope to expect from WM5 devices with good battery life.

    With 14-16MB gone for (NAND, VGA, double-buffered, video) devices with cool 3G radio stacks+Bluetooth+Wifi… that leaves 50MB. The Running apps will probably take that down to 32MB. So for actual user applications there’s probably at most 32MB of play.

    Given that running several apps is normal (and you can’t exit them anyway), you can have about 5-6 apps running, taking on average 4MB each to leave some dynmically allocated space (6MB). Figure one big app of 12MB, two medium apps of 3-4MB, and three small apps of ~500K each.

    It’s worth nothing that the .NET CF apps will typically fit in the medium size category given the large working set, even for ‘small apps’.

    You know, as a developer, that seems pretty reasonable to me. 5-6 running apps of various sizes (in addition to the OEM apps and OS) is probably a good bit. With sync in the background and media player pumping out tunes, plus one or two utilities, I can still surf up a storm (say IE is my 12MB app) and swap back to my mail (or IM, or GPS tracking) while I wait for pages to load (yeah, hopefuly with 3G that’s faster).

    It would be nice to have a bit more headroom but not bad for a small device. On my desktop I have Outlook 40MB, Explorer & IE each at 15MB, antivirus and a code editor at 14MB, and then some small stuff. The various Windows services outweigh all that – only half of my memory usage is by things I explicitly want to use.

    I can only hope for devices with much more storage space (4GB is going to be cheap) and better algorithms to use swap space intelligently in order to free up more RAM for programs in active use.

  3. tyl says:

    "Now you could make the argument that you’d still like to see a listing of the RAM you can’t directly use. The WM5 designers disagree."

    -MS attitude is both patronising and inconsistent.

  4. windowsmobile says:

    Dan S, the iPaq 4700 isn’t a phone. So there’s no Radio stack. That would save probably 4M. I believe it doesn’t have a camera either, so the DMA buffers would be smaller (probably 3M smaller). I also think it was NOR based. That would reduce or remove the PagePool (conservatively saving 2.5M). There’s almost 10M off the cuff.

    For running programs, the non-phone sku has fewer programs running in the first place (no dialer for one). Also, because it’s not a phone, HP decided which applications to add to it. On a phone device both the Manufacturer AND the Mobile Operator decide which applications to add (and they only ever add more). So you get things like 3rd party MMS clients on phone devices that aren’t on non-phone devices. Etc.

    To do an apples to apples comparison between how much RAM WM5 takes over WM 2003, you’d have to take a device that offers an upgrade, check the numbers before the upgrade and check them again after. I know we did a lot of work in WM5 to reduce RAM consumption, but I haven’t seen the results of such a comparison.

    Mike Calligaro

  5. windowsmobile says:

    Tyl, inconsistent, probably. We’re a big team of opinionated people who don’t always agree. For instance, in my spare time, I write little apps for WM devices. And every single one of them has a Menu->exit. Yeah, the official line might be that "users shouldn’t need to shut their apps down," but I’ve never agreed with it.

    Patronizing though … well not intentionally. I honestly believe that people are trying to do the right thing when they make their decisions. We get a lot of feedback from people, especially our OEMs’ Product Support teams, on what causes their users pain, and we try to design our software to lessen that pain. Sometimes we have direct evidence, "The highest percentage of PSS calls revolve around users setting up their email." And we go try to write more understandable mail setup routines as a result. And sometimes we have to extrapolate. "Would the same users who had trouble setting up their mail clients want a detailed view in the memory control panel of DMA buffers, Radio stacks, and Page Pools?"

    We’re NOT saying, "We think you’re too stupid to understand this stuff." If I felt that, I wouldn’t have written this blog entry. What we’re saying is, "We’re not capable of presenting this information in a way that wouldn’t confuse the average person." It’s our failing, but it’s hard stuff to do.

    That said, I still harbor resentment toward one of those designers who, five years ago, took away a feature that was important to me because "users don’t want a lot of options." So I know where you’re coming from.

    Mike Calligaro

  6. badbob001 says:

    My upgraded x50v is in the same boat as the HP4700: no phone radio stack, NOR device, no camera… but the reported memory is still about 49MB. Then there is about 15MB of I assume OEM added stuff, leaving me with less than 29MB of available ram. Previously in wm2003se, I had access to at least 46MB of available ram. So something is fishy. The x51v, a nand device, reports about the same memory usage. I think dell got lazy. Even though my x50v has NOR, can dell be lazy, use a slightly modified x51v rom image, and make it think it’s running on NAND? Or is the XIP thing automatic?

    Is the pagepool only for rom applications that reside on NAND? I know that user installed applications have to be copied to ram to run, but does that involve the same pagepool?

    How well is the 14MB hidden from us? Can an application look into that part of memory and see how it’s used? If so, can you write an app to spit out its usage?

    In short: where’s the beef?! 🙂

    Thanks!

  7. SeanL (MVP) says:

    Someone at the JasJar MSN experience group posted a link to this blog…

    After playing with the JasJar for a couple weeks, I notice that I am constantly resetting the device to free up RAM. There are task manager applications that will close apps such as Magic Button from Trancreative and others, thus you don’t have to go all the way down to setting->system->memory each time to close an app. I agree with above that the apps should just exit. This has been an issue all the way back to CE 1.0. Even with this nice feature to close application, memory doesn’t necessarily get freed up.

    Active Sync is a good example. Closing Active Sync doesn’t free up all the memory it used. When you start adding useful applications like 3rd party calculators, local storage and SD card clean-up utilities, custom apps, information apps, etc. the memory left is very little. There are a number of applications I have test and look very interesting, but there is no running room to play.

    Regardless of what the OS needs, my conclusion is that 64MB is not enough for a device like this. Every day I have had the unit I needed to reset the device, and this is not a good thing. 128MB would be a little better. I know about battery life, but I already have to keep the unit powered.

    Sean Liming (MVP)

  8. Dan S says:

    Allright Mike, I understand the desire for an apples to apples comparison, but the reality is your changing the subject, which is WM5.0 uses WAY more RAM than it’s predecessors. Compare a WM2003SE Axim X50v – after soft reset – 11.13 MB used to a WM5.0 upgraded X50v – a full 32 MB used — almost three times as much RAM used by WM5. Same hardware, just a different OS.

    Some of us were pretty excited that we’d be able to easily run multiple large programs in 64 MB of RAM space, (GPS, IE, Pocket Outlook, PI, etc.) as 50 or so MB’s would be available for program execution. That just isn’t the case with WM5.0 because of the huge footprint WM5.0 occupies. What is WM5 doing that requires it to consume almost three times as much memory?

  9. Eugenia says:

    I have to agree with others. I think Microsoft puts too much faith to its OEMs. It’s clear to me that some engineers at Dell or HP or Asus or whatever, don’t understand or don’t know how to tweak these values correctly to assure the maximum amount of free memory for their users.

    I don’t think that MS should change how Windows Mobile 5 works right now to fix the problem by using hacks (it’s too late now). Instead, please either EDUCATE your OEMs, or before you give them the right to use your software, put their devices under your own tests to see if they have indeed optimized their devices the right way (certification or something). I know that this can be expensive, time consuming and it will drive the device’s price up, but we, consumers, need a way to be sure that the OEMs did their job correctly.

    I will have to quote my (kernel engineer) husband here: "If a program or API allows for an easy screw up, then the resulted bug is the program/API’s fault, not the developer’s who used it".

    Dell x50v here too, btw. (I am a chicken so I haven’t upgraded to WinMob5 because of these known memory problems and general backwards app incompatibility).

  10. JD says:

    I guess my question is, how much memory are these apps taking?

    Which apps take up 10MB?

    Which apps take up 4MB?

    Which apps take up 500K?

    And Mike, any chance of using real paging (to flash) in the OS, or do apps have to handle it themselves to reduce their working set?

  11. windowsmobile says:

    Folks, I don’t know what to tell you. WM5 itself definitely does not take three times as much RAM as WM 2003 SE. We did the majority of our WM5 develpment on devices that only had 32M of RAM. On the one device we had with 64M, we specifically disabled 32M of it so that our developers wouldn’t get used to having that much (we didn’t want them to get lazy).

    We upped the standard page pool size from 2M to 4.5M because our performance testing found that to be a better size. But we also did a ton of work to make things take less RAM. On our builds, the net result was almost a wash. The larger page pool took extra RAM, but we’d almost made it back in our tightening things up.

    Regarding whether XIP happens automatically, no it doesn’t. The OEM chooses to enable it or disable it. It’s possible for an OEM to treat NOR flash as NAND. Though you’d still need a different filesystem driver for NOR and NAND devices.

    JD, we don’t page to flash. It’s only very recently that flash size has surpassed ram size. I don’t have a breakdown of which apps take how much RAM.

    Regarding how well the ram is hidden from you, most of the things I talk about in the blog entry are hidden from the OS. Of the things listed, the Page Pool is the only one the OS knows about. So no standard application could query DMA buffer, Radio stack, etc sizes. But an app could be written to show you which applications are running and how much RAM each is taking. That would help on the "I’m using 25 of 50M" question but not on the "Why is it 50 instead of 64?"

    Mike

  12. hx2210 says:

    I have a HP iPAQ hx2210 which I upgraded to WM5 a few days ago and my available RAM is 56.59MB (17.59MB before doing anything) and available ROM is 24.12MB. The lowest my availabe RAM has dropped down to is 34.98MB and that is running Word, IE, Powerpoint, Orneta Checkers, Cash Organizer, Pocket Informant, Mail and Active sync.

    I’m pretty happy with this setup but the thing that I dont understand is which vale is the stuff for startup and everything? Is it the reason I only have 56.59MB in total or is it the 17.59MB in use before I do anything?

    ROM as far as I am concerened is better under WM5 because it gives me an extra 5MB (almost) which there is no way that WM2003SE takes up more than WM5, right?

    The other thing I am interested in finding out is what Dan S asked. Why is Activesync constantly running when it isn’t even connected to a PC? Surely it is taking up some of the RAM I would like to use myself?

  13. Eugenia says:

    >Why is Activesync constantly running when it isn’t even connected to a PC?

    Because it’s the only way to have it do the right thing when you connect the PDA to a PC. Look at your PC, it also runs its ActiveSync at all times. It has to. And it doesn’t take up that much RAM anyway.

  14. Wilson says:

    > A typical Pocket PC has 240×320 dots.

    > That would be 300K. If you have a

    > 640×480 screen, it’s 600K.

    If the framebuffer had 16 bits allocated for colour per pixel, then the 240×320 screen would only need *150K* while the 640×480 screen would need 600K…

    (That’s just a picky detail.)

    Thanks for posting an article that gives us non-Microsoft developers some insight as to how RAM use differs between WM5 and WM2003.

  15. Alex K says:

    I have to agree that MS has just as much to explain as say Dell or HP on why an identical device with two OSs provides so much less usable RAM under WM5.

    At the very least MS has that relationship with HP and Dell to find out and explain exactly what it is.

    The truth is though that most of the memory IS Microsoft code. How do I know? Look at the WM5 emulators. No OEM stuff there. Here are numbers from a straight soft reset: 36.62 MB Total. In Use 19.93 MB. That’s 20MB in use on a soft reset – phone edition/QVGA.

    Now QVGA no phone: 36.99 MB Total. In use: 17.70.

    That’s still a LOT more than WM 2003SE emulators which show 29.70 MB Total main memory and only 6.35MB in Use on a soft reset. Even looking at my own Samsung i730 which is a PPC 2003SE Phone Edition device it takes 11MB at startup including OEM apps that start up.

    Mike, you can look at the emulator your self. You can look at a Dell x50v yourself. Yes, WM5 definitely takes up 3x the amount of memory than WM2003 did.

  16. Dan S says:

    First off let me say I really appreciate your commenting and posting on this, and I don’t mean to beat you up over this issue, but the math just doesn’t work out.

    You say that the OS takes up as much space in WM2003SE as it does in WM5.0. This is impossible. Your 14 MB partition of cache or whatever you want to call it is ALREADY larger than the amount of RAM used by WM2003SE on the X50v. That’s before the OS is loaded in to RAM and inexplicably takes up almost 20 additional MB’s on it’s own – despite the fact you say it takes up the same amount of space.

    If indeed the OS takes up roughly the same amount of space (something difficult to believe based upon the above numbers)I suggest MS needs to spend some time with their major OEM’s and explain to them how to make it work that way, because I have seen zero evidence of this on the devices that have been released to date.

  17. yota says:

    I think it’s a wasted effort trying to compare how much memory we see used in the end product to what MS developers know they got at the development stage.

    At least when there’s this unknown factor, the oem’s, that don’t have to justify their choices neither to Microsoft, nor to their customers.

    So, maybe we could just focus on trying to get more feedback from oem’s, asking for more control over those choices.

    Microsoft could also benefit from taking a more active part in this, as it’s their software that is getting a bad name with these poor choices.

    I still believe that Microsoft tries to make their software the best possible. After all, that is what they are selling.

    But oem’s sell much more than that. They sell us their hardware, but also their view of how memory should be used and which apps they think you need to have installed by default. Even if it’s old, non-working software they just happen to make a commercial deal with…

    Maybe we are directing our frustrations to the wrong people, at least on this point.

    Hat’s off to you Mike, and all the people who work hard at making Window Mobile a better software experience.

  18. badbob001 says:

    I see that many devices these days are designed and manufactured by third party companies. For example, HTC designs and manufactures the devices for many Dell and HP devices. On my Dell x50v, some of the system programs were written not by Dell but by HTC. In fact, I have not found one applet that says it was written by Dell. It’s not hard to imagine that the true device manufacturer and not the company with the logo on the device would be the one to write and update the device drivers, fix bugs, and configure the OS. So I would imagine that any misconfiguration that results in such reduction of ram would be the fault of the true manufacturer. The logo holding company such as Dell or HP may handle the support calls and dictate if some extra apps are to be installed, but I suspect that they don’t really have any idea how or why the device is configured the way it is.

    So why not attack the issue from all fronts? If we talk to Microsoft, they can pass that concern to the device manufactures. If we talk to the device sellers, they can pass that concern back to the device manufactures. So maybe if we are really lucky, we won’t have to buy a new device to get fixes to old software.

  19. akac says:

    Yota – I think I’ve shown a pure MS implementation of WM5 (not OEM) using the ARM based emulators also showing WM5 using up more than 3 times the amount of RAM.

    So yes, the OEMs do need to be talked about for the 15MB of RAM lost from the 64, but MS needs to be talked to about the 3 times amount of RAM used above and beyond that.

  20. windowsmobile says:

    Wilson, you’re right. I did the math for 640×480 then quickly divided by 2 when I should have divided by 4. <blushes> Thanks for catching that.

    Mike

  21. windowsmobile says:

    Alex, can you clarify which part you’re asking about? There are three numbers we could be talking about.

    1) The amount of Physical Ram on the system (ie 64M)

    2) The "Total:" line in the memory CPL (ie 50)

    3) The "In Use:" line in the memory CPL (ie 19.56)

    The blog entry primarily talked about why there’s a difference between 1 and 2. I’m pretty sure you’re asking why 3 is different after a reset on WM2003 and WM5. Before I try to answer that, I want to make sure I’m answering the right question.

    Mike

  22. windowsmobile says:

    Ug.

    I just compared what I believe are two apples to apples emulator images, and I see the 3X memory usage (for "In Use:") that I believe Alex is asking about.

    I’m going to have to dig into this and find out what’s happening. This topic deserves a Blog entry of its own. I’ll probably call it, "Who’s using my RAM?" or something like that.

    I’m not going to be able to get to this for a while. As much as I like doing these entries, they’re really far removed from my day job. 🙂 But when I get some spare time, I’ll look into why memory consumption is so much higher than I expect and report back.

    Mike Calligaro

  23. Alex K says:

    Yep, talking about In Use in response to other people’s posts. I’m looking forward to the info.

  24. Monaco says:

    Although my HTC Universal (MDA Pro) lacks 16 megs of RAM (VRAM), I would not bother too much about that.

    Program Memory (RAM) 47.93 MB.

    Built in RAM is 64 MB, i.e. 16.07 MB are "missing". Thanks to your posting and thread we now know what it is used for. So I’m fine with that.

    … BUT …

    The question should not be "where is my RAM", but "where is my ROM"???

    As to the OEM T-Mobile the ROM image is 43 MB (incl customizing and branding).

    We checked and resulted in 32 MB incl. BT and radio stack and excl. customizing and branding, so this should be correct.

    We can see 43.72 MB Storage Memory (persistent storage in ROM).

    Built in ROM (NVRAM) is 128 MB.

    We need to make up the simple calculation:

    128 MB (total) – 43 MB (ROM image) – 43.72 MB (Storage Memory) = 41.28 MB of ROM are … MISSING!!!

    Some good sources told me that this was due to a driver misfunctionality in Windows Mobile 5.0.

    I even heard rumors that FSC stopping the ROM upgrade for Pocket LOOX 718/720 was due to the same "misfunctionality".

    Is this rubbish? Any truth in that? Or is it simply correct?

    Any more information on the FSC problems?

    And most of all:

    can anyone clarify why the HTC Universal lacks so much of its ROM?

  25. badbob001 says:

    Mike,

    Can you please answer this missed question: is the page pool in the hidden "14MB" area used only for oem installed rom applications or do user installed applications run from there as well?

    I’m trying to figure out if the pagepool is needed at all on a NOR device that is correctly configured so the oem-installed rom programs can XIP. You said in an earlier blog that any user installed applications must be copied to RAM first before running because XIP only applies to oem installed rom apps. If user installed applications use the same pagepool as rom applications, then it may hurt performance to remove the pagepool since it is not practical to expect users not to install any apps. But if user installed applications used their own chunk of memory, then the pagepool would be a waste on a NOR device. Which is correct?

    Thanks!

  26. windowsmobile says:

    Monaco, I’m not aware of a bug that’s causing the loss of 40+ megs of ROM. I don’t have any visibility into FSC, but if there was an MS bug that caused the MDA Pro to lose 40M of storage, I’d most likely have heard about it.

    That said, this is the first I’ve thought about the issue you brought up, and I don’t have an explanation for it.

    There are a few things that would be taken from the user total. Off the cuff (I haven’t verified any of these numbers), there’s the radio stack (it needs RAM, but it also needs to be stored in ROM somewhere). That’s probably 4M. There’s reserved space for future updates. That’s probably 4M too. There’s a boot loader and an update loader that might account for 3M. It’s possible that the XIPKERNEL region isn’t counted in the 43M (I’m not sure). Maybe another 2M.

    Beyond that, the only thing I can think of that would occupy ROM space is a region that the OEM put on with mobile opperator apps and stuff that get loaded the first time you boot the system. I don’t know why that would be 30M though.

    Mike

  27. windowsmobile says:

    Badbob, sorry I missed your question. Yes, 3rd party code runs from the page pool. The only things that don’t run from the page pool are XIPed code and non-pageable code (typically drivers). Everything else does, whether it’s in the user filesystem, or is compressed in the image, or is on an SD card.

    For this reason, a NOR based XIP device will usually still have a pagepool. They just tend to use smaller ones. The typical NAND device page pool in WM5 is 4.5M. There’s a major XIP NOR device going to hit the market soon that has a 2M pagepool. That OEM tested various sizes and decided they liked the tradeoffs with 2M the best.

    Mike

  28. Monaco says:

    Mike, thanks a million for your quick follow-up.

    I’m actually quite surprised that you haven’t been aware of the above mentioned issue with the HTC Universal machines.

    We even crosschecked with an O2 Exec from New Zealand. I have been told that it is the same with an i-mate JASJAR.

    So obviously this issue is not due to OEM branding only.

    I also cannot imagine that HTC would "waste" 30 MB or more for their own tools or for reserving for anything else.

    I’m sure it would be no problem for you to check with one of these devices.

    Would be extremely keen on any kind of update on this.

    Looking forward to anything that provides more insight. Thanks again!

  29. barrybo says:

    "Look at the WM5 emulators. No OEM stuff there. Here are numbers from a straight soft reset: 36.62 MB Total. In Use 19.93 MB. That’s 20MB in use on a soft reset – phone edition/QVGA. "

    The DeviceEmulator is unfortunately a bit atypical in how its emulated RAM gets used. Most hardware devices should be more efficient in their memory use.

    Here are a couple of reasons:

    – the OS image is actually loaded into RAM, not NOR or NAND flash

    – the RAMFMD driver is configured to allocate a 2mb ramdisk

    – there is a preallocated 1mb frame buffer, to support the emulator’s resizable display (up to 640x480x24)

    – 303k is reserved for a bootloader

    – DMA buffers for audio and folder sharing consume another couple of hundred k

    Future Windows Mobile OS images for the DeviceEmulator will likely use less memory, as we move the OS into emulated flash, and improve video emulation.

    Barry

  30. Alex K says:

    Barry – that may be, but its the best apples to apples comparison I can give that everyone can see since BOTH are emulators and there is no OEM involved – just MS.

    But you can see the exact same thing using a Dell x50v WM2003 and Dell x50v WM5. But there an OEM is involved.

    So the facts don’t change either way.

  31. Alex J. says:

    >> but if there was an MS bug that caused the MDA Pro to lose 40M of storage, I’d most likely have heard about it. <<

    Oh oh! Can you confirm that this bug was removed BEFORE T-Mobile (or others) branded their HTC Universals?

    40M is the size that is "missing" on all of those devices at my office (MDA Pro and i-mate JasJar). If not: update? when?

    If "unrepairable": warranty?

    Best wishes!

  32. pickedaname says:

    Thanks for the info Mike.

    I was wondering, regarding both 2003se and WM5,

    How do I access the GPS coords on say a Samsung i730 or Audiovox xv6600? There is hardly any docs on the internet about how you can access this data via API from Windows or the device itself. Is there an API much like the phone API (That was nice being able to add dial functionality to my progs, thanks MS)

  33. AndyME says:

    Sorry if i sound somewhat unknowledgeable…

    I have this MDP Pro aka. HTC Universal with WM5

    when I boot the device, it gives me some 16-17 Megs of RAM. After having used it for a couple of hours, having opened and used a few apps (mail, chat, IE) and after having CLOSED all of them (no app running anymore, I verified it) the RAM is down to 2,3 or 4 Megs…Now where has this one all disappeared? why is it not freed after shutting the apps? if i want to get the RAM back, i need to soft reset again…is that normal? ( I am using MemMaid and specified there to put the IE cache on the card…)(by the way and on another note: i have not been able to remove even one app yet in a satisfactory manner. i always get a comment of the kind: could not be removed completely, remvove from the application list anyway?) I don’t know..but all this does not look very finished to me…

    Anyone who knows anything???

  34. windowsmobile says:

    AlexJ, sorry, I must not have been clear. I don’t think any such bug ever existed. I’ve certainly never heard of one. While I don’t know what the 40M is being used for, I don’t think it’s a result of a bug.

    AndyME, what you’re describing does not sound normal at all. I don’t have a JasJar, but all of the WM5 devices I’ve used do not act like that (they don’t progressively use more and more RAM over time). If the JasJar has an issue like that, it would be good to report it to the company you bought it from. They will work with the manufacturer to find out what is going on.

    Mike

  35. windowsmobile says:

    Hi everyone. I just posted a new blog entry that describes what I discovered when I investigated why the Emulator uses 3X more RAM in WM5 than WM2003 SE. We also investigated a real world OEM device and I gave the results of that as well.

    http://blogs.msdn.com/windowsmobile/archive/2005/11/29/498154.aspx

    Mike

  36. windowsmobile says:

    And one other followup. I asked the JasJar OEM about their ROM usage. (Some people are wondering if there’s a bug that results in 40M of ROM lost.) They said, no, they can account for all of the ROM being using. They didn’t tell me specifically what they’re using it for, just that they ARE using it. So there’s no bug there.

    Mike

  37. Monaco says:

    Hi Mike, due to some professional information from a colleague of mine, I now claim to know what HTC are using the ROM for …

    Other manufacturers obviously don’t do this and also from Your side it obviously was not expected to be done …

    They copy the hidden ROM image in ROM (!) again (representing kind of a working copy), which basically could represent a "quality feature" unless with 128 MB built-in ROM it would unnecessarily result in massive constraints for available persistent storage (only 43.7 MB = 1/3rd of 128 MB remains for storage memory) and leave not enough permanent free internal memory for future software installations and updates (even onto storage card).

    In this context:

    Would you please check the following registry entry

    HKLM / System / StorageManager / IMGFS

    Dword entry "ShadowROM" with value "1" ?

  38. Monaco says:

    Hi Mike, my colleague’s information turned out to be simply wrong! Due to his expertise and lack of other clear answers to the question it seemed to be a reliable statement.

    I now was able to verify that my HTC Universal ROM actually is of 75.19 MB size. Slightly under 3000 files. It includes drivers, picture / audio / video files (incl. T-Mobile branding), also f.e. T9 DLLs for a series of different languages etc etc.

    Its dimension goes far beyond the blank emulator ROM (~32 MB) and this is what seemed to be so unbelievable … but true.

    Adding another 9.9 MB of reserved space for Extended ROM which only includes 2.8 MB data (slightly over 7 MB free) and the visible 43.7 MB storage memory we have the full 128 MB ROM complete.

  39. Haesslich says:

    Well, with the h1950 I had, I found that, with a clean startup (no additional Today plugins, no extra Start Menu modifiers, etc), I had a total of 11.96MB of RAM available, which would only go down the longer I had the machine on without a soft reset, out of 32MB. With your example, a typical WM5 setup should take about 11.2MB of RAM, which would (in theory) leave a person with around 24MB, or maybe 22MB of RAM if the DMA pool took 6MB, without a cellular radio.

    Unfortunately, HP managed to chop off another 10MB of that, which made the 1950 almost unusable for anything but basic PIM functions. I don’t know how they did it – the fact that Adobe Reader 2 for PocketPC took 8MB of RAM to run meant that I was choking for RAM at the end, especially since the files I read in PDF format range from 500KB-8MB in size. WM5, with its memory management, would kill all the background tasks it could find… and still not have enough RAM to avoid choking. Pocket IE nearly died going to a webpage with quite a few graphics, and after 6-10 minutes, when I was trying to do a soft-reset, did it finally respond again.. missing most of the page.

    Maybe y’all could send a love letter to HP to suggest how they could tune your OS a bit? I don’t know how they did it, but one of their ‘average’ WM5 setups (I’ve checked the free RAM on start on the 1950 and the 2490, and confirmed with others who possess them) load 20MB for the OS.

  40. buzz_lightyear says:

    Hi Mike,

    again some very nice blog. THANX.

    Anyway, you’ve said:

    "A typical Pocket PC has 240×320 dots. That would be 300K. If you have a 640×480 screen, it’s 600K."

    I’d say, if 240×320 is 300K, then 640×480 must be 1200K, because 640×480 is 4 times more pixels.

    THANX

    buzz

  41. Korayem says:

    I have an iMate KJAM and it’s marketed as 64RAM and 128ROM and i had the same question on my mind. Thanx for the great clarifications. I find it logical now.

    BTW, here is an abstract of the FAQ found on clubimate.com which explains where is RAM:

    ################################################

    Within the memory application, why do I not see the full 128MB available?

    Windows Mobile Second Edition ROM is completely read only and only used for the operating system. The RAM is used for both running programs and storing user data. This is less than ideal as RAM is erased when the battery is flat.

    <img src="http://img387.imageshack.us/img387/8873/jasjarwmse5iw.jpg"&gt;

    Windows Mobile Second Edition

    On Windows Mobile 5.0, the ROM is used for storing user data, which is kept should the battery go flat. The RAM is only used for running programs. This is much more like how a PC works.

    Windows Mobile 5.0

    <img src="http://img387.imageshack.us/img387/7704/kjamwm55fz.jpg"&gt;

    ################################################

  42. windowsmobile says:

    Monaco, yes this discussion has been quite an eye opener for me. At one time MS wrote most of the code on the device and the OEM only wrote some drivers. (Their part was complicated and importand, but a small percentage of the total ROM on the device.) With these newer devices, more than half the code in the ROM came from a source other than MS.

    If you want to view that in a positive light, you could say, "Wow, the partnership model is really working."

    If you want to view that in a negative light, you could say, "Wow, MS isn’t providing enough code to their OEMs. They’ve got to get cracking."

    There’s truth in both viewpoints.

    Mike Calligaro

  43. puntloos says:

    Congrats on your cool blog. *hats-off smiley*.

    Now you’ve asked for some comments on choices the OEM’s and the WM team have made however that ‘quest for knowledge’ is being quite heavily obstructed by some parties in the supply chain.

    In general let me just mention this: I fully respect that a lot of the choices designers make nowadays cater more for the ‘casual, non-techie’ user than for hardened professionals

    However the same generic choice has been made with say Windows XP: it isnt that complex anymore, confusing slabs with 987345 options are hidden unless requested and my mom can find her way around the OS.

    But there’s one distinct difference between WinXP and WM5: If you looked around, you could find lots ‘go advanced mode’ options, or addon software to dissect and tune your OS. Powertoys, TweakXP, regedit etc.

    With windows mobile there’s no such possibility, and we all have to live with choices that perhaps don’t really suit us.

    This whole process is not helped by the fact that most WM5 images (the latest Dell Axim x51v ROM image as an example) are encrypted. (we’re working on this :P).

    How can I comment on what stuff is in my way when I’m not allowed to really go near it? That said, Ill tell you my greatest frustration is that I supposedly have 64Mb in my device, yet with all the will in the world Im not able to play quite a few games (quake 3 for CE, for example) that require 35-40MB of RAM. I don’t suppose there’s any hope for implementing some type of ‘swap file’ of the SD card, is there?

    And lastly, while I must admit slightly off-topic, but still sort of pertaining to what I want and don’t want in my device, the microsoft bluetooth stack inside WM5 is awful. The things it does it does decently well (although I still hear of various compatibility issues), but how can you justify leaving out so many bluetooth profiles? I guess it’s a matter of perfecting vs releasing, but Ive seen a lot of people rollback from WM5 to PPC2003 on their x50v devices for specifically that reason.

  44. puntloos says:

    Congrats on your cool blog. *hats-off smiley*.

    Now you’ve asked for some comments on choices the OEM’s and the WM team have made however that ‘quest for knowledge’ is being quite heavily obstructed by some parties in the supply chain.

    In general let me just mention this: I fully respect that a lot of the choices designers make nowadays cater more for the ‘casual, non-techie’ user than for hardened professionals

    However the same generic choice has been made with say Windows XP: it isnt that complex anymore, confusing slabs with 987345 options are hidden unless requested and my mom can find her way around the OS.

    But there’s one distinct difference between WinXP and WM5: If you looked around, you could find lots ‘go advanced mode’ options, or addon software to dissect and tune your OS. Powertoys, TweakXP, regedit etc.

    With windows mobile there’s no such possibility, and we all have to live with choices that perhaps don’t really suit us.

    This whole process is not helped by the fact that most WM5 images (the latest Dell Axim x51v ROM image as an example) are encrypted. (we’re working on this :P).

    How can I comment on what stuff is in my way when I’m not allowed to really go near it? That said, Ill tell you my greatest frustration is that I supposedly have 64Mb in my device, yet with all the will in the world Im not able to play quite a few games (quake 3 for CE, for example) that require 35-40MB of RAM. I don’t suppose there’s any hope for implementing some type of ‘swap file’ of the SD card, is there?

    And lastly, while I must admit slightly off-topic, but still sort of pertaining to what I want and don’t want in my device, the microsoft bluetooth stack inside WM5 is awful. The things it does it does decently well (although I still hear of various compatibility issues), but how can you justify leaving out so many bluetooth profiles? I guess it’s a matter of perfecting vs releasing, but Ive seen a lot of people rollback from WM5 to PPC2003 on their x50v devices for specifically that reason.

  45. Mike Gio says:

    I got a brand-new X51v running Windows Mobile 5.0 just two days ago. I took a look at the "Total" RAM and it says 49.47MB. I was confused at first and then read this blog and now I understand. Fine, that’s the OS, the drivers, the page pool, etc. But then below it I look at the "In use" line at it says ~21MB used. If the 14.5MB was the OS what is the other 21MB? It’s not running anything!

    I went to Dell’s website and got the latest ROM update. Now I have an additional 2MB. It currently reports 19.38MB in use, which leaves 30.09MB free. More than half the available RAM is still used by the OS when running *nothing*. There obviously is bug somewhere. I wish someone, either Dell or MS would just admit it. Even on a stripped down system like this I can not run applications like Quake 3 Arena which requires 40MB of RAM to run (and ran just fine on a X50v with CE 2003). What’s the deal? I’m quite angry.

  46. Richard Herd says:

    Hi,

    Ok, maybe you can elaborate a little here, as you mentioned you did all your testing on 32mb devices?

    My brand new ipaq (WM05) has 10.36 mb left after a clean boot with no programs running… I understand 32mb is a tight squeeze, but the ram detailing is unclear… Says total ram 23mb, fair enough, 9mb used for os… But then it says another 13mb in use by running programs (no matter which task manager i try nothing can find any programs running) so I can only assume this 13mb is also used by the os…

    Basically my question is, if you designed this os for 32mb devices, surely taking 70% of available ram for the os is not a great design?

    Could you imagine the uproar if the final release of vista took 400mb out of a half gig machine and didn’t allow paging a swap file to disk?

    If you could clarify this for me that would be greatly appreciated…

    Thanks

    PS, off topic, but whats the situation for developing apps for wm2005? still stuck with vb6 (yes i know, still waiting for them to shell out for a .NET license – until then they can put up with the unstable apps vb6 produces lol)… i know theres the .NET compact framework, but any chance of any info on compiling vb6 apps for wm2005? thanks

  47. Chris says:

    "You obviously can’t have a 32M device if 14M are gone before you start loading applications."

    You should talk to Palm’s developers about their 700w.

  48. youraa says:

    Hi

    I Have the same problem as AndyMe.

    I have a HTC Wizard, after soft reset I have 24-23mb free ram, I work on it for a couple of hours use different apps, and then I close everything working in the background and I have only 16-18 mb free ram. Why is that? Where is my ram :)?

  49. MikeCal says:

    If by "close everything" you mean you tapped the little X button in the upper right corner, that doesn’t close the app.  It puts it in the background so that the next time you run it, it launches quickly.  The system will close it automatically if it needs more space, but the threshold for needing more space is well below 16M.  

    If you’re going to the memory control panel and closing apps, that will actually close them.  But not all apps are shown there.  For instance, the phone app is always running and doesn’t let you close it.  If you did, you couldn’t recieve phone calls.  

    If you’re using some sort of extra tool to find applications and forcibly kill them, that’s a dangerous opperation.  If you force the application to close and it’s in the middle of a system call, it can cause resources to be leaked.  

    Our goal is for users to not need to pay attention to RAM usage on their devices.  If you’re trying to use your Wizard and it’s failing to do things because it’s out of memory, then we’re interested in fixing that problem.  If you’re using your wizard and wanting to make the "unused RAM" number go up, we’re less interested in fixing that problem.  

    Remember that unused RAM doesn’t do anyone any good.  It just sits there burning power.  Better to use it for SOMETHING.  So we don’t do any optimization for trying to increase unused RAM until we start running low on it.

    Mike

  50. Trev T says:

    Hi guys, im new to the whole memory talk jargon…..

    what my question/comment is,

    Is it feasible to use an SD card as a RAM, like a pc does with hard drive, (think its page file of something). i know these are different types of memory. Also, is this a further development of WM5, or will it be included in future OS releases, or is it thought to be even necessary….?

    the reason I ask is because I regularly attempt to edit large documents on the move (tables, embedded images etc..) and there isn’t always enough memory available when loading these, but i have 1 gig of memory sitting on the SD card doing next to nothing….

    thanks for your time and congrats on the decent forum.

  51. MikeCal says:

    Hi Trev,

    You’re correct to compare an SD card to a hard drive.  SD needs to be used as Storage, not as RAM.  

    CE doesn’t currently allow RAM paging to storage, the way the desktop does.  Why we don’t is probably too long for a comment, but is great fodder for a blog entry.  I’ll try to write one this week.

    Mike

  52. bluesgeek says:

    XV6700 here …business man …trying to get some basic email, PIM and communications out of the device.

    I have 1600 contact records and about 3,000 emails (2-3k each) loaded. I run AgileMessenger from the device. So, I am clipped to 9-12MB free ROM just getting out of my driveway. (I should note that Sprite Backup will not perform with less than 10 MB of free ROM). Running a few essential programs yanks my free RAM down to 6-12MB (hardly a stable environment). In my business I deal a lot in graphic arts and need to view, download and upload email attachments. (I have completely run out of ROM trying to send a 5 MB attachment.)

    I think it bears noting that, just the fact that we’re having this discussion shows that the memory scheme for the current devices (at least mine) is sorely lacking. Your 3rd-party developers are dealing with it all the time, especially those whose programs utilize databases.

    The cost of RAM is power consumption. At least that is user configurable. (We can buy another battery.) I can’t add more RAM.

    From where I sit, the potential of the OS running on a fast CPU is hindered by the memory scheme. I am new to Windows Mobile and was very surprised to find out that memory management is such an issue.

    I don’t run frivolous or luxury programs …no Today plugins. I’m just trying to use the device as a business tool. I don’t run a lot of apps, but I load the databases in the ones I do use. I don’t want to be constantly worrying that I don’t have enough memory for what should be routine operations (as it is, I pared down my contact records from 3,000). I just want to be able to keep a modicum of data stored on device for reference. It is not out of the question for someone to ask me to refer to or resend an email or document that is aged 2-4 weeks. I need to be able to respond to that call, and my WM5 device needs to be up to the job.

    The OS is …the RAM/ROM often isn’t.

  53. MikeCal says:

    Bluesgeek, I disagree that having  more 6-12MB of unused RAM is required for stability.  Unused RAM does nothing but waste battery life.  

    However, I’m hearing loud and clear that you need a device with more storage and RAM.  The good news is that the only thing stopping anyone from providing such a device is the cost.  If you’re willing to pay for a device with more RAM and ROM, give that feedback to your mobile opperator.  They’d love to sell more expensive devices.  If there’s a large enough market, they’ll bring larger devices to it.

    Mike

  54. MikeCal says:

    Trev, I wrote the blog entry you asked for.  It’s here: http://blogs.msdn.com/windowsmobile/archive/2006/03/31/566187.aspx

    Mike

  55. Jake o says:

    I have exactly 256 mb of RAM installed.

    My OS (windows Xp Pro) only sees that I have 128.

    only HALF of what is installed!

    Even my BIOS recognizes the fact that I have 256 MB installed. WHAT is going on?!?!

    I’ve been kind of baffled by the way that microsoft treated me when I called them.

    This is a Built system. NOT pre-bought.

    they told me to contact the manufacturer.

    I told them I built it.

    They said I could pay 35 dollars OR

    go online and try to fix it myself.

    this problem is obviously RARE as can be and noone has had  to deal with it. UGH.

    Any ideas..?

    thanks

    Jake

  56. MikeCal says:

    I’m sorry Jake, but this is the Windows Mobile team blog.  Everyone here works on Windows CE for Smartphones and PocketPCs.  Windows XP for desktop PCs is a different opperating system.  You’re better off with a blog devoted to the OS you’re having trouble with.

    Mike

  57. Terry Davis says:

    After ditching my Symbian Sony Ericsson P910i into a draw in preference of my new Vodafone V1640 (Jasjar / XDA exec etc) I have to admit that at first I was impressed. It was nice, with a large keyboard, a nifty landscape/portrait option and a good set of headphones.

    Sadly that all ended whn I switched it on. Don’t get me wrong, it booted up fine and worked as described. I very quickly noticed, however that it became slower and slower the more I used it.

    I was pretty disappointed with the stock applications that ship with WM5, microsoft are fairly unimaginative when it comes to PDA apps. So I set to installing a few custom apps.

    I had:

    SPB Pocket Plus

    SPB Diary

    SPB Weather

    Pocket informant (for the excellent month view)

    SuperDoku

    The sluggishness was palpable. you could actually count seconds bewtween app switches. That is of course if after leaving one app it actually managed to start the next.

    Even installing apps on the SD card didn’t help .

    I noticed that almost everything in the device wants its piece f the RAM cake.

    Get a text message, lose some RAM

    Start an app, lose some RAM

    set a reminder, lose some RAM

    It became unusable very quickly and will be gong for sale this weekend.

    I personally think it is shameful to re-engineer Pocket PC into WM5 claiming the great benefits of persistent memory and a great new look, when in fact to report a half decent battery life they have to reduce the RAM to a level wher the OS response is little more than a joke.

    Last night I went home, boxed up the V1640 ready for sale, dusted off the P910 and apologised to it.

    Symbian Rocks, WM5 sucks.

  58. HDoucet says:

    Hi Mike,

    Maybe you can help me with this problem – this blog seems like my best bet.

    I’m developing a C++ program for Windows CE and Windows Mobile 5 and I have a Dell Axim x51v with 64Mb RAM.

    When I try to allocate memory within my program (using alloc and realloc), I can get only a maximum of 4Mb even though my Memory application says I have over 17Mb free.

    I need to be able to allocate more that 4Mb at a time for transferring files over a wireless connection.

    Any ideas of what the problem is and how I could possibly get around it?

    Thanks much,

    HDoucet

  59. MikeCal says:

    Terry, I’m sorry to hear your experience was bad.  The JasJar has a significant amount of RAM.  I haven’t heard many complaints around RAM on that device.  The experience you’re describing sounds much more like an application constantly running and burning CPU cycles, not RAM usage.  That would also explain why putting the applications on an SD card wouldn’t change anything.  They’re still running.  

    It sounds like its too late and that you’ve already sold the device.  If you haven’t, I’d really like to hear what your experience is like if you do NOT install the applications you did.  If things are significantly different with them not installed, I’d be inclined to believe that one of them is running all the time and slowing the system down.  That would hurt your battery life as well.

    Mike

  60. MikeCal says:

    HDoucet, I’m not sure why you’re not able to allocate more RAM, but are you SURE you need to allocate so much?  4M is really excessive for an embedded app to need.  I don’t know your exact requirements, but it’s generally not necessary to load the entire file into memory to send it over a wireless connection.  

    Do you know about Memory Mapped Files and how to use them?  I suspect that’s what you want to be doing.  Check out the SDK Documentation for the APIs "CreateFileForMapping" and "MapViewOfFile."  

    Mike

  61. bluesgeek says:

    Just a comment from a user trying manage.

    I’m lucky with my XV6700 if I can clean the device up to keep 7-9 MB of RAM. I use FilePoint Exchange (http://www.bachmannsoftware.com/fpxppc.htm) to browse, upload, and download files from a server. This app, in its infancy, downloads to the device only. Today I downloaded an 8 MB file, tried to copy it to my storage card (so that I could then delete it to be able download more files), but couldn’t paste it to the card because …not enough RAM.

    Yes, I know, the 3rd-party developer should allow downloads to the card. Still, this doesn’t change the fact that people trying use these devices for serious business are being challenged by the RAM design on these devices.

  62. MikeCal says:

    bluesgeek, there are two potential solutions to this problem.  

    1) The ISV makes a fairly simple change to the program that allows you to download any sized file on your existing hardware.

    2) We start putting significantly more RAM in our devices and, as a result, are forced to start charging significantly more money for them.

    Is the latter solution really the better one?

    Today you need to download an 8M file.  Tomorrow you’ll need to download an 80M file.  Next year you’ll need to download an 800M file.  Do you really want to see us start selling thousand dollar phones with multiple gigabytes of RAM?

    It’s crazy for an embedded app that moves files around to load the entire file into RAM first.  The app should create a small buffer and stream the data through it to storage.  If they made that small change you’d be able to fill an entire 4G SD card with one file on your existing hardware.  

    I hope that while you’re trying to convince me to make more expensive phones, you’re also trying to convince the ISV to make better software.

    Mike

  63. bluesgeek says:

    Mike, I appreciate your comments.

    I agree with you, almost entirely. Of course I am prodding the vendor. Thank you for the education on the /buffer/stream concept.

    (Aside: One other limitation of FilePoint Exchange (http://www.bachmannsoftware.com/fpxppc.htm) is that uploading from the PPC device to the server can only be done to one folder, as configured on the server).

    Part of the RAM pinch is that have not chosen my device (XV6700) based on maximizing RAM, but on feature set. Still, my criticism remains. I want about 10-20 MB more of RAM in my convergence device, some of which to use for databases and programs, and some just to have a bit of headroom, so that I can copy and paste larger files, and deal with the occsasional underdeveloped program. (Even though FilePoint is limited, I rely on it during long road trips to share files with my graphics design and web design team. And I haven’t found another program to work with my server.) I will be happy to pay more and to deal with power consumption issues.

    You have earlier suggested I contact my mobile operator to request devices with more capacity. I assure that I do so (and with the OEM) at every turn.

    So, I am advocating a bit of both solutions you have listed.

    Thanks again for commenting. I think it is quite a compliment to the current state of WM5 device development that I am able to go on the road for 1-2 weeks at a time, doing graphics-intensive work, requiring the frequent transfer and management of numerous large files, over various networks, without my laptop. I hope that my critical comments are taken in the spirit intended, as a "real life" report of where RAM limitations can trip up the business power user.

    Dave

  64. Angusc says:

    I’m not sure if this is related, but is it possible in WM5 when transferring a file via bluetooth to another WM5 device, to change the default folder?  Currently the default folder seems to be on the devce under "my documents", I would love to be able to save on to the MMC to allow large file transfers from one device to another.

    Thanx for any info

    Chris.

  65. MikeCal says:

    Thanks, Dave.  I’m definitely taking your comments in the spirit intended and appreciate them.

    Truth be told, there WILL come a time when these devices have gigabytes of storage and hundreds of megabytes of RAM.  We’re just not there yet.  There’s currently a financial limitation that will go away over time.  And there’s also a technical limitiation that we’ll have solved by the time the financial limitation has gone.

    Mike

  66. wallyn says:

    Running wm5 on an ipaq 6915. I notice bluetooth uses around 15 mb of memory. With it on the panel shows 9 mb and when I turn it off it jumps back up to 25 mb. Is it suppose to use that much or is there a setting I am missing?

    Thanks

    Walter

  67. MikeCal says:

    The 6915 doesn’t use the Microsoft Bluetooth stack.  It uses a competing 3rd party one that I don’t know much about.  Sorry, I can’t tell you what to expect with that stack.

    Mike

  68. reductil says:

    Thank you so much for this great post  about <a href="http://alisaadams.bravehost.com/reductil.html"”>http://alisaadams.bravehost.com/reductil.html" title="reductil">reductil</a> and [URL=http://alisaadams.bravehost.com/reductil.html]reductil[/URL]

  69. IM0001 says:

    Hello all. I too own a Dell Axim X50v and with the latest WM05 update from dell A02, we are finally able to run our X50v’s in either WM03SE or 05 without a hitch.

    I like the 05 feal and look but the memory issue has also hit me like many others here.

    With a fresh Hard reset and everything shut down (Not hidden or running in the background. SHUT DOWN.) it only has a max of 27.7M of ram free. The reported memory is only 49.29M and rom only shows 90M with whatever I have installed used. Rom isnt a problem since most programs i install go straight to the SD card. The one anoying thing i have with WM05 is its need to install all apps to the main memory then to wherever you wish for it to be installed. Just an annoyance but whatever.

    Back to the ram issue. In WM03 I was able to free up over 40M of ram on a clean hard reset (think it was closer to 42Mish..)

    Is there any way we could tweek and edit a few entries and get the os to free up at least 30M on our devices? I do tend to use my device a little more as a Gaming/Media machine than a business device but the lack of ram hits me hard with many programs (Tony Hawk requires 28 to start.. Dont know why we cant at least try to go without it.)

  70. MrJasjar says:

    I’ve read (not everything) but enough for today. And i think the jasjar or any other device with windows was a fault for me. I used to use symbian before and didn’t experience such great memory problems. And now simpl think; windows, eats the memory 🙂

    All the same, the jasjar is a symphatethic one. Maybe i should find o rom editor and exclude some unnecessarıy programs (to me certainly). Yet don’t know however how to, I know can do make if want indeed.

    And I know, I want to do.

    Any ideas about rom editing from you?

    Thanks all…

  71. bluesgeek says:

    MikeCal said:  

    "Truth be told, there WILL come a time when these devices have gigabytes of storage and hundreds of megabytes of RAM.  We’re just not there yet.  There’s currently a financial limitation that will go away over time.  And there’s also a technical limitiation that we’ll have solved by the time the financial limitation has gone."

    Hello Mike,

    With the iPhone’s 700 MB OS, are we there yet?

    (Actually a serious question as to whether or not we will see such advances in RAM capacity in WM devices now.)

  72. Keelan says:

    hi i have a hp rx1950 with wm5 and i didnt know where else to turn i have my music from wmp10 on regularly but on most of the songs even if no other programs are running it freezes for a sec and says buffeing 12% or 56% and i can be about half a second to about 10 which gets REALLY irritating sometimes ive tried uninstalling pretty much everything and clearing internet history, ending all programs, resetting numorous times and i have a 1gb microsd.

  73. keelan says:

    i found what the problem was its saying im using 312 out of my 1000mb when everything is deleted but still ???

  74. Vic says:

    I understand your point.  Currently I only have about 14MB left on my mogul after a soft reset.  I’m running the skyfire beta that takes about 10MB.  Usually I loose 5MB after some use of the phone (I guess some memory left used by other programs).  If I close everything down, Im left with 10MB, so I can’t run skyfire.   I admit I have a lot of stuff running in my startup like HTC home theme, plugin, battery indicators, spb time, weather app, etc.  

    I would like to see how much memory my "extra" plug ins are taking and I can not see that from the memory control panel.  I remember after a ROM upgrade I had about 23MB free, of which 13 have been used for all of the plugins.  I want to do some optimization by disabling some plugins, but why can’t I see their memory usage?  (i.e. how much is SPB Time while running with the OS)

  75. bluesgeek says:

    bluesgeek said:

    "MikeCal said:  

    ‘Truth be told, there WILL come a time when these devices have gigabytes of storage and hundreds of megabytes of RAM.  We’re just not there yet.  There’s currently a financial limitation that will go away over time.  And there’s also a technical limitiation that we’ll have solved by the time the financial limitation has gone.’

    ‘Hello Mike,

    ‘With the iPhone’s 700 MB OS, are we there yet?

    ‘(Actually a serious question as to whether or not we will see such advances in RAM capacity in WM devices now.)’"

    Well, it’s been almost a year and half since I posted this, and no response. Let me ask a another way.

    How is it that Apple is about to solve the RAM problem, financially and technically, but we are still in the 20th century with WM devices and RAM?

  76. VikramG says:

    Hi Mike,

             Am using NOR Flash to store my OS image. As NOR flash is not file structured, can i make the space left in the NOR flash as a separate disk and store some application in it?

    In what way its possible. Some people adviced me to do in this fashion but they recommended a driver for doing this…."What you need is a driver that presents unused NOR Flash as a disk" is what they say….

    Pls help me to figure it out.    

  77. VikramG says:

    Hi Mike,

             Am using NOR Flash to store my OS image. As NOR flash is not file structured, can i make the space left in the NOR flash as a separate disk and store some application in it?

    In what way its possible. Some people adviced me to do in this fashion but they recommended a driver for doing this…."What you need is a driver that presents unused NOR Flash as a disk" is what they say….

    Pls help me to figure it out.    

  78. wp says:

    Hi, Mike,

    I have something to confirm about RAM consumption.

    As you said, any non-XIP program’ code is needed to load into the pagepool, not into the normal RAM. Since thr size of the page pool has been excluded from the total RAM, what the "in use" part of the remaining RAM for?

    From the above discussions, I concluded that that part is consumed by non-pageable drives and loaded/created data by the codes.

    So, if some programs require and consume lots of RAM — it should be mainly attributed to those data stored in the ROM, not the code part. If a 10 MiB program consists of only code, no data, it will consume nothing out of the RAM except the page pool, am I right?

    Thanks!

    wp

  79. wp says:

    Last words, sorry, seems a silly question.

    If I run ten applications at the same time, all those programs have to do is to share the 4.5 MiB Page pool?

    If this is true, how does the system deal with those programs’ ram usage? The system just slows down

    but not try to touch the remaining unused RAM (say, even it has 30 MiB)?

    ps, does wm6 have the same case as wm5?

    Thank you!

    wp