[ECOS] connect ethernet cable at run-time

Edgar Grimberg edgar.grimberg@zylin.com
Thu Sep 24 11:45:00 GMT 2009


Hi Lars,

> 2) When the network cable is connected, cyg_netint wakes up and does its thing.

You can write an interrupt routine for the PHY chip and have that
start/stop the ethernet.
As an example, look at:
static cyg_uint32 phy_isr(cyg_vector_t vector, cyg_addrword_t data)
static void phy_dsr(cyg_vector_t vector, cyg_ucount32 count,
cyg_addrword_t data)
from
http://www.ecosforge.net/ecosforge/trunk/ecos_mpc8313/packages/devs/eth/powerpc/quicc2pro/current/src/tsec.c


Regards,
Edgar



>
> Or is there a better way? The problem is that i dont know how to do either way.
>
> All ideas are welcome. Thank you in advance.
>
> Best Regards
> Lars Dahlin
>
> --
> Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
> and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
>
>



-- 
Edgar Grimberg
System Developer
Zylin AS
ZY1000 JTAG Debugger http://www.zylin.com/zy1000.html
Phone: (+47) 51 63 25 00

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



More information about the Ecos-discuss mailing list