Graphic code scanning method and device

CN120493965APending Publication Date: 2025-08-15VIVO MOBILE COMM CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510635663.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-16
Publication Date
2025-08-15

Smart Images

  • Figure CN120493965A_ABST
    Figure CN120493965A_ABST
Patent Text Reader

Abstract

The invention discloses a graphic code scanning method and device, and belongs to the technical field of electronics. The method comprises the steps of obtaining image feature information in an image obtained by scanning a first space under the condition that it is detected that no graphic code exists in the scanned image; determining a graphic code direction in the first space according to the image feature information; according to the graphic code direction, first voice is played, a sensor corresponding to the graphic code direction is controlled to vibrate, and the first voice is used for prompting the direction of the graphic code in the first space.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of electronic technology, and specifically relates to a method and device for scanning a graphic code. Background Art

[0002] With the development of technology, graphic codes are widely used in daily life. For example, when shopping, users can pay by scanning QR codes. To enable visually impaired users to use electronic devices to scan graphic codes, electronic devices can provide barrier-free code scanning functions.

[0003] In related technologies, when an electronic device turns on the barrier-free code scanning function, if the electronic device scans a graphic code, the electronic device can prompt the visually impaired user through voice to detect the graphic code, so that the visually impaired user can know that the current scanning direction is the correct direction.

[0004] However, when visually impaired users scan a barcode, they cannot see clearly or cannot see it at all, making it difficult for them to visually determine the position of the barcode and adjust the scanning direction. Therefore, how to enable visually impaired users to correctly adjust the direction of scanning a barcode using an electronic device is an urgent problem to be solved. Summary of the Invention

[0005] The purpose of the embodiments of the present application is to provide a method and device for scanning graphic codes, which can enable visually impaired users to correctly adjust the direction of scanning graphic codes using electronic devices, thereby improving the efficiency of visually impaired users in scanning graphic codes using electronic devices.

[0006] In a first aspect, an embodiment of the present application provides a method for scanning a graphic code, the method comprising: when it is detected that no graphic code exists in an image in a scanning interface, obtaining image feature information in the image, where the image is obtained by scanning a first space; determining the direction of the graphic code in the first space based on the image feature information; and playing a first voice based on the direction of the graphic code, and controlling the vibration of a sensor corresponding to the direction of the graphic code, the first voice being used to prompt the direction of the graphic code in the first space.

[0007] In a second aspect, embodiments of the present application provide a graphical code scanning device, comprising: an acquisition module, a determination module, and an execution module. The acquisition module is configured to, upon detecting that the graphical code is absent from an image on a scanning interface, acquire image feature information from an image obtained by scanning a first space. The image feature information is then acquired by the determination module. The direction of the graphical code in the first space is determined by the acquisition module. The execution module is configured to play a first voice message based on the graphical code direction determined by the determination module, and to control the vibration of a sensor corresponding to the graphical code direction. The first voice message indicates the direction of the graphical code in the first space.

[0008] In a third aspect, an embodiment of the present application provides an electronic device comprising a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps of the method described in the first aspect are implemented.

[0009] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0010] In a fifth aspect, an embodiment of the present application provides a chip, which includes a processor and a communication interface, the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the method described in the first aspect.

[0011] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the method described in the first aspect.

[0012] In an embodiment of the present application, when it is detected that no graphic code exists in the image in the scanning interface, image feature information in the image can be obtained, and the image is obtained by scanning the first space. Then, the direction of the graphic code in the first space can be determined based on the image feature information. Then, based on the direction of the graphic code, a first voice can be played, and the vibration of the sensor corresponding to the direction of the graphic code can be controlled. The first voice is used to prompt the direction of the graphic code in the first space. In this solution, since image feature information in the image obtained by scanning the first space can be obtained, such as the distribution of objects, edge contours, color changes and other features in the first space, the direction in which the graphic code may exist can be inferred based on these features. Then, the voice prompt and the vibration of the corresponding direction sensor can be combined to provide multi-sensory collaborative prompts to the visually impaired user, so that the visually impaired user can correctly adjust the direction of the electronic device to scan the graphic code, reducing the time of blind movement and repeated searches, and improving the efficiency of the visually impaired user in scanning the graphic code using the electronic device. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] Figure 1 This is one of the flow charts of the graphic code scanning method provided in the embodiment of the present application;

[0014] Figure 2 This is the second flowchart of the graphic code scanning method provided in the embodiment of the present application;

[0015] Figure 3 This is one of the schematic diagrams of the scanning interface provided in the embodiment of the present application;

[0016] Figure 4This is the third flowchart of the graphic code scanning method provided in the embodiment of the present application;

[0017] Figure 5 This is the second schematic diagram of the scanning interface provided in the embodiment of the present application;

[0018] Figure 6 is a schematic diagram of an input mask provided in an embodiment of the present application;

[0019] Figure 7 This is the fourth flow chart of the graphic code scanning method provided in the embodiment of the present application;

[0020] Figure 8 This is the fifth flow chart of the graphic code scanning method provided in the embodiment of the present application;

[0021] Figure 9 This is one of the schematic diagrams of the graphic code scanning device provided in the embodiment of the present application;

[0022] Figure 10 This is the second schematic diagram of the graphic code scanning device provided in an embodiment of the present application;

[0023] Figure 11 This is the third schematic diagram of the graphic code scanning device provided in an embodiment of the present application;

[0024] Figure 12 is a schematic structural diagram of an electronic device provided in an embodiment of the present application;

[0025] Figure 13 This is a schematic diagram of the hardware structure of the electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0026] The following will be combined with the accompanying drawings in the embodiments of this application to clearly describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field are within the scope of protection of this application.

[0027] The terms "first," "second," and the like in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of this application can be implemented in an order other than that illustrated or described herein, and that the objects distinguished by "first," "second," and the like are generally of the same type, and do not limit the number of objects; for example, the first object can be one or more. In addition, the term "and / or" in the specification and claims refers to at least one of the connected objects, and the character " / " generally indicates that the objects connected are in an "or" relationship.

[0028] The terms "at least one" and "at least one of" in this application refer to any one, any two, or a combination of more than two of the objects included. For example, at least one of a, b, and c can be represented by: "a", "b", "c", "a and b", "a and c", "b and c", and "a, b, and c", where a, b, and c can be single or multiple. Similarly, "at least two" means two or more, and its meaning is similar to "at least one".

[0029] The graphic code scanning method and device provided in the embodiments of the present application are described in detail below with reference to the accompanying drawings through specific embodiments and their application scenarios.

[0030] The embodiments of the present application can be applied to scenarios where users need to use electronic devices to scan graphic codes to perform operations, such as visually impaired users.

[0031] The following uses some specific scenarios of the embodiments of the present application as examples to exemplify the graphic code scanning method provided in the embodiments of the present application.

[0032] Scenario 1: Mobile payment scenario: After a visually impaired user makes a purchase at a convenience store, supermarket, restaurant, or other place, he or she needs to scan the merchant's payment QR code to complete the payment.

[0033] Scenario 2: Ordering scenario: When dining in a restaurant, visually impaired users need to scan the ordering code on the table to browse the menu and place an order.

[0034] Scenario 3: Medical service scenario: When a visually impaired user visits a hospital for treatment, he or she needs to scan the registration number to register.

[0035] It should be noted that the above-mentioned scenarios 1 to 3 are only examples of some possible scenarios in which the embodiments of the present application may be applied. In actual implementation, the embodiments of the present application can also be applied to more scenarios requiring graphic code scanning and any possible scenarios, and the embodiments of the present application are not limited here.

