Entanglement of two-mode Bose-Einstein condensates