I have a solution that may work for you..
If the cable is still turning ok - you need to confirm this
If the end is rounded off or not connecting with the drive properly - you need to confirm this also
I presume the cable is lubed nicely and no kinks, bends in it
I also presume the cable mounts to the speedo nice and firm - not cross threaded ...
Get some small sections of heat shrink that will slide over the end of the exposed cable - 1/2 -3/4" length would be plenty.
Put one section over the cable and shrink it down - trim the end flush - insert and test.
If that doesn't work - put another section over the first and shrink it down - trim - test.
I did this on a cb250 Tacho that refused to spin - only when you squeezed/pushed the cable into the back of the tacho did it jump about wildly.
after a doule layer of heat shrink - it worked as smooth as...and was still going strongly when I sold the bike..
My local repairer has used this method at least twice on customers bikes who have not wanted to buy another speedo/tacho - because the end was rounded out on the speedo/tacho/ and or cable..
give it a try.....