CN115829689A - Power-down access method and device for charging subscription monoclonal antibody - Google Patents
Power-down access method and device for charging subscription monoclonal antibody Download PDFInfo
- Publication number
- CN115829689A CN115829689A CN202211633761.1A CN202211633761A CN115829689A CN 115829689 A CN115829689 A CN 115829689A CN 202211633761 A CN202211633761 A CN 202211633761A CN 115829689 A CN115829689 A CN 115829689A
- Authority
- CN
- China
- Prior art keywords
- data structure
- charging
- order
- time
- structure body
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Charge And Discharge Circuits For Batteries Or The Like (AREA)
Abstract
The application relates to the technical field of charging pile ammeter data processing, and discloses a charging subscription monoclonal antibody power failure access method and device, wherein the method comprises the following steps: the method comprises the steps of predefining a hot data structure body of a charging order, storing frequently rewritten hot data such as active order data into a FRAM resistant to writing operation, verifying the legality and tampering of the data after the order ending data are not updated to be cold data, and dumping the data into Flash in batches.
Description
Technical Field
The application relates to the technical field of charging pile ammeter data processing, in particular to a charging subscription monoclonal antibody power failure access method and device.
Background
The charging pile has the function similar to that of an oiling machine in a gas station, can be fixed on the ground or on the wall, is installed in public buildings (public buildings, shopping malls, public parking lots and the like) and residential area parking lots or charging stations, and can charge various types of electric vehicles according to different voltage levels. The input end of the charging pile is directly connected with an alternating current power grid, and the output end of the charging pile is provided with a charging plug for charging the electric automobile. Fill electric pile and generally provide two kinds of charging methods of conventional charging and quick charge, people can use specific charging card to swipe the card and use on the human-computer interaction operation interface that fills electric pile and provide, carry out operations such as corresponding charging method, charging time, expense data printing, fill electric pile display screen and can show data such as the charge volume, expense, charging time.
And the charging unit of the charging pile stores the order number and other key information of the charging order in Flash when the charging order starts, refreshes the stored contents such as ammeter data in real time in the charging process, and uses the data stored in Flash for settlement when the charging is finished.
In the prior art, the whole charging process can update the order information in real time, and the corresponding order information is updated every second, so that the Flash is frequently operated, and the service life of the Flash can be shortened. Because the Flash work flow is to erase the block data first and then write the data. If the charging unit is powered down in the charging process, the power failure can cause data loss if Flash is erased and written in time, and the file system can be seriously damaged, so that the charging unit can be disabled.
Disclosure of Invention
The application aims to overcome the defects of the prior art and provides a charging monoclonal antibody power-down access method and device.
In a first aspect, a power down access method for a charging subscription monoclonal antibody is provided, which includes:
predefining a thermal data structure of a charging order, wherein the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value of each time interval, order starting time, order current time and a check mark;
acquiring initial ammeter reading and order starting time when charging is started;
updating the thermal data structure according to the initial electric meter reading and the order starting time, and writing the updated data structure into the FRAM;
in the charging process, reading the real-time electric meter reading and the order current time once every n seconds, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0;
in the charging process, the reading difference between the current ammeter and the initial ammeter is calculated every N hours, the reading difference of the ammeters at all time periods in the thermal data structure is updated according to the reading difference, and the updated data structure is written into the FRAM, wherein 0-once N is less than or equal to 1;
when accidental interruption occurs in the charging process, the thermal data structure body in the FRAM is automatically updated, after the power is turned on again, the current time of an order in the thermal data structure body is compared with the current time, if the comparison result is inconsistent, the thermal data structure body is uploaded to a server, so that the server performs order settlement, and an instruction is issued;
after charging is finished, the check mark is a charging finishing mark, the thermal data structure body in the FRAM is uploaded to the server, so that the server can perform order settlement, issue an order finishing instruction, and archive the thermal data structure body in Flash.
Further, the data type adopted by the initial electricity meter reading is a double-precision floating point number, and the double-precision floating point number is used for storing the electricity meter value when the charging is started.
Furthermore, the data type adopted by the real-time electricity meter reading is a double-precision floating point number and is used for storing the charging real-time electricity meter value.
Further, the data type adopted by the reading difference value of the electric meter in each time period is a single-precision floating point number, and the data type is used for storing the reading difference value of the electric meter in each time period in a stepping mode.
Further, the format of the order start time is 32-bit unix timestamp for storing the start charging time, and the format of the order current time is 32-bit unix timestamp for storing the real-time charging time.
Furthermore, the check mark is used for storing order state information and a cyclic redundancy check code, and cyclic redundancy check is performed on the thermal data structure every time the thermal data structure is updated.
Further, the order settlement comprises:
receiving a thermal data structure;
judging the legality of the thermal data structure by calculating the charging amount of each time period;
if the thermal data structure is illegal, a charging failure instruction is sent out;
if the hot data structure is legal, checking whether the hot data structure is tampered through cyclic redundancy;
if the hot data structure body is tampered, a charging failure instruction is sent out;
if the hot data structure body is not tampered, deducting money of a user;
and after the deduction is completed, sending a charging completion instruction.
In a second aspect, a charging monoclonal antibody power-down access device is provided, including:
the system comprises a predefining module, a checking module and a processing module, wherein the predefining module is used for predefining a thermal data structure of a charging order, and the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value in each time period, order starting time, order current time and a checking mark;
the acquisition module is used for acquiring the initial ammeter reading and the order starting time when charging is started;
the first updating module is used for updating the thermal data structure body according to the initial electric meter reading and the order starting time and writing the updated data structure body into the FRAM;
the second updating module is used for reading the real-time electric meter reading and the order current time every n seconds in the charging process, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0;
the third updating module is used for calculating the reading difference value between the current ammeter and the initial ammeter every N hours in the charging process, updating the reading difference value of the ammeter in each time period in the thermal data structure body according to the reading difference value, and writing the updated data structure body into the FRAM, wherein 0 & lt N & gt is less than or equal to 1;
the interruption analysis processing module is used for automatically updating the thermal data structure body in the FRAM when unexpected interruption occurs in the charging process, comparing the current time of the order in the thermal data structure body with the current time after the thermal data structure body is electrified again, and uploading the thermal data structure body to the server if the comparison result is inconsistent so that the server can perform order settlement and issue an instruction;
and the charging end processing module is used for checking that the mark is a charging end mark after charging is finished, uploading the thermal data structure body in the FRAM to the server so as to enable the server to settle orders, issue an order finishing instruction and archive the thermal data structure body in Flash.
In a third aspect, a computer-readable storage medium is provided, which stores program code for execution by a device, the program code comprising instructions for performing the steps of the method as in any one of the implementations in the first aspect.
In a fourth aspect, an electronic device is provided, which includes a processor, a memory, and a program or instructions stored on the memory and executable on the processor, the program or instructions, when executed by the processor, implementing the method as in any one of the implementations of the first aspect.
The application has the following beneficial effects: according to the method and the device, a hot data structure body is predefined, the hot data frequently rewritten such as active order data are stored in the FRAM resistant to writing operation, the order ending data are not updated and converted into cold data, and then the cold data are dumped into Flash in batches, so that the order data can be guaranteed not to be lost after power failure by utilizing the characteristic that the FRAM is not lost when power failure data are not lost, meanwhile, the frequency of data erasing and writing operation on Flash is greatly reduced, and the service life of the Flash can be effectively prolonged.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, are included to provide a further understanding of the application, and are incorporated in and constitute a part of this application for purposes of illustration and description.
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a charging monoclonal antibody power down access method according to an embodiment of the present application;
fig. 2 is a flowchart of order settlement performed by a server in a charging monoclonal antibody power failure access method according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Example one
An embodiment of the present application relates to a power failure access method for a charging monoclonal antibody, including: predefining a thermal data structure of a charging order, wherein the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value of each time interval, order starting time, order current time and a check mark; acquiring initial ammeter reading and order starting time when charging is started; updating the thermal data structure according to the initial electric meter reading and the order starting time, and writing the updated data structure into the FRAM; in the charging process, reading the real-time electric meter reading and the order current time once every n seconds, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0; in the charging process, reading difference values of the current ammeter and the initial ammeter are calculated every N hours, the reading difference values of the ammeters in all time periods in the thermal data structure body are updated according to the reading difference values, the updated data structure body is written into the FRAM, wherein the number of the once-woven fabrics is 0-1; when accidental interruption occurs in the charging process, the thermal data structure body in the FRAM is automatically updated, after the power is turned on again, the current time of an order in the thermal data structure body is compared with the current time, if the comparison result is inconsistent, the thermal data structure body is uploaded to a server, so that the server performs order settlement, and an instruction is issued; after charging is finished, the check mark is a charging finishing mark, a hot data structure body in the FRAM is uploaded to a server, so that the server can carry out order settlement, an order finishing instruction is issued, the hot data structure body is filed and stored in Flash, hot data frequently rewritten such as active order data and the like are stored in the FRAM resistant to writing operation through predefining one hot data structure body, the order finishing data are not updated and converted into cold data, and then the cold data are dumped into the Flash in batches, so that the order data can be guaranteed not to be lost after power failure by utilizing the characteristic that FRAM power failure data are not lost, meanwhile, the frequency of data erasing and writing operation on the Flash is greatly reduced, and the service life of the Flash can be effectively prolonged.
Specifically, fig. 1 shows a flowchart of a charging monoclonal antibody power-down access method in the first application embodiment, including:
s101, predefining a thermal data structure of a charging order, wherein the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value of each time period, order starting time, order current time and a check mark;
specifically, the data type adopted by the initial electricity meter reading is a double-precision floating point number, occupies 64 bits and is used for storing the electricity meter value when the charging is started;
the data type adopted by the real-time electricity meter reading is double-precision floating point number, occupies 64 bits and is used for storing the charging real-time electricity meter value;
the data type adopted by the reading difference value of the electric meter in each time period is a single-precision floating point number, illustratively, the longest charging time period is 24 hours, the time length of each time period is half an hour, the time length of each time period is divided into 48 time periods in total, the reading difference value of the electric meter in each time period occupies 48 x 32bit, the reading difference value of the electric meter in each time period is stored in a stepping mode, namely the reading difference value is calculated in each half hour and stored in a corresponding position, the reading difference value calculated in each half hour occupies 32bit, therefore, the data in 24 hours occupies 48 x 32bit in total, the storage time of the reading difference value in each half hour in the stored data is different, the storage position of the reading difference value corresponding to each half hour is also different, and therefore, each half hour has a corresponding data record, and the server can conveniently verify the legality of the data;
the order starting time is in a format of 32-bit unix timestamp, occupies 32 bits and is used for storing the starting charging time, and the order current time is in a format of 32-bit unix timestamp, occupies 32 bits and is used for storing the real-time charging time;
the check mark is used for storing order state information and cyclic redundancy check code, occupies 32 bits, and every time the hot data structure body takes place to update all carries out the cyclic redundancy check to the hot data structure body, it needs to explain that, when charging pile's operating condition changes, order state information also changes along with changing, and the order state includes: the method comprises the steps of starting charging, interrupting charging (power failure, software crash and the like), order abnormity, resetting an order (indicating the order after power failure and restarting) and ending charging and the like, wherein cyclic redundancy check is to check a hot data structure body by using a CRC algorithm so as to judge whether the hot data structure body is tampered by lawbreakers, and once data is found to be tampered, the order state is modified to be abnormal and related personnel are informed to process the order.
S102, obtaining a starting ammeter reading and an order starting time when charging is started;
s103, updating the thermal data structure according to the initial electric meter reading and the order starting time, and writing the updated data structure into the FRAM;
specifically, when charging is started, the read initial electric meter reading is written into an initial electric meter reading position of the thermal data structure, the time for starting charging of the order is written into an order starting time position of the thermal data structure, and charging is started and written into a verification mark position of the thermal data structure, at this time, other positions (the real-time electric meter reading, the electric meter reading difference value in each time period and the order current time) of the thermal data structure are all empty, and after the initial electric meter reading and the order starting time are written, the thermal data structure is verified by using a CRC algorithm to judge whether the thermal data structure is tampered by a lawbreaker or not.
S104, in the charging process, reading the real-time electric meter reading and the order current time once every n seconds, updating the thermal data structure according to the real-time electric meter reading and the order current time, and writing the updated data structure into FRAM, wherein n is larger than 0;
specifically, n may be a number such as 0.5, 1, 2, or 3, where n =1 is taken as an example, that is, during the charging process, the real-time meter reading and the current order time are read every 1 second, the thermal data structure is updated according to the real-time meter reading and the current order time, the thermal data structure is checked by using a CRC algorithm to determine whether the thermal data structure is tampered by a lawless person, and then the updated data structure is written into the FRAM.
S105, in the charging process, reading difference values of the current ammeter and the initial ammeter are calculated every N hours, the reading difference values of the ammeters in each time period in the thermal data structure are updated according to the reading difference values, the updated data structure is written into FRAM, and the number of the once-woven fabric is 0 and less than or equal to 1;
specifically, N may be a number such as 0.5, 0.8, or 1, where N =1 is taken as an example, that is, a reading difference between the current electric meter and the initial electric meter is calculated every 1 hour, so that an electric quantity deducted every hour can be calculated, a normal range of the electric quantity deducted every hour can be obtained by analyzing the conventional charging data, so that an order is determined to be abnormal when the electric quantity deducted every hour exceeds the normal range (for example, a 30KW charging pile is almost impossible to charge 32 degrees every hour, and if the electric quantity deducted every hour exceeds 32 degrees, it is determined that the current order is abnormal, a notification is sent to a relevant person to process), the reading difference of the electric meters in each time period in the thermal data structure is updated according to the reading difference, and the thermal data structure is checked by using a CRC algorithm to determine whether the thermal data structure is tampered by a lawless person, and then the updated data structure is written into a FRAM, where updating the data structure is a process of assigning an address, for example: reading pointer data of a structural body, and directly storing the data into corresponding addresses according to the addresses.
S106, when the charging process is interrupted accidentally, the thermal data structure in the FRAM is automatically updated, after the charging is carried out again, the current time of the order in the thermal data structure is compared with the current time, if the comparison result is inconsistent, the thermal data structure is uploaded to a server, so that the server carries out order settlement, and an instruction is issued;
specifically, when the charging pile is unexpectedly interrupted (power failure, software crash, etc.), the FRAM can ensure that current writing or reading is completed in a low power mode (a low power mode is a double cycle: writing is to be erased first) because the work flow is direct writing or reading (a single cycle, flash is a double cycle: writing is to be erased first) because the charging pile is abnormally powered off, but because some capacitors are arranged on a main board, the capacitors have a discharging process after power failure, and a little time or work can be performed at this time), when power failure or crash occurs, hot data in the FRAM can be updated and completed, the FRAM has the characteristic of not being lost when power failure occurs, so that reading structural information in the FRAM after resetting can be compared with the current time to find that the time is not uniform, so that order state information in a check mark of a current hot data structure diagram is modified into a reset order and then uploaded to a server, the server can issue an instruction after settlement is completed, wherein the instruction includes, a charging abnormal instruction, and if the charging instruction is changed correspondingly, the charging instruction is an abnormal instruction, and if the charging instruction is changed correspondingly changed, the charging instruction is an abnormal instruction, and the charging instruction is changed correspondingly changed according to the charging instruction, the charging instruction is: "order exception: 00000C301 (error number) ".
And S107, after the charging is finished, checking that the mark is a charging finishing mark, uploading the thermal data structure body in the FRAM to a server so that the server can perform order settlement, issuing an order finishing instruction, and filing the thermal data structure body in Flash.
Illustratively, referring to fig. 2, the order settlement includes:
s701, receiving a thermal data structure;
s702, judging the legality of the thermal data structure by calculating the charging amount of each time period;
specifically, when the validity of the thermal data structure is judged, a normal range of the electric quantity deducted per hour can be obtained by analyzing the previous charging data, and thus, when the electric quantity deducted per hour exceeds the normal range, the order abnormality can be judged.
S703, if the thermal data structure is illegal, sending a charging failure instruction;
s704, if the hot data structure is legal, whether the hot data structure is tampered or not is verified through cyclic redundancy;
specifically, when determining whether the thermal data structure is tampered with, a CRC (cyclic redundancy check) algorithm is used to check the thermal data structure to determine whether the thermal data structure is tampered with by a lawbreaker.
S705, if the hot data structure body is tampered, a charging failure instruction is sent out;
s706, if the hot data structure body is not tampered, deducting money of a user;
and S707, sending a charging completion instruction after the deduction is completed.
And after receiving the hot data structure body at the receiving end, the server verifies the legality and whether the hot data structure body is tampered, and deducts money from the user after the verification is passed, so that the charging is finished to prepare for receiving a charging request of the next client.
In addition, after the server receives the thermal data structure, the state of the current order can be acquired through the order state information stored in the check mark position, so that whether the current order is the order in the normal state or the reset order after the charging pile is restarted after power failure can be judged.
Example two
The second embodiment of the application relates to a charging order anti-power-failure access device, including:
the system comprises a predefining module, a checking module and a processing module, wherein the predefining module is used for predefining a thermal data structure of a charging order, and the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value in each time period, order starting time, order current time and a checking mark;
the acquisition module is used for acquiring the initial ammeter reading and the order starting time when charging is started;
the first updating module is used for updating the thermal data structure body according to the initial electric meter reading and the order starting time and writing the updated data structure body into the FRAM;
the second updating module is used for reading the real-time electric meter reading and the order current time once every n seconds in the charging process, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0;
the third updating module is used for calculating the reading difference value between the current ammeter and the initial ammeter every N hours in the charging process, updating the reading difference value of the ammeter in each time period in the thermal data structure body according to the reading difference value, and writing the updated data structure body into the FRAM, wherein the number of the once-woven fabrics (0N) is less than or equal to 1;
the interruption analysis processing module is used for automatically updating the thermal data structure body in the FRAM when unexpected interruption occurs in the charging process, comparing the current time of the order in the thermal data structure body with the current time after the thermal data structure body is electrified again, and uploading the thermal data structure body to the server if the comparison result is inconsistent so that the server can perform order settlement and issue an instruction;
and the charging ending processing module is used for uploading the thermal data structure body in the FRAM to the server after the charging is ended and the check mark is a charging ending mark, so that the server can perform order settlement, issue an order finishing instruction and file the thermal data structure body in Flash.
EXAMPLE III
A computer-readable storage medium according to a third embodiment of the present application, storing program code for execution by a device, the program code including steps for performing a method according to any one of the first to third embodiments of the present application;
the computer readable storage medium may be a Read Only Memory (ROM), a static storage device, a dynamic storage device, or a Random Access Memory (RAM); the computer readable storage medium may store program code for performing the steps of the method as in any one of the implementations of the embodiment of the present application when the program stored in the computer readable storage medium is executed by the processor.
Example four
An electronic device according to a fourth embodiment of the present application includes a processor, a memory, and a program or an instruction stored in the memory and executable on the processor, where the program or the instruction, when executed by the processor, implements the method according to any one of the first embodiment of the present application;
the processor may adopt a general Central Processing Unit (CPU), a microprocessor, an Application Specific Integrated Circuit (ASIC), a Graphics Processing Unit (GPU), or one or more integrated circuits, and is configured to execute a related program, so as to implement the method in any implementation manner in the first embodiment of the present application.
The processor may also be an integrated circuit electronic device having signal processing capabilities. In implementation, each step of the method in any implementation manner of the first embodiment of the present application may be implemented by an integrated logic circuit of hardware in a processor or an instruction in the form of software.
The processor may also be a general purpose processor, a digital signal processor, an Application Specific Integrated Circuit (ASIC), an FPGA (field programmable gate array) or other programmable logic device, discrete gate or transistor logic, discrete hardware components. The various methods, steps, and logic blocks disclosed in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present application may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in a memory, and a processor reads information in the memory, and performs, in combination with hardware of the storage medium, functions required to be performed by a unit included in the data processing apparatus according to the embodiment of the present application, or performs a method according to any one implementation manner in the embodiment of the present application.
The above are merely preferred embodiments of the present application; the scope of protection of the present application is not limited thereto. Any person skilled in the art should be able to cover all equivalent or changes within the technical scope of the present disclosure, which is equivalent to the technical solution and the improvement concept of the present disclosure, and the protection scope of the present disclosure.
Claims (10)
1. A power-down access method for a charging subscription monoclonal antibody is characterized by comprising the following steps:
predefining a thermal data structure of a charging order, wherein the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value of each time interval, order starting time, order current time and a check mark;
acquiring initial ammeter reading and order starting time when charging is started;
updating the thermal data structure according to the initial electric meter reading and the order starting time, and writing the updated data structure into the FRAM;
in the charging process, reading the real-time electric meter reading and the order current time once every n seconds, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0;
in the charging process, reading difference values of the current ammeter and the initial ammeter are calculated every N hours, the reading difference values of the ammeters in all time periods in the thermal data structure body are updated according to the reading difference values, the updated data structure body is written into the FRAM, wherein the number of the once-woven fabrics is 0-1;
when accidental interruption occurs in the charging process, the thermal data structure body in the FRAM is automatically updated, after the power is turned on again, the current time of an order in the thermal data structure body is compared with the current time, if the comparison result is inconsistent, the thermal data structure body is uploaded to a server, so that the server performs order settlement, and an instruction is issued;
after charging is finished, the check mark is a charging finishing mark, the thermal data structure body in the FRAM is uploaded to the server, so that the server can perform order settlement, issue an order finishing instruction, and archive the thermal data structure body in Flash.
2. The method of claim 1, wherein the type of data used for the initial meter reading is a double-precision floating-point number for storing the meter value at the beginning of charging.
3. The method for power down access to charged monoclonal antibodies of claim 1, wherein said real-time meter reading is of the double precision floating point type for storing the charged real-time meter value.
4. The method for power down access to charged monoclonal antibodies of claim 1, wherein the data type used for the difference of the electric meter readings in each time period is a single-precision floating point number, and is used for storing the difference of the electric meter readings in each time period in a stepping manner.
5. The power-down access method for charged monoclonal antibodies according to claim 1, wherein the order start time is in a format of 32-bit unix timestamp for storing the start charging time, and the order current time is in a format of 32-bit unix timestamp for storing the real-time charging time.
6. The method for power down access to charged monoclonal antibodies of claim 1, wherein the check marks are used for storing order status information and cyclic redundancy check codes, and the cyclic redundancy check is performed on the thermal data structure each time the thermal data structure is updated.
7. The charging monoclonal antibody power down access method according to any one of claims 1-6, wherein the order settlement comprises:
receiving a thermal data structure;
judging the legality of the thermal data structure by calculating the charging amount of each time period;
if the thermal data structure is illegal, a charging failure instruction is sent out;
if the hot data structure is legal, checking whether the hot data structure is tampered through cyclic redundancy;
if the hot data structure body is tampered, a charging failure instruction is sent out;
if the hot data structure body is not tampered, deducting money of a user;
and after the deduction is completed, sending a charging completion instruction.
8. The utility model provides a charging order anti-power-down access arrangement which characterized in that includes:
the system comprises a predefining module, a checking module and a processing module, wherein the predefining module is used for predefining a thermal data structure of a charging order, and the thermal data structure comprises an initial ammeter reading, a real-time ammeter reading, an ammeter reading difference value in each time period, order starting time, order current time and a checking mark;
the acquisition module is used for acquiring the initial ammeter reading and the order starting time when charging is started;
the first updating module is used for updating the thermal data structure body according to the initial electric meter reading and the order starting time and writing the updated data structure body into the FRAM;
the second updating module is used for reading the real-time electric meter reading and the order current time once every n seconds in the charging process, updating the thermal data structure body according to the real-time electric meter reading and the order current time, and writing the updated data structure body into the FRAM, wherein n is larger than 0;
the third updating module is used for calculating the reading difference value between the current ammeter and the initial ammeter every N hours in the charging process, updating the reading difference value of the ammeter in each time period in the thermal data structure body according to the reading difference value, and writing the updated data structure body into the FRAM, wherein the number of the once-woven fabrics (0N) is less than or equal to 1;
the interruption analysis processing module is used for automatically updating the thermal data structure body in the FRAM when unexpected interruption occurs in the charging process, comparing the current time of the order in the thermal data structure body with the current time after the thermal data structure body is electrified again, and uploading the thermal data structure body to the server if the comparison result is inconsistent so that the server can perform order settlement and issue an instruction;
and the charging end processing module is used for checking that the mark is a charging end mark after charging is finished, uploading the thermal data structure body in the FRAM to the server so as to enable the server to settle orders, issue an order finishing instruction and archive the thermal data structure body in Flash.
9. A computer-readable storage medium, characterized in that the computer-readable medium stores program code for execution by a device, the program code comprising steps for performing the method according to any one of claims 1-7.
10. An electronic device, comprising a processor, a memory, and a program or instructions stored on the memory and executable on the processor, which when executed by the processor, implement the method of any of claims 1-7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211633761.1A CN115829689A (en) | 2022-12-19 | 2022-12-19 | Power-down access method and device for charging subscription monoclonal antibody |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211633761.1A CN115829689A (en) | 2022-12-19 | 2022-12-19 | Power-down access method and device for charging subscription monoclonal antibody |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115829689A true CN115829689A (en) | 2023-03-21 |
Family
ID=85516684
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211633761.1A Pending CN115829689A (en) | 2022-12-19 | 2022-12-19 | Power-down access method and device for charging subscription monoclonal antibody |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115829689A (en) |
-
2022
- 2022-12-19 CN CN202211633761.1A patent/CN115829689A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8244642B2 (en) | System and method for storing metering data while increasing memory endurance | |
EP1218821B1 (en) | Improved memory integrity for meters | |
WO2018072455A1 (en) | Electric energy meter, checking method therefor, and storage medium | |
CA2577469C (en) | Firmware power cycle routine | |
WO1984004381A1 (en) | Electronic odometer | |
EP0190141A1 (en) | Hourmeter apparatus and method. | |
CN115829689A (en) | Power-down access method and device for charging subscription monoclonal antibody | |
CN115631065B (en) | File accuracy detection method based on front-end power utilization business change | |
CN111025223B (en) | Clock correction method, device, equipment and storage medium of electric energy meter | |
CN113820649B (en) | Method and device for testing service life reliability of firmware of electric energy meter | |
EP0274045A1 (en) | Electronic odometer | |
CN104200835A (en) | Method for recognizing a power outage in a data memory and recovering the data memory | |
CN115309342A (en) | Data storage method and device and electric energy meter | |
CN112946562A (en) | Power failure protection method and device for double-core intelligent electric meter and double-core intelligent electric meter | |
CN112613945A (en) | Method, device, equipment and storage medium for determining lease plan | |
CN116301665B (en) | Metering data storage method, metering data storage device, computer equipment and storage medium | |
CN114048078B (en) | Memory capacity testing method and device and electronic equipment | |
CN115932711B (en) | Data processing method, device and medium for metering reliability of electric energy meter | |
CN115878504A (en) | Rolling storage method and device of electric energy meter and electronic equipment | |
CN116386169A (en) | Vehicle data processing method and device, electronic equipment and storage medium | |
CN113298974A (en) | Dust sensor output correction method, device, equipment and storage medium | |
CN118886902A (en) | Oil purchase order payment method, device, computer equipment and storage medium | |
CN117968803A (en) | Gas meter testing method, device, controller and storage medium | |
CN118372655A (en) | Mileage synchronization method and automobile | |
CN114819498A (en) | Agricultural emission prepayment checking method, device and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |