How to move axis and make attached hinge swing freely

Lets say i ahve a robotic leg. If i move the main leg, i want the attached foot to just swing freely. How can i do this? I assume it would be a mix of a armature riggin and softbody?

I want the swinging foot to appear to be affected by intertia (ie. the foot willl swing backwards when the leg moves forward due to intertia and mass of the foot). How can this be achieved.