Air mouse pen

By integrating a laser light, camera and attitude sensor into the mouse pen, the physical cursor coordinates are calculated and transmitted, which solves the problem of low convenience of mouse pen operation in the existing technology, realizes efficient and intuitive on-screen menu operations, and improves user experience. experience.

CN118642610APending Publication Date: 2024-09-13QINGDAO DONGLIAN ANZHI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410687245.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2024-09-13

AI Technical Summary

Technical Problem

The existing mouse pen is not very convenient when operating the screen, especially when operating complex menus, the user experience is poor, and it lacks an intuitive physical cursor and an efficient control method.

Method used

An air mouse pen is designed, equipped with a laser light, camera, attitude sensor and wireless communication module. The laser light illuminates the screen to form a physical cursor. The camera captures the image and calculates the cursor coordinates, which are transmitted to the host for control operations. Combined with the wireless communication module and The host interface module enables efficient screen operations.

Benefits of technology

It improves the convenience of mouse pen operation, provides intuitive physical cursor and fast menu operations, and significantly improves the user experience, especially the efficiency and accuracy when operating complex interfaces.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118642610A
    Figure CN118642610A
Patent Text Reader

Abstract

The invention provides an air mouse pen, which comprises a mouse pen and a host interface module, a first main control MCU is used for acquiring a first main control MCU according to the pixel position of an image of a current screen on an image sensor, the distance between the mouse pen and the screen and the relative inclination angles of the image sensor in a camera inside the mouse pen relative to three axial directions of the screen; the screen coordinate of a point pointed by the physical cursor is calculated and sent to the host interface module at the same time, so that a user performs control operation on a screen according to the calculated screen coordinate; the second master control MCU is used for calculating the attitude inclination angles of the screen relative to the ground in three axial directions, sending the attitude inclination angles to the first master control MCU, forwarding a received control command of the first master control MCU to the host for execution, and forwarding execution result data to the first master control MCU, so that a digital cursor on the host is synchronized with a physical cursor of the laser lamp; and the operation convenience of the mouse pen is effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of remote control equipment, in particular to an air mouse pen. Background Art

[0002] The mouse pen is a product that combines a mouse with an electronic pen. It has the normal left and right buttons, scroll wheel, and page-turning functions of a mouse. When used as a computer pen, no special writing board is required. You can write and draw anytime and anywhere, reducing the trouble of having to carry a writing board. It is a good helper for online office and online meetings. It aims to achieve paperless office with a comfortable ordinary pen and enter the era of network integration.

[0003] In the prior art, the basic structure of the mouse pen is mostly a pen holder and a pen, and the basic shape is a common ordinary pen. The pen holder can bear the function of charging and act as an ordinary wired mouse. The pen is its main body and can act as a mouse and a stylus. The mouse pen supports the handwriting font function and can complete electronic writing, signature, etc.

[0004] However, in the prior art, the operation of the mouse pen on the screen is generally achieved by sensing the infrared signal sent by the mouse pen, thereby realizing the selection or control operation of the mouse pen on the screen; there are also some air mouse products that can be operated in the air, but these air mouse products do not have a physical cursor illuminated by a laser light, but only a digital cursor, and the operation process is not intuitive; and it is time-consuming to select a menu when operating the current remote control, especially when the menu of the operation interface is more complicated, the user experience is poor, resulting in low convenience of operation.

[0005] In view of this problem, the present invention provides an air mouse pen to solve the above problem. Summary of the invention

[0006] In order to solve the problems existing in the prior art, the present invention innovatively proposes an air mouse pen, which effectively solves the problem that the operation convenience of the mouse pen is not high due to the prior art, and effectively improves the operation convenience of the mouse pen.

[0007] A first aspect of the present invention provides an air mouse pen, comprising:

[0008] The mouse pen comprises a first main control MCU, a camera, a laser light, a first wireless communication module, a first attitude sensor and an infrared distance measurement sensor module; the camera is used to collect an instantaneous image of the current screen; the laser light is used to illuminate the menu to be operated on the current screen to form a physical cursor; the first attitude sensor is used to detect the attitude inclination of the first attitude sensor relative to the three axes of the earth; the infrared distance measurement sensor module is used to measure the distance from the mouse pen to the screen; the first main control MCU is used to obtain the instantaneous image of the current screen collected by the camera, the distance between the mouse pen and the screen, and the attitude inclination of the first attitude sensor relative to the three axes of the earth, and identify the instantaneous image according to the instantaneous image of the current screen collected by the camera. The screen imaging position in the image is calculated, and the pixel position of the current screen in the image sensor imaging in the camera is calculated; according to the attitude inclination angle of the first attitude sensor relative to the three axes of the earth and the attitude inclination angle of the screen relative to the three axes of the earth, the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the three axes of the screen is calculated; according to the pixel position of the current screen in the image sensor imaging, the distance between the mouse pen and the screen, and the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the three axes of the screen, the screen coordinates of the point pointed by the physical cursor are calculated, and the calculated screen coordinates are sent to the host interface module through the first wireless communication module, so that the user can control the screen according to the calculated screen coordinates;

[0009] A host interface module, the host interface module includes a second main control MCU, a second attitude sensor and a second wireless communication module, the second attitude sensor is used to detect the attitude inclination angle of the second attitude sensor relative to the earth in three axes, the second main control MCU is used to calculate the attitude inclination angle of the screen relative to the earth in three axes according to the attitude inclination angle of the second attitude sensor relative to the earth in three axes, and at the same time send the attitude inclination angle of the screen relative to the earth in three axes to the first main control MCU through the second wireless communication module; and forward the control command sent by the first main control MCU received to the host connected to the host interface module for execution.

[0010] The laser light and the camera are both arranged at the front end of the mouse pen, the ray direction of the laser light is parallel to the central axis of the camera, and the distance between the ray direction of the laser light and the central axis of the camera is less than a preset first distance threshold; when the laser light irradiates the center of the screen, the camera faces the center of the screen to obtain the image of the current screen, and the center point of the screen is imaged at the center position of the image sensor in the camera; when the laser light irradiates the edge of the screen, the camera faces the edge of the screen, and the edge of the screen is imaged at the center position of the image sensor in the camera.

[0011] Furthermore, the working process of the first master control MCU specifically includes:

[0012] Sending a screen image capture command to the host interface module through the first wireless communication module, and the host interface module forwarding the screen capture command to the host after receiving the screen capture command sent by the first master control MCU; the host captures the current screen image, and sends the captured screen image data to the first master control MCU through the second wireless communication module in the host interface module;

[0013] After receiving the captured screen image data, the camera is controlled to actually take a picture of the screen to obtain an instantaneous image of the current screen captured by the camera;

[0014] According to the posture inclination angle of the screen relative to the earth in three axes and the posture inclination angle of the first posture sensor relative to the earth in three axes, the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen is calculated; wherein, the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen is the sum of vector subtractions between the posture inclination angle of the image sensor in the camera inside the mouse pen relative to the earth in three axes and the inclination angle of the screen relative to the earth in three axes; the posture inclination angle of the screen relative to the earth in three axes is the sum of vector additions between the posture inclination angle of the second posture sensor relative to the earth in three axes and the posture inclination angle of the second posture sensor relative to the screen in three axes; the posture inclination angle of the image sensor in the camera inside the mouse pen relative to the earth in three axes is the sum of vector additions between the posture inclination angle of the first posture sensor relative to the earth in three axes and the posture inclination angle of the first posture sensor relative to the image sensor in the camera inside the mouse pen;

[0015] Taking the center point of the camera sensor as the origin, according to the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen, determine the geometric coordinates of the projection points of the four corner points of the current screen on the plane of the image sensor in the camera;

[0016] The captured screen image and the instantaneous image are scaled and transformed according to the distance between the mouse pen and the screen, and the pixel coordinates of the current screen imaged on the image sensor in the camera are obtained;

[0017] Based on the feature points in the captured screen image, the imaging position of the current screen in the instantaneous image is identified, and the pixel coordinates of the four corner points of the screen boundary in the instantaneous image are determined;

[0018] Taking the center point of the camera sensor as the origin, the instantaneous image is transformed again according to the known aspect ratio of the screen, so that the screen boundary in the instantaneous image is consistent with the actual screen in shape and aspect ratio;

[0019] According to the pixel coordinates of the four corner points of the screen and the laser light irradiation point in the instantaneous image, the screen coordinate value pointed by the physical cursor of the laser light irradiation point is calculated.

