A method and apparatus for reallocating in the local memory of an implantable medical device for upgrading operating software stored in the Code portion of the local memory. Electromagnets are disposed on the inner surface of the pressure vessel. This proves to be very complicated and problematic. If so, the code module is migrated to a new module container, and the code module in the original module container is replaced with a reference to the code module in the new module container. The device 1 and 2 communicates by using the obtained antenna-setting pairs. Light pipes placed substantially proximate to the distal focal points may collect the radiation.