How to solve the problem that H file cannot be opened in IAR

Publisher:喜悦的38号Latest update time:2024-08-09 Source: cnblogsKeywords:IAR Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

I am using IAR EW8051-EV-750A.


There are often errors during runtime, such as: Fatal Error[Pe005]: could not open source file "hal.h" D:CC2430 Tester-0.6PER-ReceiveLibrarycc2430HALsourcewait.c 23. After checking the information, I found that the path was not configured properly. Let me talk about the configuration below. The figure below shows what I have configured (different programs have different configurations).


For example, if the project file is in D:CC2430 Tester-0.6PER-ReceiveApp_Excc2430IAR_files, and the h file is in D:CC2430 Tester-0.6PER-ReceiveLibrarycc2430HALinclude, then $PROJ_DIR$......Librarycc2430HALinclude will do.


Knowledge points:


In the text box that defines the path of the included file, there are two very important syntaxes for defining the path of the included file. One is $TOOLKIT_DIR$, which means that the path of the included file is in the 8051 folder of the IAR installation path. That is to say, if IAR is installed in the C drive, it means the path C:Program FilesIAR SystemsEmbedded Workbench 4.05 Evaluation version8051. The other is $PROJ_DIR$, which means that the path of the included file is in the project file, that is, the same directory as the eww file and ewp file. In the project we just created, if this language is used, it means that the file now points to the folder C:Documents and SettingsAdministratorDesktopproject. There are two very important symbols used in conjunction with these two languages, which are ".." and "folder name".


..: Return to the previous folder


Folder name: means entering the folder named "folder name".


Let’s look at two specific examples.


$TOOLKIT_DIR$inc: This sentence means that the include file points to C:Program FilesIAR SystemsEmbedded Workbench 4.05 Evaluation version8051inc.


$PROJ_DIR$..Source: This sentence means that the included files point to the Source folder in the parent directory of the project directory.


Keywords:IAR Reference address:How to solve the problem that H file cannot be opened in IAR

Previous article:References - IAR include file path definition
Next article:Using PROTEUS to simulate the interface between microcontroller and LCD

Recommended ReadingLatest update time:2024-11-15 10:22

Summary of experience in using IAR
Learning the development environment is also a necessary part.   1..Summary of commonly used shortcut keys Ctrl + K: Quick Annotation Ctrl + Shif + K: Quickly remove comments Ctrl + T: Code formatting (a great shortcut key, TAB is rarely used) Ctrl + D: Enter debugging Ctrl + Shift + D: Exit debugging F1
[Microcontroller]
A wireless synchronous data acquisition method based on C8051F350
  The maneuverability of fighter jets, such as the control force and displacement of the stick/rudder, must meet technical requirements and the pilot's usage habits, so that the pilot can safely and comfortably fly the fighter jet and complete the flight mission well throughout the flight. The fighter jet control stick
[Microcontroller]
A wireless synchronous data acquisition method based on C8051F350
Design of portable physiological parameter monitor based on C8051F330
    As people's living standards improve, more and more people want to understand their basic physical conditions in a simple way. Therefore, human physiological monitors have begun to appear and are increasing in number, and have developed from single testers in the past to multi-parameter monitors today.     In re
[Medical Electronics]
Design of portable physiological parameter monitor based on C8051F330
Design of fully automatic butt welding control system through C8051F021 microcontroller and CPLD device
The fully automatic butt welding control system is developed based on the domestic electronic AC (50Hz) automatic butt welding machine. It mainly consists of three parts: an intelligent control box, a small welding head and an inverter arc welding power supply. This system changes the original discrete component elect
[Microcontroller]
Design of fully automatic butt welding control system through C8051F021 microcontroller and CPLD device
Keil IAR - Cortex M3 debugging problems and solutions (3)
Last time, we talked about that due to the continuous upgrade of the stm32 official library and iare ew arm, many configurations have changed. 1 This error occurred when upgrading stm32 stdlib 3.5 using ewarm 6.30 Error(Pe47)   declaration is incompatible with "__interwork__softfp unsigned long __get_PSP(void)", 
[Microcontroller]
Design of high-speed serial communication using 8051 microcontroller
introduction In many fields of real-time monitoring systems and communication equipment today, long-distance data transmission is often required. To this end, how to achieve high-speed, reliable and low-cost data transmission is a new technology that the 8051 microcontroller as a front-end computer or transmitter leve
[Microcontroller]
Design of high-speed serial communication using 8051 microcontroller
Analyze the three data transmission methods of 8051 microcontroller
There are usually several ways to exchange information between the microcontroller CPU and external devices: unconditional transmission, query transmission and interrupt transmission. We use the interface between a microcontroller and a microprinter as an example to describe these three methods. Assume that the user w
[Microcontroller]
Analyze the three data transmission methods of 8051 microcontroller
Modification and testing of OC8051 IP core on FPGA
Introduction In the early 1980s, Intel launched the MCS-51 microcontroller. Later, Intel released the 8051 core to many semiconductor manufacturers in the form of patent transfer, resulting in many products compatible with the MCS-51 system. These products have the same system structure as the MCS-51 and use CMOS tec
[Microcontroller]
Modification and testing of OC8051 IP core on FPGA
Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号