A Software Interface Development Method and Device Based on Loongson 2K1000
By configuring the development environment workbench and compiling WindML5.3 components, VIP mirroring projects are established based on Loongson 2K1000 and WindML, the problem of relying on QT tools for software interface development in the existing technology is solved, and the effect of cost saving and software universality is improved.
Patent Information
- Application Number
- CN202111042935.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-07
- Publication Date
- 2025-06-17
- Estimated Expiration
- 2041-09-07
AI Technical Summary
The existing software interface development technology based on Loongson relies on the QT professional interface development tool of Loongson version, and has problems such as high cost, poor versatility and poor portability.
By configuring the development environment workbench using the underlying hardware driver provided by Loongson motherboard manufacturers, WindML5.3 components based on Loongson 2K1000 are configured and compiled, VIP mirroring projects are established based on Loongson 2K1000 and WindML, and interface software development is carried out according to actual interface design requirements.
The software interface development based on Loongson 2K1000 is realized, and the QT professional interface development tool does not rely on the Loongson version, saving development costs and improving the versatility and portability of the software.
Smart Images

Figure CN113900626B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of software interface design, and in particular relates to a method and device for developing a software interface based on Loongson 2K1000. Background Art
[0002] At present, the main control chips of control equipment are mostly imported chips from companies such as Intel, AMD, and TI, and the operating systems are mostly Windows, Linux, etc. With the increasing requirements for localization in the control field and the increasing application of the VxWorks operating system in recent years, control equipment that uses domestic chips as main control chips and runs the VxWorks operating system has gradually occupied the domestic embedded real-time application market.
[0003] The Loongson 2K1000 processor is a dual-core processor produced by Loongson Zhongke Company. It is an upgraded chip of Loongson 2H. It integrates 2 GS264e processing cores, with a main frequency of 1GHz (800-900MHz for industrial grade), 64-bit DDR3 controller, 2 GMAC controllers, 2 × 4PCIE controllers and many IO interfaces. It is mainly oriented to network communication applications, and also takes into account the application in the field of terminal industrial control. The VxWorks operating system is a real-time embedded operating system (RTOS) designed and developed by WindRiver Company in the United States in 1983. Its scalability, high real-time performance and high reliability have unparalleled advantages over other embedded systems in processing multiple tasks. It is widely used in satellite communications, flight guidance, aviation navigation and other fields that require strict system real-time performance. WindML, namely Wind Media Library, is a component used for multimedia operation in the VxWorks system, including graphics display, audio, video and other processing, and provides its software development framework.
[0004] At present, the software interface development technology based on Loongson as the main control chip mostly relies on the Loongson version of QT professional interface development tools, which has disadvantages such as high cost, poor versatility and portability. Summary of the invention
[0005] In order to solve the above problems existing in the prior art, the present invention provides a method and device for developing a software interface based on Loongson 2K1000.
[0006] In order to achieve the above object, the present invention adopts the following technical solutions.
[0007] In a first aspect, the present invention provides a software interface development method based on Loongson 2K1000, comprising the following steps:
[0008] Configure the development environment workbench using the low-level hardware driver provided by the Loongson motherboard manufacturer;
[0009] Configure and compile the WindML 5.3 components based on Loongson 2K1000;
[0010] Build a VIP image project based on Loongson 2K1000 and WindML;
[0011] Develop interface software according to the actual interface design requirements.
[0012] Furthermore, the method for configuring the development environment workbench includes:
[0013] Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with 3 driver programs provided by the manufacturer. The 3 driver programs are respectively: the board support package BSP of the Loongson motherboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML 5.3 component of the Loongson version.
[0014] Even further, the method for configuring and compiling the WindML 5.3 component includes:
[0015] In the workbench environment, build a DKM kernel module project, and select MIPSI64gnule_SMP as the compiler;
[0016] Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, picture display, and graphics card;
[0017] After the config.windml file configuration is completed, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the compilation of the WindML component.
[0018] Even further, the method for building a VIP image project based on Loongson 2K1000 and WindML includes:
[0019] In the workbench environment, select ls2k1000 for BSP, select gnule and SMP multi-core for the compiler, and build a VIP image project;
[0020] After the project construction is completed, double-click on the graphical configuration file Kernel Configuration for configuration:
[0021] First, add the WindML 5.3 component: Right-click on "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search. After finding the corresponding option, add this component. Then right-click on properties in the project, and add the link path of windml in the build micros option, that is, add the string "–lwindml-5.3–lwindml-5.3_dyn" after LIBS;
[0022] Then, configure the number of serial ports according to the actual situation of the main board hardware: Enter "PC_CONSOLE" in the "find" dialog box to search, and modify the number of SIOs according to the requirements of the board;
[0023] Finally, add the TFTP option for implementing the software update of the board: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
[0024] Furthermore, the main process of interface software development includes:
[0025] Open the display window configured by windml and initialize it;
[0026] Obtain the registration information of the display driver device, including the display device, input device, font, and sound;
[0027] Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values;
[0028] Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required state on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; after jumping out of the loop, release all resources and exit the program.
[0029] In the second aspect, the present invention provides a software interface development device based on Loongson 2K1000, including:
[0030] A development environment configuration module for configuring the development environment workbench using the underlying hardware driver provided by the Loongson main board manufacturer;
[0031] A component configuration and compilation module for configuring and compiling the WindML 5.3 component based on Loongson 2K1000;
[0032] A mirror project establishment module for establishing a VIP mirror project based on Loongson 2K1000 and WindML;
[0033] The interface software development module is used for developing interface software according to actual interface design requirements.
[0034] Furthermore, the method for configuring the development environment workbench includes:
[0035] Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with 3 driver programs provided by the manufacturer. The 3 driver programs are respectively: the board support package BSP of the Loongson mainboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML5.3 component of the Loongson version.
[0036] Even further, the configuration and compilation method of the WindML5.3 component includes:
[0037] In the workbench environment, build a DKM kernel module project, and select MIPSI64gnule_SMP as the compiler;
[0038] Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, picture display, and graphics card;
[0039] After the config.windml file is configured, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the compilation of the WindML component.
[0040] Even further, the method for establishing a VIP image project based on Loongson 2K1000 and WindML includes:
[0041] In the workbench environment, select ls2k1000 for BSP, select gnule and SMP multi-core for the compiler, and build a VIP image project;
[0042] After the project is built, double-click on the graphical configuration file Kernel Configuration for configuration:
[0043] First, add the WindML5.3 component: Right-click on "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search. After finding the corresponding option, add this component, and right-click on properties in the project, and add the link path of windml in the build micros option, that is, add the string "--lwindml-5.3--lwindml-5.3_dyn" after LIBS;
[0044] Then, configure the number of serial ports according to the actual situation of the main board hardware: Search by entering "PC_CONSOLE" in the "find" dialog box and modify the number of SIOs therein according to the requirements of the board.
[0045] Finally, add the TFTP option for implementing the software update of the board: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
[0046] Furthermore, the main process of interface software development includes:
[0047] Open the display window configured by windml and initialize it;
[0048] Obtain the registration information of the display driver device, including the display device, input device, font, and sound;
[0049] Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values;
[0050] Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required state on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; After jumping out of the loop, release all resources and exit the program.
[0051] Compared with the prior art, the present invention has the following beneficial effects.
[0052] The present invention configures and compiles the WindML5.3 component based on Loongson 2K1000 by using the underlying hardware driver program provided by the Loongson main board manufacturer to configure the development environment workbench, establishes a VIP mirror project based on Loongson 2K1000 and WindML, and develops interface software according to the actual interface design requirements, realizing the software interface development based on Loongson 2K1000. The interface development method described in the present invention does not rely on the QT professional interface development tool of the Loongson version. When the software graphic interface developed is relatively simple, adopting the method described in the present invention can not only save the cost of purchasing the Loongson version QT software, but also improve the versatility and portability of the software. Description of the Drawings
[0053] Figure 1 It is a flowchart of a software interface development method based on Loongson 2K1000 according to an embodiment of the present invention.
[0054] Figure 2 It is a schematic diagram of a software interface developed based on WindML.
[0055] Figure 3It is a block diagram of a software interface development device based on Loongson 2K1000 according to an embodiment of the present invention. Detailed implementation manners
[0056] To make the objectives, technical solutions and advantages of the present invention clearer and more understandable, the present invention will be further described below in conjunction with the accompanying drawings and specific implementation manners. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without making creative efforts shall fall within the protection scope of the present invention.
[0057] Figure 1 It is a flowchart of a software interface development method based on Loongson 2K1000 according to an embodiment of the present invention, including the following steps:
[0058] Step 101, configure the development environment workbench by using the underlying hardware driver program provided by the Loongson motherboard manufacturer;
[0059] Step 102, configure and compile the WindML5.3 component based on Loongson 2K1000;
[0060] Step 103, establish a VIP (VxWorks Image Project) image project based on Loongson 2K1000 and WindML;
[0061] Step 104, perform interface software development according to actual interface design requirements.
[0062] This embodiment provides a software interface development method based on Loongson 2K1000. The hardware platform uses Loongson 2K1000 as the main control chip, and the software uses VxWorks as the operating system. The Loongson 2K1000 processor is a dual-core processor produced by Loongson Zhongke Co., Ltd., which is an upgraded chip of Loongson 2H. It integrates 2 GS264e processing cores, a main frequency of 1 GHz, a 64-bit DDR3 controller, 2 GMAC controllers, 2 ×4 PCIE controllers and numerous IO interfaces. It is mainly oriented to network communication applications and also takes into account applications in the industrial control field of terminal machines. The VxWorks operating system is a real-time embedded operating system (RTOS) designed and developed by WindRiver Corporation of the United States in 1983. Its scalability, high real-time performance and high reliability have unparalleled advantages in handling multi-tasks compared with other embedded systems, and it is widely used in fields with strict requirements for system real-time performance such as satellite communication, flight guidance, and aviation navigation.
[0063] In this embodiment, step 101 is mainly used to configure the development environment workbench. The application layer software development environment of the VxWorks6.8 operating system is the workbench software of Wind River. Since the main control chip Loongson 2K1000 in this embodiment is of the MIPS architecture, the selected development environment is the workbench 3.2 version that supports the MIPS architecture. The configuration of the development environment workbench mainly replaces the original relevant drivers in the corresponding installation directory of the workbench development environment with the underlying hardware drivers provided by the Loongson motherboard manufacturer that support the Loongson board, so as to ensure that the finally created software project is applicable to the Loongson motherboard.
[0064] In this embodiment, step 102 is mainly used to configure and compile the WindML5.3 component. WindML is part of the VxWorks library. It supports multimedia programs running on embedded operating systems and is used to provide basic graphics, video, audio technologies, etc. However, the WindML5.3 component provided in workbench is source code, and it needs to be configured and compiled in advance before linking its API function library for use. Among them, the configuration of the WindML5.3 component will directly determine the state of the graphical interface, including the handle name, font, picture display, graphics card, etc. of the interface.
[0065] In this embodiment, step 103 is mainly used to create a VIP image project. After the WindML component is configured and compiled, the development of the graphical interface software can be started. The interface software project newly created in workbench is a VIP image project. After such a project is compiled, it forms a VxWorks kernel, and after being burned to the Loongson motherboard, the VxWorks operating system and the graphical interface software can be directly run. Since this software is a graphical interface software, it is necessary to configure the WindML5.3 component compilation library, serial port, network port, etc. after creating the VIP project and before writing the program.
[0066] In this embodiment, step 104 is mainly used to develop the interface software. After the VIP image project is configured, the development of the graphical interface software can be carried out according to the specific interface design requirements. Specifically, the main framework of the WindML program that realizes the interface software development consists of three function bodies: an entry function, a main function, and a loop body function. The following is an introduction to these three functions respectively:
[0067] The entry function is used to create and activate the main task. The following is the code of an actual entry function:
[0068]
[0069] You can run this program by entering taskRoot(0, 0) under the shell. The parameter display is the ID name of the display set in the windml component, and mode is the input mode, where 0 indicates no input. Only one function, uglOSTaskCreate(), is called in the function body. This is the VxWorks function taskSpawn() encapsulated in ugl, and its role is to create and activate a task. Here, the main task tWindMLDemo of the program is created.
[0070] The main function runs after the main task is activated. It is the lifeline of the entire program, and its end means the end of the entire program. The main function mainly completes initialization, obtains the registration information of the display driver device, obtains the window size, initializes colors, etc. An example of the main program running process will be given later.
[0071] The loop body function acts as the heart and maintains the operation of the entire program by continuously obtaining messages from the message queue. The following gives the code of a window main loop function:
[0072]
[0073]
[0074] The function pauseDemo(void) is an infinite loop called by the windMLDemo() function. The loop body implements the display and refresh of the interface content and can be called the loop body function. First, it delays for 100 ms in the loop body, and then calls the Refresh(pDisplayControl) function to achieve the timed refresh of the status of some variables in the interface requirements. When the variable ugl_cleanup obtained from the Refresh function is 1, the loop can be exited and return to the main program windMLDemo, finally realizing the function of releasing interface resources and exiting the program.
[0075] According to the configuration and program operation in the above steps, the attached Figure 2 shown software graphical interface can be generated.
[0076] The interface development method described in this embodiment does not depend on the Loongson version of the QT professional interface development tool. When the developed software graphical interface is relatively simple, using the method described in the present invention can not only save the cost of purchasing the Loongson version of QT software, but also improve the versatility and portability of the software.
[0077] As an alternative embodiment, the method for configuring the development environment workbench includes:
[0078] Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with the three driver programs provided by the manufacturer. The three driver programs are respectively: the board support package BSP of the Loongson mainboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML 5.3 component of the Loongson version.
[0079] This embodiment provides a technical solution for configuring the development environment workbench. The Loongson mainboard manufacturer provides three underlying hardware drivers for supporting the Loongson board: the first is the board support package BSP of the Loongson mainboard, which is the startup code and device driver program written for the Loongson mainboard and provides intermediate layer interface functions; the second is the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture; the third is the WindML 5.3 component of the Loongson version. When configuring the development environment, only need to replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with the above three driver programs provided by the manufacturer to ensure that the finally created software project is applicable to the Loongson mainboard.
[0080] As an optional embodiment, the configuration and compilation method of the WindML 5.3 component includes:
[0081] In the workbench environment, build a DKM (VxWorks Downloadbale Kernel Module Project) kernel module project, and select MIPSI64gnule_SMP as the compiler;
[0082] Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, picture display, and graphics card;
[0083] After the config.windml file is configured, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the compilation of the WindML component.
[0084] This embodiment provides a technical solution for configuring and compiling the WindML5.3 component. As described above, since the WindML5.3 component provided in the workbench is source code, it needs to be configured and compiled in advance before linking its API function library for use. First, in the workbench environment, select the MIPSI64gnule_SMP compiler to build the DKM kernel module project. After the DKM project is built, configure the graphical configuration file config.windml in the DKM project: In the "System" settings, select the MIPSI64gnule_SMP compiler; select "System" → right-click to create a new "Sibling", select "Display" (handle), and the name can be set to 0 (any name); select "Display", right-click to create a new "Graphics", note that select "Loonson" for the Device here, which means Loongson 2K1000, and set the resolution according to the actual graphics card; create a new font, select the "FreeType" type Chinese characters in the graphical interface, create a new "FreeType Font", and add the font storage path; create a new "Window Manager" and check all options in the "Option". After the config.windml file is configured, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the WindML component compilation.
[0085] As an optional embodiment, the method for establishing a VIP image project based on Loongson 2K1000 and WindML includes:
[0086] In the workbench environment, select ls2k1000 for BSP and gnule and SMP multi-core for the compiler to build the VIP image project;
[0087] After the project is built, double-click the graphical configuration file Kernel Configuration to configure:
[0088] First, add the WindML5.3 component: Right-click on "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search, after finding the corresponding option, add this component, and right-click on properties in the project, add the link path of windml in the build micros option, that is, add the string "–lwindml-5.3–lwindml-5.3_dyn" after LIBS;
[0089] Then, configure the number of serial ports according to the actual situation of the motherboard hardware: Enter "PC_CONSOLE" in the "find" dialog box to search, and modify the number of SIOs according to the requirements of the board.
[0090] Finally, add the TFTP option for implementing the software update of the board: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
[0091] As an optional embodiment, the main process of interface software development includes:
[0092] Open the display window configured by windml and initialize it;
[0093] Obtain the registration information of the display driver device, including the display device, input device, font, and sound;
[0094] Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values;
[0095] Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required state on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; after jumping out of the loop, release all resources and exit the program.
[0096] This embodiment provides a technical solution for the main process of interface software development. The main process is implemented by a main function. The following gives a main function UGL_STATUS windMLDemo(char*pDisplay, int mode) for implementing the above main process. Since the program code is relatively large, only the main framework of the function is listed here:
[0097]
[0098]
[0099] Figure 3 This is a schematic diagram of the composition of a software interface development device based on Loongson 2K1000 according to an embodiment of the present invention. The device includes:
[0100] A development environment configuration module 11 for configuring the development environment workbench by using the underlying hardware driver program provided by the Loongson motherboard manufacturer;
[0101] A component configuration and compilation module 12 for configuring and compiling the WindML5.3 components based on Loongson 2K1000;
[0102] The mirror project establishment module 13 is used to establish a VIP mirror project based on Loongson 2K1000 and WindML;
[0103] The interface software development module 14 is used to develop interface software according to actual interface design requirements.
[0104] The device of this embodiment can be used to execute Figure 1 the technical solutions of the method embodiments shown, and their implementation principles and technical effects are similar, so they will not be elaborated here. The same applies to the following embodiments and will not be further explained.
[0105] As an optional embodiment, the method for configuring the development environment workbench includes:
[0106] Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with 3 driver programs provided by the manufacturer. The 3 driver programs are respectively: the board support package BSP of the Loongson mainboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML5.3 component of the Loongson version.
[0107] As an optional embodiment, the configuration and compilation method of the WindML5.3 component includes:
[0108] In the workbench environment, build a DKM kernel module project, and select MIPSI64gnule_SMP as the compiler;
[0109] Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, picture display, and graphics card;
[0110] After the config.windml file is configured, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the compilation of the WindML component.
[0111] As an optional embodiment, the method for establishing a VIP mirror project based on Loongson 2K1000 and WindML includes:
[0112] In the workbench environment, select ls2k1000 for BSP, select gnule and SMP multi-core for the compiler, and build a VIP mirror project;
[0113] After the project is built, double-click on the graphical configuration file Kernel Configuration for configuration:
[0114] First, add the WindML 5.3 component: Right-click on "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search. After finding the corresponding option, add this component. Then right-click on properties in the project, and add the link path of windml in the build micros option, that is, add the string "–lwindml-5.3–lwindml-5.3_dyn" after LIBS;
[0115] Then, configure the number of serial ports according to the actual situation of the main board hardware: Enter "PC_CONSOLE" in the "find" dialog box and search, and modify the number of SIOs according to the requirements of the board;
[0116] Finally, add the TFTP option for implementing the software update of the board: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
[0117] As an optional embodiment, the main process of interface software development includes:
[0118] Open the display window configured by windml and initialize it;
[0119] Obtain the registration information of the display driver device, including the display device, input device, font, and sound;
[0120] Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values;
[0121] Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required state on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; after jumping out of the loop, release all resources and exit the program.
[0122] The above are only the specific implementation manners of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by those skilled in the art within the technical scope disclosed by the present invention should be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims
1. A software interface development method based on Loongson 2K1000, characterized in that It includes the following steps: Configure the development environment workbench using the underlying hardware driver provided by the Loongson motherboard manufacturer; Configure and compile the WindML5.3 component based on Loongson 2K1000; Build a VIP image project based on Loongson 2K1000 and WindML; Develop interface software according to the actual interface design requirements; The method for configuring the development environment workbench includes: Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with 3 driver programs provided by the manufacturer. The 3 driver programs are: the board support package BSP of the Loongson motherboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML5.3 component of the Loongson version; The configuration and compilation of the WindML5.3 component based on Loongson 2K1000 includes: In the workbench environment, build a DKM kernel module project, and select MIPSI64gnule_SMP as the compiler; Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, picture display, and graphics card; After the config.windml file is configured, click on the DKM project, right-click and select "Rebuild Project", and wait to complete the compilation of the WindML component; The method for building a VIP image project based on Loongson 2K1000 and WindML includes: In the workbench environment, select ls2k1000 for BSP, select gnule and SMP multi-core for the compiler, and build a VIP image project; After the project is built, double-click the graphical configuration file Kernel Configuration for configuration: First, add the WindML5.3 component: Right-click "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search. After finding the corresponding option, add this component, and right-click properties in the project, and add the link path of windml in the build micros option, that is, add the string "--lwindml-5.3--lwindml-5.3_dyn" after LIBS; Then, configure the number of serial ports according to the actual situation of the motherboard hardware: Enter "PC_CONSOLE" in the "find" dialog box to search, and modify the number of SIOs according to the board requirements; Finally, add the TFTP option for implementing board software update: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
2. The software interface development method based on Loongson 2K1000 according to claim 1, characterized in that The main process of interface software development includes: Open the display window configured by windml and initialize it; Obtain the registration information of the display driver device, including the display device, input device, font, and sound; Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values; Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required status on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; after jumping out of the loop, release all resources and exit the program.
3. A software interface development device based on Loongson 2K1000, characterized in that Include: A development environment configuration module for configuring the development environment workbench using the underlying hardware driver provided by the Loongson motherboard manufacturer; A component configuration and compilation module for configuring and compiling WindML5.3 components based on Loongson 2K1000; A VIP image project creation module for creating a VIP image project based on Loongson 2K1000 and WindML; An interface software development module for developing interface software according to actual interface design requirements; The configured development environment workbench includes: Replace the original relevant driver programs in the corresponding installation directory of the workbench development environment with 3 driver programs provided by the manufacturer. The 3 driver programs are: the board support package BSP of the Loongson motherboard, the static link library MIPSI64 for compiling applications under the Loongson MIPS multi-core architecture, and the WindML5.3 component of the Loongson version; The configuration and compilation of WindML5.3 components based on Loongson 2K1000 includes: In the workbench environment, build a DKM kernel module project, and select MIPSI64gnule_SMP as the compiler; Configure the graphical configuration file config.windml in the DKM project. The configuration content includes handle name, font, image display, and graphics card; After the config.windml file is configured, click on the DKM project, right-click and select "RebuildProject", and wait to complete the compilation of the WindML component; The creation of a VIP image project based on Loongson 2K1000 and WindML includes: In the workbench environment, select ls2k1000 for BSP, select gnule and SMP multi-core for the compiler, and build a VIP image project; After the project is built, double-click the graphical configuration file Kernel Configuration for configuration: First, add the WindML5.3 component: right-click "find" in c++ components, enter "INCLUDE_WINDML_ALL" in the dialog box and search. After finding the corresponding option, add this component, and right-click properties in the project, and add the link path of windml in the build micros option, that is, add the string "–lwindml-5.3–lwindml-5.3_dyn" after LIBS; Then, configure the number of serial ports according to the actual situation of the motherboard hardware: enter "PC_CONSOLE" in the "find" dialog box to search, and modify the number of SIOs according to the board requirements; Finally, add the TFTP option for implementing the software update of the board card: Enter "tftp" in the search box and add it, and change "tftp server working directory" to " / ahci00:1".
4. The software interface development device based on Loongson 2K1000 according to claim 3, wherein, The main process of interface software development includes: Open the display window configured by windml and initialize it; Obtain the registration information of the display driver device, including the display device, input device, font, and sound; Create a graphics context environment variable, obtain the window size, initialize the color, and assign predefined RGB values; Use an infinite loop function to form an event handling mechanism to ensure the real-time display output of the required status on the interface. The loop body will only jump out when the set conditions are met, thus ending the interface display; after jumping out of the loop, release all resources and exit the program.
Citation Information
Patent Citations
Design method for BSP in VxWorks system
CN103955387A
UEFI (Unified Extensible Firmware Interface) firmware implementation method based on Loongson desk computer
CN104572163A