[0020] The screen coordinate value pointed by the physical cursor of the laser light irradiation point is calculated based on the pixel coordinates of the four corner points of the screen and the laser light irradiation point in the instantaneous image as follows:

[0021] The screen coordinate value pointed by the physical cursor of the laser light irradiation point is (Cx, Cy), where Cx = Px / PDx*Rx; Cy = Py / PDy*Ry; the horizontal resolution of the screen is Rx, and the vertical resolution of the screen is Ry; the number of horizontal pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Px, and the number of vertical pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Py; the total number of horizontal pixels in the screen imaging area is PDx, and the total number of vertical pixels in the screen imaging area is PDy;

[0022] The pixel coordinates of the laser light irradiation point in the instantaneous image are the pixel coordinates of the center point of the camera image sensor.

[0023] Furthermore, the capturing of feature points in the screen image to identify the imaging position of the current screen in the instantaneous image and determining the pixel coordinates of the four corner points of the screen boundary in the instantaneous image specifically includes:

[0024] After the first main control MCU receives the captured screen image and the instantaneous image, it transforms the captured screen image according to the relative inclination angle between the image sensor in the camera and the current screen and the distance between the mouse pen and the screen, so that the screen boundary in the captured screen image and the screen boundary in the instantaneous image are consistent in shape and aspect ratio, extracts feature points from the instantaneous image formed by the captured screen image on the image sensor in the camera, and uses a preset image recognition algorithm to compare and search for the imaging area of ​​the captured screen image in the instantaneous image actually captured, and determines the pixel coordinates of the four corner points of the current screen in the instantaneous image actually captured.

[0025] Furthermore, the screen capture image is a coded feature image frame with black dots on a white background. When the first main control MCU detects a preset trigger action, it sends a command to output the coded feature image frame to the host interface module through the first wireless communication module. The host interface module forwards the command to output the coded feature image frame sent by the first main control MCU to the host; the host displays the coded feature image frame on the screen and captures the current screen image. The host sends the captured screen image data to the first main control MCU through the second wireless communication module in the host interface module. After receiving the screen image capture data, the first main control MCU controls the camera to take a picture of the screen. After taking the picture The first main control MCU sends a restore normal display command to the host interface module through the first wireless communication module, and the host interface module forwards the restore normal display command sent by the first main control MCU to the host; the host cancels the screen display feature image and restores the normal image display on the screen; wherein, the image recognition algorithm includes a number of working scene parameters, and the working scene parameters are adjusted and optimized to adapt to scenes with different characteristics and different image styles. The working scene parameters support training optimization through intelligent training scenes, and the intelligent training scenes include: training optimization of the crosshair center in the upper left corner of the screen and training optimization of the crosshair center in the lower right corner of the screen.

[0026] Furthermore, the working scenes of the mouse pen include a TV remote control scene, a projection demonstration scene and a calibration scene.

[0027] Furthermore, the mouse pen further comprises a confirmation key and a function key, and the function key comprises a drawing function key and a calibration function key;

[0028] When the working scene of the mouse pen is a TV remote control scene, in response to the need to click on the menu, aim the laser light at the menu icon on the TV screen and press the confirmation key; in response to the need to turn the page, move the laser light outside the TV screen and beyond the boundary of the TV screen, and then return to the TV screen;

[0029] When the working scene of the mouse pen is a projection demonstration scene, in response to the need to click on the menu, aim the laser light at the menu icon on the projection screen and press the confirmation key; in response to the need to turn the page, move the laser light outside the projection screen and beyond the projection screen boundary, and then return to the projection screen; in response to the need to circle a picture, press and hold the drawing function key and use the laser light to draw an outline on the screen at the same time, and the driver on the host follows the handwriting of the circle drawing on the screen and keeps this handwriting until the circle drawing handwriting is cleared after the page is turned and the display is refreshed;

[0030] When the working scene of the mouse pen is the calibration scene, in response to the calibration training of the coordinates of the mouse pen, press the calibration function key, wait for a crosshair coordinate line to be superimposed and displayed in the upper left corner of the current TV screen or projection screen, aim the laser light at the center of the crosshair in the upper left corner of the screen, and press the calibration function key again; move the crosshair coordinate line to the lower right corner of the TV screen or projection screen, aim the laser light at the center of the crosshair in the lower right corner of the TV screen or projection screen again, and press the calibration function key; after the calibration is completed, the mouse pen exits the calibration scene.

[0031] Furthermore, the calibration process of the calibration scene specifically includes:

[0032] Press the calibration function key and the mouse pen enters the calibration mode;

[0033] The mouse pen sends a first training command to perform calibration training using the coordinates of the upper left corner of the TV screen or the projection screen;

[0034] After receiving the training command, the host interface module forwards the training command to the host;

[0035] The host controls the superimposition display of a cross coordinate line at the upper left corner of the TV screen or the projection screen, and sends the coordinate value of the cross coordinate line at the upper left corner to the host interface module;

[0036] The host interface module forwards the coordinate value of the cross coordinate line in the upper left corner to the mouse pen;

[0037] The mouse pen receives the coordinate value of the cross coordinate line in the upper left corner and saves it as the first standard value;

[0038] Aim the laser light at the center of the crosshairs in the upper left corner of the TV screen or projection screen, and press the calibration function key again;

[0039] The mouse pen calculates the cursor coordinate value of the current upper left corner cross coordinate line, compares the calculated coordinate value of the upper left corner cross coordinate line with the first standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the upper left corner cross coordinate line and the first standard value is less than a preset first difference threshold;

[0040] The mouse pen sends a second training command to perform calibration training using the coordinates of the lower right corner of the TV screen or the projection screen;

[0041] After receiving the command, the host interface module forwards the command to the host;

[0042] The host computer changes the cross coordinate line to the lower right corner of the TV screen or projection screen, and sends the coordinate value of the cross coordinate line at the lower right corner to the host computer interface module;

[0043] The host interface module forwards the coordinate value of the cross coordinate line in the lower right corner to the mouse pen;

[0044] The mouse pen receives the coordinate value of the cross coordinate line in the lower right corner and saves it as the second standard value;

[0045] Aim the laser light at the center of the crosshairs in the lower right corner of the TV screen or projection screen, and press the calibration function key again;

[0046] The mouse pen calculates the cursor coordinate value of the cross coordinate line at the lower right corner of the current TV screen or projection screen, analyzes the calculated coordinate value of the cross coordinate line at the lower right corner of the TV screen or projection screen with the second standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the cross coordinate line at the lower right corner and the second standard value is less than a preset second difference threshold;

[0047] The mouse pen sends an exit command to exit the calibration mode;

[0048] After receiving the exit command, the host interface module forwards the command to the host, and the host cancels the display of the cross coordinate line on the screen.

[0049] Optionally, the mouse pen also includes a plurality of batteries and a power management module, and the power management module is used to charge and manage each battery; the mouse pen determines whether the mouse pen is in use based on the current state of the first posture sensor. If the current state of the first posture sensor does not change and no operation is performed within a preset time period, the power management module controls the mouse pen to enter a sleep state and turns off the laser light; when the current state of the first posture sensor changes or there is a key operation, the power management module wakes up the mouse pen to enter a working state and turns on the laser light.

[0050] The technical solution adopted by the present invention includes the following technical effects:

[0051] 1. The first main control MCU in the mouse pen in the technical solution of the present invention is used to obtain the image of the screen taken by the camera, identify the screen imaging position in the image, calculate the pixel positions of the four corner points of the screen in the camera image sensor imaging, calculate the distance between the mouse pen and the screen, and calculate the relative inclination angles of the mouse pen and the screen in three axes. Finally, according to the pixel position of the current screen in the image sensor imaging, the distance between the mouse pen and the screen, and the relative inclination angles of the mouse pen and the screen in three axes, the screen coordinates of the point pointed by the physical cursor are calculated, and the calculated screen coordinates are sent to the host interface module through the first wireless communication module for controlling the menu in the screen, which effectively solves the problem of low convenience in operating the mouse pen due to the prior art and effectively improves the convenience of operating the mouse pen.

[0052] 2. In the technical solution of the present invention, the laser light and the camera are both arranged at the front end of the mouse pen, the ray direction of the laser light is parallel to the central axis of the camera, and the distance between the ray of the laser light and the central axis of the camera is less than a preset first distance threshold; when the laser light irradiates the screen, the camera captures the image of the current screen, so that if the laser light irradiates the center of the screen, the camera is also facing the center of the screen. At this time, the center point of the screen is imaged at the center position of the image sensor; if the laser light irradiates the edge of the screen, the camera is facing the edge of the screen. At this time, the edge of the screen is imaged at the center position of the image sensor, that is, the physical cursor irradiated by the laser light will always be imaged at the center position of the camera image sensor, which is convenient for the subsequent calculation of the screen coordinate value pointed to by the physical cursor of the laser light irradiation point.

