Consumer electronics giant Sony (SNE) agreed on Friday to buy a significant share in Olympus for $640 million, enhancing its portfolio of technologies for the medical field.

The company's will combine Olympus’s lens and optical technologies with Sony’s range of digital imaging technologies to better perform in the rapidly growing medical market.

“As part of our strategic initiatives announced in April 2012, at Sony we are aggressively pursuing the growth of our medical business, with the aim of developing it into a key pillar of our overall business portfolio,” Sony CEO Kazuo Hirai said in a statement.

The Tokyo-based consumer electronics company has been trying to steer away from its struggling TV business, looking instead of diversify into new, higher-growth sectors.

Sony is now Olympus’s biggest shareholder, holding about an 11.46% stake in the Japan-based consumer electronics and medical device maker.

The company said it believes their integration will generate “highly innovative and competitive products” as well as new business opportunities in surgical endoscopes and other related areas that are set to expand.

Sony also said that it will work with Olympus to collaborate on their two digital camera businesses.

Follow Jennifer Booton on Twitter at @Jbooton