Hastings man takes plea deal in sexual assault and child pornography case