[0053] 3. In the technical solution of the present invention, the screenshot image is a coded feature image frame with black dots on a white background. When the user is operating, the image on the screen is uncertain, and some image feature points are not obvious, which is not conducive to image recognition. At this time, the screen can be controlled to output a specific feature image frame, that is, a coded feature image frame with black dots on a white background, so as to improve the accuracy and resolution of image recognition. The coded image with black dots on a white background has a large contrast and obvious feature points, which is convenient for image recognition. Moreover, the coordinate calculation will only be performed when the preset trigger conditions are met, and the feature image frame will only be inserted when the image recognition is inaccurate. The maintenance time of the feature image frame is less than 0.1s, and the image is mainly white, so there is basically no visual impact on the user.

[0054] 4. The working scenarios of the mouse pen described in the technical solution of the present invention include TV remote control scenarios, projection demonstration scenarios and calibration scenarios, which can be applied to different usage scenarios, thus expanding the application scope of the mouse pen.

[0055] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0057] Figure 1 This is a schematic diagram of the structure of a mouse pen according to Embodiment 1 of the present invention;

[0058] Figure 2 This is a schematic diagram of the position distribution of the laser light and the camera in the mouse pen of Example 1 of the solution of the present invention;

[0059] Figure 3 This is a schematic diagram of the positional relationship between the physical cursor (digital cursor) output by the mouse pen and the resolution and screen size of the screen in Example 1 of the solution of the present invention;

[0060] Figure 4 A schematic diagram of an instantaneous screen image captured by a mouse pen camera in Example 1 of the solution of the present invention;

[0061] Figure 5 It is a schematic diagram of matching the instantaneous screen image and the screen screenshot image in the first embodiment of the solution of the present invention. DETAILED DESCRIPTION

[0062] In order to clearly illustrate the technical features of the present solution, the present invention is described in detail below through specific implementation methods and in conjunction with the accompanying drawings. The disclosure below provides many different embodiments or examples for realizing different structures of the present invention. In order to simplify the disclosure of the present invention, the components and settings of specific examples are described below. In addition, the present invention may repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed. It should be noted that the components illustrated in the accompanying drawings are not necessarily drawn to scale. The present invention omits the description of known components and processing techniques and processes to avoid unnecessary limitations on the present invention.

[0063] Embodiment 1

[0064] like Figure 1 As shown, the present invention provides an air mouse pen, comprising:

[0065] Mouse pen 1, mouse pen 1 (mouse pen body) includes a first main control MCU 11, a camera 12, a laser light 13, a first wireless communication module 14, a first attitude sensor 15 and an infrared distance sensor module 16; the camera 12 is used to capture the image of the current screen; the laser light 13 is used to illuminate the menu to be operated on the current screen to form a physical cursor (laser light irradiation point); the first attitude sensor 15 is used to detect the attitude inclination of the first attitude sensor relative to the three axes of the earth; the infrared distance sensor module 16 is used to measure the distance between the mouse pen and the screen; the first main control MCU 11 is used to obtain the instantaneous image of the current screen captured by the camera 12, the distance between the mouse pen 1 and the screen, the distance between the mouse pen 1 and the screen, and the attitude inclination of the first attitude sensor 15 relative to the three axes of the earth, according to the camera The instantaneous image of the current screen captured by the head 12 is identified, and the screen imaging position in the instantaneous image is calculated, and the pixel position of the current screen imaged by the image sensor in the camera 12 is calculated; according to the attitude inclination angle of the first attitude sensor 15 relative to the three axes of the earth and the attitude inclination angle of the screen relative to the three axes of the earth, the relative inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the three axes of the screen is calculated; according to the pixel position of the current screen imaged by the image sensor, the distance between the mouse pen 1 and the screen, and the relative inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the three axes of the screen, the screen coordinates of the point pointed by the physical cursor are calculated, and the calculated screen coordinates are sent to the host interface module 2 through the first wireless communication module 14, so that the user can control the screen according to the calculated screen coordinates;

[0066] The host interface module 2 includes a second main control MCU 21, a second attitude sensor 22 and a second wireless communication module 23. The second attitude sensor 22 is used to detect the attitude inclination angle of the second attitude sensor 22 relative to the earth in three axes. According to the attitude inclination angle of the second attitude sensor 22 relative to the earth in three axes, the attitude inclination angle of the screen relative to the earth in three axes is calculated. At the same time, the attitude inclination angle of the screen relative to the earth in three axes is sent to the first main control MCU 11 through the second wireless communication module 23; and the control command sent by the first main control MCU 11 is forwarded to the host 3 connected to the host interface module 2 for execution.

[0067] like Figure 2As shown, the laser light 13 and the camera 12 are both arranged at the front end of the mouse pen 1, the ray direction of the laser light 13 is parallel to the central axis of the camera 12, and the distance between the ray of the laser light 13 and the central axis of the camera 12 is less than a preset first distance threshold, wherein the preset first distance threshold can be adjusted according to actual conditions to make the distance between the ray direction of the laser light 13 and the central axis of the camera 12 as close as possible; when the laser light 13 irradiates the center of the screen, the camera 12 also faces the center of the screen, and at this time the center point of the screen is imaged at the center position of the camera 12 sensor; the installation position and angle of the laser light 13 and the camera 12 are fixed, when the laser light 13 moves on the screen, the area where the screen is imaged on the camera 12 sensor is also moving, and when the laser light 13 irradiates the edge of the screen, the camera 12 also faces the edge of the screen, and at this time the edge of the screen is imaged in the central area of ​​the camera 12 sensor.

[0068] like Figure 3-Figure 5 As shown, the working process of the first master MCU specifically includes: the first master MCU11 first sends a screen image capture command to the host interface module 2 through the first wireless communication module 14, and the host interface module 2 forwards the screenshot command to the host after receiving the screenshot command sent by the first master MCU11; the host captures the current screen image through the running driver, and sends the captured screen image data to the first master MCU11 through the second wireless communication module 23 of the host interface module 2.

[0069] After receiving the captured screen image data, the first main control MCU 11 immediately controls the camera 12 to actually take a picture of the screen, and obtains an instantaneous image of the current screen captured by the camera 12 .

[0070] According to the posture inclination angle of the screen relative to the three axes of the earth and the posture inclination angle of the first posture sensor 15 relative to the three axes of the earth, the relative inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the screen is calculated; wherein, the relative inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the screen is the sum of vector subtractions between the posture inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the three axes of the earth and the inclination angle of the screen relative to the three axes of the earth; the posture inclination angle of the screen relative to the three axes of the earth is the sum of vector additions between the posture inclination angle of the second posture sensor 22 relative to the three axes of the earth and the posture inclination angle of the second posture sensor 22 relative to the three axes of the screen; the posture inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the three axes of the earth is the sum of vector additions between the posture inclination angle of the first posture sensor 15 relative to the three axes of the earth and the posture inclination angle of the first posture sensor 15 relative to the three axes of the image sensor in the camera 12 inside the mouse pen 1;

[0071] Specifically, the second posture sensor 22 is arranged in the host interface module 2, and the host interface module 2 is inserted into the USB interface of the host 3. If the host and the screen are integrated, then the inclination angle of the second posture sensor 22 relative to the three axes of the screen in the orthogonal coordinate system is fixed at θ1, and the second main control MCU 21 collects the three-axis component values ​​of the second posture sensor 22 in the orthogonal coordinate system, which is the inclination angle θ2 of the second posture sensor 22 relative to the three axes of the earth. By adding θ2 and θ1 for vector, the inclination angle θ3 of the screen relative to the three axes of the earth can be obtained; if the host and the screen are not integrated, then a command can be sent through the USB interface to set the inclination angle θ3 of the screen relative to the three axes of the earth to a fixed value;

[0072] Similarly, the camera 12 image sensor is arranged in the mouse pen 1, and always maintains a fixed inclination angle θ4 with the first posture sensor 15. The first main control MCU11 collects the three-axial component values ​​of the first posture sensor 15 in the orthogonal coordinate system, which is the inclination angle θ5 of the first posture sensor 15 relative to the three axes of the earth. By adding θ5 and θ4 by vector, the inclination angle θ6 of the camera 12 image sensor relative to the earth can be obtained. Finally, θ6 and θ3 are vector-subtracted to obtain θ7, which is the relative inclination angle of the camera 12 image sensor and the screen.

