If you arrive into MAD at 11:40a, the earliest you could get to Pamplona by bus is 7:45pm, which will be after the bus has left for SJPP. You certainly could get a taxi that late, though, from outside the bus station. The taxi will probably cost around 80-100 euros.
Bus service from Madrid to Pamplona is with Alsa, but on a Conda bus. There is a bus that leaves at 1:15pm from MAD Terminal 4. It's the same bus that leaves the Ave de America station at 1:00p, so no need to hop the metro to get to a different station.
Another option is to contact Corazon Puro and see if they will do a pick-up in Pamplona that late. They are a pension about 30 kms from Pamplona, on the way to SJPP, and they will drop you in SJPP the next morning by 9:00am - early enough to start your walk after a quick visit to the Pilgrim's Office. Total cost for pick-up in Pamplona, dinner, breakfast, bed, and ride to SJPP is 43 euros per person.
http://corazonpuro.es/