WO2022127872A1 - Device motion method and electronic device - Google Patents

Device motion method and electronic device Download PDF

Info

Publication number
WO2022127872A1
WO2022127872A1 PCT/CN2021/138890 CN2021138890W WO2022127872A1 WO 2022127872 A1 WO2022127872 A1 WO 2022127872A1 CN 2021138890 W CN2021138890 W CN 2021138890W WO 2022127872 A1 WO2022127872 A1 WO 2022127872A1
Authority
WO
WIPO (PCT)
Prior art keywords
motion
movement
electronic device
motor
distance
Prior art date
Application number
PCT/CN2021/138890
Other languages
French (fr)
Chinese (zh)
Inventor
廖昌海
刘延飞
潘阳
陈柳运
Original Assignee
卧安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 卧安科技(深圳)有限公司 filed Critical 卧安科技(深圳)有限公司
Publication of WO2022127872A1 publication Critical patent/WO2022127872A1/en

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01PMEASURING LINEAR OR ANGULAR SPEED, ACCELERATION, DECELERATION, OR SHOCK; INDICATING PRESENCE, ABSENCE, OR DIRECTION, OF MOVEMENT
    • G01P15/00Measuring acceleration; Measuring deceleration; Measuring shock, i.e. sudden change of acceleration

Definitions

  • the present application belongs to the technical field of equipment movement, and in particular relates to a method of equipment movement and an electronic device.
  • the motor of the device determines whether there is a human touch behavior currently through the signal detection module. In this way, the signal detection module needs to be powered on all the time, the power consumption is high, and the energy utilization rate is low.
  • the embodiments of the present application provide a device movement method and an electronic device, which can solve the problems of high power consumption and low energy utilization rate of the electronic device during movement.
  • an embodiment of the present application provides a device movement method, which is applied to an electronic device, where the electronic device is provided with a motor, and the method includes:
  • the motion information being used to identify the state of the device
  • the device state is a motion state and the motor is not actively moving, obtain the motion direction and motion distance;
  • the motor is controlled to move in the movement direction.
  • controlling the motor to move in the movement direction includes:
  • the motor is controlled to move in the movement direction.
  • the method further includes:
  • the motor moves to a preset target position or detects an instruction to stop the movement, the movement is stopped.
  • the acquisition of movement direction and movement distance includes:
  • the method further includes:
  • the motor moves to a preset target position or a stop motion instruction is detected, the motion is stopped, and the pedometer is turned off.
  • the pedometer After the pedometer is turned on and the movement direction and movement distance are collected by the pedometer, it also includes:
  • the pedometer is turned off.
  • the motion sensor is an acceleration sensor.
  • an electronic device including:
  • a first acquisition unit configured to acquire motion information collected by a motion sensor, where the motion information is used to identify a device state
  • a second acquiring unit configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is inactive
  • the control unit is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
  • control unit is specifically used for:
  • the motor is controlled to move in the movement direction.
  • the electronic device also includes:
  • the first processing unit is configured to stop the movement if the motor moves to a preset target position or a stop movement instruction is detected.
  • the second obtaining unit is specifically used for:
  • the electronic device also includes:
  • the second processing unit is configured to stop the movement and turn off the pedometer if the motor moves to a preset target position or a stop movement instruction is detected.
  • the electronic device also includes:
  • a third processing unit configured to turn off the pedometer if the movement distance does not meet a preset start condition.
  • the motion sensor is an acceleration sensor.
  • an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, when the processor executes the computer program
  • the device movement method as described in the first aspect above is implemented.
  • an embodiment of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, implements the motion of the device according to the first aspect above method.
  • the motion information collected by the motion sensor is acquired, and the motion information is used to identify the state of the device; if the state of the device is in the motion state and the motor is in inactive motion, the motion direction and the motion distance are acquired ; if the movement distance satisfies the preset starting condition, the motor is controlled to move in the movement direction.
  • the signal detection module does not need to be powered on all the time, but only needs to collect the device motion information through the motion sensor and obtain the motion direction. And the movement distance, it can be judged whether the electronic device is moving, which reduces the power consumption and improves the energy utilization rate.
  • FIG. 1 is a schematic flowchart of a device movement method provided by the first embodiment of the present application
  • FIG. 2 is a schematic diagram of an electronic device provided by a second embodiment of the present application.
  • FIG. 3 is a schematic diagram of an electronic device provided by a third embodiment of the present application.
  • the term “if” may be contextually interpreted as “when” or “once” or “in response to determining” or “in response to detecting “.
  • the phrases “if it is determined” or “if the [described condition or event] is detected” may be interpreted, depending on the context, to mean “once it is determined” or “in response to the determination” or “once the [described condition or event] is detected. ]” or “in response to detection of the [described condition or event]”.
  • references in this specification to "one embodiment” or “some embodiments” and the like mean that a particular feature, structure or characteristic described in connection with the embodiment is included in one or more embodiments of the present application.
  • appearances of the phrases “in one embodiment,” “in some embodiments,” “in other embodiments,” “in other embodiments,” etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean “one or more but not all embodiments” unless specifically emphasized otherwise.
  • the terms “including”, “including”, “having” and their variants mean “including but not limited to” unless specifically emphasized otherwise.
  • FIG. 1 is a schematic flowchart of a device movement method provided by the first embodiment of the present application.
  • the execution subject of the device movement method in this embodiment is an electronic device, and the electronic device is provided with a motor.
  • the device movement method shown in Figure 1 may include:
  • S101 Acquire motion information collected by a motion sensor, where the motion information is used to identify a device state.
  • a motion sensor is installed on the electronic device, and the electronic device can collect motion information through the motion sensor.
  • the motion information is used to identify the device state, and the device state may include a motion state and a static state.
  • the electronic device in this embodiment can be applied in the field of smart home.
  • the electronic device in this embodiment is installed on the track of the railed curtain, and the curtain is automatically opened and closed through the movement of the electronic device.
  • manually pulling the curtain can drive the electronic device to passively move.
  • the electronic device obtains the motion information collected by the motion sensor, and the motion information identifies the device state as a motion state.
  • the motion sensor may be an acceleration sensor.
  • the electronic device acquires the motion information collected by the acceleration sensor to identify the device state. For example, the electronic device obtains the motion acceleration through the acceleration sensor, and when the motion acceleration exceeds a preset threshold, the device state is determined to be a motion state; the electronic device can also identify the device state through the tap function of the acceleration sensor, and the acceleration sensor generally has a light Knock function, when a level change occurs on the interrupt pin when tapping, it is determined whether there is a tap event by capturing the level change. When a tap event occurs and the level change exceeds the preset level threshold, it is determined that the device state is state of motion.
  • the motion information collected by the electronic device through the motion sensor can only determine whether the electronic device is in a motion state.
  • the reason for triggering the movement of the electronic device cannot be determined, and the reason for triggering the movement of the electronic device may be manually triggered by the user, triggered by motor movement, or triggered by the outside world.
  • the external triggers may include environmental triggers, such as natural wind triggers or pet triggers, and so on.
  • the electronic device determines that the device state of the electronic device is a motion state. If the motion is triggered by the active motion of the motor, it means that the motor is currently running, and there is no need to continue executing this embodiment. Therefore, after the electronic device determines that the device state of the electronic device is in the motion state, it is necessary to determine the triggering cause of the motion, to exclude the case where the motor is triggered by active motion.
  • the active motion of the motor refers to the motion controlled by the controller.
  • the electronic device can detect that the motor is moving through the sensor, but it is not controlled by the controller itself, and the motor can be determined to be inactive.
  • a pedometer may be set on the electronic device.
  • the electronic device may turn on the pedometer, and collect the movement direction and movement distance through the pedometer.
  • the movement direction is used to determine which direction the motor will move in after starting, that is, whether the motor should rotate forward or reverse.
  • the movement distance refers to the movement distance of the electronic device from the stationary position to the current position.
  • the movement distance is the trigger condition for active movement. If the movement distance exceeds the preset distance within a certain period of time, it is considered to be manually triggered by the user.
  • a preset activation condition is preset in the electronic device, and the preset activation condition is used to determine whether the current motion is an effective motion, wherein the effective motion may be understood as a motion manually triggered by a user. If the electronic device determines that the movement distance satisfies the preset start condition, it controls the motor to move in the movement direction.
  • a preset distance is pre-stored in the electronic device, and if the movement distance is greater than or equal to the preset distance, the motor is controlled to move in the movement direction.
  • the movement distance captured here is compared with the preset distance to determine whether to trigger active movement. When the movement distance exceeds the movement distance threshold, it is determined as a manual trigger by the user, and the trigger is determined to be an effective trigger, and an active movement is triggered to control the motor to move in the movement direction.
  • a pedometer is installed on the electronic device. If the movement distance does not meet the preset activation conditions, it means that the current movement is not a valid movement, and the movement may be caused by the accidental touch of the pet.
  • the pedometer can be turned off. When the next time the electronic device detects that the device state is in motion, turn on the pedometer again, detect that the motor is in inactive motion, and then obtain the motion direction and motion distance.
  • a preset target position for active movement is preset in the electronic device.
  • the preset target position may be the position corresponding to the fully opened curtain, or it may be The corresponding position when the curtains are fully closed.
  • the user can also send an instruction to stop the movement to the electronic device to manually intervene in the movement. Therefore, if the electronic device detects that the motor has moved to a preset target position or detects an instruction to stop the movement, it stops the movement.
  • the electronic device is provided with a pedometer. If the electronic device detects that the motor moves to a preset target position or detects a stop motion instruction, the motion is stopped. In order to save energy, the pedometer can be turned off.
  • the motor is controlled to move in the direction of movement, and the movement sensor can stop collecting movement information, that is, the function of judging whether to perform active movement in this embodiment is turned off to avoid The same triggering process is performed again during the active motion of the motor. If the electronic device detects that the motor has moved to a preset target position or detects a stop motion instruction, the motion is stopped, and the motion sensor can resume collecting motion information, that is, the function of judging whether to perform active motion in this embodiment is enabled.
  • a preset distance is pre-stored in the electronic device, and if the movement distances obtained multiple times within a preset time period are all less than the preset distance, it is determined that the current movement is not a valid movement. It may be other external triggers, such as wind, small animals, etc., you can turn off the pedometer and continue to cycle for the next judgment.
  • the motion information collected by the motion sensor is acquired, and the motion information is used to identify the state of the device; if the state of the device is in the motion state and the motor is in inactive motion, the motion direction and the motion distance are acquired ; if the movement distance satisfies the preset starting condition, the motor is controlled to move in the movement direction.
  • the signal detection module does not need to be powered on all the time, but only needs to collect the device motion information through the motion sensor and obtain the motion direction. And the movement distance, it can be judged whether the electronic device is moving, which reduces the power consumption and improves the energy utilization rate.
  • FIG. 2 is a schematic diagram of an electronic device provided by a second embodiment of the present application.
  • the included units are used to execute the steps in the embodiment corresponding to FIG. 1 .
  • the electronic device 2 includes:
  • a first acquiring unit 210 configured to acquire device motion information collected by a motion sensor, where the motion information is used to identify a device state
  • the second acquisition unit 220 is configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is not actively moving;
  • the control unit 230 is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
  • control unit 230 is specifically used for:
  • the motor is controlled to move in the movement direction.
  • the electronic device 2 also includes:
  • the first processing unit is configured to stop the movement if the motor moves to a preset target position or a stop movement instruction is detected.
  • the second obtaining unit 220 is specifically used for:
  • the electronic device 2 also includes:
  • the second processing unit is configured to stop the movement and turn off the pedometer if the motor moves to a preset target position or a stop movement instruction is detected.
  • the electronic device 2 also includes:
  • the third processing unit is configured to turn off the second sensor if the movement distance does not meet the preset start condition.
  • the motion sensor is an acceleration sensor.
  • FIG. 3 is a schematic diagram of an electronic device provided by a third embodiment of the present application.
  • the electronic device 3 of this embodiment includes a processor 30 , a memory 31 , and a computer program 32 stored in the memory 31 and executable on the processor 30 , such as a device motion program.
  • the processor 30 executes the computer program 32
  • the steps in each of the above embodiments of the device motion method are implemented, for example, steps 101 to 103 shown in FIG. 1 .
  • the processor 30 executes the computer program 32
  • the functions of the modules/units in each of the foregoing apparatus embodiments such as the functions of the modules 210 to 230 shown in FIG. 2, are implemented.
  • the computer program 32 can be divided into one or more modules/units, and the one or more modules/units are stored in the memory 31 and executed by the processor 30 to complete the this application.
  • the one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the computer program 32 in the electronic device 3 .
  • the computer program 32 can be divided into a first acquisition unit, a second acquisition unit, and a control unit, and the specific functions of each unit are as follows:
  • a first acquisition unit configured to acquire equipment motion information collected by the motion sensor, where the motion information is used to identify the equipment state
  • a second acquiring unit configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is inactive
  • the control unit is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
  • the electronic device may include, but is not limited to, the processor 30 and the memory 31 .
  • FIG. 3 is only an example of the electronic device 3 , and does not constitute a limitation on the electronic device 3 , and may include more or less components than those shown in the figure, or combine some components, or different components
  • the electronic device may further include an input and output device, a network access device, a bus, and the like.
  • the so-called processor 30 may be a central processing unit (Central Processing Unit, CPU), and may also be other general-purpose processors, digital signal processors (Digital Signal Processors) Processor, DSP), application-specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf Programmable Gate Array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
  • the memory 31 may be an internal storage unit of the electronic device 3 , such as a hard disk or a memory of the electronic device 3 .
  • the memory 31 may also be an external storage device of the electronic device 3, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) equipped on the electronic device 3 card, Flash Card, etc.
  • the electronic device 3 may also include both an internal storage unit of the electronic device 3 and an external storage device.
  • the memory 31 is used to store the computer program and other programs and data required by the electronic device.
  • the memory 31 can also be used to temporarily store data that has been output or will be output.
  • Embodiments of the present application further provide an electronic device, the electronic device comprising: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, the processor executing The computer program implements the steps in any of the foregoing method embodiments.
  • Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps in the foregoing method embodiments can be implemented.
  • the embodiments of the present application provide a computer program product, when the computer program product runs on a mobile terminal, the steps in the foregoing method embodiments can be implemented when the mobile terminal executes the computer program product.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium.
  • all or part of the processes in the methods of the above embodiments can be implemented by a computer program to instruct the relevant hardware.
  • the computer program can be stored in a computer-readable storage medium, and the computer program When executed by the processor, the steps of the above-mentioned various method embodiments may be implemented.
  • the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like.
  • the computer-readable medium may include at least: any entity or device capable of carrying computer program codes to the photographing device/terminal device, recording medium, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signals, telecommunication signals, and software distribution media.
  • ROM read-only memory
  • RAM random access memory
  • electrical carrier signals telecommunication signals
  • software distribution media For example, U disk, mobile hard disk, disk or CD, etc.
  • computer readable media may not be electrical carrier signals and telecommunications signals.
  • the disclosed apparatus/device and method may be implemented in other manners.
  • the apparatus/equipment embodiments described above are only illustrative.
  • the division of the modules or units is only a logical function division.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Telephone Function (AREA)

