The difficulty is seldom in the speedometer head itself. I would first pursue inspecting and lubricating or replacing the cable as suggested. If this does not solve the problem, the most likely cause is a worn out speedometer drive gear.
The driven gear, which is attached to the cable on the trans end, meshes to a circular drive gear pressed onto the transmission output shaft. This gear is plastic and over time the center of it wears down, creating a "dip" in the splines. It then makes only skipping contact with the driven gear, resulting in the needle bounce effect that you describe.
The gear itself is readily available from various toploader transmission suppliers. Installation requires removal of the transmission tailshaft housing. Exact positioning of the new gear onto the output shaft is critical for proper operation.
I have had several of these replaced over the years and it always fixed the problem.