[0073] Taking the center point of the camera 12 sensor as the origin, according to the relative inclination angle of the image sensor in the camera 12 inside the mouse pen 1 relative to the screen, determine the geometric coordinates of the projection points of the four corner points of the current screen on the plane of the image sensor in the camera 12;

[0074] Specifically, the imaging of the screen on the image sensor of camera 12 is equivalent to the projection of the screen on the plane of the image sensor of camera 12. The outer dimensions of the screen are known. According to the inclination angle θ7 between the camera 12 sensor and the screen in three axial directions, the geometric coordinates Ca1, Cb1, Cc1, and Cd1 of the projection points of the four corner points A, B, C, and D of the screen on the plane of the image sensor of camera 12 are calculated through the projection relationship.

[0075] The captured screen image and the instantaneous image are scaled and transformed according to the distance between the mouse pen and the screen, and the pixel coordinates of the current screen imaged on the image sensor in the camera are obtained;

[0076] Specifically, light travels in a straight line, and the physical object and the image are proportional to the distance. The proportional coefficient k1 is equal to the ratio of the distance l between the mouse pen 1 and the screen and the focal length f of the camera 12 lens, that is, k1 = l / f; the geometric coordinates Ca1, Cb1, Cc1, and Cd1 of the current screen imaged on the image sensor in the camera are divided by the proportional coefficient k1 to obtain the geometric coordinates Ca2, Cb2, Cc2, and Cd2 of the current screen on the camera 12 sensor. This coordinate is in units of geometric size, and we need to use the pixels of the camera 12 image sensor as the unit for calculation. The geometric size of the pixels of the camera 12 image sensor is known. The proportional coefficient k2 is obtained by dividing the number of pixels in a row by the geometric side length. The coordinates Ca2, Cb2, Cc2, and Cd2 are multiplied by the proportional coefficient k2 to obtain the coordinates Ca3, Cb3, Cc3, and Cd3, that is, the shape of the screen imaged on the camera 12 sensor in units of pixels, and the pixel coordinates of the current screen imaged on the camera image sensor).

[0077] Based on the feature points in the captured screen image, the imaging position of the current screen in the instantaneous image is identified, and the pixel coordinates of the four corner points of the screen boundary in the instantaneous image are determined; specifically, the first main control MCU11 will also transform the captured screen image according to the above process, and calculate the image formed by the screenshot image (captured screen image) on the camera 12 sensor, which is used for subsequent search of the imaging position of the screen in the captured image.

[0078] Taking the center point of the camera sensor as the origin, the instantaneous image is transformed again according to the known aspect ratio of the screen, so that the screen boundary in the instantaneous image is consistent with the actual screen in shape and aspect ratio;

[0079] According to the pixel coordinates of the four corner points of the screen and the laser light irradiation point in the instantaneous image, the screen coordinate value pointed to by the physical cursor of the laser light irradiation point is calculated; specifically, since the laser light 13 ray is parallel to the axis of the camera 12 and the distance between the two is very small, the camera 12 is facing the irradiation point of the laser light 13, so the point irradiated by the laser light 13 is finally imaged at the center point of the image sensor of the camera 12. The pixel coordinates of the center point of the image sensor of the camera 12 are known, that is, equal to half of the pixel of the image sensor. In this way, the pixel coordinates Ca4, Cb4, Cc4, Cd4 of the four corner points A, B, C, D of the screen imaged on the instantaneous image (obtained by the inverse transformation of the projection of the pixel coordinates Ca3, Cb3, Cc3, Cd3 of the current screen imaged on the image sensor in the camera) and the pixel coordinate Cp4 of the irradiation point P of the laser light 13 imaged on the instantaneous image are determined.

[0080] The first main control MCU11 calculates the coordinate position Cp1 of point P on the actual screen according to the inverse operation of the projection, where the horizontal coordinate is Cx and the vertical coordinate is Cy;

[0081] The first main control MCU11 can also calculate the coordinate position Cp1 of point P on the actual screen according to the relative relationship between Cp4 and Ca4, Cb4, Cc4, and Cd4, where the horizontal coordinate is Cx and the vertical coordinate is Cy.

[0082] like Figure 3 As shown, the laser light shines on point P on the screen, i.e., the physical cursor, and the corresponding screen coordinates are also at point P;

[0083] According to the coordinates of the four corner points A, B, C, D and the laser light irradiation point P on the screen, the coordinate value of the position pointed by the physical cursor of the laser light irradiation point is calculated, specifically:

[0084] like Figure 4 As shown, the screen coordinate value (Cp1) corresponding to the physical cursor is (Cx, Cy), where Cx = Px / PDx*Rx; Cy = Py / PDy*Ry; the horizontal resolution of the screen is Rx, and the vertical resolution of the screen is Ry; the number of horizontal pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Px, and the number of vertical pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Py; the total number of horizontal pixels in the screen imaging area is PDx, and the total number of vertical pixels in the screen imaging area is PDy. The pixel coordinates of the laser light irradiation point in the instantaneous image are the pixel coordinates of the center point of the camera image sensor.

[0085] The horizontal resolution Rx and vertical resolution Ry of the screen are known, but the screen cannot sense the physical coordinate position of the laser light 13, namely Px and Py, so it is necessary to use the camera 12 to take a picture of the screen, identify the imaging area of ​​the screen in the captured picture, and then determine the pixel coordinates Ca4, Cb4, Cc4, Cd4 (by) of the four corner points in the instantaneous image. At the same time, the position Cp4 of the image of point P on the image sensor of the camera 12 is fixed, namely the center position of the image sensor. In this way, the relative position relationship between the physical cursor point P and the four corner points A, B, C, and D of the screen on the image sensor of the camera 12 can be determined, and then the relative position relationship between the physical cursor point P and the four corner points A, B, C, and D of the screen on the screen can be restored according to the inverse transformation of the projection. In this way, Px, Py, PDx, and PDy can be determined, and the screen coordinate value corresponding to the physical cursor can be calculated as (Cx, Cy).

[0086] The method for obtaining the screenshot image of the screen is as follows:

[0087] After the first main control MCU11 receives the captured screen image and the instantaneous image, it transforms the captured screen image according to the relative inclination angle between the image sensor in the camera 12 and the current screen and the distance between the mouse pen 1 and the screen, so that the screen boundary in the captured screen image and the screen boundary in the instantaneous image are consistent in shape and aspect ratio, extracts feature points (such as the four corner points of the screen boundary) of the instantaneous image formed by the captured screen image on the image sensor in the camera, and uses a preset image recognition algorithm to compare and search for the imaging area of ​​the captured screen image in the instantaneous image actually captured, and determines the pixel coordinates Ca4, Cb4, Cc4, and Cd4 of the four corner points of the current screen in the instantaneous image actually captured.

[0088] There is no special requirement for the position of the host. It can be integrated with the screen or separated from the screen. The host interface module 2 is inserted on the host 3. If the host 3 and the screen are integrated, the second posture sensor 22 of the interface module 2 can be used to detect the posture of the screen. If the host 3 and the screen are separated, the posture of the screen cannot be detected. However, the screen is usually fixed, so it can be set to a fixed value. In addition, the inclination data only plays an auxiliary role in the calculation of the digital cursor coordinate value, so a certain error is allowed. The screenshot image is obtained by the driver through the operating system API);

[0089] The host 3 takes a screenshot of the current screen image, and sends the screenshot image data to the first main control MCU 11 through the host interface module 2;

[0090] The first master MCU 11 receives the screenshot data.

[0091] Among them, Figure 5 As shown, before calculating the screen coordinate value of the physical cursor emitted by the laser light 13, it is necessary to first determine the boundary of the imaging area of ​​the screen on the camera 12 sensor. The method used is to use the screen image for identification. The host 3 needs to install and run the driver before using the mouse pen 1. The host 3 can obtain the screenshot image. The host interface module 2 (the second main control MCU21) transmits the screenshot image to the first main control MCU11 in the mouse pen 1 through the second wireless communication module 23. After the camera 12 of the mouse pen 1 takes a picture of the screen, it searches for and identifies the screenshot image sent by the host interface module 2 in the photographed picture (instantaneous image) through the image recognition algorithm. After finding it, the boundary of the screen in the transformed photo can be determined according to the matching result between the instantaneous image after the scaling transformation and the screenshot image of the screen, thereby calculating Px, Py, PDx, and PDy.

