Skip to content
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

ModusToolbox 2.4.0 fail to resolve #include files in PSOC6 dual CPU examples #2

Open
gmgallo opened this issue Jan 7, 2022 · 11 comments
Assignees

Comments

@gmgallo
Copy link

gmgallo commented Jan 7, 2022

Prerequisites
Install a clean copy of ModusToolbox 2.4.0

Can you reproduce the problem reliably?
Yes
Did you check current release notes for known issues?
Yes
If this is not the latest release, have you checked newer releases?

Description:
I was using ModusToolbox 2.3 on Windows 10 working on a couple of projects for PSOC6 and decided to update
my projects to the latest revision of the libraries, but had may compile warnings recommending to downgrade the libs or upgrade the tools. So, today I uninstalled the old verion of ModusToolbox 2.3 and installed 2.4.0.
Set environment variables as indicated in the installation notes for Windows 10 and open my existing workspace. Trying to recompile my projects ModusToolbox went crazy throwing all sort of internal errors on the right pane.

I decided to start from scratch and create a new workspace, next created a couple of projects containing the code I need to get started again: USB_CDC_Echo and Dual CPU_IPC_Piles for CY8CPROTO-062-4343W.
Both of them compile, program, and run normally, but, in the dual CPU projects, the code editor fails to resolve the include files for main.c of both cm0p and cm4 projects and plagges the code with tags of unresolved references.
Also noted that this version is notoriously slow to react for almost any operation started from the Eclipse GUI.

A clear and concise description of what the bug is.
Unable to resolve include files in dual CPU sample projects.

Steps to Reproduce:

  1. create a new Application and select one of the dual CPU samples.

Expected Result:
clean example without errors

Actual Result:
as described

Frequency (1/1, 1/50, 1/100):
1/1

Build/Commit:
2.4.0
Please specify the release, like 1.4.1. If there is no release, give us the commit for the code you used.

Target:
CY8CPROTO-062-4343W

The chip or kit you are working with

Host OS and Version:
Windows 10
MacOS, Windows, Linux

Compiler:
default GCC
Include the version!
10
Environment
No changes made to the default installation or downloaded sample projects.

Provide the context surrounding this problem. Perhaps an IDE, a debug probe, an RTOS, etc. (and versions)

THANKS!
@rmbk19 rmbk19 self-assigned this Jan 7, 2022
@rmbk19
Copy link

rmbk19 commented Jan 7, 2022

Hi @gmgallo,

You should be able to install multiple versions of ModusToolbox and they should be compatible. Could you please share a screenshot of the internal errors that you mentioned?

I imported the Dual CPU IPC Pipes code example and built it. I was not able to observe any errors. From your description, I think that the errors that you are observing are Eclipse IDE IntelliSense errors. Could you please share the build log and a snapshot of the Problems tab in the IDE? We have come across issues where the IntelliSense fails to resolve inclusions and variables especially when the code is shared between multiple projects in the workspace. We already have an internal ticket to address this issue and our development team is working on this.

Regards,
Rakshith

@gmgallo
Copy link
Author

gmgallo commented Jan 7, 2022 via email

@gmgallo
Copy link
Author

gmgallo commented Jan 8, 2022

Here is a snapshot of the Problems tab on the dual cpu project.
image

Opening the 2.3 workspace with 2.4 I observe a large number of errors listed in the workspace error log (right pane) which I included here in a ZIP file.

cylogger.log
Workspace_log.zip

@gmgallo
Copy link
Author

gmgallo commented Jan 9, 2022

The good news is that ModusToolbox 2.4 started to be well behaved and I was able to fix and compile my existing projects migrated from 2.3, but not without running into a few nuances. For example, the existing retarget_io in my project v1.2 was incompatible with the PDL 2.0.1, so, I installed retarget_io v1.3 (shared). At compile time it throuws an error saying that can't find "cyhal_hw_types.h" I verified that the file was there in the mtb_shared PDL folders. Switching back to 1.2 (fixing the incompatibility), I notice that the project finding v1.2 and 1.3 in mtb_shard always used the later, regardles of what you configure in Library Manager, so, you have to manually delete the version(s) in mtb_shared that you don't want in your project. Eventually I switched to non-shared retarget_io 1.3 and it worked just fine. There was a few other things along the way, but this retarget_io issue consumed most of my time.

