A device comprising: a substrate comprising a semiconductor on insulator structure; an optical slab on the insulator, the optical slab formed from the semiconductor; an optical input, an optical output, at least one optical bus (203, 238) there between, and an optical ring resonator coupled to the at least one optical bus (203, 238) and extending from the optical slab, characterized by: a heater in the optical slab and within at least a portion of the optical ring resonator, the heater extending between at least an inner diameter and an outer diameter of the optical ring resonator, the heater comprising a locally doped portion of the semiconductor of the optical slab having a non-uniform doping profile; electrical connections to the heater; a memory storing predetermined electric parameters of the heater which, when applied to the heater, will cause the dopant in the heater to diffuse relative to the optical ring resonator, thereby inducing a shift in the resonance of the optical ring resonator as a result of changing a concentration of the dopant within the optical ring resonator, the predetermined electric parameters stored as a function of resonance frequency shift in the optical ring resonator during heating; and, a controller in communication with the heater using the electrical connections, the controller configured to: determine an initial resonance frequency of the optical ring resonator; determine a subset of the predetermined electric parameters at which to operate the heater based on the initial resonance frequency and a target resonance frequency; and apply the subset of the predetermined electric parameters to the heater using the electrical connections to shift a resonance frequency of the optical ring resonator from the initial resonance frequency to the target resonance frequency. a substrate comprising a semiconductor on insulator structure; an optical slab on the insulator, the optical slab formed from the semiconductor; an optical input, an optical output, at least one optical bus (203, 238) there between, and an optical ring resonator coupled to the at least one optical bus (203, 238) and extending from the optical slab, characterized by: a heater in the optical slab and within at least a portion of the optical ring resonator, the heater extending between at least an inner diameter and an outer diameter of the optical ring resonator, the heater comprising a locally doped portion of the semiconductor of the optical slab having a non-uniform doping profile; electrical connections to the heater; a memory storing predetermined electric parameters of the heater which, when applied to the heater, will cause the dopant in the heater to diffuse relative to the optical ring resonator, thereby inducing a shift in the resonance of the optical ring resonator as a result of changing a concentration of the dopant within the optical ring resonator, the predetermined electric parameters stored as a function of resonance frequency shift in the optical ring resonator during heating; and, a controller in communication with the heater using the electrical connections, the controller configured to: determine an initial resonance frequency of the optical ring resonator; determine a subset of the predetermined electric parameters at which to operate the heater based on the initial resonance frequency and a target resonance frequency; and apply the subset of the predetermined electric parameters to the heater using the electrical connections to shift a resonance frequency of the optical ring resonator from the initial resonance frequency to the target resonance frequency. a heater in the optical slab and within at least a portion of the optical ring resonator, the heater extending between at least an inner diameter and an outer diameter of the optical ring resonator, the heater comprising a locally doped portion of the semiconductor of the optical slab having a non-uniform doping profile; electrical connections to the heater; a memory storing predetermined electric parameters of the heater which, when applied to the heater, will cause the dopant in the heater to diffuse relative to the optical ring resonator, thereby inducing a shift in the resonance of the optical ring resonator as a result of changing a concentration of the dopant within the optical ring resonator, the predetermined electric parameters stored as a function of resonance frequency shift in the optical ring resonator during heating; and, a controller in communication with the heater using the electrical connections, the controller configured to: determine an initial resonance frequency of the optical ring resonator; determine a subset of the predetermined electric parameters at which to operate the heater based on the initial resonance frequency and a target resonance frequency; and apply the subset of the predetermined electric parameters to the heater using the electrical connections to shift a resonance frequency of the optical ring resonator from the initial resonance frequency to the target resonance frequency. determine an initial resonance frequency of the optical ring resonator; determine a subset of the predetermined electric parameters at which to operate the heater based on the initial resonance frequency and a target resonance frequency; and apply the subset of the predetermined electric parameters to the heater using the electrical connections to shift a resonance frequency of the optical ring resonator from the initial resonance frequency to the target resonance frequency.