[0036] The embodiments of the present application provide a method and device for scanning a graphic code. Since the electronic device can obtain image feature information in the image obtained by scanning the first space, such as object distribution, edge contours, color changes and other features in the first space, the electronic device can infer the direction in which the graphic code may exist based on these features. The electronic device can then combine voice prompts and vibrations of the corresponding direction sensor to provide multi-sensory collaborative prompts to the visually impaired user, so that the visually impaired user can correctly adjust the direction of using the electronic device to scan the graphic code, reducing the time of blind movement and repeated searches, and improving the efficiency of the visually impaired user in using the electronic device to scan the graphic code.

[0037] The execution subject of the graphic code scanning method provided in the embodiment of the present application can be a graphic code scanning device, which can be an electronic device, or a functional module or functional entity in the electronic device. The following uses an electronic device as an example to illustrate the technical solution provided in the embodiment of the present application.

[0038] Figure 1 A flowchart of a method for scanning a graphic code according to an embodiment of the present application is shown. Figure 1 As shown, the graphic code scanning method provided in the embodiment of the present application may include the following steps 201 to 203.

[0039] Step 201: When detecting that no graphic code exists in the image on the scanning interface, the electronic device obtains image feature information in the image.

[0040] In the embodiment of the present application, the above image is obtained by scanning the first space.

[0041] In the embodiment of the present application, the scanning interface is an interface used in an electronic device to scan a graphic code. The scanning interface can use the electronic device's camera to capture the image in front of the camera in real time. The user can adjust the angle of the electronic device so that the electronic device can capture the graphic code through the camera and display it in the scanning interface, thereby completing the graphic code scanning operation.

[0042] Optionally, in an embodiment of the present application, the scanning interface may be an interface of a scanning function provided by the electronic device, such as a "scan" function, or the scanning interface may be an interface in an application capable of scanning graphic codes, such as an interface in a payment application, a social application, a shopping application, a travel application, a life service application, or the like. Among them:

[0043] (1) Payment applications can be used to scan payment codes or activity QR codes and other graphic codes to make payments or participate in merchant promotions.

[0044] (2) Social applications can be used to scan graphic codes such as adding friend codes, public numbers, or mini-program codes to perform operations such as adding friends or opening various mini-programs.

[0045] (3) Shopping applications can be used to scan product graphics codes to view product details, etc.

[0046] (4) Travel applications can be used to scan the QR code to view travel routes or pay for rides.

[0047] (5) Life service applications can be used to scan graphic codes such as ordering QR codes or hotel QR codes to perform operations such as online ordering or online hotel reservations.

[0048] In the embodiments of the present application, the graphic code is a graphic with specific encoding rules, a visual data carrier that can conveniently store and transmit identification information, and is typically composed of a black and white pattern. The electronic device can use an image recognition algorithm to determine whether a graphic that meets these characteristics exists in an image captured by a camera.

[0049] In the embodiment of the present application, “no graphic code exists in the image” means that no graphic that meets the characteristics of the graphic code is identified in the image captured by the camera and displayed in the current scanning interface.

[0050] In the embodiments of the present application, the above-mentioned image feature information refers to the features presented by various visual elements in the image. These features may include at least one feature such as the edge outline, color distribution, texture, shape, line, light and dark changes, spatial layout, etc. of an object. For example, in an image of an indoor scene, the image feature information may include the outline of furniture in the room, the color of the wall, the shape of the decorations, the texture of the floor, etc. For another example, in an image of an outdoor scene, the image feature information may include the outline of a building, the shape of a tree, the color of the sky, the texture of the ground, etc.

[0051] Optionally, in embodiments of the present application, the electronic device may obtain image feature information from an image using image processing techniques and computer vision algorithms. For example, the electronic device may use edge detection algorithms, such as Canny edge detection, to extract the outline of an object in an image, use color histogram analysis to obtain color distribution characteristics, use texture analysis algorithms to identify texture patterns, and use shape recognition algorithms to determine whether a specific geometric shape exists in an image.

[0052] In the embodiment of the present application, the above-mentioned first space is the three-dimensional physical space range where the electronic device is currently located and needs to perform a graphic code scanning operation. Specifically, the first space is a three-dimensional space within a certain range around the electronic device, which includes various objects, layouts, and scene features of the user's current environment, and has a spatial range of three dimensions: length, width, and height. This spatial range will vary according to the user's specific location and operation scenario. For example, in an indoor scene, it may be the size of a room, and in an outdoor scene, it may be an area with a certain radius around the user. For example, the first space can be a restaurant dining area, a supermarket checkout area, a hospital registration hall, a station waiting room, etc.

[0053] For example, in front of a convenience store checkout counter, the first space may be the checkout area, that is, the space in front of the checkout counter where the user is located and within a certain range around it. This space includes the payment QR code on the checkout counter and various objects around it, such as goods, checkout equipment, decorations, etc. For another example, in a restaurant, the first space may be the restaurant dining area, that is, the space in front of the dining table where the user is located and within a certain range around it. This space includes the ordering QR code on the table and the space occupied by surrounding objects such as tableware and dishes.

[0054] Optionally, in an embodiment of the present application, the electronic device may use a camera to capture an image of the current space and display it on a scanning interface. If no graphics matching the characteristics of the graphic code are identified in the image displayed on the current scanning interface, the electronic device may use image processing technology and computer vision algorithms to obtain image feature information from the image, providing a basis for subsequently determining the direction of the graphic code.

[0055] Step 202: The electronic device determines the direction of the graphic code in the first space according to the image feature information.

[0056] In the embodiment of the present application, the above-mentioned graphic code direction refers to the spatial orientation of the graphic code relative to the electronic device in the current space, which may include but is not limited to the plane direction, vertical direction, tilt angle, etc.

[0057] (1) Planar direction refers to the relative position of the graphic code on the horizontal plane with the current position of the electronic device as the reference point, such as the left side, right side, front side, back side, left front side, right front side, left back side, right back side, or east side, west side, south side, north side, southeast side, northeast side, southwest side, northwest side, etc. of the electronic device.

[0058] (2) The vertical direction is the relative height of the graphic code on the vertical plane with the current height of the electronic device as the reference point, for example, above or below the electronic device.

[0059] (3) The spatial angle is the tilt angle of the graphic code relative to the electronic device. For example, if the graphic code is tilted upward by 30 degrees relative to the electronic device, the electronic device needs to be tilted upward by 30 degrees to align with the graphic code.

[0060] For example, when a user scans an order code at a seat in a restaurant dining area and uses a mobile phone to scan the table, the mobile phone determines through image feature information that the order code is located in the front left of the current location of the mobile phone, that is, the direction of the graphic code is in the front left.

[0061] For example, a user scans a promotional QR code for a product in a supermarket. The code is located on the second shelf of a shelf. The phone uses image features to determine that the code is tilted 45 degrees downward from the vertical. Since the phone is in a vertical position, the phone can determine that the code is tilted 45 degrees upward.

[0062] Optionally, in an embodiment of the present application, the electronic device can analyze the extracted image feature information such as edge contour, color distribution, texture, shape, etc. through a pre-set algorithm, and infer the possible location of the graphic code by combining the spatial geometric relationship and the common placement of the graphic code in daily scenes.

