Renesas H8S/2378F Informações Técnicas Página 99

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 109
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 98
7.3.3 Flash Memory Erasing (FDTErase.c)
(1) EraseInit
The user area is selected, the operating frequency is specified, and the erasing library is initialized. The operating
frequency specified with FDT is transmitted to the device with new bit rate selection. For initial setting of the library,
this operating frequency is used.
/*
////////////////////////
// EraseInit Function //
////////////////////////
*/
BYTE EraseInit(void)
{
InitPtr ERASE_INIT = (InitPtr)INIT_ADDR;
UserMatSelect();
FKEY = WRITE_ERASE_ENABLE;
return ((*ERASE_INIT)(Frequency));
}
(2) EraseStart
The block number for erasing is specified and the erasing library is called. The block number is received from the Flash
Development Toolkit. For details, refer to Source Files of the Sample Program.
/*
/////////////////////////
// EraseStart Function //
/////////////////////////
*/
BYTE EraseStart(BYTE blk_no)
{
ErasePtr ERASE_BLOCK = (ErasePtr)WRITE_ERASE_ADDR;
return ((*ERASE_BLOCK)(blk_no));
}
INIT_ADDR and WRITE_ERASE_ADDR are defined in KDevice.h as follows:
#define TRANS_RAM_ADDR 0xFF8000
#define INIT_ADDR (TRANS_RAM_ADDR+32)
#define WRITE_ERASE_ADDR (TRANS_RAM_ADDR+16)
91
Vista de página 98
1 2 ... 94 95 96 97 98 99 100 101 102 103 104 ... 108 109

Comentários a estes Manuais

Sem comentários