Multi-channel battery simulator, method, device, equipment and medium
By building the half-duplex communication architecture of the cache unit corresponding to the power channel module and the serial port transceiver module in the FPGA module, the problem of data packet loss during the synchronization control of the multi-channel battery simulator is solved, and the synchronization of low packet loss rate is achieved Reduced transmission and resource requirements.
Patent Information
- Application Number
- CN202411654389.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-19
- Publication Date
- 2024-12-17
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Multi-channel battery simulators are prone to data packet loss during synchronization control, especially when the communication speed increases and the amount of data is large, packet loss will occur during transmission.
Set up the cache unit and serial port transceiver module corresponding to multiple power channel modules within the FPGA module, and turn on and off through the synchronization switch unit to ensure that all output adjustment control frames are cached to the cache unit during synchronization control and then synchronous transmission is performed. , build a half-duplex communication architecture to reduce packet loss rate.
It effectively reduces the situation of packet loss, realizes synchronous transmission with low packet loss rate, and reduces the demand for communication resources, simplifies system design and reduces costs.
Smart Images

Figure CN119147803A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of battery simulators, and in particular to a multi-channel battery simulator, method, device, equipment and medium. Background Art
[0002] As the battery life of electric vehicles and the voltage of battery packs continue to increase, more and more single cells are needed, which leads to an increase in the number of channels of battery simulators for testing BMS (Battery Management System). At the same time, major manufacturers have also put forward shorter requirements for the synchronization return time of multiple power channels. Based on this, battery simulator manufacturers have optimized and improved the communication rate between battery simulators and the outside world, for example, from 25600bps to 4.5Mbps. However, after the speed optimization and improvement, because the communication structure of multi-channel battery simulators has not been optimized, data packet loss may occur when there are a large number of output channels that need to be synchronized. Summary of the invention
[0003] The present application aims to propose a multi-channel battery simulator, method, device, equipment and medium, which can reduce the packet loss of a battery simulator with a large number of output channels during the synchronous control process.
[0004] A multi-channel battery simulator according to the first embodiment of the present application includes: A plurality of power channel modules, each of which is used to simulate a battery; Main control unit; The FPGA module is internally provided with a plurality of cache units corresponding to the plurality of power channel modules one by one, and a plurality of serial port transceiver modules corresponding to the plurality of power channel modules one by one; each of the cache units is connected to the corresponding serial port transceiver module through a synchronous switch unit, and the plurality of cache units are connected to the main control unit through a communication bus; the communication mode between each serial port transceiver module and the corresponding cache unit is configured as a half-duplex communication mode; each of the synchronous switch units is controlled by the main control unit; Wherein, the communication mode between each of the power channel modules and the serial port transceiver module is configured as a half-duplex communication mode.
[0005] The multi-channel battery simulator control method according to the second aspect of the present application is applied to the multi-channel battery simulator as described in the first aspect of the present application, and the multi-channel battery simulator control method includes: Acquire multi-channel setting information, wherein the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one of the power channel modules; Generate a corresponding output adjustment control frame according to each of the battery simulation configuration parameters; Adjusting the working states of the synchronous switch units corresponding to the plurality of the power channel modules according to the multi-channel setting information, so as to transmit each of the output adjustment control frames to the corresponding serial port transceiver module; Among them, when the corresponding synchronous switch unit is turned on, each serial port transceiver module obtains the output adjustment control frame from the corresponding cache unit, and transmits the output adjustment control frame to the corresponding power channel module, so that the power channel module completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
[0006] According to the third aspect of the present application, a multi-channel battery simulator control device is applied to the multi-channel battery simulator as described above, and the multi-channel battery simulator control device includes: A parameter acquisition module, used to acquire multi-channel setting information, wherein the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one of the power channel modules; A control frame generation module, used to generate a corresponding output adjustment control frame according to each of the battery simulation configuration parameters; A data frame transmission module, used for adjusting the working states of the synchronous switch units corresponding to the plurality of the power channel modules according to the multi-channel setting information, so as to transmit each of the output adjustment control frames to the corresponding serial port transceiver module; Among them, when the corresponding synchronous switch unit is turned on, each serial port transceiver module obtains the output adjustment control frame from the corresponding cache unit, and transmits the output adjustment control frame to the corresponding power channel module, so that the power channel module completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
[0007] According to a fourth aspect of the present application, the electronic device comprises: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, the multi-channel battery simulator control method as described in the second aspect of the embodiment is implemented.
[0008] According to the computer-readable storage medium of the fifth aspect embodiment of the present application, computer executable instructions are stored, and the computer executable instructions are used to execute the multi-channel battery simulator control method as described in the second aspect embodiment above.
[0009] The multi-channel battery simulator, method, device, equipment and medium of the embodiment of the present application are provided with multiple groups of cache units and serial transceiver modules corresponding to multiple power channel modules inside the FPGA module, and the communication between each group of cache units and the serial transceiver module can be connected and disconnected through the synchronous switch unit, so that when synchronous control is required, after waiting for the output adjustment control frames of all power channel modules that need to be synchronized to be cached in the cache unit, the synchronous switch unit is turned on to complete the synchronous transmission to the serial transceiver module, thereby completing the synchronous control of multiple power channel modules and reducing the loss of data packets due to the large amount of transmitted data. In the embodiment of the present application, by constructing a cache unit corresponding to each power channel module inside the FPGA module, and constructing a half-duplex communication architecture between the cache unit, the serial transceiver module and the power channel module, the demand for communication resources can be effectively reduced under the premise of achieving synchronous transmission with a low packet loss rate, which is convenient for ensuring the realization of other functions and reducing costs.
[0010] Other features and advantages of the present application will be set forth in the following description, and in part will become apparent from the description, or may be understood by practicing the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which: Figure 1 A schematic diagram of the system architecture of a multi-channel battery simulator provided in an embodiment of the present application; Figure 2 A flowchart of a multi-channel battery simulator control method provided in an embodiment of the present application; Figure 3 A system block diagram of a multi-channel battery simulator control device provided in an embodiment of the present application.
[0012] Reference numerals: A power channel module 110 , a main control unit 120 , an FPGA module 130 , a cache unit 131 , a serial port transceiver module 132 , a synchronous switch unit 133 , and a switch control component 134 . DETAILED DESCRIPTION
[0013] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be understood as limiting the present application.
[0014] In the description of this application, if there is a description of first, second, etc., it is only for the purpose of distinguishing technical features, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features or implicitly indicating the order of the indicated technical features.
[0015] In the description of the present application, it should be understood that the descriptions involving orientation, such as the orientation or positional relationship indicated as up, down, etc., are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0016] In the description of this application, it should be noted that, unless otherwise clearly defined, terms such as setting, installing, connecting, etc. should be understood in a broad sense, and technicians in the relevant technical field can reasonably determine the specific meaning of the above terms in this application based on the specific content of the technical solution.
[0017] The technical solution of the present application will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the embodiments described below are only part of the embodiments of the present application, not all of the embodiments.
[0018] See also Figure 1 As shown, a multi-channel battery simulator provided by an embodiment of the present application includes: A plurality of power channel modules 110, each power channel module 110 is used to simulate a battery; A main control unit 120; The FPGA (Field Programmable Gate Array) module 130 is internally provided with a plurality of cache units 131 corresponding to the plurality of power channel modules 110 one by one, and a plurality of serial port transceiver modules 132 corresponding to the plurality of power channel modules 110 one by one; each cache unit 131 is connected to the corresponding serial port transceiver module 132 through a synchronous switch unit 133, and the plurality of cache units 131 are connected to the main control unit 120 through a communication bus; the communication mode between each serial port transceiver module 132 and the corresponding cache unit 131 is configured as a half-duplex communication mode; each synchronous switch unit 133 is controlled by the main control unit 120; The communication mode between each power channel module 110 and the serial port transceiver module 132 is configured as a half-duplex communication mode.
[0019] In the embodiment of the present application, multiple groups of cache units 131 and serial port transceiver modules 132 corresponding to multiple power channel modules 110 are set inside the FPGA module 130, and the communication between each group of cache units 131 and the serial port transceiver module 132 can be connected and disconnected through the synchronous switch unit 133, so that when synchronous control is required, after waiting for the output adjustment control frames of all power channel modules 110 that need to be synchronized to be cached in the cache unit 131, the synchronous switch unit 133 is turned on to complete the synchronous transmission to the serial port transceiver module 132, thereby completing the synchronous control of multiple power channel modules 110, and reducing the situation of data packet loss due to large amount of transmitted data. In the embodiment of the present application, by constructing a cache unit 131 corresponding to each power channel module 110 inside the FPGA module 130, and constructing a half-duplex communication architecture between the cache unit 131, the serial port transceiver module 132, and the power channel module 110, the demand for communication resources can be effectively reduced under the premise of achieving synchronous transmission with low packet loss rate, which is convenient for ensuring the realization of other functions and reducing costs.
[0020] The above-mentioned serial port transceiver module 132 and the power channel module 110 can achieve half-duplex communication through a 485 communication module, and a 485 isolation communication module can be further selected according to actual needs.
[0021] The power channel module 110 has a built-in controller, so that half-duplex communication with the serial port transceiver module 132 can be achieved.
[0022] The number of the power channel modules 110 is set according to actual needs. In some embodiments, 32 channels, that is, 32 power channel modules 110, are preferred, which is sufficient to meet the needs of most BMS tests.
[0023] The cache unit 131 may be a FIFO cache unit.
[0024] The cache unit 131 , the serial port transceiver module 132 , and the power channel module 110 sequentially construct a half-duplex communication architecture, and can implement half-duplex communication.
[0025] Specifically, in the embodiment of the present application, a half-duplex communication architecture is adopted, and the FIFO buffer unit can be used to store the output adjustment control frame only when the output adjustment control frame needs to be sent down, and the FIFO buffer unit can be used to store the data uploaded by the power channel module 110 when the power channel module 110 uploads data. On the basis of realizing the time-sharing storage of downlink data and upload data, the half-duplex communication architecture is cleverly used to complete the correct and high-speed transmission of data without building a full-duplex communication architecture, so that there is no need to set up two FIFO buffer units for downlink and upload separately. In addition, because the FIFO buffer unit is adopted, when data needs to be overwritten, there is no need to perform complex writing and reading logic control, and it is only necessary to ensure that the data is read by the serial port transceiver module 132 and the main control unit 120 before being overwritten.
[0026] The synchronous switch unit 133 can connect and disconnect the communication between the buffer unit 131 and the serial port transceiver module 132. When data transmission between the buffer unit 131 and the serial port transceiver module 132 is required, the synchronous switch unit 133 can be kept connected.
[0027] The above-mentioned multiple synchronous switch units 133 can be configured to be controlled by the same switch control component 134, or can be configured to be independently controlled. When synchronous control is required, it is sufficient as long as the multiple synchronous switch units 133 can be synchronously turned on or off. It is understandable that when multiple synchronous switch units 133 are configured to be controlled by the same control component, if it is necessary to adjust the output of a power channel module 110 separately, it is only necessary to keep the multiple synchronous switch units 133 in the on state.
[0028] See also Figure 2 As shown, Figure 2 1 is a flowchart of a multi-channel battery simulator control method provided by an embodiment of the present application. The multi-channel battery simulator control method is applied to the main control unit 120, including: Acquire multi-channel setting information, where the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one power channel module 110; Generate a corresponding output adjustment control frame according to each battery simulation configuration parameter; Adjust the working states of the synchronous switch units 133 corresponding to the multiple power channel modules 110 according to the multi-channel setting information, so as to transmit each output adjustment control frame to the corresponding serial port transceiver module 132; Among them, when the corresponding synchronous switch unit 133 is turned on, each serial port transceiver module 132 obtains an output adjustment control frame from the corresponding cache unit 131, and transmits the output adjustment control frame to the corresponding power channel module 110, so that the power channel module 110 completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
[0029] The multi-channel battery simulator control method in the embodiment of the present application is implemented based on the above-mentioned multi-channel battery simulator. The multi-channel battery simulator has been described in detail above and will not be repeated here.
[0030] The battery simulation configuration parameters in the above multi-channel setting information can be obtained by inputting a human-computer interaction unit set on the multi-channel battery simulator, or by obtaining an external terminal device that can be connected to the multi-channel battery simulator, such as a computer, a mobile smart terminal, etc.
[0031] The above battery simulation configuration parameters are determined by the test personnel according to the experimental requirements. After the test personnel determine, multi-channel setting information can be generated according to the battery simulation configuration parameters for transmission to the main control unit 120.
[0032] The multi-channel setting information includes at least one battery simulation configuration parameter. When synchronous control is required, it includes the battery simulation configuration parameter corresponding to each power channel module 110. When independent control is performed, it may include at least the battery simulation configuration parameter corresponding to only one power channel module 110.
[0033] The main control unit 120 and the plurality of cache units 131 are connected via a bus, such as a FSMC bus.
[0034] The multi-channel setting information includes at least one battery simulation configuration parameter corresponding to the power channel module 110. After receiving the multi-channel setting information, the main control unit 120 can generate a corresponding output adjustment control frame according to each battery simulation configuration parameter. For example, in a synchronous control scenario, the multi-channel setting information includes battery simulation configuration parameters corresponding to multiple power channel modules 110, so that an output adjustment control frame corresponding to each battery simulation configuration parameter can be generated.
[0035] The working state of the above-mentioned synchronous switch unit 133 can be flexibly adjusted according to whether synchronous control is required. For example, when synchronous control is not required, all synchronous switch units 133 can be directly kept closed. When synchronous control is required, the consistency of output adjustment control frame transmission is maintained by controlling the synchronous disconnection and connection of the synchronous switch unit 133.
[0036] The above-mentioned serial port transceiver module 132 and the cache unit 131 have half-duplex communication. When the downlink data occupies the communication channel, the uplink data cannot be used, and vice versa. Therefore, when it is necessary to send down the output adjustment control frame, it can be directly sent down, and when it is necessary to upload the channel feedback frame, it can be directly uploaded and fed back.
[0037] After receiving the output adjustment control frame, the serial port transceiver module 132 will transmit it to the power channel module 110. After receiving the output adjustment control frame, the power channel module 110 can parse the required battery simulation configuration parameters from the output adjustment control frame and complete the adjustment according to the battery simulation configuration parameters. At the same time, under the premise that the output adjustment control frame is correct, a channel response frame will also be generated and uploaded so that the main control unit 120 can determine that the output adjustment control frame is delivered correctly.
[0038] In addition, during the data transmission process of the serial port transceiver module 132, it is also possible to first determine whether there is data in the cache unit 131 that needs to be sent down, and first determine whether the main control module has data sent down to the cache unit 131, and then upload it when it is determined that there is no data sent down. The judgment method is also relatively simple, and the first count value can be directly set in the cache unit 131 to count the data of the received output adjustment control frame. As long as the first count value is not the initial value, for example, it is not 0, it can be explained that there is data sent down in the current cache unit 131, and data cannot be uploaded. Because the output adjustment control frame is generated according to a predetermined communication protocol, the data length of the output adjustment control frame, such as the number of bytes, can also be directly determined, that is, when the output adjustment control frame is sent down, the first count value in the cache unit 131, that is, the number of bytes cached, can also be determined, so that the data reading can be completed after the number of bytes counted by the first count value corresponds to the number of bytes of the adjustment control frame. After reading, the first count value can be counted back to the initial value.
[0039] In some embodiments, the multi-channel setting information further includes synchronization flag information, and the synchronization flag information is used to indicate whether the multiple power channel modules 110 are to be synchronously controlled; When the synchronization flag information indicates that the multiple power channel modules 110 need to be synchronized, the working states of the synchronization switch units 133 corresponding to the multiple power channel modules 110 are adjusted according to the multi-channel setting information to transmit each output adjustment control frame to the corresponding serial port transceiver module 132, including: Controlling the synchronous switch units 133 corresponding to the multiple power channel modules 110 to be disconnected; Transmitting the output adjustment control frames corresponding to the multiple power channel modules 110 to the corresponding cache units 131; When the output adjustment control frame corresponding to each power channel module 110 is transmitted to the corresponding buffer unit 131 , the plurality of synchronous switch units 133 are controlled to be closed to transmit the plurality of output adjustment control frames to the corresponding serial port transceiver module 132 .
[0040] The synchronization flag information allows the main control unit 120 to determine whether synchronization control is required. Specifically, after receiving the multi-channel setting information, the main control unit 120 needs to first determine the synchronization flag information therein so as to adjust the state of the synchronization switch unit 133 in time.
[0041] In this embodiment, when it is determined that synchronous control is required, the synchronous switch units 133 corresponding to the multiple power channel modules 110 that are to be synchronously controlled need to be disconnected first, so as to avoid the output adjustment control frame being directly read by the serial port transceiver unit after the main control unit 120 transmits it to the cache unit 131. After that, after waiting for the main control unit 120 to transmit all the output adjustment control frames to the corresponding cache unit 131, the multiple synchronous switch units 133 are controlled to be turned on. At this time, the multiple serial port transceiver modules 132 can obtain the corresponding output adjustment data frame from the corresponding cache unit 131 and forward it to the power channel module 110.
[0042] It should be noted that in a synchronous control scenario, when a new multi-channel setting information is received and it is determined that the synchronization identification information indicates that synchronization is required, the synchronous switch unit 133 needs to be disconnected first and then kept closed during the subsequent adjustment process.
[0043] In some implementations, when the corresponding synchronous switch unit 133 of each serial port transceiver module 132 is turned on, the serial port transceiver module 132 obtains the output adjustment control frame from the corresponding buffer unit 131 through the following steps, including: Reading a first count value in the corresponding cache unit 131, where the first count value is determined when the main control unit 120 transmits an output adjustment control frame to the cache unit 131, and is used to record the data size of the output adjustment control frame; The output adjustment control frame is read from the cache unit 131 according to the first count value, wherein the first count value is restored to an initial value when the output adjustment control frame is completely read.
[0044] The above-mentioned first count value can count the number of data bytes received by the cache unit 131, and the first count value can be read by the serial port transceiver module 132. When the cache unit 131 adopts a FIFO cache unit, the serial port transceiver module 132 only needs to use the first count value to directly read the data in the cache unit 131 without performing complex addressing operations.
[0045] The above-mentioned first count value can also be used for data frame detection. Considering that each output adjustment data frame is specified according to the same communication protocol and therefore has the same number of bytes, if it is determined during the data sending stage that the first count value is inconsistent with the number of bytes of the output adjustment data frame, it can also be preliminarily determined that the data transmission is erroneous.
[0046] After the serial port transceiver module 132 has finished reading the output adjustment data frame, the first count value will be restored to an initial value, which can usually be understood as being assigned a value of 0.
[0047] In some embodiments, the multi-channel battery simulator control method further includes: Acquire channel response frames in multiple cache units 131, each channel response frame is generated by the corresponding power channel module 110 after successfully parsing the output adjustment control frame, and is transmitted to the cache unit 131 via the serial port transceiver module 132; wherein each cache unit 131 accumulates and updates the second count value in the cache unit 131 when receiving the channel response frame; An alarm strategy is executed according to the plurality of second count values.
[0048] The channel response frame is generated after the power channel module 110 receives the output adjustment data frame and successfully parses it, and is used for feedback so that the main control unit 120 can determine whether the data has been successfully sent to the power channel module 110 .
[0049] The channel feedback frame is also counted during the process of being uploaded to the buffer unit 131 , and a second count value is determined.
[0050] The second count value is used to determine the number of bytes of the channel response data fed back by the power channel module 110 , so that the main control unit 120 can use the second count value to determine whether the power channel module 110 successfully obtains the battery simulation configuration parameters.
[0051] In some implementations, executing an alarm strategy according to a plurality of second count values includes: When the second count value in any cache unit 131 is not updated, an alarm message is generated.
[0052] In this embodiment, considering that if the power channel module 110 does not receive the correct output adjustment data frame, it is impossible to obtain the battery simulation configuration parameters, and then it is impossible to generate a channel response frame, and no data will be fed back to the cache unit 131, so that the second count value cannot be accumulated and increased, so that it can be determined that a communication failure has occurred, and it is necessary to generate an alarm message and issue an alarm so that the staff can troubleshoot the problem in time.
[0053] In some embodiments, there are multiple multi-channel setting information; the multi-channel battery simulator control method further includes: In response to the stage test completion signal, the next-order multi-channel setting information is transmitted to the main control unit 120; The stage test completion signal is generated after the stage test is completed according to any multi-channel setting information.
[0054] In this embodiment, considering the continuity of the test in the actual project, there may be multiple multi-channel setting information that needs to be sent in one test. At this time, it is necessary to send multiple multi-channel setting information in sequence, and send the next multi-channel setting information after the test of the previous multi-channel setting information is completed. The test method in this embodiment can reduce the operator's operation workload to a certain extent, which is convenient for large-scale experiments and improves the detection efficiency.
[0055] The above-mentioned stage test completion signal is generated by the BMS system or other detection test terminal after the test corresponding to each multi-channel setting information is completed, and is fed back to the host computer or main control unit 120 connected to the main controller.
[0056] In some implementations, the power channel module 110 performs output adjustment by the following steps: In response to a DMA (Data Memory Access) data reception interrupt, a data reception terminal program is entered; Obtaining output adjustment control frames in the data receiving terminal program; Parse the output adjustment control frame, obtain the corresponding battery simulation configuration parameters, and generate a channel response frame; Complete output adjustment according to battery simulation configuration parameters; The channel response frame is transmitted to the serial port transceiver module 132 .
[0057] In this embodiment, data acquisition is performed by using DMA data receiving interrupts, which can greatly reduce the computing power occupied by the power channel module 110, and can also ensure the priority of receiving the output adjustment control frame. That is, it is only necessary for each power channel module 110 to set the priority of the DMA data receiving interrupt to the highest, which can effectively improve the synchronization of receiving the output adjustment control frame.
[0058] The multi-channel battery simulator control method provided in the embodiment of the present application can be executed by a multi-channel battery simulator control device. In the embodiment of the present application, the multi-channel battery simulator control device executing the multi-channel battery simulator control method is taken as an example to illustrate the multi-channel battery simulator control device provided in the embodiment of the present application.
[0059] like Figure 3As shown, the embodiment of the present application also provides a multi-channel battery simulator control device, the multi-channel battery simulator control device includes: A parameter acquisition module, used to acquire multi-channel setting information, where the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one power channel module 110; A control frame generation module, used to generate a corresponding output adjustment control frame according to each battery simulation configuration parameter; A data frame transmission module, used to adjust the working state of the synchronous switch unit 133 corresponding to the plurality of power channel modules 110 according to the multi-channel setting information, so as to transmit each output adjustment control frame to the corresponding serial port transceiver module 132; Among them, when the corresponding synchronous switch unit 133 is turned on, each serial port transceiver module 132 obtains an output adjustment control frame from the corresponding cache unit 131, and transmits the output adjustment control frame to the corresponding power channel module 110, so that the power channel module 110 completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
[0060] The multi-channel battery simulator control device in the embodiment of the present application can be an electronic device, or a component in an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or it can be other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (AR) / virtual reality (VR) device, a robot, a wearable device, an ultra-mobile personal computer (Ultra-mobile per Sonal CompUter, UMPC), a netbook or a personal digital assistant (per Sonal digital aSSiStant, PDA), etc. It can also be a server, a network attached storage (Network AttaChed Storage, NAS), a personal computer (per Sonal CompUter, PC), a television (teleViSion, tV), a teller machine or a self-service machine, etc., and the embodiment of the present application is not specifically limited.
[0061] The embodiment of the present application also provides an electronic device, including: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, the multi-channel battery simulator control method as described above is implemented. The source meter provided in the embodiment of the present application can implement each process implemented in the embodiment of the multi-channel battery simulator control method described above, and achieve the same beneficial effects. To avoid repetition, it will not be repeated here.
[0062] An embodiment of the present application also provides a computer-readable storage medium, which stores computer-executable instructions. The computer-executable instructions are executed by a processor or a control module, so that the above-mentioned processor can execute the multi-channel battery simulator control method in the above-mentioned embodiment, for example, execute the method described above.
[0063] It should be clear that the present application is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present application.
[0064] The functional blocks shown in the above structural block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application-specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present application are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier. "Machine-readable medium" may include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROMs, flash memories, erasable ROMs (EROMs), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.
[0065] It should also be noted that the exemplary embodiments mentioned in this application describe some methods or systems based on a series of steps or devices. However, this application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiment, or in a different order from the embodiment, or several steps can be performed simultaneously.
[0066] Aspects of the present disclosure are described above with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device to produce a machine so that these instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the functions / actions specified in one or more boxes of the flowchart and / or block diagram. Such a processor can be a general-purpose processor, a special-purpose processor, a special application processor, or a field programmable logic circuit. It can also be understood that each box in the block diagram and / or flowchart and the combination of boxes in the block diagram and / or flowchart can also be implemented by dedicated hardware that performs the specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions.
[0067] The above are only specific implementation methods of the present application. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. It should be understood that the protection scope of the present application is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in this application, and these modifications or replacements should be included in the protection scope of this application.
Claims
1. A multi-channel battery simulator, characterized in that: include: A plurality of power channel modules, each of which is used to simulate a battery; Main control unit; The FPGA module is internally provided with a plurality of cache units corresponding to the plurality of power channel modules one by one, and a plurality of serial port transceiver modules corresponding to the plurality of power channel modules one by one; each of the cache units is connected to the corresponding serial port transceiver module through a synchronous switch unit, and the plurality of cache units are connected to the main control unit through a communication bus; the communication mode between each serial port transceiver module and the corresponding cache unit is configured as a half-duplex communication mode; each of the synchronous switch units is controlled by the main control unit; Wherein, the communication mode between each of the power channel modules and the serial port transceiver module is configured as a half-duplex communication mode.
2. A multi-channel battery simulator control method, characterized in that: Applied to the multi-channel battery simulator as claimed in claim 1, the multi-channel battery simulator control method comprises: Acquire multi-channel setting information, wherein the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one of the power channel modules; Generate a corresponding output adjustment control frame according to each of the battery simulation configuration parameters; Adjusting the working states of the synchronous switch units corresponding to the plurality of the power channel modules according to the multi-channel setting information, so as to transmit each of the output adjustment control frames to the corresponding serial port transceiver module; Among them, when the corresponding synchronous switch unit is turned on, each serial port transceiver module obtains the output adjustment control frame from the corresponding cache unit, and transmits the output adjustment control frame to the corresponding power channel module, so that the power channel module completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
3. The multi-channel battery simulator control method according to claim 2, characterized in that: The multi-channel setting information further includes synchronization flag information, and the synchronization flag information is used to indicate whether the multiple power channel modules are to be synchronously controlled; In the case where the synchronization flag information indicates that the plurality of power channel modules need to be synchronized, adjusting the working states of the synchronization switch units corresponding to the plurality of power channel modules according to the multi-channel setting information to transmit each of the output adjustment control frames to the corresponding serial port transceiver module includes: Controlling the synchronous switch units corresponding to the plurality of power channel modules to be disconnected; Transmitting the output adjustment control frames corresponding to the plurality of power channel modules to the corresponding cache units; When the output adjustment control frame corresponding to each power channel module is transmitted to the corresponding cache unit, the plurality of synchronous switch units are controlled to be closed to transmit the plurality of output adjustment control frames to the corresponding serial port transceiver module.
4. The multi-channel battery simulator control method according to claim 3, characterized in that: When the corresponding synchronous switch unit of each serial port transceiver module is turned on, the serial port transceiver module obtains the output adjustment control frame from the corresponding buffer unit through the following steps, including: reading a first count value in the corresponding cache unit, where the first count value is determined when the main control unit transmits the output adjustment control frame to the cache unit and is used to record the data size of the output adjustment control frame; The output adjustment control frame is read from the cache unit according to the first count value, wherein the first count value is restored to an initial value when the reading of the output adjustment control frame is completed.
5. The multi-channel battery simulator control method according to claim 2, characterized in that: The multi-channel battery simulator control method further includes: Acquire channel response frames in a plurality of the cache units, each of the channel response frames being generated by the corresponding power channel module after successfully parsing the output adjustment control frame, and transmitted to the cache unit via the serial port transceiver module; wherein each of the cache units, when receiving the channel response frame, cumulatively updates the second count value in the cache unit; An alarm strategy is executed according to a plurality of said second count values.
6. The multi-channel battery simulator control method according to claim 5, characterized in that: The executing the alarm strategy according to the plurality of the second count values comprises: When the second count value in any of the cache units is not updated, an alarm message is generated.
7. The multi-channel battery simulator control method according to claim 2, characterized in that: The power channel module completes output adjustment through the following steps: In response to the DMA data receiving interrupt, the data receiving terminal program is entered; Acquiring the output adjustment control frame in the data receiving terminal program; Parsing the output adjustment control frame to obtain the corresponding battery simulation configuration parameters and generating a channel response frame; Complete output adjustment according to the battery simulation configuration parameters; The channel response frame is transmitted to the serial port transceiver module.
8. A multi-channel battery simulator control device, characterized in that: Applied to the multi-channel battery simulator as claimed in claim 1, the multi-channel battery simulator control device comprises: A parameter acquisition module, used to acquire multi-channel setting information, wherein the multi-channel setting information includes a battery simulation configuration parameter corresponding to at least one of the power channel modules; A control frame generation module, used to generate a corresponding output adjustment control frame according to each of the battery simulation configuration parameters; A data frame transmission module, used for adjusting the working states of the synchronous switch units corresponding to the plurality of the power channel modules according to the multi-channel setting information, so as to transmit each of the output adjustment control frames to the corresponding serial port transceiver module; Among them, when the corresponding synchronous switch unit is turned on, each serial port transceiver module obtains the output adjustment control frame from the corresponding cache unit, and transmits the output adjustment control frame to the corresponding power channel module, so that the power channel module completes the output adjustment according to the battery simulation configuration parameters in the adjustment control frame.
9. An electronic device, characterized in that: The electronic device comprises a processor and a memory storing computer program instructions; When the processor executes the computer program, the multi-channel battery simulator control method according to any one of claims 2 to 7 is implemented.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the multi-channel battery simulator control method as described in any one of claims 2 to 7.
Citation Information
Patent Citations
Method of reducing message transmission overhead of parallel multi-digital signal processor
CN101163129A
Synchronous processing method for multimedia broadcast multicast service, upper network element and lower network element
CN102055724A
Large-capacity high-speed multichannel data playback device and method
CN113986130A
ZYNQ-based multichannel DAC pulse output control system and method
CN117424599A
High-speed parallel operation control system and method and power supply test system
CN117572803A