[0063] For example, in a checkout scenario, if there is a rectangular edge outline similar to a checkout counter in the image, and there are common product display patterns and textures around it, the electronic device can determine that it is a checkout scene. In this scenario, since many merchants will place the payment code on the right or left side of the checkout counter near the edge to facilitate customer scanning, the electronic device can determine that the graphic code is likely to be located directly in front of the checkout counter, that is, slightly to the right or left of the direction facing the electronic device's camera.

[0064] For example, in a restaurant scene, if there are shape features formed by the leg lines of tables and chairs at the bottom of the image and texture features of the tablecloth at the top, since the order code is generally placed on the table surface for customers to scan and order, the electronic device can judge based on these image features and the rule that restaurant order codes are usually placed on the table surface that the electronic device is located in the direction of the table surface, that is, above the current direction of the electronic device camera.

[0065] Step 203: The electronic device plays the first voice according to the direction of the graphic code, and controls the sensor corresponding to the direction of the graphic code to vibrate.

[0066] In the embodiment of the present application, the first voice is used to prompt the direction of the graphic code in the first space.

[0067] In the embodiments of the present application, the above-mentioned sensor is a vibration-related sensor in an electronic device, such as a vibration motor. Modern electronic devices, such as smartphones and tablets, usually have multiple vibration sensors built in. These vibration sensors can be independently controlled by the electronic device, causing different positions of the electronic device to vibrate separately. For example, multiple micro vibration motors can be distributed around the edges of the electronic device, each motor corresponding to a direction of the electronic device. By precisely controlling the vibration of the vibration sensor in the corresponding direction, the user can sense the vibration of the device in a specific direction through tactile sensation.

[0068] Optionally, in an embodiment of the present application, after determining the direction of the graphic code, the electronic device may send a vibration instruction to the corresponding vibration sensor based on the direction of the graphic code. For example, if the graphic code is in the front left, the electronic device may send a vibration instruction to the vibration sensors on the left and front sides, causing the vibration sensors on both sides to vibrate.

[0069] Optionally, in the embodiment of the present application, the intensity of the sensor vibration can be adjusted according to actual needs. For example, as the user gradually approaches the graphic code, the vibration intensity can be appropriately increased to prompt the user that they are moving in the right direction.

[0070] Optionally, in an embodiment of the present application, after determining the direction of the graphic code, the electronic device can generate and play corresponding voice prompt content, such as "The graphic code is in front of you on the left", "Please move the device to the right front to approach the graphic code", and other clear directional guidance words to ensure that visually impaired users can quickly and clearly know the direction of the graphic code.

[0071] Optionally, in an embodiment of the present application, after determining the direction of the graphic code, the electronic device can generate and play corresponding voice prompt content, and at the same time control the vibration of the sensor corresponding to the direction of the graphic code, so that the voice prompt and vibration feedback can be combined, and the user can be clearly informed of the direction of the graphic code through voice through auditory perception, and auxiliary perception can be performed through vibration through tactile perception, helping the user to know the direction of the graphic code more accurately.

[0072] Optionally, in an embodiment of the present application, the electronic device can voice prompt the user of the direction of movement when using the electronic device to scan the code to find the graphic code, and combine the mobile phone vibration sensor to remind the moving direction.

[0073] Optionally, in an embodiment of the present application, the electronic device can capture a graphic code based on the minimum focal length of the electronic device. When the graphic code is not captured in the image captured by the camera at the minimum focal length, the electronic device can use voice to remind the user to move the phone, for example: "The graphic code may be to your lower left, please move your phone to the lower left." Since the camera has a larger field of view at a low focal length, it can scan the information in the scene over the largest possible range. The location of the graphic code can be captured by simply moving up, down, left, or right. The prompt of the movement direction can be combined with the up, down, left, and right vibration sensors in the electronic device to solve the problem of unclear outdoor voice reminders.

[0074] Optionally, in an embodiment of the present application, if the electronic device detects a blurred, tilted, or partially obscured graphic code, it can automatically adjust the image angle through image processing technology for intelligent recognition, thereby minimizing the complexity of operations for the visually impaired. For example, deblurring can be performed by filtering, noise reduction, sharpening, contrast enhancement, and other strategies combined with OpenCV hardware acceleration. Tilt and occlusion problems can be geometrically corrected through corner detection, contour analysis, perspective transformation, etc. Multi-frame complementary technology can also be used to stitch together the occluded parts to improve the success rate of scanning. The image processing solutions exemplified above are mature existing technologies, which are used as auxiliary scanning for complex scenes and will not be expanded upon in detail here.

[0075] An embodiment of the present application provides a method for scanning a graphic code. Since the electronic device can obtain image feature information in the image obtained by scanning the first space, such as object distribution, edge contours, color changes and other features in the first space, the electronic device can infer the direction in which the graphic code may exist based on these features. The electronic device can then combine voice prompts and vibrations of the corresponding direction sensor to provide multi-sensory collaborative prompts to the visually impaired user, so that the visually impaired user can correctly adjust the direction of using the electronic device to scan the graphic code, reducing the time of blind movement and repeated searches, and improving the efficiency of the visually impaired user in using the electronic device to scan the graphic code.

[0076] Optionally, in the embodiment of the present application, Figure 1 ,like Figure 2 As shown, before the above step 201, the graphic code scanning method provided by the embodiment of the present application further includes the following step 301, and after the above step 203, the graphic code scanning method provided by the embodiment of the present application further includes the following step 302.

[0077] Step 301: The electronic device scans a first space through a scanning interface based on a first focal length to obtain an image.

[0078] In the embodiment of the present application, the focal length refers to the distance from the center of the lens to the image sensor, which determines the field of view and magnification of the camera lens. The first focal length refers to a smaller focal length value used by the electronic device in the initial stage of the scanning process.

[0079] Optionally, in the embodiments of the present application, the electronic device can use a smaller first focal length for scanning, thereby increasing the field of view of the lens. This allows the device to scan as much information within the first space as possible, facilitating rapid location of the graphical code. This allows the electronic device to directly capture the graphical code through the camera even if it is located relatively far away or in an off-center location, providing a basis for subsequent location and recognition of the graphical code.

[0080] For example, when a user is preparing to scan a payment QR code at a supermarket checkout counter, using a smaller first focal length can allow the scanning interface to cover a larger area around the checkout counter, increasing the possibility of capturing the QR code in the first scan.

[0081] Step 302: When detecting that at least one graphic code exists in the first space, the electronic device scans the at least one graphic code using a second focal length and obtains graphic code information of the at least one graphic code.

[0082] In the embodiment of the present application, the second focal length is greater than the first focal length.

[0083] In the embodiments of the present application, the graphic code information refers to the encoded data stored within the graphic code, which typically contains data related to a specific object, such as a website link, product information, payment account information, text information, etc. During the scanning process, the electronic device can decode the graphic code and convert the binary data contained therein into readable digital information, so that the user can perform corresponding operations based on this information, such as jumping to a specific webpage, completing a payment, recording product information, etc.

[0084] Optionally, in an embodiment of the present application, after detecting the graphic code, the electronic device can use a larger second focal length to scan the graphic code, thereby making the magnification of the lens higher and the details clearer, so as to more accurately capture the details of the graphic code, thereby making it easier to identify the encoded content of the graphic code, thereby improving the accuracy and efficiency of recognition.

[0085] For example, when a user scans a promotional graphic code at a distance in a shopping mall, using the second focal length can obtain the details of the graphic code more clearly and accurately identify it even at a certain distance.

