- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You did not #include your generated .h files where needed. And the begin of your .h do not have the #ifndef xxx #define xxx pattern as usual in C language.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It doesn't matter. The problem is with definitions like this: #define RESET_WRX `$INSTANCE_NAME`_WRX_Write(0)
Robert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry Bob, you are right that I should add all the *.h files where they are needed but I don't want to do it. I want to design new component where all should be done automatically without adding anything manually. Just drag and drop your component, compile project and so on... Could you give me some tips how to change it? R
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Maybe the solution is to include all the *.h files that will be generated (for all component pins) to the *.c file of component API like this:
#include "`$INSTANCE_NAME`_CSX.h"
#include "`$INSTANCE_NAME`_RDX.h"
#include "`$INSTANCE_NAME`_WRX.h"
#include "`$INSTANCE_NAME`_DCX.h"
#include "`$INSTANCE_NAME`_RESX.h"
#include "`$INSTANCE_NAME`_DATA.h"
Robert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that way it is correct.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
But maybe there is a better way to design component API? R
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You probably already red the "Component Author Guide", there is no other way to create a component.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
robiw,
I believe that using a customizer written in Microsoft Studio you can fill-in any *.h, *.c, *.v files with custom code. This is a lot of work! Conditional compilation is an easier alternative.