[0092] Considering that the instantaneous screen image photographed by the mouse pen 1 and the screen shot image sent by the host interface module 2 are different in resolution and screen size, they need to be identified by an image recognition algorithm.

[0093] The image on the screen is uncertain when the user is operating, and some image feature points are not obvious, which is not conducive to image recognition. At this time, the screen can be controlled to output specific feature image frames to improve the accuracy and resolution of image recognition. The output specific image is a coded image with black dots on a white background, with a large contrast and obvious feature points, which is convenient for image recognition. Coordinate calculation is performed only when the user presses a key operation, and the feature image frame is inserted only when the image recognition is inaccurate. The maintenance time of the feature image frame is less than 0.1s, and the image is mainly white, so there is basically no visual impact on the user.

[0094] The specific operation process of controlling the screen to output a specific feature image frame is as follows: the first main control MCU11 detects a key action (preset trigger condition or preset trigger action) and needs to calculate the coordinates; the first main control MCU11 sends an output feature image frame command to the host interface module 2 through the first wireless communication module 14, and the host interface module 2 forwards the command to the host 3 after receiving the output feature image frame command sent by the first main control MCU11; the host 3 displays the feature image on the screen through the running driver program, and captures the current screen image, and the host 3 sends the captured screen image data to the first main control MCU11 through the second wireless communication module 23 of the host interface module 2. After receiving the screen image capture data, the first main control MCU11 controls the camera 12 to take a picture of the screen. After taking the picture, the first main control MCU11 sends a restore normal display command to the host interface module 2 through the first wireless communication module 14, and the host interface module 2 receives the restore normal display command sent by the first main control MCU11, and then forwards the command to the host 3; the host 3 cancels the screen display feature image through the running driver program and restores the normal image display of the screen.

[0095] The image recognition algorithm may be a pre-trained convolutional neural network, or other image recognition algorithms, and the present invention is not limited thereto.

[0096] The working scenes of the mouse pen 1 include a TV remote control scene, a projection demonstration scene, and a calibration scene. The mouse pen 1 also includes a confirmation key and a function key, wherein the function key includes a drawing function key and a calibration function key.

[0097] When the working scene of the mouse pen 1 is a TV remote control scene, in response to the need to click on the menu, the laser light is aimed at the menu icon on the TV screen and the confirmation key is pressed; in response to the need to turn the page, the laser light 13 is moved outside the TV screen and beyond the TV screen boundary, and then returns to the TV screen;

[0098] When the working scene of the mouse pen 1 is a projection demonstration scene, in response to the need to click on the menu, the laser light 13 is aimed at the menu icon on the projection screen, and the confirmation key is pressed; in response to the need to turn the page, the laser light 13 is moved outside the projection screen, beyond the projection screen boundary, and then returned to the projection screen; in response to the need to circle a picture, the drawing function key is pressed, and the laser light 13 is used to draw an outline on the screen at the same time, and the driver on the host 3 follows the handwriting of the circle drawing on the screen and keeps this handwriting until the circle drawing handwriting is cleared after the page is turned and the display is refreshed;

[0099] When the working scene of the mouse pen 1 is the calibration scene, in response to the calibration training of the coordinates of the mouse pen 1, press the calibration function key, wait for a crosshair coordinate line to be superimposed and displayed in the upper left corner of the current TV screen or projection screen, aim the laser light 13 at the center of the crosshair in the upper left corner of the screen, and press the calibration function key again; move the crosshair coordinate line to the lower right corner of the TV screen or projection screen, aim the laser light 13 at the center of the crosshair in the lower right corner of the TV screen or projection screen again, and press the calibration function key; after the calibration is completed, the mouse pen exits the calibration scene.

[0100] The training optimization of the calibration scene specifically includes:

[0101] Press the calibration function key, and the mouse pen 1 enters the calibration mode;

[0102] The first main control MCU 11 in the mouse pen 1 sends a first training command to perform calibration training using the coordinates of the upper left corner of the TV screen or the projection screen;

[0103] After receiving the training command, the second main control MCU 21 in the host interface module 2 forwards the training command to the host 3;

[0104] The host 3 controls the superimposition and display of a cross coordinate line at the upper left corner of the TV screen or the projection screen, and sends the coordinate value of the cross coordinate line at the upper left corner to the second main control MCU 21 in the host interface module 2;

[0105] The second main control MCU 21 in the host interface module 2 forwards the coordinate value of the cross coordinate line in the upper left corner to the first main control MCU 11 in the mouse pen 1;

[0106] The first main control MCU11 in the mouse pen 1 receives the coordinate value of the cross coordinate line in the upper left corner and saves it as the first standard value;

[0107] Aim the laser light 13 at the center of the cross coordinate line in the upper left corner of the TV screen or projection screen, and press the calibration function key again;

[0108] The first main control MCU11 in the mouse pen 1 calculates the cursor coordinate value of the current upper left corner cross coordinate line, compares the calculated coordinate value of the upper left corner cross coordinate line with the first standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the upper left corner cross coordinate line and the first standard value is less than a preset first difference threshold;

[0109] The first main control MCU 11 in the mouse pen 1 sends a second training command to perform calibration training using the coordinates of the lower right corner of the TV screen or the projection screen;

[0110] After receiving the command, the second main control MCU 21 in the host interface module forwards the command to the host 3;

[0111] The host 3 changes the cross coordinate line to the lower right corner of the TV screen or projection screen, and sends the coordinate value of the cross coordinate line at the lower right corner to the second main control MCU 21 in the host interface module 2;

[0112] The second main control MCU 21 in the host interface module 2 forwards the coordinate value of the cross coordinate line in the lower right corner to the first main control MCU 11 in the mouse pen 1;

[0113] The first main control MCU 11 in the mouse pen 1 receives the coordinate value of the cross coordinate line in the lower right corner and saves it as the second standard value;

[0114] Aim the laser light 13 at the center of the cross coordinate line in the lower right corner of the TV screen or projection screen, and press the calibration function key again;

[0115] The first main control MCU11 in the mouse pen 1 calculates the cursor coordinate value of the cross coordinate line at the lower right corner of the current TV screen or projection screen, analyzes the calculated coordinate value of the cross coordinate line at the lower right corner of the TV screen or projection screen with the second standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the cross coordinate line at the lower right corner and the second standard value is less than the preset second difference threshold;

[0116] The first main control MCU 11 in the mouse pen 1 sends an exit command to exit the calibration mode;

[0117] After receiving the exit command, the second main control MCU 21 in the host interface module 2 forwards the command to the host 3, and the host 3 cancels the display of the cross coordinate line on the screen.

[0118] When the user operates the mouse pen, due to the different positions and angles between the mouse pen 1 and the screen, the picture taken by the camera is the effect of scaling, twisting, and rotating the real screen. The first main control MCU 11 needs to eliminate the effects of scaling, twisting, and rotation when searching for the screen boundary, so these transformations must be processed accordingly in the image recognition algorithm to make the calculated cursor coordinates more accurate. The first main control MCU 11 does not simply use the image recognition algorithm to eliminate the effects of scaling, twisting, and rotation, but also measures the distance between the mouse pen and the screen through the infrared ranging module 16, and calculates the relative tilt angle through the first attitude sensor 15 on the mouse pen 1 and the second attitude sensor 22 on the host interface module 2, to assist in analyzing the effects of scaling, twisting, and rotation. The first attitude sensor 15 and the second attitude sensor 22 can both be gravity / gyroscope / geomagnetic sensors.

[0119] The host interface module 2 is inserted into the host 3, and usually maintains a fixed position relationship with the screen to obtain a screenshot image. When in use, the host interface module 2 sends the posture data of the screen detected by itself to the first main control MCU11 in the mouse pen 1 through the second wireless communication module 23. The first main control MCU11 compares the posture data of the screen with the posture data of the mouse pen 1 detected by itself, and calculates the relative position in space between the image sensor of the camera 12 and the screen and the angles in three axes. These angle data can be used to assist in correcting the deformation of the image taken by the camera 12.

[0120] The mouse pen 1 also includes a battery 17 and a power management module 18, and the power management module 18 is used to charge and manage the battery 17; the mouse pen 1 determines whether the mouse pen 1 is in use based on the current state of the first posture sensor 15. If the current state of the first posture sensor 15 does not change and no operation is performed within a preset time period, the power management module 18 controls the mouse pen 1 to enter a sleep state and turn off the laser light 13; when the current state of the first posture sensor 15 changes or there is a key operation, the power management module 18 wakes up the mouse pen 1 to enter a working state and turns on the laser light 13.

