Data calling method, system, dual-chip sales terminal and readable storage medium

By implementing the data call method on the security chip and application chip of the dual-chip sales terminal, the problem of difficulty in data transmission between chips is solved, and data peer-to-peer and efficient data processing are realized.

CN113177202BActive Publication Date: 2025-04-15NEW POS TECH
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202011059272.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-30
Publication Date
2025-04-15
Estimated Expiration
2040-09-30

AI Technical Summary

Technical Problem

In existing dual-chip sales terminals, data transmission is difficult between security chips and application chips, resulting in data ambiguous problems.

Method used

By implementing data calling methods on the security chip and application chip, the application chip sends call commands to the security chip, the security chip performs system calls and feedbacks the results, and data transmission across chips is realized.

Benefits of technology

It realizes data transmission between the secure chip and the application chip, solves the problem of data aberration and improves the system's data processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113177202B_ABST
    Figure CN113177202B_ABST
Patent Text Reader

Abstract

The present application is applicable to the field of sales terminal technology, and provides a data calling method, including: a security chip receives a calling command sent by an application chip, and the calling command includes a function name and parameters of a target calling function. The calling command is parsed to obtain the function name included in the calling command, a system call is made through the target calling function, a calling result is obtained, and the calling result is fed back to the application chip. According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data calling result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the technical field of sales terminals, and in particular, relates to a data calling method, system, dual-chip sales terminal and readable storage medium. Background Art

[0002] In existing dual-chip sales terminals, since the security chip is an independently running system, the data in the security chip is only processed and transmitted inside the security chip. The application chip cannot obtain the data of the security chip, making it difficult to transmit data between the dual chips, resulting in unequal data at both ends. Summary of the invention

[0003] The embodiments of the present application provide a data calling method, apparatus, terminal device and readable storage medium, which can solve the problem that the existing data communication method based on dual-chip sales terminals is difficult to transmit data between the dual chips, resulting in unequal data at both ends.

[0004] In a first aspect, an embodiment of the present application provides a data calling method, which is applied to a security chip, comprising:

[0005] Receiving a call command sent by the application chip; wherein the call command includes a function name and parameters of a target call function;

[0006] Parsing the calling command to obtain the function name included in the calling command;

[0007] A system call is performed through the target calling function to obtain a calling result, and the calling result is fed back to the application chip; wherein the calling result includes a function calling result and an error code.

[0008] In a second aspect, an embodiment of the present application provides a data calling method, which is applied to an application chip, including:

[0009] Sending a call command to the security chip so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function;

[0010] The calling result returned by the security chip is received and parsed to obtain the parsed function calling result; wherein the calling result includes the function calling result and an error code.

[0011] In a third aspect, an embodiment of the present application provides a data calling system, which is applied to a security chip, including:

[0012] A receiving module, used for receiving a calling command sent by the application chip; wherein the calling command includes a function name and parameters of a target calling function;

[0013] A first parsing module, used for parsing the calling command to obtain the function name included in the calling command;

[0014] The calling module is used to make a system call through the target calling function, obtain a calling result, and feed back the calling result to the application chip; wherein the calling result includes a function calling result and an error code.

[0015] In a fourth aspect, an embodiment of the present application provides a data calling system, which is applied to an application chip, including:

[0016] A first sending module is used to send a call command to the security chip so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function;

[0017] The second parsing module is used to receive and parse the call result returned by the security chip to obtain the parsed function call result; wherein the call result includes the function call result and an error code.

[0018] In the fifth aspect, an embodiment of the present application provides a dual-chip sales terminal, including a security chip, an application chip, and a computer program stored and executable on the security chip and the application chip, wherein the security chip implements the data calling method described in the first aspect when executing the computer program, and the application chip implements the data calling method described in the second aspect when executing the computer program.

[0019] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the data calling method as described in the first aspect or the second aspect above is implemented.

[0020] In a seventh aspect, an embodiment of the present application provides a computer program product. When the computer program product runs on a terminal device, the terminal device executes the data calling method described in the first aspect or the second aspect above.

[0021] According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data call result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.

[0022] It can be understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0024] Figure 1 It is a flowchart of the data calling method provided in the embodiment of the present application;

[0025] Figure 2 is a flowchart of a data calling method provided by another embodiment of the present application;

[0026] Figure 3 is a schematic diagram of a data transmission software framework between an application chip and a security chip provided in an embodiment of the present application;

[0027] Figure 4 It is a structural diagram of a data calling system provided in an embodiment of the present application;

[0028] Figure 5 is a structural diagram of a data calling system provided by another embodiment of the present application;

[0029] Figure 6 It is a structural schematic diagram of a dual-chip sales terminal provided in an embodiment of the present application. DETAILED DESCRIPTION

[0030] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.

[0031] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.

[0032] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0033] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.

[0034] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.

[0035] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.

[0036] The data calling method provided in the embodiment of the present application can be applied to terminal devices such as dual-chip sales terminals, and the embodiment of the present application does not impose any restrictions on the specific type of terminal devices.

[0037] Embodiment 1

[0038] Figure 1 A schematic flow chart of the data calling method provided in the present application is shown. As an example but not a limitation, the method can be applied to a security chip.

[0039] S101, receiving a call command sent by an application chip; wherein the call command includes a function name and parameters of a target call function;

[0040] In a specific application, a call command sent by an application chip (Application processor, AP) is received. The call command refers to a command sent by the application chip to control the security chip (Security processor, SP) to make a system call according to a target call function. The call command should include but is not limited to the function name and parameters of the target call function. The function name can be a string, for example, the function name of the target call function can be rpc_open, rpc_ioctl, rpc_close or read.

[0041] For example, if a data reading function needs to be called, the corresponding calling command received from the application chip should include the name of the data reading function read and the parameters of the data reading function.

[0042] S102, parsing the calling command to obtain the function name included in the calling command;

[0043] In a specific application, the received calling command is parsed to obtain the function name of the target calling function contained in the calling command to determine the target calling function.

[0044] S103, performing a system call through the target calling function, obtaining a calling result, and feeding back the calling result to the application chip; wherein the calling result includes a function calling result and an error code.

[0045] In a specific application, further analysis is performed to obtain the parameters of the target calling function in the calling command, and the above parameters are passed into the target calling function to implement a system call through the target calling function, obtain a function calling result corresponding to the target calling function, and package the function calling result and error code to generate a calling result and send it to the application chip. It is understandable that the calling result includes but is not limited to the function calling result and error code.

[0046] For example, if the target calling function is a data reading function (read), a data reading operation is performed through the data reading function, and the read data and error code are packaged to generate a calling result and send it to the application chip.

[0047] The error code is a code generated when an error occurs when making a system call through the target calling function. It is understood that if the system call is successful through the target calling function, the corresponding error code is 0 or empty. If the system call fails through the target calling function, the corresponding function call result is empty.

[0048] In one embodiment, before step S101, the following steps are included:

[0049] A communication protocol with the application chip is preset, and the communication protocol is used to set the format of the calling command.

[0050] In a specific application, before making a system call, the communication protocol between the security chip and the application chip can be preset; the communication protocol is used to set the format of the call command sent by the application chip.

[0051] In this embodiment, the communication protocol stipulates that the call command sent by the application chip must include a protocol header, a function name (in string form) of the target call function, and parameters of the target call function. For example, the format of the call command is: protocol header, function name, parameters.

[0052] In one embodiment, the communication protocol is also used to set the format of the call result sent by the security chip. For example, the call result sent by the communication protocol to the security chip must include a protocol header, a function call result, and an error code. For example, the format of the call result is: protocol header, function call result, error code. After making a system call through the target call function, the security chip needs to package the protocol header, function call result, and error code to generate a call result.

[0053] In one embodiment, before step S101, the method further includes:

[0054] When receiving the registration notification instruction sent by the application chip, completing the registration notification according to the registration notification instruction;

[0055] When trigger data is detected, a notification is generated according to the trigger data, and the notification is sent to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end.

[0056] In a specific application, when a registration notification instruction is received from an application chip, a registration notification is performed according to the registration instruction; when trigger data is detected, a corresponding notification is generated according to the trigger data, and the notification is sent to the application chip. Among them, the registration notification refers to a mode in which a corresponding notification is generated according to the trigger data when trigger data is received, and the notification is used to notify the application chip that the trigger data is detected on the security chip side. The trigger data can be key information detected by the security chip, IC card insertion or IC card removal, and other data that triggers different functional operations.