Abstract

Provided is a device motion method, applicable to the technical field of device motion, comprising: obtaining motion information collected by a motion sensor, the motion information being used for identifying a device state (S101); if the device state is a state of motion and a motor is in non-active motion, then obtaining the direction of motion and the distance of motion (S102); if the distance of motion meets a preset start condition, then controlling the motor to move in the direction of motion (S103). When the electronic device is in motion, it is unnecessary for the motor to determine by means of a signal detection module whether there is currently a human touch behavior, and the signal detection module need not constantly be in a powered-on state; it is necessary only to collect device motion information by means of the motion sensor and obtain the direction of motion and the distance of motion in order to determine whether the electronic device is in motion, thus reducing power consumption and improving energy efficiency.

Description

一种设备运动方法及电子设备A device movement method and electronic device
本申请要求于2020年12月18日在中国专利局提交的、申请号为202011504905.4的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese Patent Application No. 202011504905.4 filed with the Chinese Patent Office on December 18, 2020, the entire contents of which are incorporated herein by reference.
技术领域technical field
本申请属于设备运动技术领域,尤其涉及一种设备运动方法及电子设备。The present application belongs to the technical field of equipment movement, and in particular relates to a method of equipment movement and an electronic device.
背景技术Background technique
现有的智能家居领域,很多设备应用了基于触摸的运动方法,即设备如果检测当前存在人为触摸行为,则电机启动,设备自动运动。这样,可以使用户更加方便使用智能家居设备。In the existing smart home field, many devices apply the touch-based motion method, that is, if the device detects that there is a human touch behavior, the motor will be started and the device will move automatically. In this way, the user can use the smart home device more conveniently.
但是,现有的设备在实现上述功能时,是设备的电机通过信号检测模块来判断当前是否存在人为触摸行为。这样,就需要信号检测模块一直处于通电的状态,功率消耗较高,能源利用率低。However, when the existing device implements the above functions, the motor of the device determines whether there is a human touch behavior currently through the signal detection module. In this way, the signal detection module needs to be powered on all the time, the power consumption is high, and the energy utilization rate is low.
技术问题technical problem
本申请实施例提供了一种设备运动方法及电子设备,可以解决电子设备在运动时,功率消耗较高,能源利用率低的问题。The embodiments of the present application provide a device movement method and an electronic device, which can solve the problems of high power consumption and low energy utilization rate of the electronic device during movement.
技术解决方案technical solutions
第一方面,本申请实施例提供了一种设备运动方法,应用于电子设备,所述电子设备设置有电机,所述方法包括:In a first aspect, an embodiment of the present application provides a device movement method, which is applied to an electronic device, where the electronic device is provided with a motor, and the method includes:
获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;acquiring motion information collected by the motion sensor, the motion information being used to identify the state of the device;
若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;If the device state is a motion state and the motor is not actively moving, obtain the motion direction and motion distance;
若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。If the movement distance satisfies the preset starting condition, the motor is controlled to move in the movement direction.
进一步地,所述若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动,包括:Further, if the movement distance satisfies a preset start condition, controlling the motor to move in the movement direction includes:
若所述运动距离大于或等于预设距离,则控制电机向所述运动方向运动。If the movement distance is greater than or equal to the preset distance, the motor is controlled to move in the movement direction.
进一步地,在所述若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动之后,还包括:Further, after the controlling the motor to move in the moving direction if the moving distance satisfies the preset starting condition, the method further includes:
若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动。If the motor moves to a preset target position or detects an instruction to stop the movement, the movement is stopped.
进一步地,所述获取运动方向和运动距离,包括:Further, the acquisition of movement direction and movement distance includes:
开启计步器,通过所述计步器采集运动方向和运动距离。Turn on the pedometer, and collect the movement direction and movement distance through the pedometer.
进一步地,在所述若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动之后,还包括:Further, after the controlling the motor to move in the moving direction if the moving distance satisfies the preset starting condition, the method further includes:
若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动,并且关闭所述计步器。If the motor moves to a preset target position or a stop motion instruction is detected, the motion is stopped, and the pedometer is turned off.
进一步地,在所述开启计步器,通过所述计步器采集运动方向和运动距离之后,还包括:Further, after the pedometer is turned on and the movement direction and movement distance are collected by the pedometer, it also includes:
若所述运动距离不满足预设启动条件,则关闭所述计步器。If the movement distance does not meet the preset activation condition, the pedometer is turned off.
进一步地,所述运动传感器为加速度传感器。Further, the motion sensor is an acceleration sensor.
第二方面,本申请实施例提供了一种电子设备,包括:In a second aspect, an embodiment of the present application provides an electronic device, including:
第一获取单元,用于获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;a first acquisition unit, configured to acquire motion information collected by a motion sensor, where the motion information is used to identify a device state;
第二获取单元,用于若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;a second acquiring unit, configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is inactive;
控制单元,用于若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。The control unit is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
进一步地,所述控制单元,具体用于:Further, the control unit is specifically used for:
若所述运动距离大于或等于预设距离,则控制电机向所述运动方向运动。If the movement distance is greater than or equal to the preset distance, the motor is controlled to move in the movement direction.
进一步地,所述电子设备,还包括:Further, the electronic device also includes:
第一处理单元,用于若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动。The first processing unit is configured to stop the movement if the motor moves to a preset target position or a stop movement instruction is detected.
进一步地,所述第二获取单元,具体用于:Further, the second obtaining unit is specifically used for:
开启计步器,通过所述计步器采集运动方向和运动距离。Turn on the pedometer, and collect the movement direction and movement distance through the pedometer.
进一步地,所述电子设备,还包括:Further, the electronic device also includes:
第二处理单元,用于若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动,并且关闭所述计步器。The second processing unit is configured to stop the movement and turn off the pedometer if the motor moves to a preset target position or a stop movement instruction is detected.
进一步地,所述电子设备,还包括:Further, the electronic device also includes:
第三处理单元,用于若所述运动距离不满足预设启动条件,则关闭所述计步器。A third processing unit, configured to turn off the pedometer if the movement distance does not meet a preset start condition.
进一步地,所述运动传感器为加速度传感器。Further, the motion sensor is an acceleration sensor.
第三方面,本申请实施例提供了一种电子设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如上述第一方面所述的设备运动方法。In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, when the processor executes the computer program The device movement method as described in the first aspect above is implemented.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现如上述第一方面所述的设备运动方法。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, implements the motion of the device according to the first aspect above method.
有益效果beneficial effect
本申请实施例中,获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。上述方案,电子设备在进行运动时,无需电机通过信号检测模块来判断当前是否存在人为触摸行为,信号检测模块无需一直处于通电的状态,只需要通过运动传感器采集的设备运动信息,并且获取运动方向和运动距离,就可以判断电子设备是否进行运动,降低了功率的消耗,并且提高了能源利用率。In the embodiment of the present application, the motion information collected by the motion sensor is acquired, and the motion information is used to identify the state of the device; if the state of the device is in the motion state and the motor is in inactive motion, the motion direction and the motion distance are acquired ; if the movement distance satisfies the preset starting condition, the motor is controlled to move in the movement direction. In the above solution, when the electronic device is in motion, there is no need for the motor to use the signal detection module to determine whether there is human touch behavior. The signal detection module does not need to be powered on all the time, but only needs to collect the device motion information through the motion sensor and obtain the motion direction. And the movement distance, it can be judged whether the electronic device is moving, which reduces the power consumption and improves the energy utilization rate.
附图说明Description of drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions in the embodiments of the present application more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only for the present application. In some embodiments, for those of ordinary skill in the art, other drawings can also be obtained according to these drawings without any creative effort.
图1是本申请第一实施例提供的一种设备运动方法的示意流程图;FIG. 1 is a schematic flowchart of a device movement method provided by the first embodiment of the present application;
图2是本申请第二实施例提供的电子设备的示意图;2 is a schematic diagram of an electronic device provided by a second embodiment of the present application;
图3是本申请第三实施例提供的电子设备的示意图。FIG. 3 is a schematic diagram of an electronic device provided by a third embodiment of the present application.
本发明的实施方式Embodiments of the present invention
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。In the following description, for the purpose of illustration rather than limitation, specific details such as a specific system structure and technology are set forth in order to provide a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be practiced in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
应当理解,当在本申请说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。It is to be understood that, when used in this specification and the appended claims, the term "comprising" indicates the presence of the described feature, integer, step, operation, element and/or component, but does not exclude one or more other The presence or addition of features, integers, steps, operations, elements, components and/or sets thereof.
还应当理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。It will also be understood that, as used in this specification and the appended claims, the term "and/or" refers to and including any and all possible combinations of one or more of the associated listed items.
如在本申请说明书和所附权利要求书中所使用的那样,术语“如果”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。类似地,短语“如果确定”或“如果检测到[所描述条件或事件]”可以依据上下文被解释为意指“一旦确定”或“响应于确定”或“一旦检测到[所描述条件或事件]”或“响应于检测到[所描述条件或事件]”。As used in the specification of this application and the appended claims, the term "if" may be contextually interpreted as "when" or "once" or "in response to determining" or "in response to detecting ". Similarly, the phrases "if it is determined" or "if the [described condition or event] is detected" may be interpreted, depending on the context, to mean "once it is determined" or "in response to the determination" or "once the [described condition or event] is detected. ]" or "in response to detection of the [described condition or event]".
另外,在本申请说明书和所附权利要求书的描述中,术语“第一”、“第二”、“第三”等仅用于区分描述,而不能理解为指示或暗示相对重要性。In addition, in the description of the specification of the present application and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the description, and should not be construed as indicating or implying relative importance.
在本申请说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。References in this specification to "one embodiment" or "some embodiments" and the like mean that a particular feature, structure or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in other embodiments," etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean "one or more but not all embodiments" unless specifically emphasized otherwise. The terms "including", "including", "having" and their variants mean "including but not limited to" unless specifically emphasized otherwise.
请参见图1,图1是本申请第一实施例提供的一种设备运动方法的示意流程图。本实施例中一种设备运动方法的执行主体为电子设备,电子设备设置有电机。如图1所示的设备运动方法可以包括:Please refer to FIG. 1 . FIG. 1 is a schematic flowchart of a device movement method provided by the first embodiment of the present application. The execution subject of the device movement method in this embodiment is an electronic device, and the electronic device is provided with a motor. The device movement method shown in Figure 1 may include:
S101:获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态。S101: Acquire motion information collected by a motion sensor, where the motion information is used to identify a device state.
在本实施中,电子设备上装有运动传感器,电子设备可以通过运动传感器采集运动信息。其中,运动信息用于识别设备状态,设备状态可以包括运动状态和静止状态。In this implementation, a motion sensor is installed on the electronic device, and the electronic device can collect motion information through the motion sensor. The motion information is used to identify the device state, and the device state may include a motion state and a static state.
本实施例中的电子设备可以应用在智能家居领域,例如,将本实施例中的电子设备安装在有轨窗帘的轨道上,通过电子设备的运动,自动开关窗帘。在电子设备静止的时候,人手拉动窗帘,可以带动电子设备被动运动,电子设备获取由运动传感器采集的运动信息,运动信息识别设备状态为运动状态。The electronic device in this embodiment can be applied in the field of smart home. For example, the electronic device in this embodiment is installed on the track of the railed curtain, and the curtain is automatically opened and closed through the movement of the electronic device. When the electronic device is stationary, manually pulling the curtain can drive the electronic device to passively move. The electronic device obtains the motion information collected by the motion sensor, and the motion information identifies the device state as a motion state.
其中,运动传感器可以为加速度传感器。电子设备获取由加速度传感器采集的运动信息,来识别设备状态。例如,电子设备通过加速度传感器获取到运动加速度,当运动加速度超过预设阈值时,判定设备状态为运动状态;电子设备也可以通过加速度传感器的轻敲功能来识别设备状态,加速度传感器一般带有轻敲功能,在轻敲时中断引脚上发生电平变化,通过捕获电平变化来判断是否有轻敲事件,当发生轻敲事件且电平变化超过预设电平阈值时,判定设备状态为运动状态。The motion sensor may be an acceleration sensor. The electronic device acquires the motion information collected by the acceleration sensor to identify the device state. For example, the electronic device obtains the motion acceleration through the acceleration sensor, and when the motion acceleration exceeds a preset threshold, the device state is determined to be a motion state; the electronic device can also identify the device state through the tap function of the acceleration sensor, and the acceleration sensor generally has a light Knock function, when a level change occurs on the interrupt pin when tapping, it is determined whether there is a tap event by capturing the level change. When a tap event occurs and the level change exceeds the preset level threshold, it is determined that the device state is state of motion.
需要说明的是,在本步骤中,电子设备通过运动传感器采集的运动信息只能判断电子设备是否为运动状态。但是,当判定电子设备处于运动状态时,触发电子设备运动的原因并不能确定,触发电子设备运动的原因可以为用户手动触发、电机运动触发或者外界触发。其中,外界触发可以包括环境触发,例如,自然风触发或者宠物触发等等。It should be noted that, in this step, the motion information collected by the electronic device through the motion sensor can only determine whether the electronic device is in a motion state. However, when it is determined that the electronic device is in a motion state, the reason for triggering the movement of the electronic device cannot be determined, and the reason for triggering the movement of the electronic device may be manually triggered by the user, triggered by motor movement, or triggered by the outside world. The external triggers may include environmental triggers, such as natural wind triggers or pet triggers, and so on.
S102:若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离。S102: If the device state is a motion state and the motor is not actively moving, obtain a motion direction and a motion distance.
电子设备判定电子设备的设备状态为运动状态,如果运动的触发原因是电机主动运动触发,则说明当前电机正在运行,不需要再继续执行本实施例。所以,电子设备判定电子设备的设备状态为运动状态后,需要对运动的触发原因进行判定,排除电机主动运动触发的情况。The electronic device determines that the device state of the electronic device is a motion state. If the motion is triggered by the active motion of the motor, it means that the motor is currently running, and there is no need to continue executing this embodiment. Therefore, after the electronic device determines that the device state of the electronic device is in the motion state, it is necessary to determine the triggering cause of the motion, to exclude the case where the motor is triggered by active motion.
一般情况下,电机主动运动是指由控制器控制的运动,电子设备可以通过传感器检测到电机正在运动,但是又不是控制器自身控制的,则可以判定电机为非主动运动。In general, the active motion of the motor refers to the motion controlled by the controller. The electronic device can detect that the motor is moving through the sensor, but it is not controlled by the controller itself, and the motor can be determined to be inactive.
若电子设备检测到设备状态为运动状态,且电机为非主动运动,则获取运动方向和运动距离。具体来说,本实施例中,电子设备上可以设置计步器,在获取运动方向和运动距离时,电子设备可以开启计步器,通过计步器采集运动方向和运动距离。If the electronic device detects that the device state is a motion state and the motor is not actively moving, the motion direction and motion distance are obtained. Specifically, in this embodiment, a pedometer may be set on the electronic device. When acquiring the movement direction and movement distance, the electronic device may turn on the pedometer, and collect the movement direction and movement distance through the pedometer.
运动方向用于判断后续电机启动后往哪个方向运动,即电机应该正转还是反转。运动距离指的是电子设备从静止位置到当前位置的运动距离。运动距离是主动运动的触发条件,如果在一定时间内运动距离超过预设距离,则认为是用户手动触发。The movement direction is used to determine which direction the motor will move in after starting, that is, whether the motor should rotate forward or reverse. The movement distance refers to the movement distance of the electronic device from the stationary position to the current position. The movement distance is the trigger condition for active movement. If the movement distance exceeds the preset distance within a certain period of time, it is considered to be manually triggered by the user.
S103:若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。S103: If the movement distance satisfies a preset start condition, control the motor to move in the movement direction.
电子设备中预先设置预设启动条件,预设启动条件用于判断当前运动是否为有效运动,其中,有效运动可以理解为用户手动触发的运动。若电子设备判断运动距离满足预设启动条件,则控制电机向运动方向运动。A preset activation condition is preset in the electronic device, and the preset activation condition is used to determine whether the current motion is an effective motion, wherein the effective motion may be understood as a motion manually triggered by a user. If the electronic device determines that the movement distance satisfies the preset start condition, it controls the motor to move in the movement direction.
具体地说,电子设备中预先存储预设距离,若运动距离大于或等于预设距离,则控制电机向所述运动方向运动。这里捕获的运动距离跟预设距离作比较,判断是否触发主动运动。当运动距离超过运动距离阈值时,则判定为用户手动触发,判定此次触发为有效触发,触发主动运动,控制电机向所述运动方向运动。Specifically, a preset distance is pre-stored in the electronic device, and if the movement distance is greater than or equal to the preset distance, the motor is controlled to move in the movement direction. The movement distance captured here is compared with the preset distance to determine whether to trigger active movement. When the movement distance exceeds the movement distance threshold, it is determined as a manual trigger by the user, and the trigger is determined to be an effective trigger, and an active movement is triggered to control the motor to move in the movement direction.
一种实施方式中,电子设备上设置计步器,若运动距离不满足预设启动条件,说明当前运动不是有效运动,可能为宠物误触导致发生运动等情况。这里,为了节约能源,可以关闭计步器。当下次电子设备检测到设备状态为运动状态时,再开启计步器,检测电机为非主动运动,再获取运动方向和运动距离。In one embodiment, a pedometer is installed on the electronic device. If the movement distance does not meet the preset activation conditions, it means that the current movement is not a valid movement, and the movement may be caused by the accidental touch of the pet. Here, to save energy, the pedometer can be turned off. When the next time the electronic device detects that the device state is in motion, turn on the pedometer again, detect that the motor is in inactive motion, and then obtain the motion direction and motion distance.
一种实施方式中,电子设备中会预设主动运动的预设目标位置,以安装在有轨窗帘轨道上的电子设备为例,预设目标位置可以为窗帘完全打开时对应的位置,也可以为窗帘完全关闭时对应的位置。此外,用户也可以向电子设备发送停止运动的指令,人为干预本次运动。所以,若电子设备检测电机运动到预设目标位置或者检测到停止运动指令,则停止运动。In one embodiment, a preset target position for active movement is preset in the electronic device. Taking the electronic device installed on the tracked curtain track as an example, the preset target position may be the position corresponding to the fully opened curtain, or it may be The corresponding position when the curtains are fully closed. In addition, the user can also send an instruction to stop the movement to the electronic device to manually intervene in the movement. Therefore, if the electronic device detects that the motor has moved to a preset target position or detects an instruction to stop the movement, it stops the movement.
一种实施方式中,电子设备上设置计步器,若电子设备检测电机运动到预设目标位置或者检测到停止运动指令,则停止运动,为了节约能源,可以关闭计步器。In one embodiment, the electronic device is provided with a pedometer. If the electronic device detects that the motor moves to a preset target position or detects a stop motion instruction, the motion is stopped. In order to save energy, the pedometer can be turned off.
一种实施方式中,若电子设备判断运动距离满足预设启动条件,则控制电机向运动方向运动,运动传感器可以停止采集运动信息,即关闭本实施例中的判断是否进行主动运动的功能,避免电机主动运动过程中再次进行相同的触发处理。若电子设备检测电机运动到预设目标位置或者检测到停止运动指令,则停止运动,运动传感器可以重新开始采集运动信息,即开启本实施例中的判断是否进行主动运动的功能。In one embodiment, if the electronic device determines that the movement distance satisfies the preset start conditions, the motor is controlled to move in the direction of movement, and the movement sensor can stop collecting movement information, that is, the function of judging whether to perform active movement in this embodiment is turned off to avoid The same triggering process is performed again during the active motion of the motor. If the electronic device detects that the motor has moved to a preset target position or detects a stop motion instruction, the motion is stopped, and the motion sensor can resume collecting motion information, that is, the function of judging whether to perform active motion in this embodiment is enabled.
一种实施方式中,电子设备中预先存储预设距离,若在预设时间段内多次获取的运动距离都小于预设距离,则判定当前运动不是有效运动。可能是其他外界触发,如风、小动物等,可以关闭计步器,继续循环下一次判断。In one embodiment, a preset distance is pre-stored in the electronic device, and if the movement distances obtained multiple times within a preset time period are all less than the preset distance, it is determined that the current movement is not a valid movement. It may be other external triggers, such as wind, small animals, etc., you can turn off the pedometer and continue to cycle for the next judgment.
本申请实施例中,获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。上述方案,电子设备在进行运动时,无需电机通过信号检测模块来判断当前是否存在人为触摸行为,信号检测模块无需一直处于通电的状态,只需要通过运动传感器采集的设备运动信息,并且获取运动方向和运动距离,就可以判断电子设备是否进行运动,降低了功率的消耗,并且提高了能源利用率。In the embodiment of the present application, the motion information collected by the motion sensor is acquired, and the motion information is used to identify the state of the device; if the state of the device is in the motion state and the motor is in inactive motion, the motion direction and the motion distance are acquired ; if the movement distance satisfies the preset starting condition, the motor is controlled to move in the movement direction. In the above solution, when the electronic device is in motion, there is no need for the motor to use the signal detection module to determine whether there is human touch behavior. The signal detection module does not need to be powered on all the time, but only needs to collect the device motion information through the motion sensor and obtain the motion direction. And the movement distance, it can be judged whether the electronic device is moving, which reduces the power consumption and improves the energy utilization rate.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that the size of the sequence numbers of the steps in the above embodiments does not mean the sequence of execution, and the execution sequence of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
请参见图2,图2是本申请第二实施例提供的电子设备的示意图。包括的各单元用于执行图1对应的实施例中的各步骤。具体请参阅图1对应的实施例中的相关描述。为了便于说明,仅示出了与本实施例相关的部分。参见图2,电子设备2包括:Please refer to FIG. 2 , which is a schematic diagram of an electronic device provided by a second embodiment of the present application. The included units are used to execute the steps in the embodiment corresponding to FIG. 1 . For details, please refer to the relevant description in the embodiment corresponding to FIG. 1 . For convenience of explanation, only the parts related to this embodiment are shown. Referring to Figure 2, the electronic device 2 includes:
第一获取单元210,用于获取由运动传感器采集的设备运动信息,所述运动信息用于识别设备状态;a first acquiring unit 210, configured to acquire device motion information collected by a motion sensor, where the motion information is used to identify a device state;
第二获取单元220,用于若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;The second acquisition unit 220 is configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is not actively moving;
控制单元230,用于若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。The control unit 230 is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
进一步地,所述控制单元230,具体用于:Further, the control unit 230 is specifically used for:
若所述运动距离大于或等于预设距离,则控制电机向所述运动方向运动。If the movement distance is greater than or equal to the preset distance, the motor is controlled to move in the movement direction.
进一步地,所述电子设备2,还包括:Further, the electronic device 2 also includes:
第一处理单元,用于若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动。The first processing unit is configured to stop the movement if the motor moves to a preset target position or a stop movement instruction is detected.
进一步地,所述第二获取单元220,具体用于:Further, the second obtaining unit 220 is specifically used for:
开启计步器,通过所述计步器采集运动方向和运动距离。Turn on the pedometer, and collect the movement direction and movement distance through the pedometer.
进一步地,所述电子设备2,还包括:Further, the electronic device 2 also includes:
第二处理单元,用于若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动,并且关闭所述计步器。The second processing unit is configured to stop the movement and turn off the pedometer if the motor moves to a preset target position or a stop movement instruction is detected.
进一步地,所述电子设备2,还包括:Further, the electronic device 2 also includes:
第三处理单元,用于若所述运动距离不满足预设启动条件,则关闭第二传感器。The third processing unit is configured to turn off the second sensor if the movement distance does not meet the preset start condition.
进一步地,所述运动传感器为加速度传感器。Further, the motion sensor is an acceleration sensor.
图3是本申请第三实施例提供的电子设备的示意图。如图3所示,该实施例的电子设备3包括:处理器30、存储器31以及存储在所述存储器31中并可在所述处理器30上运行的计算机程序32,例如设备运动程序。所述处理器30执行所述计算机程序32时实现上述各个设备运动方法实施例中的步骤,例如图1所示的步骤101至103。或者,所述处理器30执行所述计算机程序32时实现上述各装置实施例中各模块/单元的功能,例如图2所示模块210至230的功能。FIG. 3 is a schematic diagram of an electronic device provided by a third embodiment of the present application. As shown in FIG. 3 , the electronic device 3 of this embodiment includes a processor 30 , a memory 31 , and a computer program 32 stored in the memory 31 and executable on the processor 30 , such as a device motion program. When the processor 30 executes the computer program 32 , the steps in each of the above embodiments of the device motion method are implemented, for example, steps 101 to 103 shown in FIG. 1 . Alternatively, when the processor 30 executes the computer program 32, the functions of the modules/units in each of the foregoing apparatus embodiments, such as the functions of the modules 210 to 230 shown in FIG. 2, are implemented.
示例性的,所述计算机程序32可以被分割成一个或多个模块/单元,所述一个或者多个模块/单元被存储在所述存储器31中,并由所述处理器30执行,以完成本申请。所述一个或多个模块/单元可以是能够完成特定功能的一系列计算机程序指令段,该指令段用于描述所述计算机程序32在所述电子设备3中的执行过程。例如,所述计算机程序32可以被分割成第一获取单元、第二获取单元、控制单元,各单元具体功能如下:Exemplarily, the computer program 32 can be divided into one or more modules/units, and the one or more modules/units are stored in the memory 31 and executed by the processor 30 to complete the this application. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the computer program 32 in the electronic device 3 . For example, the computer program 32 can be divided into a first acquisition unit, a second acquisition unit, and a control unit, and the specific functions of each unit are as follows:
第一获取单元,用于获取由运动传感器采集的设备运动信息,所述运动信息用于识别设备状态;a first acquisition unit, configured to acquire equipment motion information collected by the motion sensor, where the motion information is used to identify the equipment state;
第二获取单元,用于若所述设备状态为运动状态,且所述电机为非主动运动,则获取运动方向和运动距离;a second acquiring unit, configured to acquire the movement direction and the movement distance if the device state is a motion state and the motor is inactive;
控制单元,用于若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动。The control unit is configured to control the motor to move in the movement direction if the movement distance satisfies a preset start condition.
所述电子设备可包括,但不仅限于,处理器30、存储器31。本领域技术人员可以理解,图3仅仅是电子设备3的示例,并不构成对电子设备3的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件,例如所述电子设备还可以包括输入输出设备、网络接入设备、总线等。The electronic device may include, but is not limited to, the processor 30 and the memory 31 . Those skilled in the art can understand that FIG. 3 is only an example of the electronic device 3 , and does not constitute a limitation on the electronic device 3 , and may include more or less components than those shown in the figure, or combine some components, or different components For example, the electronic device may further include an input and output device, a network access device, a bus, and the like.
所称处理器30可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路 (Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA) 或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。The so-called processor 30 may be a central processing unit (Central Processing Unit, CPU), and may also be other general-purpose processors, digital signal processors (Digital Signal Processors) Processor, DSP), application-specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf Programmable Gate Array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
所述存储器31可以是所述电子设备3的内部存储单元,例如电子设备3的硬盘或内存。所述存储器31也可以是所述电子设备3的外部存储设备,例如所述电子设备3上配备的插接式硬盘,智能存储卡(Smart Media Card, SMC),安全数字(Secure Digital, SD)卡,闪存卡(Flash Card)等。进一步地,所述电子设备3还可以既包括所述电子设备3的内部存储单元也包括外部存储设备。所述存储器31用于存储所述计算机程序以及所述电子设备所需的其他程序和数据。所述存储器31还可以用于暂时地存储已经输出或者将要输出的数据。The memory 31 may be an internal storage unit of the electronic device 3 , such as a hard disk or a memory of the electronic device 3 . The memory 31 may also be an external storage device of the electronic device 3, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) equipped on the electronic device 3 card, Flash Card, etc. Further, the electronic device 3 may also include both an internal storage unit of the electronic device 3 and an external storage device. The memory 31 is used to store the computer program and other programs and data required by the electronic device. The memory 31 can also be used to temporarily store data that has been output or will be output.
需要说明的是,上述装置/单元之间的信息交互、执行过程等内容,由于与本申请方法实施例基于同一构思,其具体功能及带来的技术效果,具体可参见方法实施例部分,此处不再赘述。It should be noted that the information exchange, execution process and other contents between the above-mentioned devices/units are based on the same concept as the method embodiments of the present application. For specific functions and technical effects, please refer to the method embodiments section. It is not repeated here.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. Module completion, that is, dividing the internal structure of the device into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment may be integrated in one processing unit, or each unit may exist physically alone, or two or more units may be integrated in one unit, and the above-mentioned integrated units may adopt hardware. It can also be realized in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing from each other, and are not used to limit the protection scope of the present application. For the specific working processes of the units and modules in the above-mentioned system, reference may be made to the corresponding processes in the foregoing method embodiments, which will not be repeated here.
本申请实施例还提供了一种电子设备,该电子设备包括:至少一个处理器、存储器以及存储在所述存储器中并可在所述至少一个处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现上述任意各个方法实施例中的步骤。Embodiments of the present application further provide an electronic device, the electronic device comprising: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, the processor executing The computer program implements the steps in any of the foregoing method embodiments.
本申请实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现可实现上述各个方法实施例中的步骤。Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps in the foregoing method embodiments can be implemented.
本申请实施例提供了一种计算机程序产品,当计算机程序产品在移动终端上运行时,使得移动终端执行时实现可实现上述各个方法实施例中的步骤。The embodiments of the present application provide a computer program product, when the computer program product runs on a mobile terminal, the steps in the foregoing method embodiments can be implemented when the mobile terminal executes the computer program product.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质至少可以包括:能够将计算机程序代码携带到拍照装置/终端设备的任何实体或装置、记录介质、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质。例如U盘、移动硬盘、磁碟或者光盘等。在某些司法管辖区,根据立法和专利实践,计算机可读介质不可以是电载波信号和电信信号。The integrated unit, if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments can be implemented by a computer program to instruct the relevant hardware. The computer program can be stored in a computer-readable storage medium, and the computer program When executed by the processor, the steps of the above-mentioned various method embodiments may be implemented. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like. The computer-readable medium may include at least: any entity or device capable of carrying computer program codes to the photographing device/terminal device, recording medium, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signals, telecommunication signals, and software distribution media. For example, U disk, mobile hard disk, disk or CD, etc. In some jurisdictions, under legislation and patent practice, computer readable media may not be electrical carrier signals and telecommunications signals.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the foregoing embodiments, the description of each embodiment has its own emphasis. For parts that are not described or described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each particular application, but such implementations should not be considered beyond the scope of this application.
在本申请所提供的实施例中,应该理解到,所揭露的装置/设备和方法,可以通过其它的方式实现。例如,以上所描述的装置/设备实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided in this application, it should be understood that the disclosed apparatus/device and method may be implemented in other manners. For example, the apparatus/equipment embodiments described above are only illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or Components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-mentioned embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the above-mentioned embodiments, those of ordinary skill in the art should understand that: it can still be used for the above-mentioned implementations. The technical solutions described in the examples are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions in the embodiments of the application, and should be included in the within the scope of protection of this application.

Claims (8)

  1. 一种设备运动方法,其特征在于,应用于电子设备,所述电子设备安装在有轨窗帘的轨道上,通过电子设备的运动,自动开关窗帘,所述电子设备设置有电机,所述方法包括:A device movement method, characterized in that it is applied to electronic devices, the electronic devices are installed on the track of a tracked curtain, the curtains are automatically opened and closed through the movement of the electronic device, the electronic device is provided with a motor, and the method includes: :
    获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;acquiring motion information collected by the motion sensor, the motion information being used to identify the state of the device;
    若所述设备状态为运动状态,且所述电机为非主动运动,则开启计步器,通过所述计步器采集运动方向和一定时间内的运动距离;If the device state is a motion state, and the motor is not actively moving, turn on the pedometer, and collect the movement direction and the movement distance within a certain period of time through the pedometer;
    若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动,所述运动距离满足预设启动条件,包括:If the movement distance satisfies the preset start condition, the motor is controlled to move in the movement direction, and the movement distance satisfies the preset start condition, including:
    所述运动距离大于或等于预设距离。The moving distance is greater than or equal to a preset distance.
  2. 如权利要求1所述的设备运动方法,其特征在于,在所述若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动之后,还包括:The device movement method according to claim 1, wherein after the controlling the motor to move in the movement direction if the movement distance satisfies a preset start condition, the method further comprises:
    若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动。If the motor moves to a preset target position or detects an instruction to stop the movement, the movement is stopped.
  3. 如权利要求1所述的设备运动方法,其特征在于,在所述若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动之后,还包括:The device movement method according to claim 1, wherein after the controlling the motor to move in the movement direction if the movement distance satisfies a preset start condition, the method further comprises:
    若所述电机运动到预设目标位置或者检测到停止运动指令,则停止运动,并且关闭所述计步器。If the motor moves to a preset target position or a stop motion instruction is detected, the motion is stopped, and the pedometer is turned off.
  4. 如权利要求1所述的设备运动方法,其特征在于,在所述开启计步器,通过所述计步器采集运动方向和一定时间内的运动距离之后,还包括:The device movement method according to claim 1, wherein after the pedometer is turned on and the movement direction and the movement distance within a certain period of time are collected by the pedometer, the method further comprises:
    若所述运动距离不满足预设启动条件,则关闭所述计步器。If the movement distance does not meet the preset activation condition, the pedometer is turned off.
  5. 如权利要求1-4任一项所述的设备运动方法,其特征在于,所述运动传感器为加速度传感器。The device motion method according to any one of claims 1-4, wherein the motion sensor is an acceleration sensor.
  6. 一种电子设备,其特征在于,所述电子设备安装在有轨窗帘的轨道上,通过电子设备的运动,自动开关窗帘,所述电子设备设置有电机,包括:An electronic device, characterized in that the electronic device is installed on the track of a tracked curtain, and the curtain is automatically opened and closed through the movement of the electronic device, and the electronic device is provided with a motor, comprising:
    第一获取单元,用于获取由运动传感器采集的运动信息,所述运动信息用于识别设备状态;a first acquisition unit, configured to acquire motion information collected by a motion sensor, where the motion information is used to identify a device state;
    第二获取单元,用于若所述设备状态为运动状态,且所述电机为非主动运动,则开启计步器,通过所述计步器采集所述运动方向和一定时间内的运动距离;a second acquisition unit, configured to turn on a pedometer if the device state is a motion state and the motor is not actively moving, and collect the motion direction and the motion distance within a certain period of time through the pedometer;
    控制单元,用于若所述运动距离满足预设启动条件,则控制电机向所述运动方向运动,所述运动距离满足预设启动条件,包括:A control unit, configured to control the motor to move in the movement direction if the movement distance satisfies the preset start condition, and the movement distance satisfies the preset start condition, including:
    所述运动距离大于或等于预设距离。The moving distance is greater than or equal to a preset distance.
  7. 一种电子设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如权利要求1至5任一项所述的方法。 An electronic device, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, when the processor executes the computer program, the processor according to claim 1 to 5. The method of any one.
  8. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至5任一项所述的方法。A computer-readable storage medium storing a computer program, characterized in that, when the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.
PCT/CN2021/138890 2020-12-18 2021-12-16 Device motion method and electronic device WO2022127872A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011504905.4A CN112731821B (en) 2020-12-18 2020-12-18 Equipment movement method and electronic equipment
CN202011504905.4 2020-12-18

Publications (1)

Publication Number Publication Date
WO2022127872A1 true WO2022127872A1 (en) 2022-06-23

Family

ID=75603141

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/138890 WO2022127872A1 (en) 2020-12-18 2021-12-16 Device motion method and electronic device

Country Status (2)

Country Link
CN (1) CN112731821B (en)
WO (1) WO2022127872A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112731821B (en) * 2020-12-18 2023-03-24 卧安科技(深圳)有限公司 Equipment movement method and electronic equipment
CN115016557A (en) * 2022-07-06 2022-09-06 北京万东医疗科技股份有限公司 Limiting device and method, speed control method and device and controller
CN115902766B (en) * 2022-11-22 2023-11-07 荣耀终端有限公司 Measurement method and related device

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130282325A1 (en) * 2012-04-19 2013-10-24 Fujitsu Limited Operating movement detection device, operating movement detection method, and program
CN103427723A (en) * 2013-07-10 2013-12-04 宁波杜亚机电技术有限公司 Hand-pulling-started curtain opening and closing motor
CN104840080A (en) * 2015-05-14 2015-08-19 慧锐通智能科技股份有限公司 Curtain control method and system with human body intention perception function
CN106371732A (en) * 2016-11-24 2017-02-01 广东小天才科技有限公司 Method for controlling electronic curtain and electronic terminal
CN109184536A (en) * 2018-07-16 2019-01-11 上海博开遮阳科技有限公司 A kind of control method of electrically driven curtain
CN109357620A (en) * 2018-11-27 2019-02-19 广东好太太科技集团股份有限公司 A kind of stroke detection and the device for judging the direction of motion
CN112731821A (en) * 2020-12-18 2021-04-30 卧安科技(深圳)有限公司 Equipment movement method and electronic equipment

