Pedrosa signs off 2012 with a win