How to write Micro-controller port function and port number in C code inside MATLAB function block?
Afficher commentaires plus anciens
I am trying to write C code into MATLAB function block and generate code using Embedded coder. My function blocks contain some I/O ports functions (i.e. palreadPad(PORT_G, Led_D13))and port identifier(i.e. PORT_G) for a micro controller. When I tried to generate code, MATLAB is showing error message like "Undefined function or variable 'PORT_G'". I need to generate code with these port function and port number in order to run micro controller. I don't want to define the function here because it is a built in function for micro controller. I don't want to set the variable as well (i.e PORT_G=0). How can I avoid the errors and generate code from Embedded coder?


Réponses (0)
Catégories
En savoir plus sur Deployment, Integration, and Supported Hardware dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!