@rmbk19
Copy link

rmbk19 commented Jan 10, 2022

Hi @gmgallo,

is there a place where I can download previous versions?

You can download ModusToolbox 2.3 from this link.

Please note that installation document indicates that you should uninstall the previous versions of ModusToolbox.

I believe the installation document asks to uninstall all beta versions of ModusToolbox 2.4 and not previous versions of ModusToolbox. However, if you do find that it is mentioned, please share a snapshot of the document and I will create an internal ticket to fix the documentation.

I notice that the project finding v1.2 and 1.3 in mtb_shard always used the later, regardles of what you configure in Library Manager, so, you have to manually delete the version(s) in mtb_shared that you don't want in your project

This should not be the case. The Library Manager should pick the version selected when you have fixed the library version and not default to the latest version. Let me run some tests to recreate the issue. I will notify the development team in case I am able to recreate the issue. I understand that the issue is fixed now but could you please share a screenshot of the retarget io library in Library Manager?

Regards,
Rakshith

@gmgallo
Copy link
Author

gmgallo commented Jan 11, 2022

could you please share a screenshot of the retarget io library in Library Manager?
image
Here is how I made retarget_io 1.3 work for cm4

You are right. The note about uninstalled previous versions refer to Beta versions.

@rmbk19
Copy link

rmbk19 commented Jan 18, 2022

Hi @gmgallo,

I tried running Library Manager with multiple applications to recreate the issue but I was unable to observe the issue. The library version fixed in the Library Manager was always picked even when higher versions were present in the mtb_shared directory.
As you now have your application working, you should not be facing any issues. In case you do, please let us know by creating a git issue or by creating a thread in our community - Infineon Developer Community

Regards,
Rakshith

@gmgallo
Copy link
Author

gmgallo commented Jan 19, 2022

Hi Rakishith,

I believe that this change has to be done for the two CPU projects: CM0p and CM4, and I only did it for CM4.
Still there is an open question:

_"At compile time (retartget_io 1.3 shared) throuws an error saying that it can't find "cyhal_hw_types.h" I verified that the file was there in the mtb_shared PDL folders."

If not shared it goes into the CM4 Lib folder and works fine in my case. Have you experienced that?

Thank you!

@rmbk19
Copy link

rmbk19 commented Feb 1, 2022

Hi @gmgallo,

Apologies for the delay in my response.
As this is a new query could you please create a new issue so that we can ensure that it is tracked? Also, please let us know if you are facing the issue in CM0+ or CM4 application. Please note that HAL is not supported in CM0+.

Regards,
Rakshith

@gmgallo
Copy link
Author

gmgallo commented Feb 1, 2022

Hi Rakishith,
That is not really a new issue, since at the root of the problem is always about unresolved include files from the shared workspace folder. I'm pressed to move forward with this project and moving the retarget-io to to the CM4 Lib folder (by unchecking shared) solved my problem, I need to move on and can't distract time right now trying to troubleshoot that issue.
I'll open a new ticket when I ran into it again with the next project.

PS: I'm not trying to use HAL in CM0+, I know that is not available there, but I would like to find the ways to use USB CDC using PDL library dependencies only. Is that possible?

Thanks for your support!

@EktaNashine07
Copy link

Hello @gmgallo

The USB CDC uses USB Middleware to implement CDC Class-specific functions. The USB Middleware in turn uses the USBFS driver from PDL to interface with the hardware. Thus it is possible to implement USB CDC from on the CM0+ without using HAL.

The PSoC 6 USB CDC example uses only USB Middleware and USBFS PDL specific functions. It does not use any function from the HAL.

Kindly let us know if you require any further clarification on this.

Best Regards
Ekta

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants