If you record in Logic and you can't get the tracks in sync check these things:
1. Go to Logic Pro X > Preferences > Audio and make sure the Recording Delay is set to 0.
2. Go to the Record tab at the top of the screen and make sure Low Latency Mode is unchecked.