[0086] Optionally, in an embodiment of the present application, the electronic device can quickly locate the position of the graphic code through dynamic zoom and low-magnification focal length, increase the focal length, magnify the part, and scan and identify when the code appears on the screen.

[0087] Optionally, in an embodiment of the present application, during the process of scanning a graphic code, the electronic device may first use a smaller focal length to quickly scan a larger spatial range, thereby quickly locating the approximate position of the graphic code. After detecting the graphic code, the electronic device may switch to a larger focal length for refined scanning, thereby ensuring that its encoded content can be accurately identified.

[0088] For example, the electronic device is a mobile phone. Figure 3 As shown in (a), assuming that a visually impaired user is ready to scan the code, he opens the scanning interface 10 of the mobile phone and aims it at the front. At this time, the mobile phone first uses the minimum focal length, such as 0.5X, in order to obtain the image information in front of the screen in the largest range, so as to quickly find the position of the graphic code. When the QR code 11 appears on the screen, a voice reminder is given: "A QR code is detected, please keep the phone stable", and the phone vibrates to remind you. Strong vibration means full alignment, and weak vibration means approaching the target. At the same time, the mobile phone can automatically focus, intercept this part of the image, and increase the focal length, such as Figure 3 As shown in (b), the QR code 11 is enlarged to a suitable size to complete the scanning, and after the scanning is successful, a voice reminder is given: "The QR code scanning has been completed, please proceed to the next step."

[0089] In this way, during the process of scanning the graphic code, the electronic device can make the scanning process more efficient by reasonably switching the focal length, so that it can use a smaller focal length to quickly locate the graphic code while using a larger focal length to accurately identify the coding content, thereby improving the efficiency and accuracy of graphic code scanning.

[0090] Optionally, in the embodiment of the present application, Figure 1 ,like Figure 4 As shown, after the above step 203, the graphic code scanning method provided in the embodiment of the present application further includes the following steps 401 to 404.

[0091] Step 401: When detecting that at least two graphic codes exist in a first space, the electronic device obtains graphic code information of the at least two graphic codes.

[0092] In the embodiment of the present application, the above-mentioned graphic code information is the specific function of the graphic code.

[0093] For example, the graphic code information of a graphic code may be a payment code of an application, or the graphic code information of a graphic code may be a friend-adding code of an application, or the graphic code information of a graphic code may be a product detail code for obtaining product information.

[0094] Optionally, in an embodiment of the present application, when the electronic device detects the presence of two or more graphic codes in the first space, the electronic device can use a built-in decoding algorithm to analyze the pattern and coding structure of each detected graphic code, and extract information that can clarify its purpose, associated services or pointed resources, thereby determining the specific function or purpose represented by each graphic code based on this information.

[0095] For example, at a convenience store checkout counter, a user uses an electronic device to detect two graphic codes. The electronic device uses a decoding algorithm to analyze and identify one as App A payment code, used to pay the merchant for purchases, and the other as App B payment code, also used to pay the merchant.

[0096] For example, a user might use an electronic device to detect three graphic codes at a restaurant table. Using a decoding algorithm, the electronic device identifies one as an ordering code, used to display the restaurant's electronic menu for ordering; the other as a friend-adding code on a social app, used to add the restaurant's official account as a friend in the app so the user can receive notifications about restaurant promotions, new product recommendations, and more.

[0097] Step 402: The electronic device displays at least two graphic code information and plays a second voice.

[0098] In the embodiment of the present application, the second voice is used to prompt that the first space includes the at least two graphic code information.

[0099] Optionally, in an embodiment of the present application, after detecting and identifying multiple graphic codes, the electronic device may display the function or purpose of each graphic code in a list, icon, or other intuitive form on the scanning interface, such as "App A Payment Code," "App B Add Friend Code," etc., allowing the user to quickly browse and distinguish the functions of different graphic codes. Furthermore, the electronic device may provide a voice prompt to the user regarding the function or purpose of each graphic code, such as "Two graphic codes detected: App A Payment Code and App B Add Friend Code," etc., to help visually impaired users understand the currently available graphic code types.

[0100] Step 403: The electronic device receives a first input of target graphic code information among at least two graphic code information.

[0101] In the embodiment of the present application, the above-mentioned first input is used to trigger the electronic device to perform an operation corresponding to the target graphic code information selected by the first input.

[0102] Optionally, in the embodiments of the present application, the first input includes, but is not limited to, a user's touch input of the target graphic code information using a touch device such as a finger or a stylus, a user's voice command, a user's specific gesture, or other feasible input. The specific input may be determined based on actual usage requirements and is not limited in the embodiments of the present application.

[0103] Optionally, in an embodiment of the present application, the touch input may be a single-click input, a double-click input, or any number of click inputs, or may be a long-press input or a short-press input.

[0104] Optionally, in an embodiment of the present application, the above-mentioned specific gesture can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture.

[0105] Optionally, in an embodiment of the present application, the first input may be a click input of the target graphic code information by the user, or the first input may be an input in which the user slides at least two graphic code information so that the electronic device selects the target graphic code information.

[0106] Optionally, in an embodiment of the present application, the above-mentioned first input can also be the user calling up the selection input mask through a specific voice command and making a voice reply, so that the electronic device executes the input of the operation corresponding to the target graphic code information.

[0107] It should be noted that the selection input mask is a semi-transparent or fully transparent interactive layer displayed on the screen of an electronic device, which is used to provide clearer feedback and a more convenient input method when the user performs a selection operation.

[0108] Optionally, in an embodiment of the present application, the above-mentioned first input can also be the user awakening the selection input mask through a specific voice command, and inputting the number corresponding to the target graphic code information by handwriting so that the electronic device executes the operation corresponding to the target graphic code information.

[0109] In this embodiment of the present application, the target graphical code information is the specific functional information of a specific graphical code selected by the user through the first input and meeting their current needs among multiple graphical code information. For example, when a user selects an order code in a restaurant scenario, the specific function of the order code for ordering is the target graphical code information.

[0110] Step 404: The electronic device executes an operation corresponding to the target graphic code information in response to the first input.

[0111] Optionally, in an embodiment of the present application, after receiving the first input of the target graphic code information, the electronic device may perform an operation corresponding to the target graphic code information, which may include but is not limited to: payment operation, adding a friend operation, opening an application operation, obtaining information operation, etc. Specifically:

[0112] (1) Payment operation: If the target graphic code is a payment code, the electronic device can perform the payment operation, that is, open the corresponding payment application interface and display elements such as the payment amount input box and the confirmation payment button, waiting for the user to enter the amount and complete the payment process.

[0113] (2) Add friend operation: If the target graphic code is an add friend code, the electronic device can perform the add friend operation, that is, start the social application corresponding to the target graphic code, enter the add friend interface, automatically fill in the other party's user information, and send an add friend request to the target user.

[0114] (3) Information acquisition operation: If the target graphic code is a product details code or a scenic spot introduction code, etc., which is used to provide information, the electronic device can perform an information acquisition operation, that is, obtain and parse the link or data stored in the graphic code, and then jump to the corresponding web page or application interface to display the detailed information of the product or the introduction text, pictures, audio guide and other content of the scenic spot.

[0115] (4) Open application operation: If the target graphic code is associated with the download or opening operation of a certain application, the electronic device can jump to the application store page or directly start the corresponding application.

[0116] Optionally, in an embodiment of the present application, when multiple codes appear on the screen, the electronic device can automatically collect code information and display it on the screen in a list format for the user to switch with gestures, and automatically broadcast detailed code information when switching.

