7 years, 8 months ago.

Cannot find EthernetInterface.h with mbed-os

I am trying to test out the improved networking stack witht he mbed os 5 release and ran into a problem I cannot seem to get around. Trying to compile the example in the documentation I get error 5 cannot open source input file "EthernetInterface.h". It can successfully find the TCPSocket and UDPSocket headers.

I tried adding the EthernetInterface library to the program and it then finds the header, but of course a ton of other conflicts pop up.

Anyone have any ideas?

Tim

3 Answers

7 years, 8 months ago.

I ran into the same issue.

So with a lot of digging I found mbed-os/hal/targets.json this list all of the libraries that each board supports. I think this is how they do includes for the header files. I am currently in the process of getting ethernet support for nucleo_f767zi(which is still in the mail)

I added IPv4 to the features field but had to work through some hardware support. We will see if it work when my board get here, at least it compile now.

Hmm, Interesting Ill take a look at the file. From what I can tell there is no online mbed-os-dev library yet so this may be an offline work around

posted by Tim Zuercher 09 Aug 2016

Make sure to removed the added libraries. The EthernetInterface library seems to be enable with either Ethernet in the "device_has" field or IPv4 in the features field. I am not sure which one would be better. I just went with IPv4.

posted by Seth King 09 Aug 2016

It looks like the EthernetInterface in the feature tree is quite a bit different or out of date than the code in the library/ devicehas. I might try switch it and see if that is more useful.

posted by Seth King 09 Aug 2016
7 years, 8 months ago.

Having the same problem here but what's more frustrating is the lack of response from the ST team. I have not found an *easy* way to pull the mbed-os release down and then push back to the online builder.

In the meanwhile I am trying this route: https://developer.mbed.org/users/DieterGraef/code/Nucleo_F746ZG_Ethernet/ which uses the older code release

Yeah, hacking the targets.json file(in the blinky example) did not work in the end when I was trying to get UDP working. So I am going to try to building something from scratch with the cli tool.

posted by Seth King 10 Aug 2016

Yeah, still no luck here either. I ended up deciding to wait and use mbed 2.

posted by Tim Zuercher 10 Aug 2016
7 years, 8 months ago.

Hi im trying to port my software to the new release. At first on the Github base. What i found so long is that the new version relies on a correct device.h in the target folder. Only the one from TARGET_NUCLEO_F767Zi (not yet included in the online compiler version) is correct (thanks O Hagendorf). The FAT file system has only a 32bit sector counter (should be 64bit).

i will report issues as i find them.

with best regards Dieter Graef