Device for generation of an output signal having a desired frequency, the device comprising: a MEMS oscillator comprising a MEMS resonator for generating a reference signal; a temperature control system associated with the MEMS resonator and provided for maintaining the MEMS resonator at a desired operation temperature in response to a temperature setting signal; a control unit, communicatively coupled with the temperature control system and provided for generating the temperature setting signal therefor; the control unit comprising at least one input node for receiving a parameter set, said parameter set comprising at least a first parameter indicative of a sensed ambient temperature; and the control unit being provided for selecting the operation temperature for the MEMS resonator from a plurality of pre-characterised temperatures based on the received parameter set; characterized in that the device comprises a compensation unit provided for generating the output signal from the reference signal generated by the MEMS resonator, the compensation unit being communicatively coupled with the control unit for receiving at least one compensation parameter from the control unit, the control unit being provided for generating the at least one compensation parameter based on the received parameter set; and in that the received parameter set comprises a fourth parameter indicating time frames during which stability of the reference signal is not necessary and in that the control unit is provided for postponing setting the operation temperature for the MEMS resonator to a different pre-characterised temperature to a time frame indicated by the fourth parameter. a MEMS oscillator comprising a MEMS resonator for generating a reference signal; a temperature control system associated with the MEMS resonator and provided for maintaining the MEMS resonator at a desired operation temperature in response to a temperature setting signal; a control unit, communicatively coupled with the temperature control system and provided for generating the temperature setting signal therefor; the control unit comprising at least one input node for receiving a parameter set, said parameter set comprising at least a first parameter indicative of a sensed ambient temperature; and the control unit being provided for selecting the operation temperature for the MEMS resonator from a plurality of pre-characterised temperatures based on the received parameter set; characterized in that the device comprises a compensation unit provided for generating the output signal from the reference signal generated by the MEMS resonator, the compensation unit being communicatively coupled with the control unit for receiving at least one compensation parameter from the control unit, the control unit being provided for generating the at least one compensation parameter based on the received parameter set; and in that the received parameter set comprises a fourth parameter indicating time frames during which stability of the reference signal is not necessary and in that the control unit is provided for postponing setting the operation temperature for the MEMS resonator to a different pre-characterised temperature to a time frame indicated by the fourth parameter.