An important issue in Ambient Intelligence (AmI) is the massive deployment of intelligent agents embedded in the environment which are adaptive to the users' profiles, preferences and needs. This is why, the use of agent-oriented methodologies and frameworks is almost mandatory to easily develop software for AmI scenarios. ICARO is a software framework that promotes the use of different organizational and behavioral patterns to implement multi-agent systems (MAS). Its extensive use in several projects demonstrates a substantial increase in software productivity. Also, in order to reduce the coding effort it is usual to design MAS at a higher level. In this sense, code generation from MAS specifications into ICARO framework has been performed. INGENIAS Development Kit (IDK) supports both the specification of MAS models, including any feature required to implement MAS with ICARO, and a set of facilities for code generation. This paper describes the development of AmI applications thanks to the integration of ICARO and IDK. Two IDK modules have been developed, namely a "code generation" and a "code update support" module.