I have developed software for close to 18 years, and have been managing its development for the last 7. I also hold both an MBA and PM from a reputable university.
Honestly, I don't think you need either.
If your intention (as you describe) is to "prepare" for an upcoming career in management, then I'd suggest you find an existing manager and shadow them, and, if possible, get your hands dirty practising management as well. Based on what I've seen over the years, this approach is, without a doubt, the best way to prepare for a career in management.
(consider for a moment that you might not enjoy management at all, in which case this approach also helps you minimise your costs associated with learning)
For what it's worth, and as other posters have touched on, I found the MBA to be a great capstone course, that provides you with a strong set of generalist skills across all aspects of business. It will equip you with both knowledge and a sense of confidence that will certainly help you over the long-term, and will probably open many doors - due to both the reputation that preceedes it as well as the network of peers in your MBA alumni network (the latter will vary depending on where you study, and if you do go ahead with the MBA, I suggest you strongly consider the strength of alumni networks when surveying business schools).
The PM on the other hand is highly specialised. Whilst its body of knowledge is very thorough, I find that it is often overkill in a practical setting - although that all depends on the size of your project(s), the size of your team(s), and the extent to which your organisation practises textbook project management techniques. As a simple rule of thumb, unless you're in an organisation that explicitly seeks to employ qualified PMs (and abides by all the classic PM processes and procedures), you're better off avoiding this qualification.
So yes, in summary, your best bet is to seek out existing managers and learn from them. But you can't go wrong with an MBA (provided you choose your school wisely), and PM is overkill unless your organisation is PM-oriented.
On a side note, I find your choice of words interesting. You say that you'd like to "advance your career from development to management", when in reality, it's a sideways (as opposed to an upwards) move. But perhaps I'm being overly analytical on your choice of words.
Good luck :)