2018-06-06 01:00 PM
Hello Everyone, I need do a MAC address broadcast of an ethernet data packet to a network by using the destination address as ff:ff:ff:ff:ff:ff . I don't want to an assign an ip to my devkit. Just want to do a layer 2 broadcast. I'm using STM32F207ZG. Which API's should i use for this and how can i do this? Thanks
2018-06-06 01:30 PM
HAL_ETH_TransmitFrame(&EthHandle, framelength); ??
STM32Cube_FW_F4_V1.21.0\Projects\STM324xG_EVAL\Applications\LwIP\LwIP_IAP\Src\ethernetif.c
Look at the F4 examples, basically an F2 with a CM4F rather than a CM3, *very* similar. I can build CM3 code that runs on both platforms and selects clock speeds dynamically (ie 120 MHz vs 168 MHz, AHB/APB), not super complicated, and the F4 gets more attention and code examples.
2018-06-06 04:10 PM
Hey Clive,
Thank You very much for your help but I guess LwIP middleware is used if you're trying to include aTCP/IP stack to work with TCP/IP protocols, I just want to keep it till data link layer. Correct me if i'm wrong i'm new to this? But what i'm trying to do is to send an ethernet packet just using the mac address assigned to mydevkit and flood all the other devices on the network using destination address ff:ff:ff:ff:ff:ff and check it on wireshark whether is detects my ethernet packet. I don't want to assign any ip address to my board i want to transfer ethernet packet just by the mac address(Mac address broadcast). Do i need to include LwIP or anykind of middleware for this?
2018-06-06 05:25 PM
I was citing code that used the raw frame interface. Strip out the stuff you don't want. Grep the source trees for other examples if you need them.
Here the HAL library itself for the F4, will be equivalent for F2
STM32Cube_FW_F4_V1.19.0\Drivers\STM32F4xx_HAL_Driver\Src\stm32f4xx_hal_eth.c
2018-06-07 08:14 AM
Alright thanks a lot Clive