[0117] For example, Figure 5 As shown in (a) in FIG, assuming that the electronic device scans three graphic codes, the first graphic code is the payment code 12 of application A, the second graphic code is the payment code 13 of application B, and the third graphic code is the friend adding code 14 of application C, then the electronic device can automatically collect information of all codes, such as Figure 5 As shown in (b) in the figure, it is displayed on the screen in a list with a voice reminder, such as "3 graphic codes are detected, the first one is A application payment code, the second one is B application payment code, and the third one is C application add friend, please select". By default, the screen is swiped left and right to switch the selection order. When sliding, the detailed information of the currently selected graphic code is automatically broadcasted, for example: "The currently selected one is A application payment code". After selection, if there is no operation for 3 seconds, the electronic device can automatically open the graphic code. Figure 6 As shown in (a) in FIG, the user can also use a preset voice command to call up the selection input mask 15, and then directly answer the number by voice, such as answering "the second one", and directly scan the second B application payment code, such as Figure 6 As shown in (b) above, users can also directly select a number by handwriting in the input mask. Writing the number "2" also has the same effect. If a graphic code is selected by mistake, the user can exit and reselect using an exit gesture, such as a shake gesture. The exit gesture can be customized by the user.

[0118] In this way, electronic devices can help visually impaired users quickly understand the purpose of each graphic code by directly displaying the graphic code information on the scanning interface and playing voice prompts, so that users can make accurate choices, avoid the inconvenience and time waste caused by incorrect operations, and improve the accuracy and efficiency of operations.

[0119] Optionally, in the embodiment of the present application, Figure 4 ,like Figure 7 As shown, before the above step 402, the graphic code scanning method provided in the embodiment of the present application further includes the following step 501, and the above step 402 can be specifically implemented through the following step 402a.

[0120] Step 501: The electronic device determines scene information corresponding to a first space based on an image and location information of the electronic device.

[0121] In the embodiments of the present application, the location information of the electronic device is information about the electronic device's geographic location obtained by the electronic device using positioning technologies such as the Global Positioning System (GPS), Wireless Fidelity (Wi-Fi), or Bluetooth. For example, the location information may be a well-known restaurant, a supermarket chain, or a shopping mall.

[0122] In the embodiment of the present application, the scene information corresponding to the first space is a description of the environment and situation of the current first space, which may include but is not limited to information such as the type of place, specific location, scene function, etc. Specifically:

[0123] (1) Types of places may include restaurants, supermarkets, hospitals, schools, etc.

[0124] (2) The specific location can be a certain floor of a shopping mall or a certain number on a certain street, etc.

[0125] (3) The scene function can be a payment scene, a food ordering scene, a registration scene, etc.

[0126] Optionally, in an embodiment of the present application, the electronic device can capture the currently scanned image through a camera, extract image features related to the scene, and simultaneously utilize positioning technology to obtain the device's location information. The electronic device can then combine the image features with the location information and perform a comprehensive analysis using a built-in scene recognition algorithm or machine learning model to determine the current specific scene, such as a restaurant, supermarket, or hospital, as well as the specific activities within the scene, such as ordering food, shopping, or registering for an appointment, thereby providing accurate scene information for subsequent steps.

[0127] Step 402a: The electronic device sorts at least two pieces of graphic code information according to the priorities of the graphic codes corresponding to the scene information, and displays the sorted at least two pieces of graphic code information.

[0128] In the embodiments of the present application, the priority of the graphic codes is a rule for sorting the graphic codes in a specific scenario based on factors such as their function, purpose, and user needs. It determines which graphic codes will be displayed first in a multi-code scenario to facilitate user selection and operation.

[0129] Optionally, in an embodiment of the present application, the electronic device can analyze the current scene through a machine learning model that is pre-trained based on a large number of users' scanning behavior data in different scenarios to determine the priority of the graphic code in the current scene.

[0130] For example, in a supermarket checkout scenario, the electronic device can determine that the user needs to pay, and thus set the priority of the payment code to a higher level; while in a restaurant ordering scenario, the electronic device can determine that the user needs to order food, and thus set the priority of the ordering graphic code to a higher level.

[0131] Optionally, in an embodiment of the present application, the priority of the graphic code may also be a rule preset by the electronic device, or a rule preset by the user, which may be determined based on actual usage requirements and is not limited by the embodiment of the present application.

[0132] Optionally, in an embodiment of the present application, after the electronic device sorts at least two graphic code information according to the priority of the graphic code corresponding to the scene information, these graphic code information can be displayed in the scanning interface in the sorted order.

[0133] Optionally, in an embodiment of the present application, the user can set the priority of multiple codes in advance through the electronic device, such as giving priority to using application A for payment, so that the payment code of application B is directly filtered out during scanning and the payment code of application A is directly identified.

[0134] Optionally, in this embodiment of the present application, users can set the priority of multiple codes in advance, such as prioritizing payment with App A when making a payment, or prioritizing order codes when ordering. After this setting, other types of graphic codes will be automatically filtered out during the scanning process, and the target graphic code will be directly identified and scanned, reducing the interference caused by other graphic codes to the user. If no clear graphic code priority is set, intelligent recommendations can be made based on location information. The intelligently recommended graphic code will be displayed first in the multi-code list on the screen, reducing the cost of manual switching and selection by the user.

[0135] In this way, the electronic device can sort the recognized graphic code information according to the scene information and the priority of the graphic code in the current scene, so that the user can quickly find the graphic code information that better meets the needs of the current scene, avoid the user being disturbed by graphic code information irrelevant to the scene, and improve the accuracy and efficiency of the operation.

[0136] Optionally, in the embodiment of the present application, Figure 1 ,like Figure 8 As shown, after the above step 203, the graphic code scanning method provided in the embodiment of the present application further includes the following steps 601 to 603.

[0137] Step 601: When it is detected through a scanning interface that a first space includes at least two graphic codes, the electronic device determines scene information based on location information of the electronic device.

[0138] Optionally, in an embodiment of the present application, when the scanning interface detects that the first space includes at least two graphic codes, and the electronic device determines that the user needs to select one of these graphic codes to perform an operation, the electronic device may analyze the image captured by the camera and displayed in the scanning interface, extract image features related to the scene, and obtain the device's location information through positioning technology. The electronic device may then combine the image features in the image with the location information and perform a comprehensive analysis using a built-in scene recognition algorithm or machine learning model to determine the specific scene currently in use, such as a restaurant, supermarket, or hospital, as well as the specific activities within the scene, such as ordering food, shopping, or registering for an appointment. Based on this scene information, the electronic device can then determine the graphic code that the user needs to select in that scene.

[0139] Step 602: The electronic device determines a target graphic code from at least two graphic codes based on the scene information and historical code scanning information corresponding to the scene information.

[0140] In the embodiment of the present application, the above-mentioned historical scanning information refers to the record of graphic codes previously scanned by the user in the same scenario, which may include but is not limited to the type, frequency, and time of use of the graphic code.

[0141] In an embodiment of the present application, the target graphic code is the graphic code that the user is most likely to scan among at least two graphic codes, determined by the electronic device based on current scene information and the user's historical scanning information.

[0142] Optionally, in an embodiment of the present application, when the electronic device detects through a scanning interface that the first space includes at least two graphic codes, the electronic device can determine the scene information based on the location information of the electronic device, and query the historical scanning information of the electronic device in the scene information based on the current scene information, that is, the historical scanning information corresponding to the scene information, so that the graphic code that best meets the user's current needs can be determined from these graphic codes.

