Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

ENC28J60 - very precise value for Rbias is needed? - SOLVED

Status
Not open for further replies.

Eugen_E

Full Member level 6
Joined
Nov 29, 2004
Messages
383
Helped
44
Reputation
86
Reaction score
11
Trophy points
1,298
Location
Romania
Activity points
2,862
enc28j60

I started building an embedded webserver with ENC28J60 and ATmega16. The circuit is inspired from http://www.tuxgraphics.org/electronics/200611/embedded-webserver.shtml, adapted for ATmega16, and with a few additions.
I started testing with firmware from http://www.tuxgraphics.org/common/src2/article06111/eth_rem_dev_tcp-2.10.tar.gz - adapted for ATmega16 and recompiled.
When I run the code from test1.c, the LEDs connected to ENC28J60 flash according to specifications, but finally the link state LED remains off. I use a 1m crossover cable connected to PC.

I want to ask if the link establishment problem could be because of a wrong Rbias value (I used 2k7 and 2k2). The Rbias value should be chosen according to the silicon revision of the chip, but i don't know the revision. However, if i used a wrong value, could this influence reception for a small length cable, or could it damage the chip?
ENC28J60 runs a bit warm, is this normal?

Thanks
 

enc28j60 rbias

Depending on the revision you have to run the SPI bus between 8 & 10MHz or it won't talk. The ENC28J60 runs warm. The wrong resistor will just make the waveform incorrect but no damage.
 

    Eugen_E

    Points: 2
    Helpful Answer Positive Rating
rbias

Thanks.
I read the silicon rev from the chip (using UART for debugging) and found it to be Rev. B4, so Rbias=2k7. I still have the link problem.

Reading on the Rev. B4 Silicon Errata I learned the chip has quite many bugs ranging from incorrect LED illumination to bad reception when the TPIN+/TPIN- are inverted, it's necessary to run the SPI at >8MHz...
I run the AVR uC at 12.5MHz, from the CLKOUT of ENC28J60, and the SPI is used at 6.25MHz. I think this is Ok, because it's recommended in the Errata and the uC can communicate with ENC28J60.

If you used a Rev. B4 chip, please share your experience.
 

enc28j60 magjack

Problem solved. The Ethernet integrated connector+transformer+filter had different internal connections than the one on the schematic when i designed the PCB. After I corrected the connections I received ping responses with 0% loss and 0.9ms delay. Now it works great.
 

enc28j60 revision

i'm tring to build the same webserver . it's working perfect in simulation ( i use proteus 7.4) but on the board it doesn't. when the avr is sending spi commands to the enc28j60 the ethernet leds are turning off. i suspect it's a spi comunication problem. the wiring to the magjack is ok. i use atmega16 with a 16mhz crystal. i think i addapted the code ok(it's working in simulation). any ideeas ?

later edit: it's for sure a SPI problem. when i send something through SPI to the enc28j60 the leds turn off. i don't think this is normal...
 

Hey can i get your adapted code for atmega16? thanks a lot.
 

Re: ENC28J60 - very precise value for Rbias is needed? - SOL

can you post the Proteus file?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top