A capability sharing method, device and medium based on intelligent POS device
By installing applications on smart POS devices and using the Zeroconf protocol and peer-to-peer technology to achieve automatic device discovery and encrypted communication, the problem of fixed functions of traditional smart POS devices is solved, flexible, efficient and secure capability sharing between devices is achieved, and device interoperability and user experience are improved.
Patent Information
- Application Number
- CN202311545166.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-20
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2043-11-20
AI Technical Summary
Traditional smart POS devices have fixed hardware functions, which makes them unable to meet emerging business needs. The functions of devices vary greatly and are difficult to share. Existing communication protocols have problems such as low communication efficiency, single point failure risks, lack of offline support, and privacy and security risks.
It uses applications to manage device capabilities, utilizes the Zeroconf protocol and peer-to-peer technology to achieve automatic device discovery and connection, ensures security through encrypted communication, supports offline operation, and shares capability information and hardware functions between devices.
It achieves flexible, efficient and secure capability sharing among different smart POS devices, reduces development and maintenance costs, improves device interoperability and user experience, and meets the diverse needs of merchants and users.
Smart Images

Figure CN117593831B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of smart POS technology, and in particular to a capability sharing method, device and medium based on smart POS devices. Background Art
[0002] Smart POS (Point of Sale) devices play a vital role in the commercial sector, processing key tasks such as transactions, payments, and data management. However, traditional smart POS devices typically have fixed hardware capabilities, which can hinder their ability to meet emerging demands in an ever-changing business environment. Furthermore, because different models of smart POS devices typically have varying hardware capabilities, functional differences exist between them, making it difficult for merchants and developers to share capabilities across devices.
[0003] Traditionally, to share device capabilities, developers typically need to use different SDKs (Software Development Kits) or APIs (Application Programming Interfaces) to adapt to the capabilities of each device. These capabilities may vary depending on the device type, hardware specifications, or manufacturer. Figure 1 This paper demonstrates how to adapt device capabilities using traditional approaches, which can be limited by hardware and interface constraints. This approach is limited in that it requires custom code for each device, increasing development and maintenance costs and time. Furthermore, these approaches often rely on specific operating systems and hardware, limiting the application of capability sharing across different platforms.
[0004] Another way to share device capabilities is to use communication protocols such as MQTT or WebSocket. Figure 2 and Figure 3 This paper presents a device sharing method based on MQTT and WebSocket. This method leverages network communication protocols to enable devices to share their capabilities. Although these technologies perform well in various application scenarios and are widely used for inter-device communication, they also have some significant limitations, including:
[0005] Inefficient communication: Communication protocols such as MQTT and WebSocket can sometimes result in high communication latency, especially in poor network conditions or with limited bandwidth. This can affect the real-time nature of interactions and cause inconvenience for certain applications requiring high real-time performance.
[0006] Single point of failure risk: When establishing communication connections using these protocols, it is usually necessary to rely on a central server or proxy to coordinate and forward messages. If the central server fails or is interrupted, the entire communication system may be affected, resulting in communication interruption between devices.
[0007] Inability to provide full offline support: Protocols such as MQTT and WebSocket typically require devices to remain online for communication. This may not be suitable for applications that require offline operation, as the device must always be connected and cannot work properly in an environment with no network connection or connection.
[0008] Privacy and security risks: These communication protocols may pose certain privacy and security risks when transmitting data. Unencrypted data transmission may be vulnerable to eavesdropping or man-in-the-middle attacks, thereby exposing sensitive information.
[0009] Low resource utilization: Communication protocols such as MQTT and WebSocket may occupy a large amount of network bandwidth and system resources when transmitting data between devices. Especially in the case of frequent communication, this may lead to low resource utilization and affect device performance.
[0010] Higher costs: Maintaining and managing MQTT or WebSocket communication systems typically requires additional costs, including the operation and maintenance of server and network infrastructure, as well as the energy costs required to keep devices online.
[0011] Considering the above limitations, while communication protocols such as MQTT and WebSocket are useful in certain scenarios, they are not suitable for all smart POS device capability sharing requirements. Therefore, a more flexible, efficient, and secure method is needed to meet the capability sharing requirements between different devices. Summary of the Invention
[0012] In light of this, the present invention aims to propose a capability sharing method based on smart POS devices, allowing different smart POS devices to share their capabilities, thereby expanding their hardware functionality and improving efficiency. This enables different smart POS devices to collaborate and fully utilize their resources, providing merchants and end users with more convenient and efficient services to meet evolving business needs.
[0013] In order to achieve the above technical objectives, the technical solution adopted by the present invention is:
[0014] The present invention provides a capability sharing method based on an intelligent POS device, comprising the following steps:
[0015] Step 1: Install an application on each smart POS device to manage device capabilities.
[0016] Step 2: When a smart POS device needs to access the capabilities of other smart POS devices, the smart POS device is used as a requesting device. The requesting device uses the application to find other smart POS devices in the same local area network and establish a communication connection.
[0017] Step 3: The requesting device uses an application to find an available target device in the local area network;
[0018] Step 4: The requesting device sends a service request to the target device through the application program;
[0019] Step 5: After receiving the service request, the target device performs authorization verification on the requesting device. After the verification is successful, the target device processes the service request, generates a response, and sends it back to the requesting device.
[0020] Step 6: After receiving the response, the requesting device processes the response as needed;
[0021] Step 7: After the target device capability sharing is completed, the smart POS devices are disconnected.
[0022] Furthermore, the application is configured with a capability sharing management module, a communication module, a local storage module, a data format processing module and a request processing module;
[0023] The capability sharing management module is used to register the capability information of the smart POS device itself and maintain the capability list of the smart POS device;
[0024] The communication module uses the Zeroconf protocol and point-to-point technology. The Zeroconf protocol has automatic site selection and service discovery functions. The point-to-point technology is responsible for point-to-point communication connections between smart POS devices. The communication module is also configured with multiple protocol interfaces of different communication protocol types, which are used to respond to corresponding communication protocols.
[0025] The local storage module is responsible for storing the pre-configured unique identifier of the smart POS device and the authorization information for accessing the sharing function;
[0026] The data format processing module is responsible for performing data format conversion and data encapsulation;
[0027] The request processing module is responsible for processing service requests and responses.
[0028] Furthermore, the requesting device in step 2 uses an application to find other smart POS devices in the same local area network and establish a communication connection; specifically, the process includes:
[0029] Step 21: The requesting device automatically discovers other smart POS devices in the same local area network through the Zeroconf protocol in the communication module of the application;
[0030] Step 22: The requesting device establishes a point-to-point communication connection with other smart POS devices in the same local area network through the point-to-point technology in the communication module of the application.
[0031] Furthermore, the step 3 specifically includes:
[0032] Step 31: The requesting device queries the capability information of other smart POS devices in the same local area network through the application program;
[0033] Step 32: The requesting device finds all available smart POS devices in the same local area network according to the access purpose and the query result;
[0034] Step 33: If the number of all available smart POS devices is 1, the smart POS device is used as the target device; if the number of all available smart POS devices is greater than 1, one of the smart POS devices is selected as the target device.
[0035] Furthermore, in step 31, the capability information of other smart POS devices in the same local area network is queried by broadcasting in the local area network, scanning a QR code, or manually entering a device identifier.
[0036] When broadcasting within a local area network (LAN), each smart POS device automatically broadcasts its available capabilities, including printing, code scanning, and card reading services, using the Zeroconf protocol. The requesting device monitors the broadcast content and automatically discovers the capabilities of other smart POS devices within the same LAN using the Zeroconf protocol.
[0037] When using the QR code scanning method, each smart POS device generates a QR code carrying its own capability information. The requesting device scans the QR code generated by each smart POS device in the same local area network and obtains the corresponding capability information.
[0038] When manually inputting device identifiers, manually input the unique identifier of each smart POS device in the same local area network, determine the corresponding smart POS device based on the unique identifier, and find the corresponding capability information from the capability sharing management module in the application of the smart POS device.
[0039] Furthermore, the step 4 specifically includes:
[0040] Step 41: The requesting device initiates a service request, where the service request includes a data format of the service request, a unique identifier of the requesting device, authorization information of the requesting device, and request data of the shared target device capability.
[0041] Step 42: encrypt the service request;
[0042] Step 43: The requesting device sends the encrypted service request to the target device via the selected communication protocol.
[0043] Furthermore, the step 5 specifically includes:
[0044] Step 51: The protocol interface in the application of the target device that is compatible with the communication protocol selected by the requesting device responds to the communication protocol, receives the encrypted service request, and then decrypts the encrypted service request;
[0045] Step 52: After decryption, the service request is obtained, including the data format of the service request, the unique identifier of the requesting device, the authorization information of the requesting device, and the request data of the shared target device capabilities;
[0046] Step 53: Determine whether the data format of the service request is consistent with the data format that the target device can read. If so, proceed to step 54; otherwise, convert the data format of the service request into a data format that the target device can read through the data format processing module of the application.
[0047] Step 54: Verify whether the identity of the requesting device is legitimate based on the unique identifier of the requesting device. If so, proceed to step 55; otherwise, end the process;
[0048] Step 55: Verify whether the requesting device has the access right to capability sharing based on the authorization information of the requesting device. If so, proceed to step 56; otherwise, end the process.
[0049] Step 56: The request processing module of the application processes the request data for sharing the target device capabilities, determines the hardware functions required to be used in the target device based on the request data for sharing the target device capabilities, and activates the corresponding hardware components. The target device then executes the corresponding functions through the hardware components.
[0050] Step 57: If access information is required in the request data for sharing the target device's capabilities, the target device will provide the required access information;
[0051] Step 58: The target device generates response data, and encapsulates the response data through the data format processing module of the application program and sends the response data back to the requesting device.
[0052] Furthermore, the step 6 specifically includes:
[0053] Step 61: After receiving the encapsulated response data, the requesting device performs parsing processing to obtain a parsing result;
[0054] Step 62: The application is further configured with an interface display module. If the requesting device needs to display the parsing result to the end user, the parsing result is displayed through the interface display module of the application;
[0055] Step 63: Generate a report based on the analysis results and record the transaction information.
[0056] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the method for sharing capabilities based on a smart POS device as described above is implemented.
[0057] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-mentioned capability sharing method based on an intelligent POS device.
[0058] By adopting the above technical solution, the present invention has the following beneficial effects compared with the prior art:
[0059] Capability Sharing and Expansion: This invention allows different smart POS devices to share their capabilities. This means that merchants can simply install an application to transform a single smart POS device into a collaborative platform for multiple devices. This allows merchants to easily expand the capabilities of their devices without investing in additional hardware.
[0060] Improved efficiency: By sharing device capabilities, different smart POS devices can work together, avoiding idle resources and wasting resources. Merchants can handle customer needs more efficiently and provide faster and higher-quality services.
[0061] Reduced risk of failure: The present invention uses applications to establish communication connections, without relying on a central server or proxy to coordinate and forward messages. If the central server fails or is interrupted, it will not affect communication between devices.
[0062] Offline support: Instead of deploying services over the internet, devices can be shared through interconnected applications on the local area network (LAN), reducing overall operating costs. By leveraging the LAN and Zeroconf peer-to-peer technology, different devices can automatically discover, share, and expand their hardware capabilities, such as printing, barcode scanning, and card reading. This not only improves interoperability between smart POS devices, but also provides merchants and users with more flexible and powerful payment and management solutions while reducing development and maintenance complexity.
[0063] Privacy and security: An encryption mechanism is added during data transmission to ensure the security of data transmission.
[0064] Resource Conservation: Compared to traditional hardware expansion methods, this method saves hardware resources and costs. Merchants do not need to purchase additional equipment, but can simply share equipment through interconnected applications, reducing overall operating costs.
[0065] Develop once, run everywhere: The application can be installed and run on different smart POS devices, regardless of the hardware configuration. This means that the application developed once can be applied to multiple devices, reducing the workload of development and maintenance.
[0066] Enhanced user experience: Device sharing enables merchants to offer more comprehensive and diverse services, thereby improving the end-user experience. Users enjoy more choices and convenience. For example, a single smart POS device can provide both payment and printing functions, improving user satisfaction.
[0067] Customization and Flexibility: This invention allows merchants to customize functions and interfaces according to their needs, without being restricted by the fixed functions and interfaces of traditional SDKs. This provides greater flexibility, enabling merchants to meet the different needs of different scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0068] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0069] Figure 1 It is a deployment structure diagram of traditional SDKs and APIs to adapt to the capabilities of different devices.
[0070] Figure 2 This is a diagram of the device sharing deployment structure based on MQTT in the existing technology.
[0071] Figure 3This is a diagram of a device sharing deployment structure based on WebSocket in the prior art.
[0072] Figure 4 This is a deployment structure diagram of a capability sharing method based on smart POS devices provided in an embodiment of the present invention.
[0073] Figure 5 This is a flow chart of a capability sharing method based on a smart POS device provided by an embodiment of the present invention.
[0074] Figure 6 is a schematic diagram of an electronic device provided by an embodiment of the present invention.
[0075] Figure 7 It is a schematic diagram of a computer-readable storage medium provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0076] The present invention will be described in further detail below with reference to the accompanying drawings and examples. It is particularly noted that the following examples are intended only to illustrate the present invention and are not intended to limit the scope of the present invention. Similarly, the following examples are only some embodiments of the present invention and are not intended to be exhaustive. All other embodiments obtained by those of ordinary skill in the art without creative effort are intended to fall within the scope of protection of the present invention.
[0077] The present invention provides a capability sharing method based on intelligent POS devices, such as Figure 4 This approach allows different smart POS devices to share functionality and expand their hardware capabilities. Through applications, devices can work together to improve efficiency and provide more convenient and efficient services for merchants and end users. Figure 4 The unique deployment structure of the present invention is shown.
[0078] See Figure 5 , is a capability sharing method based on an intelligent POS device of the present invention, comprising the following steps:
[0079] Step 1. Install an application for managing device capabilities on each smart POS device. The application is intended to serve as a medium for communication and collaboration between devices. The application can run across platforms to achieve capability sharing between different models of devices and can run on multiple smart POS operating systems.
[0080] In this embodiment, the application is configured with a capability sharing management module, a communication module, a local storage module, a data format processing module, and a request processing module;
[0081] The capability sharing management module is used to register the capability information of the smart POS device itself, including printing, code scanning, card reading, etc., so that other devices can query and access these functions, and maintain a capability list of the smart POS device so that other devices can understand its available functions;
[0082] The communication module uses the Zeroconf protocol and peer-to-peer technology. The Zeroconf protocol has automatic site selection and service discovery functions, allowing smart POS devices to automatically discover other devices within the same local area network. The peer-to-peer technology is responsible for the peer-to-peer communication connection between smart POS devices. This process is automatic and does not require manual configuration or intervention by the user. At the same time, the communication module also manages the maintenance of the connection to ensure that the communication between devices remains stable and efficient. The communication module is also configured with multiple protocol interfaces of different communication protocol types, which are used to respond to corresponding communication protocols. Multiple different protocol interfaces can adapt to different communication protocols and can meet different communication requirements.
[0083] The local storage module is responsible for storing the pre-configured unique identifier of the smart POS device and the authorization information for accessing the sharing function. The application can uniquely identify each smart POS device and ensure that only authorized smart POS devices can access the sharing function. The unique identifier is used for device authentication, and the authorization information is used for verifying access rights to the sharing function.
[0084] The data format processing module is responsible for performing data format conversion and data packaging. Applications can handle data formats and protocols across different devices and services to ensure seamless capability sharing. The data format processing module supports multiple data formats and can be used to resolve data format differences between different devices and services. Data formats and communication protocols may vary across different smart POS devices. The data format processing module is responsible for performing data conversion and data packaging to ensure that data is correctly transmitted and interpreted between different devices. This standardized data format enables devices to seamlessly share information without worrying about compatibility issues between different devices.
[0085] The request processing module is responsible for processing service requests and responses, ensuring that the transmission of requests and responses is secure and reliable.
[0086] Step 2: When a smart POS device needs to access the capabilities of other smart POS devices, the smart POS device is used as a requesting device. The requesting device uses the application to find other smart POS devices in the same local area network and establish a communication connection.
[0087] In this embodiment, the requesting device in step 2 uses an application to find other smart POS devices in the same local area network and establish a communication connection; specifically, the steps include:
[0088] Step 21: The requesting device automatically discovers (device discovers) other smart POS devices within the same local area network (LAN) using the Zeroconf protocol within the application's communication module. Device discovery: Each smart POS device periodically broadcasts information about its available services, including printing, barcode scanning, and card reading. These broadcast messages contain the device's identifier, available functions, communication protocol type, and other relevant information. Other devices within the same LAN receive these broadcast messages and can identify the presence and availability of the other device.
[0089] Step 22: The requesting device establishes a peer-to-peer communication connection with other smart POS devices within the same local area network (LAN) using peer-to-peer technology within the application's communication module. Once the devices discover each other, they automatically establish a peer-to-peer communication connection. This connection is bidirectional, allowing the devices to communicate and collaborate with each other. This peer-to-peer connection is implemented within the interconnected application's internal communication module, ensuring secure and reliable communication.
[0090] Step 3: The requesting device uses the application to locate available target devices within the local area network. Once the devices establish a peer-to-peer connection, they can begin sharing their capabilities. The requesting device can selectively use the services of other devices to expand its hardware capabilities. For example, a smart POS terminal can query for available printers nearby and select one to print a receipt.
[0091] In this embodiment, step 3 specifically includes:
[0092] Step 31: The requesting device queries the capability information of other smart POS devices in the same local area network through the application. The device can query the capability information of other devices in the local area network. Through the application, the device can view the function lists registered by other devices to understand which functions and capabilities are available.
[0093] Step 32: The requesting device finds all available smart POS devices in the same local area network based on the access purpose and the query result. For example, if the access purpose is printing, the query result is to check whether each smart POS device has a printing function. If devices 1, 2, 4, and 5 have a printing function, but devices 3 and 6 do not, then all available smart POS devices in the same local area network are found, and devices 1, 2, 4, and 5 are selected as candidate devices.
[0094] Step 33: If the number of all available smart POS devices is 1, then the smart POS device is used as the target device; if the number of all available smart POS devices is greater than 1, then one of the smart POS devices is selected as the target device, and the interface display module displays multiple target device options. The user selects one of the smart POS devices as the target device based on the options. After selecting the target device, the user display module displays the management capabilities and management capability sharing options corresponding to the target device. The user selects the hardware functions to be shared by the target device from multiple options based on access requirements.
[0095] In this embodiment, the querying of the capability information of other smart POS devices in the same local area network in step 31 is performed by broadcasting in the local area network, scanning a QR code, or manually entering a device identifier.
[0096] When broadcasting within a local area network (LAN), each smart POS device automatically broadcasts its available capabilities, including printing, barcode scanning, and card reading services, via the Zeroconf protocol. The requesting device monitors the broadcast and automatically discovers the capabilities of other smart POS devices within the same LAN using the Zeroconf protocol. Applications can automatically trigger device capability sharing based on user requests, and support automated rules and event notification mechanisms. Automatic triggering means triggering capability sharing based on user and application predefined rules and sending event notifications to users.
[0097] When using the QR code scanning method, each smart POS device generates a QR code carrying its own capability information. The requesting device scans the QR code generated by each smart POS device in the same local area network and obtains the corresponding capability information.
[0098] When manually inputting device identifiers, manually input the unique identifier of each smart POS device in the same local area network, determine the corresponding smart POS device based on the unique identifier, and find the corresponding capability information from the capability sharing management module in the application of the smart POS device.
[0099] Step 4: The requesting device sends a service request to the target device through the application program;
[0100] In this embodiment, step 4 specifically includes:
[0101] Step 41: The requesting device initiates a service request, which includes a data format of the service request, a unique identifier of the requesting device, authorization information of the requesting device, and request data for sharing target device capabilities. The request data for sharing target device capabilities refers to a specific description of the required target device capabilities to ensure that the target device can correctly understand the purpose of the request.
[0102] Step 42: Encrypt the service request to ensure that data transmission between smart POS devices is protected, thereby enhancing the privacy and security of data transmission. This ensures that data is encrypted during transmission and only legitimate devices can decrypt and understand the communication content.
[0103] Step 43: The requesting device sends the encrypted service request to the target device via the selected communication protocol.
[0104] Step 5: After receiving the service request, the target device performs authorization verification on the requesting device. After the verification is successful, the target device processes the service request, generates a response, and sends it back to the requesting device.
[0105] In this embodiment, step 5 specifically includes:
[0106] Step 51: The protocol interface in the application of the target device that is compatible with the communication protocol selected by the requesting device responds to the communication protocol, receives the encrypted service request, and then decrypts the encrypted service request;
[0107] For example, the target device's application may be configured with an http protocol interface, an https protocol interface, a socket protocol interface, and the like. If the requesting device transmits a service request to the target device using the http protocol, the target device's http protocol interface will respond with the http protocol and receive the service request. The configuration of different protocol interfaces allows for adapting to a variety of communication protocols for data transmission, ensuring seamless communication between different smart POS devices and enabling capability sharing. Communication protocols may also vary between devices, and protocol responses can be executed through the protocol interfaces to ensure correct data transmission.
[0108] Step 52: After decryption, the service request is obtained, including the data format of the service request, the unique identifier of the requesting device, the authorization information of the requesting device, and the request data of the shared target device capabilities;
[0109] Step 53 determines whether the data format of the service request is consistent with a data format readable by the target device. If so, proceed to step 54. Otherwise, the application's data format processing module converts the service request data format into a data format readable by the target device to facilitate data reading. This data format conversion ensures data interaction between different smart POS devices, enabling capability sharing and ensuring consistency between requests and responses. If the two devices use different data formats, the data format processing module performs the necessary data conversion to ensure data consistency. This may involve converting the data from one format to another so that the receiving device can correctly interpret the data.
[0110] Step 54: Verify the identity of the requesting device based on its unique identifier. If so, proceed to step 55; otherwise, the process ends. Verifying the identity of the requesting device ensures that the requesting device is authorized, ensuring data transmission security and ensuring that both ends of the communication are authorized. This prevents unauthorized devices from participating in the communication, improving communication security.
[0111] Step 55: Verify whether the requesting device has access rights to capability sharing based on the authorization information of the requesting device. If so, proceed to step 56; otherwise, end the process. The target device checks whether the requesting device has access rights to the required capability sharing. This can be customized according to the merchant's settings and policies to ensure the security of data transmission.
[0112] Step 56: The request processing module of the application processes the request data of the shared target device capability, determines the required hardware functions of the target device based on the request data of the shared target device capability, and activates the corresponding hardware components. The target device performs the corresponding functions, such as printing, scanning, card reading, etc., through the hardware components;
[0113] Step 57: If access information is required in the request data for sharing the target device's capabilities, the target device will provide the required access information;
[0114] Step 58: The target device generates response data, which includes the requested capability sharing result, response parameters, and status information. The response data is encapsulated by the application's data format processing module and sent back to the requesting device, ensuring that the requesting device can further process the response.
[0115] Step 6: After receiving the response, the requesting device processes the response as needed;
[0116] In this embodiment, step 6 specifically includes:
[0117] Step 61: After receiving the encapsulated response data, the requesting device performs parsing to obtain a parsing result for further processing or display.
[0118] Step 62: The application is further configured with an interface display module. If the requesting device needs to display the parsing result to the end user, the parsing result is displayed through the interface display module of the application;
[0119] Step 63: Generate a report based on the analysis results and record the transaction information.
[0120] Step 7: After the target device capability sharing is completed, the smart POS devices are disconnected and no longer maintain continuous communication. This ensures efficient use of resources and high performance of the devices.
[0121] Through these detailed steps, the present invention enables capability sharing between devices, including querying and selectively using functions, processing data formats, and maintaining communication security. These technical details and practical operations enable smart POS devices to collaborate within the same local area network, fully utilizing each other's capabilities and improving efficiency and convenience.
[0122] Example:
[0123] To more specifically illustrate embodiments of the present invention, consider the following scenario:
[0124] In a restaurant, there are multiple smart POS devices, including POS terminals, printers, and payment terminals.
[0125] Each smart POS device is equipped with an application program. When a customer places an order, the POS terminal needs to send the order information to the payment terminal for payment. In this process, the capability sharing method of the present invention is used.
[0126] The POS terminal automatically discovers the payment terminal through the Zeroconf protocol and peer-to-peer technology and establishes a peer-to-peer communication connection. This discovery process is automatic and does not require manual intervention.
[0127] The POS terminal sends a payment request to the payment terminal. The payment request includes the order information and the payment amount. After receiving the payment request, the payment terminal performs identity authentication and authorization checks to ensure that the POS terminal has permission to perform the payment operation.
[0128] After authorization is passed, the payment terminal performs the payment operation and generates a successful payment response. The response is sent back to the POS terminal to continue order processing.
[0129] After receiving the response, the POS terminal can send an order print request to the printer to generate an order receipt. The order print request includes order details and a print format.
[0130] After receiving the order print request, the printer performs authentication to ensure that the POS terminal has permission to perform the printing operation. The printer then performs the printing operation, generates an order receipt, and provides it to the customer.
[0131] Through the above-described embodiments, the present invention addresses the problems of functional independence, resource waste, and inefficient communication between traditional smart POS devices through technological innovation. By interconnecting applications, peer-to-peer connections, shared capabilities, and maintaining secure communications, the present invention provides more efficient and convenient services for merchants and end users. These detailed descriptions of the technical details and practical operations provide a solid foundation for the application of the present invention and a rich reference for those skilled in the art.
[0132] like Figure 6 As shown, an embodiment of the present invention further provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned capability sharing method based on a smart POS device when executing the program.
[0133] like Figure 7 As shown, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, which implements the above-mentioned capability sharing method based on smart POS devices when executed by a processor.
[0134] In addition, the functional units in various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0135] 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 technical solution of the present invention, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the various embodiments of the present invention. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0136] The above descriptions are only some embodiments of the present invention and do not limit the scope of protection of the present invention. Any equivalent device or equivalent process transformation made by using the contents of the description and drawings of the present invention, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A capability sharing method based on smart POS devices, characterized in that: The steps include: Step 1: Install an application on each smart POS device to manage device capabilities. Step 2: When a smart POS device needs to access the capabilities of other smart POS devices, the smart POS device is used as a requesting device. The requesting device uses the application to find other smart POS devices in the same local area network and establish a communication connection. Step 3: The requesting device uses an application to find an available target device in the local area network; Step 4: The requesting device sends a service request to the target device through the application program; specifically, the following steps are included: Step 41: The requesting device initiates a service request, where the service request includes a data format of the service request, a unique identifier of the requesting device, authorization information of the requesting device, and request data of the shared target device capability. Step 42: Encrypt the service request; Step 43: The requesting device sends the encrypted service request to the target device via the selected communication protocol; Step 5: After receiving the service request, the target device performs authorization verification on the requesting device. After the verification is successful, the target device processes the service request, generates a response, and sends it back to the requesting device. Specifically, the steps include: Step 51: The protocol interface in the application of the target device that is compatible with the communication protocol selected by the requesting device responds to the communication protocol, receives the encrypted service request, and then decrypts the encrypted service request; Step 52: After decryption, the service request is obtained, including the data format of the service request, the unique identifier of the requesting device, the authorization information of the requesting device, and the request data of the shared target device capabilities; Step 53: Determine whether the data format of the service request is consistent with the data format that the target device can read. If so, proceed to step 54; otherwise, convert the data format of the service request into a data format that the target device can read through the data format processing module of the application. Step 54: Verify whether the identity of the requesting device is legitimate based on the unique identifier of the requesting device. If so, proceed to step 55; otherwise, end the process; Step 55: Verify whether the requesting device has the access right to capability sharing based on the authorization information of the requesting device. If so, proceed to step 56; otherwise, end the process. Step 56: The request processing module of the application processes the request data for sharing the target device capabilities, determines the hardware functions required to be used in the target device based on the request data for sharing the target device capabilities, and activates the corresponding hardware components. The target device then executes the corresponding functions through the hardware components. Step 57: If access information is required in the request data for sharing the target device's capabilities, the target device will provide the required access information; Step 58: The target device generates response data, and encapsulates the response data through the data format processing module of the application program and sends the response data back to the requesting device; Step 6: After receiving the response, the requesting device processes the response as needed; Step 7: After the target device capability sharing is completed, the smart POS devices are disconnected.
2. A capability sharing method based on an intelligent POS device as claimed in claim 1, characterized in that: The application is configured with a capability sharing management module, a communication module, a local storage module, a data format processing module and a request processing module; The capability sharing management module is used to register the capability information of the smart POS device itself and maintain the capability list of the smart POS device; The communication module uses the Zeroconf protocol and point-to-point technology. The Zeroconf protocol has automatic site selection and service discovery functions. The point-to-point technology is responsible for point-to-point communication connections between smart POS devices. The communication module is also configured with multiple protocol interfaces of different communication protocol types, which are used to respond to corresponding communication protocols. The local storage module is responsible for storing the pre-configured unique identifier of the smart POS device and the authorization information for accessing the sharing function; The data format processing module is responsible for performing data format conversion and data encapsulation; The request processing module is responsible for processing service requests and responses.
3. A capability sharing method based on an intelligent POS device as claimed in claim 2, characterized in that: In step 2, the requesting device uses the application to find other smart POS devices in the same local area network and establish a communication connection; specifically, the following steps are involved: Step 21: The requesting device automatically discovers other smart POS devices in the same local area network through the Zeroconf protocol in the communication module of the application; Step 22: The requesting device establishes a point-to-point communication connection with other smart POS devices in the same local area network through the point-to-point technology in the communication module of the application.
4. A capability sharing method based on an intelligent POS device as claimed in claim 2, characterized in that: The step 3 specifically includes: Step 31: The requesting device queries the capability information of other smart POS devices in the same local area network through the application program; Step 32: The requesting device finds all available smart POS devices in the same local area network according to the access purpose and the query result; Step 33: If the number of all available smart POS devices is 1, the smart POS device is used as the target device; if the number of all available smart POS devices is greater than 1, one of the smart POS devices is selected as the target device.
5. A capability sharing method based on an intelligent POS device as claimed in claim 4, characterized in that: In step 31, the capability information of other smart POS devices in the same local area network is queried by broadcasting in the local area network, scanning a QR code, or manually entering a device identifier. When broadcasting within a local area network (LAN), each smart POS device automatically broadcasts its available capabilities, including printing, code scanning, and card reading services, using the Zeroconf protocol. The requesting device monitors the broadcast content and automatically discovers the capabilities of other smart POS devices within the same LAN using the Zeroconf protocol. When using the QR code scanning method, each smart POS device generates a QR code carrying its own capability information. The requesting device scans the QR code generated by each smart POS device in the same local area network and obtains the corresponding capability information. When manually inputting device identifiers, manually input the unique identifier of each smart POS device in the same local area network, determine the corresponding smart POS device based on the unique identifier, and find the corresponding capability information from the capability sharing management module in the application of the smart POS device.
6. A capability sharing method based on an intelligent POS device as claimed in claim 1, characterized in that: The step 6 specifically includes: Step 61: After receiving the encapsulated response data, the requesting device performs parsing processing to obtain a parsing result; Step 62: The application is further configured with an interface display module. If the requesting device needs to display the parsing result to the end user, the parsing result is displayed through the interface display module of the application; Step 63: Generate a report based on the analysis results and record the transaction information.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the capability sharing method based on the smart POS device is implemented as described in any one of claims 1 to 6.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the capability sharing method based on a smart POS device is implemented as described in any one of claims 1 to 6.