[0143] For example, if a registration number and a friend-adding code are posted on the wall of a hospital's registration hall, and users often scan the registration number to register in this hospital, when the user comes to the hospital again to scan the code, the electronic device scans the registration number and the friend-adding code, and the electronic device can obtain the current location information and the historical code scanning information at the current location, that is, the electronic device is currently in this hospital, and the electronic device has frequently scanned the registration number in the current hospital in the past, then the electronic device can directly determine the registration number as the graphic code that best meets the user's current needs, instead of adding a friend code, so that the electronic device can eliminate the interference of the friend code and directly execute the operation corresponding to the registration number.

[0144] Step 603: The electronic device executes the operation corresponding to the target graphic code.

[0145] Optionally, in the embodiment of the present application, the operations corresponding to the target graphic code may include but are not limited to: payment operation, adding friend operation, opening application operation, obtaining information operation, etc. For specific operations, please refer to the description in the above embodiment and will not be repeated here.

[0146] Optionally, in an embodiment of the present application, the electronic device can combine historical code scanning data to form a memory, and preferentially identify historical graphic code information in corresponding scenarios to improve code scanning efficiency.

[0147] Optionally, in an embodiment of the present application, since the scenes of daily activities of visually impaired people are relatively fixed, such as shopping malls and hospitals near residential areas, the electronic device can establish a memory database of the image in the scanning interface, the current location, and the type of graphic code finally selected each time the graphic code is scanned. Through the training of the artificial intelligence (AI) model, the next time the user arrives at the corresponding scene, the electronic device can combine the memory data of historical code scanning to quickly guide the user to find the required graphic code information. For example, a voice prompt: "The last graphic code opened was the A application payment code. Do you want to reopen it?"

[0148] In this way, when multiple graphic codes are scanned at the same time, the electronic device can combine the scene information and the corresponding historical scanning information to determine which graphic code is the graphic code that best meets the user's current needs, so that the operation corresponding to the graphic code can be directly executed, reducing the user's operational burden of selecting graphic codes and improving the efficiency and accuracy of the scanning operation.

[0149] In the embodiment of the present application, a complete interactive solution is provided to guide the visually impaired to quickly locate and distinguish and identify multi-code scenarios, which solves the pain point faced by the visually impaired in their daily lives of having difficulty scanning graphic codes and brings convenience to their lives.

[0150] The embodiments of this application provide a method for assisting visually impaired users in quickly locating and identifying multiple codes. This method effectively addresses the difficulty visually impaired users face in scanning graphical codes in their daily lives, enabling them to scan graphical codes and identify multiple codes more independently and efficiently, thus improving their daily lives. The overall solution is convenient and highly feasible, providing new ideas and perspectives for integrating humanistic care into technological products and enhancing user experience, particularly for functional modules designed to help visually impaired users better perceive the world. It serves as a valuable reference and supplement for future research.

[0151] The following is a schematic illustration of the graphic code scanning method provided in the embodiment of the present application through specific examples.

[0152] For example, suppose a visually impaired user is checking out at a supermarket checkout counter. They activate the Scan function on their phone, causing the phone to display a scanning interface. The supermarket's payment code is on the left side of the checkout counter. If the visually impaired user points their phone's camera toward the right side of the checkout counter, the phone can use its minimum focal length to identify the code. If the code is not recognized, the phone can then capture image features from the current image, including rectangular edge contours resembling the checkout counter and common product display patterns and textures, to determine that the current scene is a checkout. In this scenario, since many merchants place the payment code on the right or left side of the checkout counter, near the edge, for easier scanning. Since the current scene is on the right side of the checkout counter and the code is absent, the phone can determine that the code is likely on the left side of the checkout counter, meaning that the phone's camera is facing leftward. The phone then plays a voice prompt: "The code is on your left side. Please move your phone to the left." It also controls the vibration sensor on the left side of the phone to vibrate, guiding the visually impaired user to move their phone to the left. Following the voice prompt, the visually impaired user points their phone's camera to the left side of the checkout counter and attempts to identify the code again. The mobile phone detects the graphic code in the scanning interface, increases the focal length, magnifies the area where the graphic code is located in the image, and recognizes it. After successful recognition, the mobile phone emits a prompt sound "A application payment code has been recognized" and displays the payment interface of A application, so that the visually impaired user can enter the payment amount and complete the payment.

[0153] As another example, suppose a visually impaired user needs to order food at a restaurant. They activate the scan function on their phone, causing the phone to display a scanning interface. The order code and the add-friend code are located on the left front of the table. If the visually impaired user points their phone's camera toward the right front of the table, the phone may use its minimum focal length to perform pattern code recognition and fail to detect the code. The phone then captures image feature information from the current image, including the rectangular edge outline of the table, the shape of the chairs, and the pattern texture of the menu, to determine that the current scene is a restaurant order. In this scenario, since many restaurants place the order code near the left or right front of the table for easy scanning, and the current scene is the right front of the table and no pattern code is present, the phone can determine that the pattern code is likely located on the left front of the table, meaning that the phone's camera is facing slightly to the left front. The phone then plays a voice prompt: "The order code is located on your left front. Please move your phone toward the left front." It also controls the vibration sensor on the left side of the phone to vibrate, guiding the visually impaired user to move their phone toward the left front. Following the voice prompt, the visually impaired user points their phone's camera toward the left front of the table and attempts to recognize the pattern code again. When the phone detects both an ordering code and a friend-adding code in the scanning interface, it increases the focus, magnifying the area containing the graphic code within the image and capturing the graphic code information for both codes. Using a built-in decoding algorithm, the phone analyzes the patterns and encoding structure of the two codes, identifying the first as the restaurant's ordering code, used for ordering; the second as the friend-adding code, used to add the restaurant's microservices staff as a friend for follow-up services or notifications. The phone then displays the two code information in a list and plays a notification: "Two codes detected, the first for ordering and the second for friend-adding. Please select." The visually impaired user then swipes to select the ordering code, which is then prompted with a notification: "Currently selected is the ordering code." If the user does not perform any action within three seconds, the phone automatically opens the ordering code and displays the ordering interface, allowing the visually impaired user to browse the menu and place their order.

[0154] As another example, suppose a visually impaired user is in the registration hall of a hospital. At this time, the visually impaired user turns on the scan function of the mobile phone, so that the mobile phone displays the scanning interface, and points the mobile phone camera at the registration window. The mobile phone detects that the user is near a hospital based on the current GPS positioning information, and combines the hospital-specific registration window sign, queue call screen, hospital sign, etc. detected in the scanning interface to determine that the current scene is a hospital registration scene. At the same time, the mobile phone accesses the historical scanning information stored locally and retrieves that in this hospital scene, the user has scanned the registration number many times to perform the registration operation. Therefore, the mobile phone plays a voice prompt: "The graphic code opened last time was the registration number, do you want to reopen it?" After the visually impaired user replies "yes" through voice, the mobile phone can directly open the registration interface so that the visually impaired user can choose the department and doctor to register.

[0155] Each of the above-mentioned method embodiments, or various possible implementation methods in each method embodiment, can be executed separately, or any two or more of them can be executed in combination with each other. The specific implementation can be determined according to actual usage requirements, and the embodiments of this application do not limit this.

[0156] The graphic code scanning method provided in the embodiment of the present application can be executed by a graphic code scanning device. In the embodiment of the present application, the graphic code scanning device provided in the embodiment of the present application is described by taking the graphic code scanning method executed by the graphic code scanning device as an example.

[0157] Figure 9 FIG. 1 shows a possible structural diagram of a graphic code scanning device involved in some embodiments of the present application. Figure 9 As shown, the graphic code scanning device 70 may include: an acquisition module 71 , a determination module 72 and an execution module 73 .

[0158] The acquisition module 71 is configured to acquire image feature information in an image obtained by scanning the first space when it is detected that no graphic code exists in the image in the scanning interface.

[0159] The determining module 72 is configured to determine the direction of the graphic code in the first space according to the image feature information acquired by the acquiring module 71 .

[0160] The execution module 73 is used to play a first voice according to the direction of the graphic code determined by the determination module 72, and control the sensor corresponding to the direction of the graphic code to vibrate. The first voice is used to indicate the direction of the graphic code in the first space.

[0161] In one possible implementation, combining Figure 9 ,like Figure 10 As shown, the graphical code scanning device provided in this embodiment of the present application further includes a scanning module 74. This scanning module 74 is configured to, upon detecting that no graphical code exists in the image on the scanning interface, scan the first space via the scanning interface based on a first focal length to obtain an image before the acquisition module 71 acquires image feature information from the image. This scanning module 74 is further configured to, upon detecting that at least one graphical code exists in the first space, scan the at least one graphical code using a second focal length greater than the first focal length, after the execution module 73 controls the vibration of the sensor corresponding to the graphical code direction, and upon detecting that at least one graphical code exists in the first space.

[0162] In one possible implementation, combining Figure 9 ,like Figure 11As shown, the graphic code scanning device provided by the embodiment of the present application also includes: a display module 75 and a receiving module 76. The above-mentioned acquisition module 71 is also used to acquire the graphic code information of at least two graphic codes when it is detected that there are at least two graphic codes in the first space after the execution module 73 controls the vibration of the sensor corresponding to the graphic code direction. The display module 75 is used to display the at least two graphic code information acquired by the acquisition module 71 and play a second voice, which is used to prompt that the first space includes at least two graphic code information. The receiving module 76 is used to receive a first input of the target graphic code information among the at least two graphic code information displayed by the display module 75. The above-mentioned execution module 73 is also used to execute the operation corresponding to the target graphic code information in response to the first input received by the receiving module 76.

[0163] In one possible implementation, the determination module 72 is further configured to determine scene information corresponding to the first space based on the image and the position information of the electronic device before the display module 75 displays the at least two pieces of graphic code information. The display module 75 is specifically configured to sort the at least two pieces of graphic code information based on the priority of the graphic codes corresponding to the scene information determined by the determination module 72, and to display the sorted at least two pieces of graphic code information.

[0164] In one possible implementation, the determination module 72 is further configured to: after the execution module 73 controls the vibration of the sensor corresponding to the direction of the graphic code, if the scanning interface detects that the first space includes at least two graphic codes, determine scene information based on the location information of the electronic device; and determine a target graphic code from the at least two graphic codes based on the scene information and historical code scanning information corresponding to the scene information. The execution module 73 is further configured to perform an operation corresponding to the target graphic code.

[0165] In an embodiment of the present application, a graphic code scanning device is provided. Since the graphic code scanning device can obtain image feature information in the image obtained by scanning the first space, such as object distribution, edge contours, color changes and other features in the first space, the graphic code scanning device can infer the direction in which the graphic code may exist based on these features. Then, the graphic code scanning device can combine voice prompts and vibrations of the corresponding direction sensor to provide multi-sensory collaborative prompts to the visually impaired user, so that the visually impaired user can correctly adjust the direction of scanning the graphic code using the graphic code scanning device, reducing the time of blind movement and repeated searches, and improving the efficiency of the visually impaired user in scanning the graphic code using the graphic code scanning device.

[0166] The graphic code scanning device in the embodiment of the present application can be an electronic device or a component in an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal or other device other than a terminal. For example, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, an in-vehicle electronic device, a mobile Internet device (MID), an augmented reality (AR) / virtual reality (VR) device, a robot, a wearable device, an ultra-mobile personal computer (UMPC), a netbook or a personal digital assistant (PDA), etc. It can also be a server, a network attached storage (NAS), a personal computer (PC), a television (TV), a teller machine or a self-service machine, etc., and the embodiment of the present application does not specifically limit it.

[0167] The graphic code scanning device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0168] The graphic code scanning device provided in the embodiment of the present application can implement each process implemented in the above method embodiment. To avoid repetition, it will not be described here.

[0169] Alternatively, as Figure 12 As shown, an embodiment of the present application further provides an electronic device 1000, including a processor 1001 and a memory 1002, wherein the memory 1002 stores a program or instruction that can be run on the processor 1001, and when the program or instruction is executed by the processor 1001, the various steps of the above-mentioned graphic code scanning method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0170] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.

[0171] Figure 13 A schematic diagram of the hardware structure of an electronic device implementing an embodiment of the present application.

[0172] The electronic device 100 includes but is not limited to components such as a radio frequency unit 101 , a network module 102 , an audio output unit 103 , an input unit 104 , a sensor 105 , a display unit 106 , a user input unit 107 , an interface unit 108 , a memory 109 , and a processor 110 .

[0173] Those skilled in the art will understand that the electronic device 100 may also include a power source (such as a battery) to power each component, and the power source may be logically connected to the processor 110 through a power management system, thereby implementing functions such as charging, discharging, and power consumption management through the power management system. Figure 13 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be repeated here.

[0174] The processor 110 is configured to obtain image feature information from an image in the scanning interface when detecting that no graphic code exists in the image, where the image is obtained by scanning the first space.

[0175] The processor 110 is further configured to determine the direction of the graphic code in the first space according to the image feature information.

[0176] The processor 110 is further configured to play a first voice according to the direction of the graphic code and control the vibration of the sensor corresponding to the direction of the graphic code. The first voice is configured to indicate the direction of the graphic code in the first space.

[0177] Optionally, the sensor 105 is configured to, upon detecting that no graphical code is present in the image on the scanning interface, scan the first space via the scanning interface at a first focal length to obtain an image before acquiring image feature information from the image. The sensor 105 is further configured to, upon detecting that at least one graphical code is present in the first space and after controlling sensor vibration corresponding to the direction of the graphical code, scan the at least one graphical code at a second focal length and acquire graphical code information for the at least one graphical code, the second focal length being greater than the first focal length.

[0178] Optionally, the processor 110 is further configured to, after controlling the vibration of the sensor corresponding to the graphic code direction, obtain graphic code information of the at least two graphic codes upon detecting the presence of at least two graphic codes in the first space. The display unit 106 is configured to display the at least two graphic code information and play a second voice message indicating that the first space includes at least two graphic code information. The user input unit 107 is configured to receive a first input for a target graphic code information from the at least two graphic code information. The processor 110 is further configured to, in response to the first input, execute an operation corresponding to the target graphic code information.

[0179] Optionally, the processor 110 is further configured to determine scene information corresponding to the first space based on the image and the position information of the electronic device before displaying the at least two graphic codes. The display unit 106 is specifically configured to sort the at least two graphic codes according to the priority of the graphic codes corresponding to the scene information, and display the sorted at least two graphic codes.

