This post has had a lot of views, but no suggested solutions. Not surprising, I suppose, in view of what I discovered was the real problem. I could hide my stupidity, but perhaps it's better to be honest.
After trying a different battery, and a different motor body, I realised the problem was actually the charger, as the blue light on the battery would sometimes go out if I moved the cable. So the problem was that when the light went out I thought the battery was fully charged, but the Dyson was correctly telling me that it was only partly charged, or, in fact, hardly charged at all. A new charger has solved the problem.
Amazing how easy it is to forget you should always check the basic things first.