-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(Other): Add zephyr related wrapper and system file in MSDK #990
Conversation
7a8904f
to
e98ae4c
Compare
@@ -0,0 +1,171 @@ | |||
# Makefile - Analog Devices SDK |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the copyright/license text in these CMakeLists.txt files match the copyrights used in the other files? Or do these files need the particular format you used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sihyung-maxim, what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe this copyright/license text still works because the license identifier references Apache 2.0, and our LICENSE
file at the root of the MSDK repo applies to every file and subdirectory within the root.
.txt
files don't need to follow the same format as the source files as it depends on the context of how they're used - they can be used for documentation, data storing, configuration setting, and even as scripts/code. I think it's more of a matter of whether we want to keep consistency with our files, but I recommend using our default copyrights in this case since it's used in a scripting/make context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was default copyright lines that we and other vendor added in zephyr files.
But it make sense it be consistent on the hal layer.
Updated please see: 632d579
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree, be consistent with the rest of the MSDK
4f85fea
to
cd88f6a
Compare
hal_adi content moved insdie MSDK as it is Signed-off-by: Sadik Ozer <[email protected]>
Signed-off-by: Sadik Ozer <[email protected]>
Copyright section uptaed to it be consistent Add missing (C) Signed-off-by: Sadik Ozer <[email protected]>
cd88f6a
to
db92826
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ozersa @MaureenHelm FYI we have #include <mxc_device.h>
for each micro that we can use here to make maintenance of this file a bit easier. It does the same job
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ozersa does this add the source files to the top-level build? Since Zephyr uses CMake it would also be nice to start setting things up more modularly for each library to support find_package
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks noted.
endif() | ||
string(TOUPPER ${TARGET_LC} TARGET_UC) | ||
|
||
zephyr_compile_definitions( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ozersa also suggest adding -D${TARGET_UC}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, will consider on next update.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Jake-Carter I took a look it now, to apply it on #996
But a little confused.
Do you propose replacing
-DTARGET=${TARGET_UC} with -DTARGET=-D${TARGET_UC} ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ozersa just to have both TARGET
and the actual value of TARGET_UC
defined.
zephyr_compile_definitions(
-D${TARGET_UC}
-DTARGET=${TARGET_UC}
...
)
Some places in the drivers need to check the target value. Since the pre-processor can't do string comparisons sometimes TARGET_UC
itself is checked.
#ifdef MAX78000
// ...
#endif
Description
hal_adi is repository that used by zephyr sdk.
By this PR the content of this repository moved in MSDK repository to centralize it.
Wrapper layer added to get one common zephyr shim driver on zephyr layer.
It will be nice if wrap layer function been added peripheral driver in future.
hal_adi folder layout listed below. After this PR being merged MAX folder content totally will comes from MSDK.
Checklist Before Requesting Review