put receiver stuff in ready function