Family Cites Families (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3718794B2 (en) * 2000-02-09 2005-11-24 三和シヤッター工業株式会社 Control mechanism for electrical switchgear for buildings
JP2006314389A (en) * 2005-05-10 2006-11-24 Yokota:Kk Electric curtain
JP4864452B2 (en) * 2005-12-27 2012-02-01 三和シヤッター工業株式会社 Control device for electric shutter for building
FR2960086B1 (en) * 2010-05-12 2012-08-03 Somfy Sas METHOD FOR LOCATING A CONTROL UNIT OF A MANEUVER ACTUATOR OF A WINDOW COVERING ELEMENT
EP4148226A3 (en) * 2011-03-11 2023-05-17 Lutron Technology Company LLC Low power radio frequency receiver
CN102723902A (en) * 2012-06-05 2012-10-10 广州市瑞翔机电有限公司 Curtain motor device triggered by magnet and magnetic-sensitive switch
US10058205B2 (en) * 2014-04-01 2018-08-28 Crestron Electornics, Inc. Automatic and dynamic torque calibration for drapery track system
CN105003188A (en) * 2015-08-21 2015-10-28 湖州高鼎智能科技有限公司 Multifunctional and intelligent curtain
CN105840037B (en) * 2016-05-23 2017-10-24 北京理工大学 A kind of multifunctional window and curtain Controller and method
CN106017506A (en) * 2016-06-22 2016-10-12 浙江工商职业技术学院 Route and hand-pulling start direction detection device of electric curtain
CN108375916B (en) * 2018-01-17 2021-09-14 深圳市博孚机电有限公司 Use method of electric curtain based on Bluetooth module
CN108412408B (en) * 2018-01-17 2020-12-25 深圳市博孚机电有限公司 Control method of electric curtain
CN110393419A (en) * 2019-06-28 2019-11-01 卧安科技(深圳)有限公司 Curtain electric control driving device
CN110568787B (en) * 2019-08-16 2022-02-22 佛山市绿创窗饰有限公司 Electric curtain control system and method capable of stopping at any time when being pulled
CN110543136B (en) * 2019-09-02 2021-11-12 同济大学 Monitoring control system of movable curtain
CN110623510A (en) * 2019-09-29 2019-12-31 珠海格力电器股份有限公司 Control method and system of intelligent curtain

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130282325A1 (en) * 2012-04-19 2013-10-24 Fujitsu Limited Operating movement detection device, operating movement detection method, and program
CN103427723A (en) * 2013-07-10 2013-12-04 宁波杜亚机电技术有限公司 Hand-pulling-started curtain opening and closing motor
CN104840080A (en) * 2015-05-14 2015-08-19 慧锐通智能科技股份有限公司 Curtain control method and system with human body intention perception function
CN106371732A (en) * 2016-11-24 2017-02-01 广东小天才科技有限公司 Method for controlling electronic curtain and electronic terminal
CN109184536A (en) * 2018-07-16 2019-01-11 上海博开遮阳科技有限公司 A kind of control method of electrically driven curtain
CN109357620A (en) * 2018-11-27 2019-02-19 广东好太太科技集团股份有限公司 A kind of stroke detection and the device for judging the direction of motion
CN112731821A (en) * 2020-12-18 2021-04-30 卧安科技(深圳)有限公司 Equipment movement method and electronic equipment

Also Published As

Publication number Publication date
CN112731821B (en) 2023-03-24
CN112731821A (en) 2021-04-30

Similar Documents

Publication Publication Date Title
WO2022127872A1 (en) Device motion method and electronic device
JP6446548B2 (en) Main MCU wake-up circuit, method and apparatus
CN110966243B (en) Upwind rotating speed detection and soft start control method and system for air conditioner fan
CN108132735B (en) Terminal and application control method
CN104683598A (en) Proximity sensor threshold adjusting method and device and intelligent device
WO2011088672A1 (en) Intelligent charging method and device for terminal
CN107831987B (en) False touch control method and device for preventing gesture operation
US20140372737A1 (en) Electronic device and method for automatically waking up operating system of electronic device
CN110910878B (en) Voice wake-up control method and device, storage medium and household appliance
CN105637450A (en) Screen sensitivity adjustment method and mobile terminal
CN108647047A (en) A kind of awakening method and system based on mobile terminal
CN105517109A (en) Method and device for controlling background scanning of wireless local area network in mobile terminal
CN204256444U (en) A kind of ultra-low power consumption wireless intelligent control system being applicable to body sense or Sound control
WO2019047412A1 (en) Menu management method and apparatus, multimedia touch control device, and storage medium
US20120091823A1 (en) Mobile storage device and method for managing power consumption of the mobile storage device
WO2016180241A1 (en) Energy-conservation management method and apparatus for terminal and terminal
CN111179924B (en) Method and system for optimizing awakening performance based on mode switching
WO2014066018A1 (en) Triggering attract mode for devices
CN111376245B (en) Steering engine control method and system and robot
CN110335599B (en) Voice control method, system, equipment and computer readable storage medium
US8412146B2 (en) Mutual awakening system and method thereof between a handheld device and a wireless communication module
CN111383633A (en) Voice recognition continuity control method and device, intelligent terminal and storage medium
CN112596600B (en) Screen unlocking method and device, storage medium and mobile terminal
CN112083792B (en) Mobile terminal control method and device and mobile terminal
CN108717349B (en) Terminal bright screen control method and device, terminal and storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21905798

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 25/10/2023)

122 Ep: pct application non-entry in european phase

Ref document number: 21905798

Country of ref document: EP

Kind code of ref document: A1