[0121] In the projection demonstration scene, when the mouse pen 1 is used to circle a picture, the cursor trajectory data is first received, and then the trajectory data is de-jittered and optimized, so that the handwriting of the circle becomes smooth and natural.

[0122] The mouse pen 1 communicates with the host 3 through the host interface module 2, controls the host 3 to take screenshots, insert special identification frames and other operations, obtains the data required for calculating coordinates, and after calculating the screen coordinates, sends the user's control operation information through the first wireless communication module 14.

[0123] The complete normal working mode of the mouse pen is as follows:

[0124] (1) The first main control MCU 11 in the mouse pen 1 detects the action of a key or the first gesture motion sensor 15, wakes up, enters a normal working mode, and turns on the laser light 13;

[0125] (2) The user directs the laser light 13 toward a predetermined position on the screen;

[0126] (3) The first main control MCU 11 in the mouse pen 1 sends a screenshot command through the first wireless communication module 14 to read the screenshot image data;

[0127] (4) After receiving the screenshot command, the second main control MCU 21 in the host interface module 2 forwards the screenshot command to the host 3 through the USB interface;

[0128] (5) The host 3 takes a screenshot of the current screen image and sends the screenshot image data to the host interface module 2 via the USB interface;

[0129] (6) The second main control MCU 21 in the host interface module 2 sends the screen capture image data to the first main control MCU 11 in the mouse pen 1 through the second wireless communication module 23;

[0130] (7) The first master MCU 11 in the mouse pen 1 receives the screen capture image data (captures the screen image) from the second master MCU 21 in the host interface module 2;

[0131] (8) The first main control MCU 11 in the mouse pen 1 controls the camera 12 to take a picture of the screen (instantaneous image);

[0132] (9) The first main control MCU 11 in the mouse pen 1 sends a read command through the first wireless communication module 14 and the second wireless communication module 23 to read the posture data of the second posture magnetic sensor 22 in the host interface module 2 relative to the three axes of the earth;

[0133] (10) The second main control MCU 21 in the host interface module 2 receives the read command and collects the posture data of the second posture magnetic sensor 22 relative to the three axes of the earth;

[0134] (11) The second main control MCU 21 in the host interface module 2 sends the posture data of the second posture magnetic sensor 22 relative to the three axes of the earth to the first main control MCU 11 in the mouse pen 1 through the second wireless communication module 23 and the first wireless communication module 14;

[0135] (12) The first main control MCU 11 in the mouse pen 1 receives the posture data of the second posture magnetic sensor 22 relative to the three axes of the earth;

[0136] (13) The first main control MCU 11 in the mouse pen 1 collects the first attitude sensor 15 thereof and collects the attitude inclination angle of the first attitude sensor 15 relative to the three axes of the earth;

[0137] (14) The first main control MCU 11 in the mouse pen 1 calculates the relative inclination angle and rotation angle between the image sensor of the camera 12 and the screen according to the posture data of the second posture magnetic sensor 22 relative to the three axes of the earth and the posture inclination angle of the first posture sensor 15 relative to the three axes of the earth;

[0138] (15) The first main control MCU 11 in the mouse pen 1 controls the infrared distance sensor module 16 to measure the distance between the mouse pen 1 and the screen;

[0139] (16) The first main control MCU 11 in the mouse pen 1 takes the center point of the camera sensor as the origin, transforms the captured screen image and the instantaneous image according to the relative inclination angle, rotation angle and distance between the mouse pen 1 and the screen, and determines the geometric coordinates of the projection points of the four corner points of the current screen on the image sensor plane of the camera 12;

[0140] (17) The first main control MCU 11 in the mouse pen 1 scales the transformed image according to the distance between the mouse pen 1 and the screen, and finally calculates the image of the screen on the image sensor of the camera 12 to obtain the pixel coordinates of the current screen imaged on the image sensor in the camera;

[0141] (18) The first main control MCU 11 in the mouse pen 1 uses an image recognition algorithm to automatically identify a matching screen shot image (capture a screen image) from the photos taken by the camera 12;

[0142] (19) The first main control MCU 11 in the mouse pen 1 determines the boundary and four corner points of the screen in the instantaneous image according to the matching result, that is, determines the pixel coordinates of the four corner points of the boundary of the screen in the instantaneous image;

[0143] (20) The first main control MCU11 in the mouse pen 1 uses the center point of the image sensor of the camera 12 as the coordinates of the physical cursor, and coordinates the four corner points. The first main control MCU11 in the mouse pen 1 performs an inverse transformation on the pixel coordinates of the physical cursor and the four corner points on the image sensor of the camera 12 according to the known aspect ratio of the screen, and the relative inclination angle and distance between the image sensor of the camera 12 and the screen, to obtain the pixel coordinates of the four corner points of the boundary of the screen in the instantaneous image;

[0144] (21) The first main control MCU11 in the mouse pen 1 calculates the pixel points of PDx, PDy, Px, and Py according to the result of the inverse transformation;

[0145] (22) The first main control MCU 11 in the mouse pen 1 calculates the absolute coordinate value of the physical cursor;

[0146] (23) The first main control MCU 11 in the mouse pen 1 sends the absolute coordinate value of the physical cursor to the second main control MCU 21 in the host interface module 2 through the first wireless communication module 14 and the second wireless communication module 23;

[0147] (24) The second main control MCU 21 in the host interface module 2 sends the absolute coordinate value of the physical cursor to the host 3 through the USB interface;

[0148] (25) Host 3 sends the absolute coordinate value of the physical cursor to the host operating system for corresponding control operations;

[0149] (26) The first main control MCU 11 in the mouse pen 1 monitors the first posture sensor 15, and enters the sleep mode if there is no movement for a long time and no other operations.

[0150] In addition, the workflow of the complete calibration mode is as follows:

[0151] (1) Press the calibration function key, and the mouse pen 1 enters the calibration mode;

[0152] (2) The first main control MCU 11 in the mouse pen 1 sends a training command through the first wireless communication module 14 and the second wireless communication module 23, and calibrates using the coordinates of the upper left corner;

[0153] (3) After receiving the command, the second master control MCU 21 in the host interface module 2 forwards the command to the host 3 through the USB interface;

[0154] (4) Host 3 controls to display a cross coordinate line in the upper left corner of the screen;

[0155] (5) The host 3 sends the coordinate value of the cross coordinate line in the upper left corner to the second main control MCU 21 in the host interface module 2;

[0156] (6) The second main control MCU 21 in the host interface module 2 forwards the coordinate value of the cross coordinate line in the upper left corner to the first main control MCU 11 in the mouse pen 1 through the second wireless communication module 23 and the first wireless communication module 14;

[0157] (7) The first main control MCU 11 in the mouse pen 1 receives the coordinate value of the cross coordinate line in the upper left corner and saves it as the first standard value;

[0158] (8) The user aligns the laser light 13 with the center of the cross coordinate line in the upper left corner of the screen and presses the calibration function key again;

[0159] (9) The first main control MCU 11 in the mouse pen 1 calculates the cursor coordinate value of the center of the current upper left corner cross coordinate line according to the normal working mode;

[0160] (10) The first main control MCU 11 in the mouse pen 1 analyzes the calculated cursor coordinate value of the center of the current upper left corner cross coordinate line with the first standard value, and corrects the working scene parameters in the image recognition algorithm;

[0161] (11) The first main control MCU 11 in the mouse pen 1 sends a training command through the first wireless communication module 14 and the second wireless communication module 23, and calibrates using the coordinates of the lower right corner;

[0162] (12) After receiving the training command, the second main control MCU 21 in the host interface module 2 forwards the training command to the host 3 through the USB interface;

[0163] (13) Host 3 moves the cross coordinate line to the lower right corner of the screen;

[0164] (14) The host 3 sends the coordinate value of the cross coordinate line in the lower right corner to the second main control MCU 21 in the host interface module 2;

[0165] (15) The second main control MCU 21 in the host interface module 2 forwards the coordinate value of the cross coordinate line in the lower right corner to the first main control MCU 11 in the mouse pen 1 through the second wireless communication module 23 and the first wireless communication module 14;

[0166] (16) The first main control MCU 11 in the mouse pen 1 receives the coordinate value of the cross coordinate line in the lower right corner and saves it as the second standard value;

[0167] (17) The user aligns the laser light 13 with the center of the cross coordinate line in the lower right corner of the screen and presses the calibration function key again;

[0168] (18) The first main control MCU 11 in the mouse pen 1 calculates the cursor coordinate value of the center of the current lower right corner cross coordinate line according to the normal working mode;