[0057] For example, if the security chip detects the insertion of an IC card, an IC card insertion notification is generated based on the IC card insertion data, and the IC card insertion notification is sent to the application chip to notify the application chip that the IC card insertion is detected at the security chip end. The IC card insertion data may include information such as the time of IC card insertion and the ID of the IC card.

[0058] According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data call result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.

[0059] Embodiment 2

[0060] Figure 2 Another schematic flow chart of the data calling method provided in the present application is shown. As an example but not a limitation, the method can be applied to an application chip.

[0061] S201, sending a call command to the security chip, so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function;

[0062] In a specific application, when generating a call command, the application chip first calls the pre-set unified encapsulation interface in the sales terminal software development toolkit POS SDK library, and encapsulates the protocol header, the function name and parameters of the target call function through the interface to generate the corresponding call command, and sends the call command to the security chip, so that the security chip performs a system call of the target call function according to the protocol data. The pre-set unified encapsulation interface can be specifically set according to actual needs, for example, the pre-set unified encapsulation interface is any open interface (for example, xxx_open() interface).

[0063] S202: Receive and parse the call result returned by the security chip to obtain the parsed function call result; wherein the call result includes the function call result and an error code.

[0064] In a specific application, the call result returned by the security chip is received, and the call result is parsed to obtain the parsed function call result; wherein the call result includes but is not limited to the function call result and the error code. The error code is a code generated when an error occurs when making a system call through the target call function. It is understandable that if the system call is successful through the target call function, the corresponding error code is 0 or empty. If the system call fails through the target call function, the function call result is empty.

[0065] For example, if the target calling function is a data reading function read, the calling result includes the read data and an error code.

[0066] In one embodiment, before step 201, the following steps are included:

[0067] Sending a registration notification instruction to the security chip, so that the security chip performs registration notification according to the registration notification instruction;

[0068] The monitoring mode is started, and when a notification sent by the security chip is monitored, a corresponding call command is generated according to the notification.

[0069] In a specific application, a registration notification instruction is sent to the security chip, so that the security chip performs registration notification according to the registration notification instruction when receiving the registration notification instruction, so that when the security chip detects trigger data, a corresponding notification is generated and fed back; the select monitoring mode is started, and when the notification sent by the security chip is monitored, a corresponding call command is generated according to the notification.

[0070] For example, if the notification shows that an IC card is detected to be inserted into the security chip, a data read call command is generated (the data read call command includes the name of the data read function read and the parameters of the data read function), and the data read call command is sent to the security chip to control the security chip to perform a data read operation according to the data read function (read) contained in the data read call command.

[0071] In one embodiment, before step 201, the method further includes:

[0072] A socket interface is created, where the socket interface is used to receive the call result and the notification.

[0073] In a specific application, a socket interface is created in advance, and the socket interface is used to receive the call result and notification sent by the security chip.

[0074] like Figure 3 As shown, a schematic diagram of a data transmission software framework between an application chip and a security chip is provided.

[0075] like Figure 3 As shown, on the application chip side, a socket-based inter-process communication layer is added between the sales terminal software development kit POS SDK and the Universal Asynchronous Receiver / Transmitter (UART) to achieve multi-client connection and data transmission.

[0076] Before sending the registration notification, the application chip can send an open function (open) call command to the security chip: call the preset open interface in the POS SDK (for example, xxx_open interface) through the application layer, the preset open interface sends the open function (open) call command to the security chip, the security chip executes the system call in the open function rpc_open, and after the security chip successfully executes the open function system call, it returns sp_fd to the above preset open interface, indicating that the open function system call is successful and the open access function is realized.

[0077] After the application chip successfully calls the open function system, it can create a pair of interconnected sockets (the socket can be an unnamed socket for easy data transmission). The socket includes a read handle sv[0] and a write handle sv[1]. When the application chip sends the registration notification command to the security chip, it creates a listening thread and passes the write handle sv[1] as a parameter to the above thread. At the same time, it calls select to listen to the read and write handles of the socket client, and sends the read handle sv[0] to the application layer, so that the application layer adds the read handle sv[0] to the select listening.

