Besides, I'm not sure what indication people get that the ewoks won the battle, just because we see some stormtroopers get knocked down. I find it strange how so many people blow the scenes of individual troops being taken by surprise out of proportion, but ignore the parts which show groups of ewoks fleeing from retaliatory attacks (AT-STs in particular). Besides, if the majority of the ewoks hadn't been driven off, then how would Han Solo have been able to convince the Imperial officers inside the bunker that the battle was over?
"Grant Allen [...] had written a book about the Evolution of the Idea of God. [...] it would be much more interesting if God wrote a book about the evolution of the idea of Grant Allen." ~ G. K. Chesterton, The Everlasting Man