Skip to main content
Graduate
June 26, 2024
Question

How to send/receive Ethernet packets in STM32MP157

  • June 26, 2024
  • 2 replies
  • 2806 views

Hi,

I want to send and receive data using Ethernet.

I tried this Linux version code, but it didn't works. https://gist.github.com/austinmarton/1922600 

After I failed to try, I found this header code, STMMAC.

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/net/ethernet/stmicro/stmmac/stmmac.h  

Should I make a program based on this code??

 

I've searched a lot, but I couldn't find any related cases.

I'm not good enough to make the whole program code.

If you have any relevant content or examples, please let me know....

 

    This topic has been closed for replies.

    2 replies

    Technical Moderator
    June 28, 2024

    Hi @inkong ,

     

    Not sure to get your question 

    Ethernet can be manage by OpenSTLinux

    refer to How to configure ethernet interface - stm32mpu 

    Ethernet overview - stm32mpu

     

    Olivier 

    Visitor II
    July 16, 2024

    If you want to generate data over the ethernet port (just to validate or something) you could use for instance command line from linux (e.g. wget)
    https://linux.die.net/man/1/wget

    To download an image in an endless while loop for instance:

    while [ 1 ]; do wget https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.1.42.tar.gz; done;

     (it will do forever (untill stopped) a download of the kenrnel archive in tar.gz format, which is ~200 MB of size. )