Three terminals optoelectronics devices integrated into a silicon on silicon waveguide