There is a game specific test for the cannon in diags. With the test started and the coin door closed, push the start button and the cannon should rotate about 1/3 of the way out and stop. Push the start button again and it should rotate all the way out and back to the home position without stopping. While running the test, watch the DMD to see that the switches are working properly. If the two micro switches are working properly, you have an opto issue.