[0180] Optionally, the processor 110 is further configured to: after controlling the vibration of the sensor corresponding to the direction of the graphical code, if the scanning interface detects that the first space includes at least two graphical codes, determine scene information based on the location information of the electronic device; and determine a target graphical code from the at least two graphical codes based on the scene information and historical code scanning information corresponding to the scene information. The processor 110 is further configured to execute an operation corresponding to the target graphical code.

[0181] An embodiment of the present application provides an electronic device. Since the electronic device can obtain image feature information in an image obtained by scanning a first space, such as object distribution, edge contours, color changes, and other features in the first space, the electronic device can infer the direction in which a graphic code may exist based on these features. The electronic device can then combine voice prompts and vibrations of corresponding direction sensors to provide multi-sensory collaborative prompts to visually impaired users, enabling the visually impaired user to correctly adjust the direction in which the electronic device is used to scan the graphic code, thereby reducing the time of blind movement and repeated searches and improving the efficiency of the visually impaired user in scanning graphic codes using the electronic device.

[0182] The electronic device provided in the embodiment of the present application can implement each process implemented in the above method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here. The beneficial effects of various implementations in this embodiment can be specifically referred to the beneficial effects of the corresponding implementations in the above method embodiment. To avoid repetition, it will not be repeated here.

[0183] It should be understood that in an embodiment of the present application, the input unit 104 may include a graphics processing unit (GPU) 1041 and a microphone 1042, and the graphics processor 1041 processes the image data of a static picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The display unit 106 may include a display panel 1061, and the display panel 1061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 107 includes a touch panel 1071 and at least one of other input devices 1072. The touch panel 1071 is also called a touch screen. The touch panel 1071 may include two parts: a touch detection device and a touch controller. Other input devices 1072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and an operating stick, which will not be repeated here.

[0184] The memory 109 can be used to store software programs and various data. The memory 109 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, applications or instructions required for at least one function (such as a sound playback function, an image playback function, etc.). In addition, the memory 109 may include a volatile memory or a non-volatile memory, or the memory 109 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM), and a direct memory bus random access memory (DRRAM). The memory 109 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.

[0185] Processor 110 may include one or more processing units. Optionally, processor 110 integrates an application processor and a modem processor. The application processor primarily handles operations related to the operating system, user interface, and application programs, while the modem processor primarily processes wireless communication signals, such as a baseband processor. It is understood that the modem processor may not be integrated into processor 110.

[0186] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned graphic code scanning method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0187] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer-readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0188] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned graphic code scanning method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0189] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0190] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned graphic code scanning method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0191] It should be noted that, in this article, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element. In addition, it should be noted that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in the opposite order according to the functions involved. For example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0192] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), including a number of instructions for enabling a terminal (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in each embodiment of the present application.

[0193] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.

Claims

1. A method for scanning a graphic code, characterized in that: Used in electronic equipment, including: When it is detected that no graphic code exists in the scanned image, image feature information in the image is obtained by scanning the first space; determining the direction of the graphic code in the first space according to the image feature information; According to the direction of the graphic code, a first voice is played, and a sensor corresponding to the direction of the graphic code is controlled to vibrate, wherein the first voice is used to prompt the direction of the graphic code in the first space.

2. The method according to claim 1, characterized in that In the case where it is detected that no graphic code is present in the image on the scanning interface, before acquiring the image feature information in the image, the method further includes: Scanning the first space through the scanning interface based on the first focal length to obtain the image; After controlling the sensor corresponding to the direction of the graphic code to vibrate, the method further includes: When at least one graphic code is detected in the first space, a second focal length is used to scan the at least one graphic code and obtain graphic code information of the at least one graphic code, where the second focal length is greater than the first focal length.

3. The method according to claim 1, characterized in that After controlling the sensor corresponding to the direction of the graphic code to vibrate, the method further includes: When detecting that at least two graphic codes exist in the first space, acquiring graphic code information of the at least two graphic codes; Displaying the at least two graphic code information and playing a second voice, wherein the second voice is used to prompt that the first space includes the at least two graphic code information; receiving a first input of target graphic code information among the at least two graphic code information; In response to the first input, an operation corresponding to the target graphic code information is executed.

4. The method according to claim 3, characterized in that Before displaying the at least two graphic code information, the method further includes: determining scene information corresponding to the first space based on the image and the position information of the electronic device; The displaying of the at least two graphic code information includes: The at least two pieces of graphic code information are sorted according to the priorities of the graphic codes corresponding to the scene information, and the sorted at least two pieces of graphic code information are displayed.

5. The method according to claim 1, wherein After controlling the sensor corresponding to the direction of the graphic code to vibrate, the method further includes: determining scene information based on the position information of the electronic device when detecting that the first space includes at least two graphic codes; Determining a target graphic code from the at least two graphic codes according to the scene information and historical code scanning information corresponding to the scene information; Execute the operation corresponding to the target graphic code.

6. A graphic code scanning device, characterized in that: The graphic code scanning device includes: an acquisition module, a determination module and an execution module; The acquisition module is configured to acquire image feature information from an image on the scanning interface when detecting that no graphic code exists in the image, where the image is obtained by scanning the first space; The determining module is configured to determine the direction of the graphic code in the first space according to the image feature information acquired by the acquiring module; The execution module is used to play a first voice according to the direction of the graphic code determined by the determination module, and control the vibration of the sensor corresponding to the direction of the graphic code, wherein the first voice is used to indicate the direction of the graphic code in the first space.

7. The graphic code scanning device according to claim 6, characterized in that: The graphic code scanning device further includes: a scanning module; The scanning module is configured to, when detecting that no graphic code is present in the image on the scanning interface, scan the first space based on the first focal length through the scanning interface to obtain the image before the acquisition module acquires the image feature information in the image; The scanning module is further configured to, after the execution module controls the vibration of the sensor corresponding to the direction of the graphic code, scan the at least one graphic code using a second focal length when detecting that at least one graphic code exists in the first space, and obtain graphic code information of the at least one graphic code, wherein the second focal length is greater than the first focal length.

8. The graphic code scanning device according to claim 6, characterized in that: The graphic code scanning device further includes: a display module and a receiving module; The acquisition module is further configured to, after the execution module controls the sensor corresponding to the graphic code direction to vibrate, acquire graphic code information of the at least two graphic codes when detecting that at least two graphic codes exist in the first space; The display module is configured to display the at least two pieces of graphic code information acquired by the acquisition module and play a second voice message, wherein the second voice message is configured to prompt that the first space includes the at least two pieces of graphic code information; The receiving module is configured to receive a first input of target graphic code information among the at least two graphic code information displayed by the display module; The execution module is further configured to execute an operation corresponding to the target graphic code information in response to the first input received by the receiving module.

9. The graphic code scanning device according to claim 8, characterized in that: The determining module is further configured to determine scene information corresponding to the first space based on the image and the position information of the electronic device before the display module displays the at least two pieces of graphic code information; The display module is specifically configured to sort the at least two graphic code information according to the priorities of the graphic codes corresponding to the scene information determined by the determination module, and display the sorted at least two graphic code information.

10. The graphic code scanning device according to claim 6, characterized in that: The determining module is further configured to: After the execution module controls the sensor corresponding to the direction of the graphic code to vibrate, if it is detected through the scanning interface that the first space includes at least two graphic codes, determining scene information based on the position information of the electronic device; and, determining a target graphic code from the at least two graphic codes based on the scene information and historical code scanning information corresponding to the scene information; The execution module is further configured to execute an operation corresponding to the target graphic code.