An Ambient Intelligence System for Assisted Living