User`s manual

RX600 & RX200 Series Simple Flash API for RX
R01AN0544EU0250 Rev.2.50 Page 32 of 33
March 4, 2014
4.12 R_FlashGetVersion
Returns the current version of the Flash API.
Format
uint32_t R_FlashGetVersion(void);
Parameters
None.
Return Values
Version of Flash API.
Properties
Prototyped in file “r_flash_api_rx_if.h
Implemented in file “r_flash_api_rx.c
Description
This function will return the version of the currently installed Flash API. The version number is encoded
where the top 2 bytes are the major version number and the bottom 2 bytes are the minor version number.
For example, Version 4.25 would be returned as 0x00040019.
Reentrant
Yes.
Example
uint32_t cur_version;
/* Get version of installed Flash API. */
cur_version = R_FlashGetVersion();
/* Check to make sure version is new enough for this application’s use. */
if (MIN_VERSION > cur_version)
{
/* This Flash API version is not new enough and does not have XXX feature
that is needed by this application. Alert user. */
....
}
Special Notes:
This function is specified to be an inline function in r_flash_api_rx.c.