User manual
mikroBasic PRO for PIC32
MikroElektronika
154
Prototype
sub function Clock_kHz() as longint
Description Function returns device clock in kHz, rounded to the nearest integer.
This is an “inline” routine; code is generated in the place of the call, so the call doesn’t count against
the nested call limit.
Parameters None.
Returns Device clock in kHz, rounded to the nearest integer.
Requires Nothing.
Example
clk = Clock_kHz();
Notes None.
Prototype
sub function Clock_MHz() as word
Description Function returns device clock in MHz, rounded to the nearest integer.
This is an “inline” routine; code is generated in the place of the call, so the call doesn’t count against
the nested call limit.
Parameters None.
Returns Device clock in MHz, rounded to the nearest integer.
Requires Nothing.
Example
clk = Clock_Mhz();
Notes None.
Prototype
sub function Get_Fosc_kHz() as longint
Description Function returns device clock in kHz, rounded to the nearest integer.
Parameters None.
Returns Device clock in kHz.
Requires Nothing.
Example
clk = Get_Fosc_kHz();
Notes Get_Fosc_kHz is a library function rather than a built-in routine; it is presented in this topic for the
sake of convenience.
Clock_kHz
Clock_Mhz
Get_Fosc_kHz