Try installing the cable on the Speedo first out of the dash and slide the Speedo and cable into dash knowing that its not kinked then connect it to the trans making sure there is no kinks all the way down.
That looks like ballest resistor for the points ignition system. You need to test that wire with the key on, of it has 12 bolts connect it to one side of the resistor. Then check the other side of the resistor or should be about 6 to 8 volts that wire goes to the points. Hope this helps.
Have you checked the timing at idle when hot? Or maybe the carb is to hot boiling over ? It could be a air leak at the base of the carb? Ck and see of the air pump is working it needs to be there to keep the exhaust valves cool.