[0078] When the application chip receives a notification from the security chip through select monitoring, it reads the data in the notification and writes 1 byte of data to the write handle sv[1] to wake up the select monitoring of the application layer. When the application monitors the notification received by the socket read handle sv[0] through select, it calls any data read interface (for example, xxx_read) of the POS SDK to read the data in the write handle sv[1], generates a corresponding data read call command according to the data contained in the notification, and sends it to the security chip for system call. At the same time, the socket service is connected. When the universal asynchronous receiver and transmitter UART receives the call result fed back by the security chip SP, it sends the call result to the corresponding socket client and to the POS SDK. The POS SDK parses the call result and returns the function call result and error code obtained after parsing to the application layer to realize the select function of dual-processor compatibility with single-processor and improve the efficiency of data transmission between dual chips.

[0079] According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data call result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.

[0080] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0081] Embodiment 3

[0082] Corresponding to the data calling method described in the first embodiment above, Figure 4 A structural block diagram of a data calling system 100 provided in an embodiment of the present application is shown, which is applied to a security chip. For ease of explanation, only the parts related to the embodiment of the present application are shown.

[0083] Reference Figure 4 , the data calling system 100 comprises:

[0084] A receiving module, used for receiving a calling command sent by the application chip; wherein the calling command includes a function name and parameters of a target calling function;

[0085] A first parsing module, used for parsing the calling command to obtain the function name included in the calling command;

[0086] The calling module is used to make a system call through the target calling function, obtain a calling result, and feed back the calling result to the application chip; wherein the calling result includes a function calling result and an error code.

[0087] In one embodiment, the data calling system 100 further includes:

[0088] The setting module is used to pre-set the communication protocol between the application chip and the application chip, and the communication protocol is used to set the format of the calling command.

[0089] In one embodiment, the data calling system 100 further includes:

[0090] A registration module, configured to complete the registration notification according to the registration notification instruction when receiving the registration notification instruction sent by the application chip;

[0091] A generating module is used to generate a notification according to the trigger data when trigger data is detected, and send the notification to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end.

[0092] According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data call result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.

[0093] Embodiment 4

[0094] Corresponding to the data calling method described in the second embodiment above, Figure 5 A structural block diagram of a data calling system 200 provided in an embodiment of the present application is shown, which is applied to an application chip. For ease of explanation, only the parts related to the embodiment of the present application are shown.

[0095] Reference Figure 5 , the data calling system 200 comprises:

[0096] The first sending module 201 is used to send a call command to the security chip so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function;

[0097] The second parsing module 202 is used to receive and parse the call result returned by the security chip to obtain the parsed function call result; wherein the call result includes the function call result and an error code.

[0098] In one embodiment, the data calling system 200 further includes:

[0099] A second sending module is used to send a registration notification instruction to the security chip, so that the security chip performs a registration notification according to the registration notification instruction;

[0100] The monitoring module is used to start the monitoring mode and generate a corresponding call command according to the notification when monitoring the notification sent by the security chip.

[0101] The data calling system 200 further includes:

[0102] A creation module is used to create a socket interface, and the socket interface is used to receive the call result and the notification.

[0103] According to the calling instruction carrying the function name of the target function, a system call is made in the target function, so that the application chip can directly obtain the data call result of the security chip, realize the system call across chips, and improve the data processing efficiency of the system.

[0104] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.

[0105] Figure 6 This is a schematic diagram of the structure of a dual-chip point of sale (POS) terminal provided in one embodiment of the present application. Figure 6 As shown, the dual-chip sales terminal 6 of this embodiment includes: a security chip 60, an application chip 61, a computer program 62 stored and executable on the security chip 60, and a computer program 63 stored and executable on the application chip 61. When the security chip 60 executes the computer program 62, the steps of the data calling method in the above-mentioned embodiment 1 are implemented, and when the application chip 61 executes the computer program 63, the steps of the data calling method in the above-mentioned embodiment 2 are implemented.

[0106] The dual-chip sales terminal 6 can be a sales terminal or other equipment. The dual-chip sales terminal can include, but is not limited to, a security chip 60 and an application chip 61. Those skilled in the art can understand that Figure 6It is only an example of the dual-chip sales terminal 6 and does not constitute a limitation on the dual-chip sales terminal 6. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components, for example, it may also include input and output devices, network access devices, etc.

[0107] The so-called security chip 60 may be a security processor (SP); the so-called application chip 61 may be an application processor (AP).

[0108] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0109] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned method embodiments can be implemented.

[0110] An embodiment of the present application provides a computer program product. When the computer program product runs on a mobile terminal, the mobile terminal can implement the steps in the above-mentioned method embodiments when executing the computer program product.

[0111] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, the steps of the above-mentioned various method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device that can carry the computer program code to the camera device / dual-chip sales terminal, recording medium, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, RandomAccess Memory), electric carrier signal, telecommunication signal and software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.

[0112] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0113] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0114] In the embodiments provided in the present application, it should be understood that the disclosed devices / network equipment and methods can be implemented in other ways. For example, the device / network equipment embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0115] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0116] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. A data calling method, characterized in that: Applied to security chips, including: Receiving a call command sent by the application chip; wherein the call command includes a function name and parameters of a target call function; Parsing the calling command to obtain the function name included in the calling command; Performing a system call through the target calling function, obtaining a calling result, and feeding back the calling result to the application chip; wherein the calling result includes a function calling result and an error code; Before receiving the call command sent by the application chip, the method further includes: When receiving the registration notification instruction sent by the application chip, completing the registration according to the registration notification instruction; When trigger data is detected, a notification is generated based on the trigger data and the notification is sent to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end, and the trigger data is data detected at the security chip that triggers different functional operations, including: key information, IC card insertion or IC card removal.

2. The data calling method according to claim 1, characterized in that: Before receiving the call command sent by the application chip, the method includes: A communication protocol with the application chip is preset, and the communication protocol is used to set the format of the calling command.

3. A data calling method, characterized in that: Applied to application chips, including: Sending a call command to the security chip so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function; Receiving and parsing the call result returned by the security chip to obtain the parsed function call result; wherein the call result includes the function call result and an error code; The sending of the call command to the security chip so that the security chip performs a system call according to the protocol data includes: Send a registration notification instruction to the security chip so that the security chip is registered according to the registration notification instruction; when the security chip detects trigger data, generate a notification according to the trigger data, and send the notification to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end, and the trigger data is data that triggers different functional operations detected by the security chip, including: key information, IC card insertion or IC card removal.

4. The data calling method according to claim 3, characterized in that: The method further includes: starting a monitoring mode, and when a notification sent by the security chip is monitored, generating a corresponding call command according to the notification.

5. The data calling method according to claim 4, characterized in that: Before sending the call command to the security chip so that the security chip performs a system call according to the protocol data, the method further includes: A socket interface is created, where the socket interface is used to receive the call result and the notification.

6. A data calling system, characterized in that: Applied to security chips, including: A receiving module, used for receiving a calling command sent by the application chip; wherein the calling command includes a function name and parameters of a target calling function; A first parsing module, used for parsing the calling command to obtain the function name included in the calling command; A calling module, used to make a system call through the target calling function, obtain a calling result, and feed back the calling result to the application chip; wherein the calling result includes a function calling result and an error code; The data calling system further includes: A registration module, configured to complete registration according to the registration notification instruction when receiving the registration notification instruction sent by the application chip; A generation module is used to generate a notification according to the trigger data when trigger data is detected, and send the notification to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end, and the trigger data is data detected at the security chip that triggers different functional operations, including: key information, IC card insertion or IC card removal.

7. A data calling system, characterized in that: Applied to application chips, including: A first sending module is used to send a call command to the security chip so that the security chip performs a system call according to the protocol data; wherein the call command includes a function name and parameters of a target call function; A second parsing module is used to receive and parse the call result returned by the security chip to obtain the parsed function call result; wherein the call result includes the function call result and an error code; The data calling system further includes: The second sending module is used to send a registration notification instruction to the security chip so that the security chip is registered according to the registration notification instruction; when the security chip detects trigger data, a notification is generated according to the trigger data, and the notification is sent to the application chip; wherein the notification is used to notify the application chip that the trigger data is detected at the security chip end, and the trigger data is data that triggers different functional operations detected at the security chip, including: key information, IC card insertion or IC card removal.

8. The data calling system according to claim 7, characterized in that: The data calling system further includes: The monitoring module is used to start the monitoring mode and generate a corresponding call command according to the notification when monitoring the notification sent by the security chip.

9. A dual-chip sales terminal, comprising a security chip, an application chip, and a computer program stored and executable on the security chip and the application chip, characterized in that: When the security chip executes the computer program, the method according to any one of claims 1 to 2 is implemented; when the application chip executes the computer program, the method according to any one of claims 3 to 5 is implemented.

Citation Information

Patent Citations

  • An information security-oriented embedded computer SiP module design method and circuit

    CN109697173A