Fixing login for headpin/sam