[0169] (19) The first main control MCU 11 in the mouse pen 1 calculates the cursor coordinate value of the center of the current lower right corner cross coordinate line and analyzes it with the second standard value, and corrects the working scene parameters in the image recognition algorithm again;

[0170] (20) The first main control MCU 11 in the mouse pen 1 sends an exit command through the first wireless communication module 14 and the second wireless communication module 23 to exit the calibration mode;

[0171] (21) The mouse pen exits the calibration mode and enters the normal working mode;

[0172] (22) After receiving the exit command, the second master control MCU 21 in the host interface module 2 forwards the command to the host 3 through the USB interface;

[0173] (23) Host 3 cancels the display of the cross coordinate line on the screen.

[0174] In the technical solution of the present invention, the air mouse pen has a laser light. When the laser light is irradiated onto the screen, there is a light spot, forming a physical cursor. For an ordinary screen, such as an LED screen or a projection wall, it is impossible to perceive the irradiation position of the laser light. The air mouse pen of the technical solution of the present invention also has a camera. The screen is photographed by the camera while the laser light is irradiating. The position of the laser light irradiation is different, and the imaging position of the screen in the camera image sensor is different in the image taken by the camera. Not only can the screen be photographed, and the specific position of the laser light irradiation point on the screen, that is, the digital cursor, can be calculated according to the imaging position of the screen in the camera image sensor, but the coordinates of the digital cursor can also be sent to the host through wireless communication, so that the digital cursor on the host is synchronized with the physical cursor of the laser light. Then, in conjunction with the function buttons on the air mouse pen, the corresponding menu on the screen position irradiated by the laser light can be operated.

[0175] The current remote control only has direction keys, and it is time-consuming to select menus through the direction keys during operation. Especially when the menus on the operation interface are complex, the user experience is poor. However, the air mouse pen in the technical solution of the present invention can directly use a laser light to illuminate the menu to be operated, which is more convenient, quick and intuitive.

[0176] The first main control MCU in the mouse pen in the technical solution of the present invention is used to obtain the image of the screen taken by the camera, identify the screen imaging position in the image, calculate the pixel positions of the four corner points of the screen in the camera image sensor imaging, calculate the distance between the mouse pen and the screen, and calculate the relative inclination angles of the mouse pen and the screen in three axes. Finally, according to the pixel position of the current screen in the image sensor imaging, the distance between the mouse pen and the screen, and the relative inclination angles of the mouse pen and the screen in three axes, the screen coordinates of the point pointed by the physical cursor are calculated, and the calculated screen coordinates are sent to the host interface module through the first wireless communication module for controlling the menu in the screen, effectively solving the problem of low convenience of mouse pen operation caused by the prior art, and effectively improving the convenience of mouse pen operation.

[0177] In the technical solution of the present invention, the laser light and the camera are both arranged at the front end of the mouse pen, the ray direction of the laser light is parallel to the central axis of the camera, and the distance between the ray direction of the laser light and the central axis of the camera is less than a preset first distance threshold; when the laser light irradiates the center of the screen, the camera also faces the screen to obtain the image of the current screen, that is, the physical cursor irradiated by the laser light will always be imaged at the center position of the camera image sensor.

[0178] In the technical solution of the present invention, the screen captured image is subjected to angular projection transformation and scaling transformation according to the relative inclination angle and distance between the camera image sensor and the screen, and the transformed image is used for search and identification, thereby ensuring the accuracy and reliability of the transformed and identified screen boundaries and the coordinates of the four corner points, thereby improving the accuracy of the calculation of the screen coordinate values ​​of the physical cursor of the laser light.

[0179] The recognition of the screenshot image in the technical solution of the present invention is specifically as follows: the screenshot image is recognized in the instantaneous image of the photo through a convolutional neural network algorithm, and the position of the screen imaging on the camera sensor is calculated through a two-dimensional Fourier transform algorithm; in order to adapt to different application environments, some calibration parameters are set, including: the distance between the laser light ray and the axis line of the camera, the horizontal calibration compensation coefficient, the vertical calibration compensation coefficient, the screen fixed posture parameter or the measured parameter, the first posture sensor calibration coefficient, the second posture sensor calibration coefficient, and the working scene parameters are adjusted and optimized to adapt to scenes with different characteristics and different image styles. The working scene parameters support training optimization through calibration scenes, and the calibration scenes include: training optimization of the crosshair center in the upper left corner of the screen and training optimization of the crosshair center in the lower right corner of the screen, thereby ensuring the reliability of the image recognition algorithm.

[0180] The working scenarios of the mouse pen described in the technical solution of the present invention include TV remote control scenarios, projection demonstration scenarios and calibration scenarios, and can be applied to different usage scenarios, thereby expanding the application scope of the mouse pen.

[0181] Although the above describes the specific implementation mode of the present invention in conjunction with the accompanying drawings, it is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that various modifications or variations that can be made by those skilled in the art on the basis of the technical solution of the present invention without creative work are still within the scope of protection of the present invention.

Claims

1. An air mouse pen, characterized in that: include: A mouse pen, the mouse pen comprising a first main control MCU, a camera, a laser light, a first wireless communication module, a first attitude sensor and an infrared ranging sensor module; The camera is used to collect the instantaneous image of the current screen; the laser light is used to illuminate the menu to be operated on the current screen to form a physical cursor; the first posture sensor is used to detect the posture inclination of the first posture sensor relative to the three axes of the earth; the infrared ranging sensor module is used to measure the distance from the mouse pen to the screen; the first main control MCU is used to obtain the instantaneous image of the current screen collected by the camera, the distance between the mouse pen and the screen, and the posture inclination of the first posture sensor relative to the three axes of the earth, and identify the screen imaging position in the instantaneous image according to the instantaneous image of the current screen collected by the camera, and calculate the pixel position of the current screen imaged by the image sensor in the camera; calculate the relative inclination of the image sensor in the camera inside the mouse pen relative to the three axes of the screen according to the posture inclination of the first posture sensor relative to the three axes of the earth and the posture inclination of the screen relative to the three axes of the earth; calculate the screen coordinates of the point pointed by the physical cursor according to the pixel position of the current screen imaged by the image sensor, the distance between the mouse pen and the screen, and the relative inclination of the image sensor in the camera inside the mouse pen relative to the three axes of the screen, and send the calculated screen coordinates to the host interface module through the first wireless communication module, so that the user can control the screen according to the calculated screen coordinates; A host interface module, the host interface module includes a second main control MCU, a second attitude sensor and a second wireless communication module, the second attitude sensor is used to detect the attitude inclination angle of the second attitude sensor relative to the earth in three axes, the second main control MCU is used to calculate the attitude inclination angle of the screen relative to the earth in three axes according to the attitude inclination angle of the second attitude sensor relative to the earth in three axes, and at the same time send the attitude inclination angle of the screen relative to the earth in three axes to the first main control MCU through the second wireless communication module; and forward the control command sent by the first main control MCU received to the host connected to the host interface module for execution.

2. The air mouse pen according to claim 1, characterized in that: The laser light and the camera are both arranged at the front end of the mouse pen, the ray direction of the laser light is parallel to the central axis of the camera, and the distance between the ray direction of the laser light and the central axis of the camera is less than a preset first distance threshold; when the laser light irradiates the center of the screen, the camera faces the center of the screen to obtain the image of the current screen, and the center point of the screen is imaged at the center position of the image sensor in the camera; when the laser light irradiates the edge of the screen, the camera faces the edge of the screen, and the edge of the screen is imaged at the center position of the image sensor in the camera.

