src/ENC28J60.c
static void enc28j60_enable(const struct enc28j60_dev *priv) {
    /* enable interrupt logic */

    phy_write(priv, ENC28J60_PHIR, 0); // clear all PHY interrupt flags
    phy_write(priv, ENC28J60_PHIE, (_BV(PGEIE) | _BV(PLNKIE)));

    // clear all interrupt flags
    bfc(priv, ENC28J60_EIR, (_BV(PKTIF) | _BV(DMAIF) | _BV(LINKIF) |
                             _BV(TXIF) | _BV(TXERIF) | _BV(RXERIF)));
    // enable interrupts (except for DMA, which is currently not used)
    wcr(priv, ENC28J60_EIE, (_BV(INTIE) | _BV(PKTIE) | _BV(LINKIE) |
                             _BV(TXIE) | _BV(TXERIF) | _BV(RXERIE)));

    /* enable receive */
    bfs(priv, ENC28J60_ECON1, _BV(RXEN));
}
/*!
 * @brief Enable chip to RX and TX, enable interrupts
 */
@brief Enable chip to RX and TX, enable interrupts
@brief Enable chip to RX and TX enable interrupts
static void enc28j60_enable(const struct enc28j60_dev *priv) {
    phy_write(priv, ENC28J60_PHIR, 0); 
    phy_write(priv, ENC28J60_PHIE, (_BV(PGEIE) | _BV(PLNKIE)));
    bfc(priv, ENC28J60_EIR, (_BV(PKTIF) | _BV(DMAIF) | _BV(LINKIF) |
                             _BV(TXIF) | _BV(TXERIF) | _BV(RXERIF)));
    wcr(priv, ENC28J60_EIE, (_BV(INTIE) | _BV(PKTIE) | _BV(LINKIE) |
                             _BV(TXIE) | _BV(TXERIF) | _BV(RXERIE)));
    bfs(priv, ENC28J60_ECON1, _BV(RXEN));
}
static void enc28j60_enable ( const struct enc28j60_dev * priv ) { phy_write ( priv , ENC28J60_PHIR , 0 ) ; phy_write ( priv , ENC28J60_PHIE , ( _BV ( PGEIE ) | _BV ( PLNKIE ) ) ) ; bfc ( priv , ENC28J60_EIR , ( _BV ( PKTIF ) | _BV ( DMAIF ) | _BV ( LINKIF ) | _BV ( TXIF ) | _BV ( TXERIF ) | _BV ( RXERIF ) ) ) ; wcr ( priv , ENC28J60_EIE , ( _BV ( INTIE ) | _BV ( PKTIE ) | _BV ( LINKIE ) | _BV ( TXIE ) | _BV ( TXERIF ) | _BV ( RXERIE ) ) ) ; bfs ( priv , ENC28J60_ECON1 , _BV ( RXEN ) ) ; }
@brief Enable chip to RX and TX, enable interrupts
@brief Enable chip to RX and TX enable interrupts
/* enable interrupt logic */ // clear all PHY interrupt flags // clear all interrupt flags // enable interrupts (except for DMA, which is currently not used) /* enable receive */