This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: HAL_PLATFORM_RESET


Tim Drury <tdrury@siliconmotorsports.com> writes:

> I'm still trying to get my board to return to a reset (or redboot)
> state after running a test instead of looping forever inside
> cyg_test_exit().  The macro to reset the board, HAL_PLATFORM_RESET,
> is not defined for my ARM eb40a.  What would be the best way to
> define it?

Here's what I've been using (on a custom AT91R40807 board):

#define HAL_PLATFORM_RESET() \
    CYG_MACRO_START          \
    HAL_WRITE_UINT32(AT91_WD+AT91_WD_CMR, 0x3700); \
    HAL_WRITE_UINT32(AT91_WD+AT91_WD_OMR, 0x2343); \
    CYG_MACRO_END



Regards,
   --Daniel



-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]