receiving frames added and a few fixes