Hi Ruwe,
The driver is supposed to work on F107, F2 and F4 but so far it has been tested only on the F107, testing coverage will improve in next weeks.
Anyway if you find any problem we can address it via forum.
Giovanni
STM32 Ethernet Demo
- Giovanni
- Site Admin
- Posts: 14895
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: STM32 Ethernet Demo
Hi all
I tried the demo on a STM32F407ZGT6-based custom board with DP83848I PHY and it works OK!
To compile the thing, I had to creatively copy-paste rccEnableETH(), rccDisableETH() and rccResetETH() defines from F1's RCC code. To get it running i had to adjust mac_lld_start() to kick PHY into power up mode before commanding reset procedure. Otherwise the reset procedure would never complete. I'm kinda new to this programming thing, so I didn't consider any side effects this change may have.
But anyways, the board responds to ping and the web server works. Great job guys!
73 de OH2GVE
I tried the demo on a STM32F407ZGT6-based custom board with DP83848I PHY and it works OK!
To compile the thing, I had to creatively copy-paste rccEnableETH(), rccDisableETH() and rccResetETH() defines from F1's RCC code. To get it running i had to adjust mac_lld_start() to kick PHY into power up mode before commanding reset procedure. Otherwise the reset procedure would never complete. I'm kinda new to this programming thing, so I didn't consider any side effects this change may have.
But anyways, the board responds to ping and the web server works. Great job guys!
73 de OH2GVE
- Giovanni
- Site Admin
- Posts: 14895
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: STM32 Ethernet Demo
Hi,
Thanks for testing, I will fix the RCC issue.
About the PHY initialization, it is assumed the PHY is initialized in board.c being the reset procedure dependent on the board and the PHY part.
Giovanni
Thanks for testing, I will fix the RCC issue.
About the PHY initialization, it is assumed the PHY is initialized in board.c being the reset procedure dependent on the board and the PHY part.
Giovanni
Re: STM32 Ethernet Demo
Got myself one of those DP83848 boards too, for use with a STM32F4-DISCOVERY board. Should be fun.
I co-designed a STM32F4 based board for educational use a few months back, with Ethernet support. DP83848's were too expensive ($4 per 100), so we went with Micrel KSZ8031RNL PHY's ($0,70 per 100). I'll give the board a try with ChibiOS if I find the time.
I co-designed a STM32F4 based board for educational use a few months back, with Ethernet support. DP83848's were too expensive ($4 per 100), so we went with Micrel KSZ8031RNL PHY's ($0,70 per 100). I'll give the board a try with ChibiOS if I find the time.
-
rubenswerk
- Posts: 104
- Joined: Wed Feb 22, 2012 11:39 am
Re: STM32 Ethernet Demo
I always wondered why everyone uses the expensive DP83848, but it's really hard to find example boards with the KSZ8031. The QFN24 package with its ground plane is not so easy to solder at home, but I would really like to try. The Micrel is small and cheap. But I don't want to design a board without having seen a working reference design.
@kgysmits:
If you'd have a Micrel example or a link to a board using it, this would be very helpful. Please let us know if it works with ChibiOS. Thanks!
@kgysmits:
If you'd have a Micrel example or a link to a board using it, this would be very helpful. Please let us know if it works with ChibiOS. Thanks!
Re: STM32 Ethernet Demo
I have attached a part of the STM32F4 with KSZ8031 design. The prototypes work with the FreeRTOS lwIP demo, no further tests were done.
To solder the center pad, you could design your board with a nice big via underneath the chip so you can solder it by hand. 50% solder coverage is plenty for a good connection. The pads on the edges of the board are easy to solder, as they are also accessible from the side somewhat. make sure your proto footprint pads stick out from underneath the chip at least 2mm.
Don't expect my testing results any time soon, got a few exams coming up and a school project to catch up with first.
To solder the center pad, you could design your board with a nice big via underneath the chip so you can solder it by hand. 50% solder coverage is plenty for a good connection. The pads on the edges of the board are easy to solder, as they are also accessible from the side somewhat. make sure your proto footprint pads stick out from underneath the chip at least 2mm.
Don't expect my testing results any time soon, got a few exams coming up and a school project to catch up with first.
- Attachments
-
- KSZ8031_STM32F4.png (35.33 KiB) Viewed 6280 times
- Giovanni
- Site Admin
- Posts: 14895
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: STM32 Ethernet Demo
Hi,
A note, the "IP checksum offload" is already enabled in the driver (bit ETH_MACCR_IPCO), it is just not enabled in lwIP. Anyway I am adding an option to enable or disable it in the driver too.
Giovanni
A note, the "IP checksum offload" is already enabled in the driver (bit ETH_MACCR_IPCO), it is just not enabled in lwIP. Anyway I am adding an option to enable or disable it in the driver too.
Giovanni
Re: STM32 Ethernet Demo
@Giovanni,
Strange, I had to enable calculation in LwIP - otherwise all packages had the checksum set to 0...
Strange, I had to enable calculation in LwIP - otherwise all packages had the checksum set to 0...
- Giovanni
- Site Admin
- Posts: 14895
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: STM32 Ethernet Demo
Do I need to enable something else apart from ETH_MACCR_IPCO?
Edit: found it, it is a setting in the CIC field of TDES0, I am adding it.
Giovanni
Edit: found it, it is a setting in the CIC field of TDES0, I am adding it.
Giovanni