I’m going with the question being a real-life scenario.
Really it’d depend. How am I entering the castle? How about defending? (You never quite specified which side I’m on for this castle siege, so I’ll do both)
Attacking
Siege Tower: I’m most likely going to be among the middle mass, so I’d need reach first of all, so I’d go maybe spear (polearm) and once in close, I think an arming sword and heater shield. A warhammer or pick might be a great sidearm (and we’re to assume all choices include carrying some sort of dagger. I’m going rondel)
Ladders: Definitely a heater shield, spear, and arming sword. Shield to defend against archer fire (and I’m hoping my plate will block the rest) spear when I’m near the top to jab upwards, and once over go straight to the arming sword.
Battering Ram: I’d like a heater shield still as well as an arming sword, but here I’d also want a pick. There’s going to be murder holes above me, and that’s just going to be a death trap until we take the gatehouse fully. Long story short, I expect to die.
Breach: Heater, sword, pick. Archers’ll probably be firing at me from above while we’re stuck in a roving mass of bodies until either side breaks.
Defending
Siege Tower: Spear. They’ll be coming from in front of me or slightly above. great for taking shots at their legs and crotch. Once in close, I’ll just grab whatever is laying about for close quaters and take my rondel as my offhand.
Ladders: Spear. Got a good reach, I can stab and push them off. Rondel if they get too close.
Battering Ram: Depends. If we’re talking among the front two ranks, spear and pavise. Hold them back as long as possible while spearing over or beside the shield. Again, sword sidearm. If I’m in the gatehouse, I’m going to focus on using a bow to fire down through the murder holes.
Breach: Front lines, same as before with the battering ram. Hold them in the breach while the archers pick them off from above. If I am on the walls, again go with a bow.