Teach you how to port UCOS-II applications to VC

Teach you how to port UCOS-II applications to run on VC2017


foreword

         An operating system (English: Operating System, abbreviation: OS) is a group of interrelated system software programs that manage and control computer operations, use and run hardware and software resources, and provide public services to organize user interactions. According to the operating environment, the operating system can be divided into desktop operating system, mobile operating system, server operating system, embedded operating system and so on. This article introduces in detail the specific operation of porting UCOS-II applications to VC2017. I hope it will be helpful to everyone. The files needed for porting are shared free of charge in the network disk link.


Tip: The following is the main text of this article. It is not easy to write an article. I hope it can help you. Please attach a link when reprinting.

1. Preparation

        Prepare V2.91 source code Source, user code (code related to the application program) App, code related to the transplantation platform (code related to the processor of UCOS-II) Ports. Refer to the sharing link below for these three files, among which Ports is the modified VC compilation environment suitable for 64-bit win7/win10 systems.

Link: https://pan.baidu.com/s/1Qz0qWqekozA-lhNU0NgxFg 
Extraction code: 2023 

Second, the detailed steps of transplantation

        Open VC2017 to create a new project.

         Open the created project and add the prepared Ports, App, and Source folders to it.

         Delete header files, source files, and resource files in the project.

         Create three folders, Ports, App, and Source.

         Add the files in the Ports, App, and Source folders in the project directory to the Ports, App, and Source files in the project.

         Click the debug button, and an error is reported at this time.

         Right-click the project UCOSII and add the header file path.

         At this time, an error is still reported, and continue to rename os_cfg_r.h to os_cfg.h.

         After modifying, click Debug again or report an error.

         Continue to change and define your own priorities.

         After the modification and debugging, an error is still reported, and the included problem is repeated.

         Continue to modify and delete the redundant include.

         After deleting, click Debug, or an error is reported, the problem of the linker.

         Continue to change, add winmm.lib.

         Click Debug again to run the program successfully, so far, the transplantation is over.


Summarize

        The above is what I want to talk about today. This article introduces in detail how to port the application on UCOSII to run on VC2017. I hope it will be helpful to everyone.

Guess you like

Origin blog.csdn.net/m0_66360845/article/details/129410644