Skip to content

Commit

Permalink
Add module.lb file and fix include path.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Wolfram committed Sep 22, 2020
1 parent 21e011b commit 4c71bae
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modm/platform/eth/stm32/freertos_networkinterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/

#include <eth.hpp>
#include <lan8720a.hpp>
#include <modm/platform/eth/eth.hpp>
#include <modm/platform/eth/lan8720a.hpp>

#include <freertos/FreeRTOS.h>
#include <freertos/task.h>
Expand Down
41 changes: 41 additions & 0 deletions src/modm/platform/eth/stm32/module.lb
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# Copyright (c) 2016-2018, Niklas Hauser
# Copyright (c) 2017, Fabian Greif
# Copyright (c) 2020, Mike Wolfram
#
# This file is part of the modm project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
# -----------------------------------------------------------------------------

def init(module):
module.name = ":platform:eth"
module.description = "Ethernet of STM32F4/F7"

def prepare(module, options):
device = options[":target"]

# FIXME the driver is for L4 only
if device.identifier["family"] not in ["f7"]:
return False

return True

def build(env):
device = env[":target"]

properties = device.properties
properties["target"] = device.identifier

env.substitutions = properties
env.outbasepath = "modm/src/modm/platform/eth"

env.copy("eth.hpp")
env.copy("eth_impl.hpp")
env.copy("lan820a.hpp")
env.copy("freertos_networkinterface.cpp")

0 comments on commit 4c71bae

Please sign in to comment.