fixing carrier register calculation