Controllable output method of monitoring equipment
By setting the controllable output variables in the embedded software of the rail transit monitoring equipment, the problems that need to be modified frequently and restart the system when the device is abnormal, realize remote debugging and heat debt, and reduces the time and cost of the problem.
Patent Information
- Application Number
- CN202411315367.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-20
- Publication Date
- 2025-01-24
AI Technical Summary
In outdoor monitoring equipment of rail transit, when there is an abnormality in the communication processor or acquisition extension, the program needs to be remodified, the printout code is added, the system needs to be compiled, downloaded and restarted to view interface data and process data, resulting in a long time to troubleshoot problems and cost. High, difficult to locate faults.
By setting a multi-bit unsigned long integer variable that controls the output in the embedded software, using macro definitions to define the meaning of each output, display the output trigger port in the visual interface of the host computer, and determine the corresponding trigger output The output status is sent to the host computer to display the interface data and process data.
In the case of the case of not writing procedures and restarting the system, remotely obtain on -site debugging information, shorten the problem of problem investigation, reduce labor costs, ensure that the state of failure is not damaged, and ensure the accuracy of the problem positioning.
Smart Images

Figure CN119357028A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of output control, and in particular to a controllable output method of monitoring equipment for outdoor use in rail transit. Background Art
[0002] In the outdoor monitoring equipment of rail transit, the communication processor is responsible for processing the data collected by the acquisition extension and sending it to the display and control terminal through the network port. The outdoor monitoring equipment is mainly for real-time monitoring of the external settings of the railway track system to ensure the safe operation of rail transit. The communication processor is used to collect the data of the acquisition extension, and after analysis and processing, the data is transmitted to the microcomputer monitoring computer through the CAN port. The acquisition extension is used to collect information such as current and temperature on the steel-clad copper cable of the track. The display and control terminal displays the software of the real-time value of the current.
[0003] When the communication processor is working normally, in order not to affect the operation of the system, there is no debugging information and printing information. When the communication processor or the acquisition extension is abnormal, the communication processor needs to view the data of each interface or local parameter data, and it is necessary to modify the program again, add the print output code, compile it and download it to the processor, and restart the system before it can be displayed.
[0004] When the embedded program is running normally, it does not have the function of debugging and viewing process variables. It can only print the data that needs to be viewed by changing the code when necessary. This method is more suitable for indoor debugging. When problems occur on site, especially when the rail transit is not at the skylight point, it is impossible to modify the software and restart the system, and it is particularly difficult to troubleshoot the problem. After arriving at the site, it is also necessary to repeatedly modify the program, repeatedly burn the program, and repeatedly restart the system. The skylight point refers to the time when the rail transit trains are not running at night, and you can apply for maintenance of the equipment of the rail transit system. The time point of application is the skylight point.
[0005] It can be seen that the method of obtaining interface data and process data by constantly modifying the program on site will lead to the following problems:
[0006] (1) Problem investigation requires on-site visit, which is time-consuming, labor-intensive, and costly.
[0007] (2) The fault phenomenon is destructive and difficult to reproduce later, making it difficult to locate the fault.
[0008] (3) The debug version may be inconsistent with the running version.
[0009] Therefore, how to provide a method for obtaining interface data and process data without burning a program or restarting the system is a technical problem that urgently needs to be solved by those skilled in the art. Summary of the invention
[0010] In view of the above problems, the present invention provides a controllable output method of a monitoring device for overcoming the above problems or at least partially solving the above problems.
[0011] The present invention provides the following scheme:
[0012] A controllable output method for monitoring equipment, comprising:
[0013] A multi-bit unsigned long integer variable for controlling output is set in the embedded software; each bit of the unsigned long integer variable represents a different output;
[0014] Using macro definition, define the output meaning represented by each output;
[0015] Displaying the trigger ports corresponding to all the outputs in the visual interface of the host computer;
[0016] After determining that the trigger port is triggered, determining that the output corresponding to the triggered trigger port is the target output, and sending the controllable output variable to the embedded software, the embedded software assigns the received value to the controllable output variable, so that the embedded software uses a conditional judgment method to determine the output state required to be executed by the target output, and the output state includes turning on the output and turning off the output;
[0017] After determining that the output state is open output, the data corresponding to the output meaning corresponding to the target output is sent to the host computer so that the data can be displayed in the visual interface of the host computer, and the data includes interface data and / or process data.
[0018] Preferably: a uint64 unsigned long integer variable for controlling the output is set in the embedded software.
[0019] Preferably, when it is determined that the bit corresponding to the triggered trigger port is 1, the output state is determined to be output on.
[0020] Preferably, when it is determined that the bit corresponding to the triggered trigger port is 0, the output state is determined to be output closed.
[0021] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:
[0022] The controllable output method of a monitoring device provided by an embodiment of the present invention can remotely debug the monitoring device, preliminarily troubleshoot problems, shorten the troubleshooting time, and reduce labor costs. The system can be restarted to ensure that hot debugging is performed in a fault state. The program can be kept consistent without changing the program version, ensuring accurate problem location. The method can be applied to all embedded software programs to solve the problem of difficult debugging of embedded programs.
[0023] Of course, any product implementing the present invention does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0025] Figure 1 is a flow chart of a controllable output method of a monitoring device provided by an embodiment of the present invention;
[0026] Figure 2 This is a flow chart of a setting process taking setting a uint64 unsigned long integer variable as an example provided by an embodiment of the present invention;
[0027] Figure 3 It is a schematic diagram of the display state of the visual interface provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0028] The technical scheme in the embodiment of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiment of the present invention. Obviously, the described embodiment is only a part of the embodiment of the present invention, not all of the embodiments. Based on the embodiment of the present invention, all other embodiments obtained by ordinary technicians in this field belong to the scope of protection of the present invention.
[0029] See also Figure 1 , is a controllable output method of a monitoring device provided by an embodiment of the present invention, such as Figure 1 As shown, the method may include:
[0030] S101: Setting a multi-bit unsigned long integer variable for controlling output in the embedded software; each bit of the unsigned long integer variable represents a different output; in a specific implementation, the embodiment of the present invention may provide a uint64 unsigned long integer variable for controlling output in the embedded software.
[0031] S102: using a macro definition method, defining the output meaning represented by each output;
[0032] S103: Displaying the trigger ports corresponding to all the outputs in the visual interface of the host computer;
[0033] S104: After determining that the trigger port is triggered, determine that the output corresponding to the triggered trigger port is the target output; and send the controllable output variable to the embedded software, and the embedded software assigns the received value to the controllable output variable, so as to use the conditional judgment method to determine the output state required to be executed by the target output, and the output state includes open output and closed output; in specific implementation, the embodiment of the present invention can provide that when it is determined that the bit corresponding to the triggered trigger port is 1, the output state is determined to be open output. When it is determined that the bit corresponding to the triggered trigger port is 0, the output state is determined to be closed output.
[0034] S105: After determining that the output state is open output, the data corresponding to the output meaning corresponding to the target output is sent to the host computer so that the data can be displayed in the visual interface of the host computer, and the data includes interface data and / or process data.
[0035] The controllable output method of the monitoring device provided in the embodiment of the present invention can view system faults or process data without burning the program or restarting the system. On-site debugging information can be obtained remotely, and when a fault is found, the on-site information can be obtained as soon as possible. When the controllable output function is implemented, the information to be output can be controlled according to the needs without changing the program. That is, the program can be run on-site without outputting any information and running in full state, and the output data can be controlled when it is necessary to view the output data. The hot debugging function can also be implemented. When the system is not restarted, the fault state can be guaranteed not to be destroyed, and the problem can be troubleshooted on-site.
[0036] The following takes setting a uint64 unsigned long integer variable as an example to describe in detail the controllable output method of the monitoring device provided by the embodiment of the present invention. Figure 2 shown.
[0037] (1) When designing embedded software, set a uint64 unsigned long integer variable OutCt l to control the output;
[0038] (2) Each bit of the unsigned long integer variable OutCtl represents the control of an output. The specific setting method is shown in Table 1.
[0039] bit63 bit62 bit61 bit60 bit59 bit58 bit57 bit56 bit55 bit54 bit53 bit52 bit51 bit50 bit49 bit48 bit47 bit46 bit45 bit44 bit43 bit42 bit41 bit40 bit39 bit38 bit37 bit36 bit35 bit34 bit33 bit32 bit31 bit30 bit29 bit28 bit27 bit26 bit25 bit24 bit23 bit22 bit21 bit20 bit19 bit18 bit17 bit16 bit15 bit14 bit13 bit12 bit11 bit10 bit9 bit8 bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0
[0040] For example: bit0 represents output 1, bit1 represents output 2, bit2 represents output 3, bit3 represents output 4, and so on. 64 bits can represent 64 different outputs.
[0041] (3) Use macro definition to set the output corresponding to the bit of OutCt 1. Define the output meaning represented by each output.
[0042] #define OUTPUT_DEBUG1 1 / / Corresponding to bit0, output 1
[0043] #define OUTPUT_DEBUG2 2 / / Corresponding to bit1, output 2
[0044] #define OUTPUT_DEBUG3 3 / / Corresponding to bit2, output 3
[0045] #define OUTPUT_DEBUG4 4 / / Corresponding to bit3, output 4
[0046] #define OUTPUT_DEBUG5 5 / / Corresponding to bit4, output 5
[0047] (4) Provide a judgment function to determine whether the bit is 1,
[0048] The implementation is as follows:
[0049] bool JudgeBitIsOne(uint64 OutCtl,uint64 pos)
[0050] {
[0051] if(pos<0||pos>63)
[0052] {
[0053] return false;
[0054] }
[0055] if(OutCtl&(0x01< <pos))
[0056] {
[0057] return true;
[0058] }
[0059] else
[0060] {
[0061] return false;
[0062] }
[0063] }
[0064] (5) Where output is required, use conditional judgment to determine whether the bit needs to be output.
[0065] (6) The matching host computer displays all output trigger ports through a visual interface. Users can change the output status by clicking on each trigger port. Figure 3 .
[0066] For example, when output 3 is checked, the host computer software will change the corresponding bit to 1, indicating that the information output is turned on. Here, bit control can meet multiple output conditions.
[0067] This method can be used to design some commonly used outputs into controllable outputs. When needed, you can open the output at any time through the output control to view some necessary information. The output can be background printing, or the data can be transmitted to the host computer through the network port for display.
[0068] This method can also be used to view various required interface data information and process data information without changing the program. It can also be used to obtain various debugging information on site in the first place without going to the site.
[0069] In summary, the controllable output method of monitoring equipment provided by this application can remotely debug the monitoring equipment, preliminarily troubleshoot problems, shorten the troubleshooting time, and reduce labor costs. The system can be restarted to ensure hot debugging in the fault state. The program can be kept unchanged to ensure that the program version is consistent and the problem is accurately located. This method can be applied to all embedded software programs to solve the problem of difficult debugging of embedded programs.
[0070] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0071] It can be seen from the above description of the implementation mode that those skilled in the art can clearly understand that the present invention can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention or some parts of the embodiments.
[0072] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can refer to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the partial description of the method embodiment. The system and system embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without creative work.
[0073] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims
1. A controllable output method for monitoring equipment, characterized in that: include: Set a multi-bit unsigned long integer variable in the embedded software to control the output; Each bit of the unsigned long integer variable represents a different output; Using macro definition, define the output meaning represented by each output; Displaying the trigger ports corresponding to all the outputs in the visual interface of the host computer; After determining that the trigger port is triggered, determining that the output corresponding to the triggered trigger port is the target output, and sending the controllable output variable to the embedded software, the embedded software assigns the received value to the controllable output variable, so that the embedded software uses a conditional judgment method to determine the output state required to be executed for the target output, and the output state includes turning on the output and turning off the output; After determining that the output state is open output, the data corresponding to the output meaning corresponding to the target output is sent to the host computer so that the data can be displayed in the visual interface of the host computer, and the data includes interface data and / or process data.
2. The controllable output method of monitoring equipment according to claim 1, characterized in that: In the embedded software, set a uint64 unsigned long integer variable to control the output.
3. The controllable output method of monitoring equipment according to claim 1, characterized in that: When it is determined that the bit corresponding to the triggered trigger port is 1, the output state is determined to be output on.
4. The controllable output method of monitoring equipment according to claim 1, characterized in that: When it is determined that the bit corresponding to the triggered trigger port is 0, the output state is determined to be output off.