What type of mechanism can I use to connect 2 coaxial pipes of unequal diameters, where the outer pipe can slide over the inner pipe? I was thinking about splines, is there any better way...? Also, if I want the connection to be leakproof, what are the options that I have ?
Do the pipes need to be "keyed" such that they cant rotate with respect to each other? If not, you can maybe seal the inner pipe like a piston(inner pipe) in a cylinder( outer pipe) shaft/T/U/oring/seal etc. Not sure how those seals work with gases as they do with liquids, but air is a gas and pneumatic cylinders work the same!
You would need a dual O ring system with sufficient spacing between the O rings. As for a sealant, use a silicon based lubricant. The interference pressure for would need to exceed the pneumatic pressure in the pipes.
As for picking the pipes in varying positions, an helical cam system would suffice with dual spring-loaded bearing balls that keep it either locked or open through a rotation (twisting) motion.