Unable to access the dataflash of Controller R5f100LE using e2studio.

I just created the workspace and project in e2studio, I added the library file

pfdl.h   pfdl.inc   pfdl.lib   r_pfdl.c

i did not even called those function of library in main function.

added  this code in r_cg_userdefine.h

////////////

#define FLASH_START_ADDRESS     (0xF1000U)                              /* Start address of data flash               */
#define TARGET_BLOCK            (0U)                                    /* Block number of target(0 ~ 3)             */
#define BLOCK_SIZE              (0x400U)                                /* Block size                                */
#define WRITE_SIZE              (1U)                                    /* Size of data to be written at once        */
#define MAX_VALUE               (0xFFU)                                 /* Maximum value of writing                  */
#define MAX_ADDRESS             ((TARGET_BLOCK + 1U) * BLOCK_SIZE - 1U) /* Maximum address of writing                */
#define PFDL_NG                 (1U)                                    /* Failure to Data Flash                     */
#define FDL_FRQ                 (32U)                                   /* Setting frequency (MHz)                   */
#define FDL_VOL                 (0x00U)                                 /* Voltage mode                              */


void    R_FDL_Init(void);
uint8_t R_FDL_BlankCheck(void);
uint8_t R_FDL_Erase(void);
uint8_t R_FDL_Verify(void);
void    R_FDL_Read(void);
uint8_t R_FDL_Write(void);
void    R_FDL_ChangeAddress(void);
uint8_t R_FDL_ExecuteWrite(void);
uint8_t R_FDL_ClearDataFlash(void);

#if    TARGET_BLOCK > 3U
#error target_block error!!
#endif

 

////////////////////////////////

 

I just compiled the project, i found these error.

these are already available in library file in pfdl.h

 


E0562310:Undefined external symbol "_PFDL_Open" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_g_write_address" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_g_write_value" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_PFDL_Handler" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_PFDL_Execute" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_g_read_value" referenced in ".\src\cg_src\r_pfdl.obj"
E0562310:Undefined external symbol "_PFDL_Close" referenced in ".\src\cg_src\r_pfdl.obj"

Renesas Optimizing Linker Abort
makefile:73: recipe for target 'dataflash.abs' failed
make: *** [dataflash.abs] Error 1

 

 

 

 

These are mentioned in pfdl.h as

extern  pfdl_status_t  __far PFDL_Open(__near pfdl_descriptor_t* descriptor_pstr);

then why is creating the error.

 

i downloaded library files from

https://www.renesas.com/en-in/software/D3016256.html

i downloaded sample code from

https://www.renesas.com/en-in/software/D3016442.html

I added the library file in the sample code which i downloaded, which is also showing the same error.

so i created the new project then also its showing same problem .

 

 

Please HELP.

  • Hi Hiroshi,

    Any updates with the issue? Have you found what's causing the error?

    JB
    RenesasRulz Forum Moderator
  • Hi JB,

    Nope, I tried my best to solve <_PFDL_Open" referenced in ".\src\cg_src\r_pfdl.obj"> this error, i was able to compile it with cubesuit+ in CCRL with no error. I am unable to fine the reason why these error popped up in e2studio.
  • In reply to Hiroshi:

    Hiroshi,

    How did you add the library to your e2studio project?

    Mike Clements
    RenesasRulz Moderator
  • In reply to Hiroshi:

    This thread will be archived due to inactivity.

    Mke Clements
    RenesasRulz Moderator