Altera_Forum
Honored Contributor
20 years agoLAN91C111 driver bug
in the file "altera_avalon_lan91c111.c" in the path "...\components\altera_avalon_lan91c111\UCOSII\src" the assignment:
IOWR_ALTERA_AVALON_LAN91C111_TCR( dev-> base_addr,ALTERA_AVALON_LAN91C111_TCR_TXENA_MSK | ALTERA_AVALON_LAN91C111_TCR_PAD_EN_MSK); in the fuction "low_level_init", overwrite the previous register assignment targeted for full-duplex connection: IOWR_ALTERA_AVALON_LAN91C111_TCR(dev->base_addr,value); in the fuction "configure_phy", causing collision and lost packet in full-duplex trasmissions. You can replace the first assignment with: value = IORD_ALTERA_AVALON_LAN91C111_TCR(dev->base_addr); value |= ALTERA_AVALON_LAN91C111_TCR_TXENA_MSK | ALTERA_AVALON_LAN91C111_TCR_PAD_EN_MSK ; IOWR_ALTERA_AVALON_LAN91C111_TCR(dev->base_addr,value); declaring: alt_u16 value; bye