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: ip address acessing in application saved by redboot.


Hi,

On Tue, Mar 11, 2003 at 12:54:43PM +0530, rameshs at danlawinc dot com wrote:
> Hi,
>    I am working in the redboot porting for Adderboard.
> I have one doubt. Redboot saves the ip and ethernet information in the flash
> memory.I want to know how to acess the ipaddress in the application which is
> used by redboot.I know the ethernet address is acessed through the virtual
> vector.Can any one please give how to acess the ip address stored in the
> flash by Redboot.I want to weather any routine is there in the code for
> acessing the ip address.

For me the following is doing this.

   struct in_addr addr;
   CYGACC_CALL_IF_FLASH_CFG_OP( CYGNUM_CALL_IF_FLASH_CFG_GET
                              , const_cast<char *>("bootp_my_ip")
                              , &addr.s_addr
                              , CYGNUM_FLASH_CFG_OP_CONFIG_IP
                              );

hth, christoph
-- 

-- 
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]