]> git.sur5r.net Git - freertos/blob - Demo/ColdFire_MCF51CN128_CodeWarrior/Sources/eth_phy.h
Start to re-arrange files to include FreeRTOS+ in main download.
[freertos] / Demo / ColdFire_MCF51CN128_CodeWarrior / Sources / eth_phy.h
1 /*!\r
2  * \file    eth.h\r
3  * \brief   Definitions for Ethernet Physical Layer Interface\r
4  * \version $Revision: 1.3 $\r
5  * \author  Michael Norman\r
6  */\r
7 \r
8 #ifndef _ETH_PHY_H\r
9 #define _ETH_PHY_H\r
10 \r
11 /*******************************************************************/\r
12 \r
13 /* MII Register Addresses */\r
14 #define PHY_BMCR                                    (0x00)\r
15 #define PHY_BMSR                    (0x01)\r
16 #define PHY_PHYIDR1                                 (0x02)\r
17 #define PHY_PHYIDR2                                 (0x03)\r
18 #define PHY_ANAR                                    (0x04)\r
19 #define PHY_ANLPAR                          (0x05)\r
20 \r
21 /* Bit definitions and macros for PHY_CTRL */\r
22 #define PHY_BMCR_RESET                  (0x8000)\r
23 #define PHY_BMCR_LOOP                       (0x4000)\r
24 #define PHY_BMCR_SPEED                  (0x2000)\r
25 #define PHY_BMCR_AN_ENABLE                  (0x1000)\r
26 #define PHY_BMCR_POWERDOWN          (0x0800)\r
27 #define PHY_BMCR_ISOLATE                (0x0400)\r
28 #define PHY_BMCR_AN_RESTART             (0x0200)\r
29 #define PHY_BMCR_FDX                        (0x0100)\r
30 #define PHY_BMCR_COL_TEST               (0x0080)\r
31 \r
32 /* Bit definitions and macros for PHY_STAT */\r
33 #define PHY_BMSR_100BT4             (0x8000)\r
34 #define PHY_BMSR_100BTX_FDX         (0x4000)\r
35 #define PHY_BMSR_100BTX             (0x2000)\r
36 #define PHY_BMSR_10BT_FDX           (0x1000)\r
37 #define PHY_BMSR_10BT               (0x0800)\r
38 #define PHY_BMSR_NO_PREAMBLE        (0x0040)\r
39 #define PHY_BMSR_AN_COMPLETE        (0x0020)\r
40 #define PHY_BMSR_REMOTE_FAULT       (0x0010)\r
41 #define PHY_BMSR_AN_ABILITY         (0x0008)\r
42 #define PHY_BMSR_LINK               (0x0004)\r
43 #define PHY_BMSR_JABBER             (0x0002)\r
44 #define PHY_BMSR_EXTENDED           (0x0001)\r
45 \r
46 /* Bit definitions and macros for PHY_AN_ADV */\r
47 #define PHY_ANAR_NEXT_PAGE          (0x8001)\r
48 #define PHY_ANAR_REM_FAULT              (0x2001)\r
49 #define PHY_ANAR_PAUSE                  (0x0401)\r
50 #define PHY_ANAR_100BT4                 (0x0201)\r
51 #define PHY_ANAR_100BTX_FDX             (0x0101)\r
52 #define PHY_ANAR_100BTX                 (0x0081)\r
53 #define PHY_ANAR_10BT_FDX                   (0x0041)\r
54 #define PHY_ANAR_10BT                   (0x0021)\r
55 #define PHY_ANAR_802_3                  (0x0001)\r
56 \r
57 /* Bit definitions and macros for PHY_AN_LINK_PAR */\r
58 #define PHY_ANLPAR_NEXT_PAGE        (0x8000)\r
59 #define PHY_ANLPAR_ACK              (0x4000)\r
60 #define PHY_ANLPAR_REM_FAULT        (0x2000)\r
61 #define PHY_ANLPAR_PAUSE                    (0x0400)\r
62 #define PHY_ANLPAR_100BT4                   (0x0200)\r
63 #define PHY_ANLPAR_100BTX_FDX       (0x0100)\r
64 #define PHY_ANLPAR_100BTX                   (0x0080)\r
65 #define PHY_ANLPAR_10BTX_FDX        (0x0040)\r
66 #define PHY_ANLPAR_10BT                 (0x0020)\r
67 \r
68 /*******************************************************************/\r
69 \r
70 #endif  /* _ETH_PHY_H */\r