I did bit operators wrong the first time.