1 Reply Latest reply on Nov 28, 2019 4:23 AM by MoTa_728816

    Project.h header file

    miki_4426356

      Hello

      I don't know if this is the correct place to ask, but I will do so anyway.

      I looked at the project.h header file today and saw that there were no #pragma once or #ifndef in the file. I have programmed a bit in C/C++ and thought this was a standard and a must-have.

      Am I wrong about this? In the case I am - can anyone tell me why?

       

      Many thanks

        • 1. Re: Project.h header file
          MoTa_728816

          Hi,

           

          That is a very good question!

          I have never thought of that, actually I'm lazy enough so I've never explored the Project.h.

           

          So I opened one of my project's "Project.h", I skipped the comments.

           

          Then there were only "#include" statements.

          And each ".h" file included by this statement had #ifndef ~ #endif,

          so  even if "Project.h" will be included more than twice,

          it will not cause problem.

           

          But anyway, thanks for your question, I learned ;-)

           

          Project.h

          ======================

          #include "cyfitter_cfg.h"

          #include "cydevice_trm.h"

          #include "cyfitter.h"

          #include "cydisabledsheets.h"

          #include "UART.h"

          #include "UART_SPI_UART.h"

          #include "UART_PINS.h"

          #include "UART_SPI_UART_PVT.h"

          #include "UART_PVT.h"

          #include "UART_BOOT.h"

          #include "UART2.h"

          #include "UART2_SPI_UART.h"

          #include "UART2_PINS.h"

          #include "UART2_SPI_UART_PVT.h"

          #include "UART2_PVT.h"

          #include "UART2_BOOT.h"

          #include "uart_rx_int.h"

          #include "uart2_rx_int.h"

          #include "UART_SCBCLK.h"

          #include "UART_tx.h"

          #include "UART_tx_aliases.h"

          #include "UART_rx.h"

          #include "UART_rx_aliases.h"

          #include "UART2_SCBCLK.h"

          #include "UART2_tx.h"

          #include "UART2_tx_aliases.h"

          #include "UART2_rx.h"

          #include "UART2_rx_aliases.h"

          #include "cy_em_eeprom.h"

          #include "core_cm0_psoc4.h"

          #include "CyFlash.h"

          #include "CyLib.h"

          #include "cyPm.h"

          #include "cytypes.h"

          #include "cypins.h"

          #include "CyDMA.h"

          #include "CyLFClk.h"

          ======================

           

          moto