3. The air mouse pen according to claim 2, characterized in that: The working process of the first master control MCU specifically includes: Sending a screen image capture command to the host interface module through the first wireless communication module, and the host interface module forwarding the screen capture command to the host after receiving the screen capture command sent by the first master control MCU; the host captures the current screen image, and sends the captured screen image data to the first master control MCU through the second wireless communication module in the host interface module; After receiving the captured screen image data, the camera is controlled to actually take a picture of the screen to obtain an instantaneous image of the current screen captured by the camera; According to the posture inclination angle of the screen relative to the earth in three axes and the posture inclination angle of the first posture sensor relative to the earth in three axes, the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen is calculated; wherein, the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen is the sum of vector subtractions between the posture inclination angle of the image sensor in the camera inside the mouse pen relative to the earth in three axes and the inclination angle of the screen relative to the earth in three axes; the posture inclination angle of the screen relative to the earth in three axes is the sum of vector additions between the posture inclination angle of the second posture sensor relative to the earth in three axes and the posture inclination angle of the second posture sensor relative to the screen in three axes; the posture inclination angle of the image sensor in the camera inside the mouse pen relative to the earth in three axes is the sum of vector additions between the posture inclination angle of the first posture sensor relative to the earth in three axes and the posture inclination angle of the first posture sensor relative to the image sensor in the camera inside the mouse pen; Taking the center point of the camera sensor as the origin, according to the relative inclination angle of the image sensor in the camera inside the mouse pen relative to the screen, determine the geometric coordinates of the projection points of the four corner points of the current screen on the plane of the image sensor in the camera; The captured screen image and the instantaneous image are scaled and transformed according to the distance between the mouse pen and the screen, and the pixel coordinates of the current screen imaged on the image sensor in the camera are obtained; Based on the feature points in the captured screen image, the imaging position of the current screen in the instantaneous image is identified, and the pixel coordinates of the four corner points of the screen boundary in the instantaneous image are determined; Taking the center point of the camera sensor as the origin, the instantaneous image is transformed again according to the known aspect ratio of the screen, so that the screen boundary in the instantaneous image is consistent with the actual screen in shape and aspect ratio; According to the pixel coordinates of the four corner points of the screen and the laser light irradiation point in the instantaneous image, the screen coordinate value pointed by the physical cursor of the laser light irradiation point is calculated.

4. The air mouse pen according to claim 3, characterized in that: The screen coordinate value pointed by the physical cursor of the laser light irradiation point is calculated based on the pixel coordinates of the four corner points of the screen and the laser light irradiation point in the instantaneous image as follows: The screen coordinate value pointed by the physical cursor of the laser light irradiation point is (Cx, Cy), where Cx = Px / PDx*Rx; Cy = Py / PDy*Ry; the horizontal resolution of the screen is Rx, and the vertical resolution of the screen is Ry; the number of horizontal pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Px, and the number of vertical pixels from the upper left corner of the screen imaging area to the center point of the camera sensor is Py; the total number of horizontal pixels in the screen imaging area is PDx, and the total number of vertical pixels in the screen imaging area is PDy; The pixel coordinates of the laser light irradiation point in the instantaneous image are the pixel coordinates of the center point of the camera image sensor.

5. The air mouse pen according to claim 3, characterized in that: The method of identifying the imaging position of the current screen in the instantaneous image based on the feature points in the captured screen image and determining the pixel coordinates of the four corner points of the boundary of the screen in the instantaneous image specifically includes: After the first main control MCU receives the captured screen image and the instantaneous image, it transforms the captured screen image according to the relative inclination angle between the image sensor in the camera and the current screen and the distance between the mouse pen and the screen, so that the screen boundary in the captured screen image and the screen boundary in the instantaneous image are consistent in shape and aspect ratio, extracts feature points from the instantaneous image formed by the captured screen image on the image sensor in the camera, and uses a preset image recognition algorithm to compare and search for the imaging area of ​​the captured screen image in the instantaneous image actually captured, and determines the pixel coordinates of the four corner points of the current screen in the instantaneous image actually captured.

6. The air mouse pen according to claim 5, characterized in that: The screen shot image is a coded feature image frame with black dots on a white background. When the first main control MCU detects a preset trigger action, it sends a command to output the coded feature image frame to the host interface module through the first wireless communication module. The host interface module forwards the command to output the coded feature image frame sent by the first main control MCU to the host. The host displays the coded feature image frame on the screen and captures the current screen image. The host sends the captured screen image data to the first main control MCU through the second wireless communication module in the host interface module. After receiving the screen image capture data, the first main control MCU controls the camera to take a photo of the screen. After taking the photo, the first main control MCU controls the camera to take a photo of the screen. A main control MCU sends a restore normal display command to the host interface module through the first wireless communication module, and the host interface module forwards the restore normal display command sent by the first main control MCU to the host; the host cancels the screen display feature image and restores the normal image display of the screen; wherein, the image recognition algorithm includes a number of working scene parameters, and the working scene parameters are adjusted and optimized to adapt to scenes with different characteristics and different image styles. The working scene parameters support training optimization through intelligent training scenes, and the intelligent training scenes include: training optimization of the crosshair center in the upper left corner of the screen and training optimization of the crosshair center in the lower right corner of the screen.

7. The air mouse pen according to claim 6, characterized in that: The working scenarios of the mouse pen include TV remote control scenario, projection demonstration scenario and intelligent training scenario.

8. The air mouse pen according to claim 7, characterized in that: The mouse pen also includes a confirmation key and a function key, and the function key includes a drawing function key and a training function key; When the working scene of the mouse pen is a TV remote control scene, in response to the need to click on the menu, aim the laser light at the menu icon on the TV screen and press the confirmation key; In response to the need to turn the page, the laser light is moved outside the TV screen and beyond the limit of the TV screen, and then returns to the TV screen; When the working scene of the mouse pen is the projection demonstration scene, in response to the need to click on the menu, aim the laser light at the menu icon on the projection screen and press the confirmation key; In response to the need to turn the page, the laser light is moved outside the projection screen and beyond the projection screen boundary, and then returned to the projection screen; When you need to circle a picture, press and hold the drawing function key and use the laser light to draw the outline. The frame line will be cancelled after changing the page. When the working scene of the mouse pen is the intelligent training scene, in response to the intelligent training of the mouse pen, press the training function key, wait for the coordinate line of a crosshair to be superimposed and displayed in the upper left corner of the current TV screen or projection screen, aim the laser light at the center of the crosshair in the upper left corner of the screen, and press the training function key again; move the coordinate line of the crosshair to the lower right corner of the TV screen or projection screen, aim the laser light at the center of the crosshair in the lower right corner of the TV screen or projection screen again, and press the training function key; After the training is completed, the mouse pen exits the intelligent training scene.

9. The air mouse pen according to claim 8, characterized in that: The training optimization of the intelligent training scenario specifically includes: Press the training function key and the mouse pen enters the intelligent training mode; The mouse pen sends a first training command, and uses the coordinates of the upper left corner of the TV screen or the projection screen to perform intelligent training; After receiving the training command, the host interface module forwards the training command to the host; The host controls the superimposition display of a cross coordinate line at the upper left corner of the TV screen or the projection screen, and sends the coordinate value of the cross coordinate line at the upper left corner to the host interface module; The host interface module forwards the coordinate value of the cross coordinate line in the upper left corner to the mouse pen; The mouse pen receives the coordinate value of the cross coordinate line in the upper left corner and saves it as the first standard value; Aim the laser light at the center of the crosshairs in the upper left corner of the TV screen or projection screen, and press the training function key again; The mouse pen calculates the cursor coordinate value of the current upper left corner cross coordinate line, compares the calculated coordinate value of the upper left corner cross coordinate line with the first standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the upper left corner cross coordinate line and the first standard value is less than a preset first difference threshold; The mouse pen sends a second training command, and uses the coordinates of the lower right corner of the TV screen or projection screen to perform intelligent training; After receiving the command, the host interface module forwards the command to the host; The host computer changes the cross coordinate line to the lower right corner of the TV screen or projection screen, and sends the coordinate value of the cross coordinate line at the lower right corner to the host computer interface module; The host interface module forwards the coordinate value of the cross coordinate line in the lower right corner to the mouse pen; The mouse pen receives the coordinate value of the cross coordinate line in the lower right corner and saves it as the second standard value; Aim the laser light at the center of the crosshairs in the lower right corner of the TV screen or projection screen, and press the training function key again; The mouse pen calculates the cursor coordinate value of the cross coordinate line at the lower right corner of the current TV screen or projection screen, analyzes the calculated coordinate value of the cross coordinate line at the lower right corner of the TV screen or projection screen with the second standard value, and corrects the working scene parameter of the image recognition algorithm so that the difference between the calculated coordinate value of the cross coordinate line at the lower right corner and the second standard value is less than a preset second difference threshold; The mouse pen sends an exit command to exit the smart correction mode; After receiving the exit command, the host interface module forwards the command to the host, and the host cancels the display of the cross coordinate line on the screen.

10. The air mouse pen according to any one of claims 1 to 9, characterized in that: The mouse pen also includes a plurality of batteries and a power management module, and the power management module is used to charge and manage each battery; the mouse pen determines whether the mouse pen is in use according to the current state of the first posture sensor. If the current state of the first posture sensor does not change and no operation is performed within a preset time, the power management module controls the mouse pen to enter a sleep state and turns off the laser light; when the current state of the first posture sensor changes or there is a key operation, the power management module wakes up the mouse pen to enter a working state and turns on the laser light.