[core] Move fixups to platform dir
This commit is contained in:
30
README.md
30
README.md
@@ -78,8 +78,9 @@ arduino/
|
|||||||
│ ├─ cores/ Core files
|
│ ├─ cores/ Core files
|
||||||
│ ├─ libraries/ Supported built-in libraries
|
│ ├─ libraries/ Supported built-in libraries
|
||||||
├─ libretuya/
|
├─ libretuya/
|
||||||
│ ├─ api/ Library interfaces (.h) for LibreTuya Arduino cores
|
│ ├─ api/ LibreTuya API for Arduino frameworks
|
||||||
│ ├─ <library name>.cpp Built-in platform-independent libraries
|
│ ├─ compat/ Fixes for compatibility with ESP32 framework
|
||||||
|
│ ├─ libraries/ Built-in platform-independent libraries
|
||||||
boards/
|
boards/
|
||||||
├─ <board name>/ Board-specific code
|
├─ <board name>/ Board-specific code
|
||||||
│ ├─ variant.cpp Arduino variant initialization
|
│ ├─ variant.cpp Arduino variant initialization
|
||||||
@@ -89,13 +90,15 @@ builder/
|
|||||||
├─ frameworks/ Framework builders for PlatformIO
|
├─ frameworks/ Framework builders for PlatformIO
|
||||||
│ ├─ <platform name>-sdk.py Vanilla SDK build system
|
│ ├─ <platform name>-sdk.py Vanilla SDK build system
|
||||||
│ ├─ <platform name>-arduino.py Arduino Core build system
|
│ ├─ <platform name>-arduino.py Arduino Core build system
|
||||||
|
├─ arduino-common.py Builder to provide ArduinoCore-API and LibreTuya APIs
|
||||||
├─ main.py Main PlatformIO builder
|
├─ main.py Main PlatformIO builder
|
||||||
fixups/
|
docs/ Project documentation, guides, tips, etc.
|
||||||
├─ <platform name>/ Code fix-ups to replace SDK parts
|
|
||||||
platform/
|
platform/
|
||||||
├─ <platform name>/ Other platform-specific files
|
├─ <platform name>/ Platform-specific configurations
|
||||||
│ ├─ bin/ Binary blobs (bootloaders, etc.)
|
│ ├─ bin/ Binary blobs (bootloaders, etc.)
|
||||||
|
│ ├─ fixups/ Code fix-ups to replace SDK parts
|
||||||
│ ├─ ld/ Linker scripts
|
│ ├─ ld/ Linker scripts
|
||||||
|
│ ├─ openocd/ OpenOCD configuration files
|
||||||
tools/
|
tools/
|
||||||
├─ <tool name>/ Tools used during the build
|
├─ <tool name>/ Tools used during the build
|
||||||
platform.json PlatformIO manifest
|
platform.json PlatformIO manifest
|
||||||
@@ -133,7 +136,7 @@ As such, there are numerous CPUs with the same numbers but different series, whi
|
|||||||
- RTL8722DM (found in ambd_arduino)
|
- RTL8722DM (found in ambd_arduino)
|
||||||
- and probably many more
|
- and probably many more
|
||||||
|
|
||||||
Different Ameba series are not compatible with each other. Apparently, there isn't a public SDK for AmebaZ that can support C++ properly (yet).
|
Different Ameba series are not compatible with each other. Apparently, there isn't an official public SDK for AmebaZ that can support C++ properly.
|
||||||
|
|
||||||
## Arduino Core support status
|
## Arduino Core support status
|
||||||
|
|
||||||
@@ -171,3 +174,18 @@ Legend:
|
|||||||
- ❓ untested
|
- ❓ untested
|
||||||
- ❌ not implemented (yet?)
|
- ❌ not implemented (yet?)
|
||||||
- \- not applicable
|
- \- not applicable
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
See [LICENSE](LICENSE). Project is licensed under MIT License.
|
||||||
|
|
||||||
|
Parts of the code may come from third parties, vendor SDKs or other open-source projects.
|
||||||
|
Most of these files are marked with appropriate copyright/author/license notices.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
|
|||||||
@@ -17,13 +17,13 @@ ldscript = board.get("build.ldscript_arduino")
|
|||||||
|
|
||||||
SDK_DIR = platform.get_package_dir("framework-realtek-amb1")
|
SDK_DIR = platform.get_package_dir("framework-realtek-amb1")
|
||||||
BOARD_DIR = join(platform.get_dir(), "boards", variant)
|
BOARD_DIR = join(platform.get_dir(), "boards", variant)
|
||||||
FIXUPS_DIR = join(platform.get_dir(), "fixups", "realtek-ambz")
|
|
||||||
PLATFORM_DIR = join(platform.get_dir(), "platform", "realtek-ambz")
|
PLATFORM_DIR = join(platform.get_dir(), "platform", "realtek-ambz")
|
||||||
|
FIXUPS_DIR = join(PLATFORM_DIR, "fixups")
|
||||||
CORE_DIR = join(platform.get_dir(), "arduino", "realtek-ambz")
|
CORE_DIR = join(platform.get_dir(), "arduino", "realtek-ambz")
|
||||||
assert isdir(SDK_DIR)
|
assert isdir(SDK_DIR)
|
||||||
assert isdir(env.subst(BOARD_DIR))
|
assert isdir(env.subst(BOARD_DIR))
|
||||||
assert isdir(env.subst(FIXUPS_DIR))
|
|
||||||
assert isdir(env.subst(PLATFORM_DIR))
|
assert isdir(env.subst(PLATFORM_DIR))
|
||||||
|
assert isdir(env.subst(FIXUPS_DIR))
|
||||||
assert isdir(env.subst(CORE_DIR))
|
assert isdir(env.subst(CORE_DIR))
|
||||||
|
|
||||||
# Flags
|
# Flags
|
||||||
|
|||||||
@@ -13,12 +13,12 @@ ldscript = board.get("build.ldscript_sdk")
|
|||||||
|
|
||||||
SDK_DIR = platform.get_package_dir("framework-realtek-amb1")
|
SDK_DIR = platform.get_package_dir("framework-realtek-amb1")
|
||||||
BOARD_DIR = join(platform.get_dir(), "boards", variant)
|
BOARD_DIR = join(platform.get_dir(), "boards", variant)
|
||||||
FIXUPS_DIR = join(platform.get_dir(), "fixups", "realtek-ambz")
|
|
||||||
PLATFORM_DIR = join(platform.get_dir(), "platform", "realtek-ambz")
|
PLATFORM_DIR = join(platform.get_dir(), "platform", "realtek-ambz")
|
||||||
|
FIXUPS_DIR = join(PLATFORM_DIR, "fixups")
|
||||||
assert isdir(SDK_DIR)
|
assert isdir(SDK_DIR)
|
||||||
assert isdir(env.subst(BOARD_DIR))
|
assert isdir(env.subst(BOARD_DIR))
|
||||||
assert isdir(env.subst(FIXUPS_DIR))
|
|
||||||
assert isdir(env.subst(PLATFORM_DIR))
|
assert isdir(env.subst(PLATFORM_DIR))
|
||||||
|
assert isdir(env.subst(FIXUPS_DIR))
|
||||||
|
|
||||||
flash_addr = board.get("build.amb_flash_addr")
|
flash_addr = board.get("build.amb_flash_addr")
|
||||||
flash_ota1_offset = env.subst("$FLASH_OTA1_OFFSET")
|
flash_ota1_offset = env.subst("$FLASH_OTA1_OFFSET")
|
||||||
@@ -110,7 +110,6 @@ env.Append(
|
|||||||
# fmt: off
|
# fmt: off
|
||||||
join(BOARD_DIR),
|
join(BOARD_DIR),
|
||||||
join(FIXUPS_DIR),
|
join(FIXUPS_DIR),
|
||||||
join(PLATFORM_DIR),
|
|
||||||
join(SDK_DIR, "project", "realtek_amebaz_va0_example", "inc"),
|
join(SDK_DIR, "project", "realtek_amebaz_va0_example", "inc"),
|
||||||
join(SDK_DIR, "component", "os", "freertos"),
|
join(SDK_DIR, "component", "os", "freertos"),
|
||||||
join(SDK_DIR, "component", "os", "freertos", "freertos_v8.1.2", "Source", "include"),
|
join(SDK_DIR, "component", "os", "freertos", "freertos_v8.1.2", "Source", "include"),
|
||||||
|
|||||||
Reference in New Issue
Block a user