[go: up one dir, main page]

CN108616663A - File sharing method, device, mobile terminal and storage medium - Google Patents

File sharing method, device, mobile terminal and storage medium Download PDF

Info

Publication number
CN108616663A
CN108616663A CN201810470293.8A CN201810470293A CN108616663A CN 108616663 A CN108616663 A CN 108616663A CN 201810470293 A CN201810470293 A CN 201810470293A CN 108616663 A CN108616663 A CN 108616663A
Authority
CN
China
Prior art keywords
mobile terminal
motion state
identification information
state
terminal
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN201810470293.8A
Other languages
Chinese (zh)
Inventor
罗培伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201810470293.8A priority Critical patent/CN108616663A/en
Publication of CN108616663A publication Critical patent/CN108616663A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72409User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories
    • H04M1/72412User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories using two-way short-range wireless interfaces
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Environmental & Geological Engineering (AREA)
  • Telephone Function (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the application discloses a file sharing method and device, a mobile terminal and a storage medium, and relates to the field of mobile terminals. Wherein the method comprises the following steps: the method comprises the steps that a first mobile terminal obtains identification information of other mobile terminals in a preset connection mode under the condition that the file sharing function is detected to be started and the motion state is a first preset motion state; determining a second mobile terminal in the other mobile terminals according to the identification information, wherein the second mobile terminal is a mobile terminal with a file sharing function being started and a motion state being a second preset motion state within a preset time range, and the first preset motion state and the second preset motion state are correlated; and directly connecting communication with the second mobile terminal and sharing files. The sharing process is simple to operate, the sharing speed is high, and the user experience is improved.

Description

文件分享方法、装置、移动终端及存储介质File sharing method, device, mobile terminal and storage medium

技术领域technical field

本申请涉及移动终端技术领域,更具体地,涉及一种文件分享方法、装置、移动终端及存储介质。The present application relates to the technical field of mobile terminals, and more specifically, to a file sharing method, device, mobile terminal and storage medium.

背景技术Background technique

移动终端在彼此进行文件分享时,需要在分享时选中分享对象,由分享对象点击确认后与分享对象进行连接,将文件分享给分享对象。该分享过程操作繁琐,用户体验较差。When the mobile terminals share files with each other, they need to select a sharing object when sharing, and the sharing object clicks and confirms to connect with the sharing object and share the file with the sharing object. The sharing process is cumbersome to operate, and the user experience is poor.

发明内容Contents of the invention

鉴于上述问题,本申请提出了一种文件分享方法、装置、移动终端及存储介质,以解决上述问题,提高用户体验。In view of the above problems, the present application proposes a file sharing method, device, mobile terminal and storage medium to solve the above problems and improve user experience.

第一方面,本申请实施例提供了一种文件分享方法,所述方法包括:第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息;根据所述识别信息,确定所述其他移动终端中的第二移动终端,所述第二移动终端为文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,所述第一预设运动状态与所述第二预设运动状态相互关联;与所述第二移动终端直连通信连接并进行文件分享。In the first aspect, the embodiment of the present application provides a file sharing method, the method includes: when the first mobile terminal detects that the file sharing function is enabled and the motion state is the first preset motion state, connect to According to the identification information, determine the second mobile terminal among the other mobile terminals, the second mobile terminal has the file sharing function turned on and the motion state is the second within the preset time range Two mobile terminals in a preset motion state, the first preset motion state and the second preset motion state are interrelated; and the second mobile terminal is directly connected to the second mobile terminal for file sharing.

第二方面,本申请实施例提供了一种文件分享方法,所述方法包括:第二移动终端在检测到文件分享功能开启且运动状态为第二预设运动状态的情况下,接收第一移动终端发送的直连通信连接请求;获取所述第一移动终端的识别信息;根据所述第一移动终端的识别信息判断所述第一移动终端是否文件分享功能开启且在预设时间范围内运动状态为第一预设运动状态,所述第一预设运动状态与所述第二预设运动状态相互关联;若是,根据所述直连通信连接请求与所述第一移动终端直连通信连接并进行文件分享。In the second aspect, the embodiment of the present application provides a file sharing method, the method includes: when the second mobile terminal detects that the file sharing function is turned on and the motion state is the second preset motion state, receiving the first motion A direct communication connection request sent by the terminal; obtaining the identification information of the first mobile terminal; judging whether the first mobile terminal has a file sharing function enabled and is moving within a preset time range according to the identification information of the first mobile terminal The state is a first preset motion state, and the first preset motion state is associated with the second preset motion state; if so, connect directly to the first mobile terminal according to the direct communication connection request and share files.

第三方面,本申请实施例提供了一种文件分享装置,所述装置包括:信息获取模块,用于第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息;终端确定模块,用于根据所述识别信息,确定所述其他移动终端中的第二移动终端,所述第二移动终端为文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,所述第一预设运动状态与所述第二预设运动状态相互关联;执行模块,用于与所述第二移动终端直连通信连接并进行文件分享。In the third aspect, the embodiment of the present application provides a file sharing device, the device includes: an information acquisition module, used for the case where the first mobile terminal detects that the file sharing function is enabled and the motion state is the first preset motion state Next, the identification information of other mobile terminals is obtained through a preset connection method; the terminal determination module is configured to determine a second mobile terminal among the other mobile terminals according to the identification information, and the second mobile terminal has a file sharing function A mobile terminal that is turned on and whose motion state is a second preset motion state within a preset time range, the first preset motion state is associated with the second preset motion state; the execution module is configured to communicate with the second preset motion state The two mobile terminals are directly connected by communication and share files.

第四方面,本申请实施例提供了一种文件分享装置,所述装置包括:请求接收模块,第二移动终端在检测到文件分享功能开启且运动状态为第二预设运动状态的情况下,接收第一移动终端发送的直连通信连接请求;信息获取模块,用于获取所述第一移动终端的识别信息;判断模块,用于根据所述第一移动终端的识别信息判断所述第一移动终端是否文件分享功能开启且在预设时间范围内运动状态为第一预设运动状态,所述第一预设运动状态与所述第二预设运动状态相互关联;处理模块,用于若是,根据所述直连通信连接请求与所述第一移动终端直连通信连接并进行文件分享。In the fourth aspect, the embodiment of the present application provides a file sharing device, the device includes: a request receiving module, when the second mobile terminal detects that the file sharing function is enabled and the motion state is the second preset motion state, Receive a direct communication connection request sent by the first mobile terminal; an information acquisition module, configured to acquire identification information of the first mobile terminal; a judging module, configured to judge the first mobile terminal based on the identification information of the first mobile terminal Whether the file sharing function of the mobile terminal is turned on and the motion state is the first preset motion state within the preset time range, and the first preset motion state is related to the second preset motion state; the processing module is used for if and performing file sharing with the first mobile terminal through a direct communication connection according to the direct communication connection request.

第五方面,本申请实施例提供了一种移动终端,包括存储器及处理器,所述存储器耦接到所述处理器,所述存储器存储指令,当所述指令由所述处理器执行时所述处理器执行上述的方法。In the fifth aspect, the embodiment of the present application provides a mobile terminal, including a memory and a processor, the memory is coupled to the processor, and the memory stores instructions, which are executed when the instructions are executed by the processor. The processor executes the above method.

第六方面,本申请实施例提供了一种具有处理器可执行的程序代码的计算机可读存储介质,所述程序代码使所述处理器执行上述的方法。In a sixth aspect, the embodiment of the present application provides a computer-readable storage medium having a program code executable by a processor, and the program code causes the processor to execute the above-mentioned method.

本申请提供的文件分享方法、装置、移动终端及存储介质,在两个移动终端之间具有相互关联的运动状态的情况下,通过预设连接方式进行身份识别,将识别到的具有相互关联的运动状态的两个移动终端直连通信连接,使彼此之间进行文件方向。该方案中,可以通过控制移动终端的运动状态使移动终端之间直连通信连接并进行文件分享,操作简单方便。The file sharing method, device, mobile terminal and storage medium provided by the present application, in the case that two mobile terminals have interrelated motion states, identify the identity through the preset connection mode, and identify the interrelated The two mobile terminals in the motion state are directly connected by communication, so as to carry out file direction between each other. In this solution, the mobile terminals can be directly connected by communication and share files by controlling the motion state of the mobile terminals, and the operation is simple and convenient.

本申请的这些方面或其他方面在以下实施例的描述中会更加简明易懂。These or other aspects of the present application will be more concise and understandable in the description of the following embodiments.

附图说明Description of drawings

为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings that need to be used in the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those skilled in the art, other drawings can also be obtained based on these drawings without any creative effort.

图1示出了本申请实施例中移动终端之间的直连交互示意图;FIG. 1 shows a schematic diagram of a direct connection interaction between mobile terminals in an embodiment of the present application;

图2示出了本申请第一实施例提出的文件分享方法的流程图;FIG. 2 shows a flow chart of the file sharing method proposed in the first embodiment of the present application;

图3示出了本申请第二实施例提出的文件分享方法的流程图;FIG. 3 shows a flowchart of a file sharing method proposed in the second embodiment of the present application;

图4示出了本申请第三实施例提出的文件分享方法的流程图;FIG. 4 shows a flowchart of a file sharing method proposed in the third embodiment of the present application;

图5示出了本申请第四实施例提出的文件分享装置的功能模块图;FIG. 5 shows a functional block diagram of a file sharing device proposed in a fourth embodiment of the present application;

图6示出了本申请第五实施例提出的文件分享装置的功能模块图;FIG. 6 shows a functional module diagram of a file sharing device proposed in a fifth embodiment of the present application;

图7示出了本申请实施例提出的移动终端的一种结构框图;FIG. 7 shows a structural block diagram of a mobile terminal proposed in an embodiment of the present application;

图8示出了本申请实施例提出的移动终端的一种结构图;FIG. 8 shows a structural diagram of a mobile terminal proposed in an embodiment of the present application;

图9示出了本申请实施例的用于执行根据本申请实施例的文件分享方法的移动终端的框图。Fig. 9 shows a block diagram of a mobile terminal for executing the file sharing method according to the embodiment of the present application according to the embodiment of the present application.

具体实施方式Detailed ways

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the application with reference to the drawings in the embodiments of the application. Apparently, the described embodiments are only some of the embodiments of the application, not all of them. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of this application.

移动终端之间进行文件分享已经成为用户的常用功能。常用的文件分享功能可能有,通过蓝牙分享、NFC(Near Field Communication,近场通信)分享、通过移动数据网络或者无线局域网络等联网后的分享等。但是蓝牙传输速率较慢,NFC传输距离太短,而通过联网分享,要求必须有网络连接,且传输速度受网络状况影响较大。通过移动终端之间的直连通信连接进行文件分享,允许移动终端之间具有一定的距离范围,且传输速度快,传输过程中不需要消耗额外的网络流量,对于在一定距离范围内的移动终端之间,具有良好的传输效果。File sharing between mobile terminals has become a common function for users. Commonly used file sharing functions may include sharing via Bluetooth, sharing via NFC (Near Field Communication, near field communication), sharing via a mobile data network or a wireless local area network, etc. after networking. However, the transmission rate of Bluetooth is slow, and the transmission distance of NFC is too short. Sharing through the Internet requires a network connection, and the transmission speed is greatly affected by the network conditions. File sharing through direct communication connections between mobile terminals allows a certain distance between mobile terminals, and the transmission speed is fast, and no additional network traffic is consumed during the transmission process. For mobile terminals within a certain distance Between, has a good transmission effect.

发明人发现,若用户进行移动终端之间的直连时,连接发起的移动终端需要寻找其他移动终端,用户需要从寻找到的移动终端中点击选中要连接的移动终端,向被选中的移动终端发起请求。而被请求的移动终端需要在用户点击确认后,两个移动终端之间才能直连,如图1所示,进行文件传输。其中,直连即直连通信连接。The inventors have found that if a user performs a direct connection between mobile terminals, the mobile terminal that initiates the connection needs to find other mobile terminals, and the user needs to click and select the mobile terminal to be connected from the found mobile terminals, and send the mobile terminal to the selected mobile terminal. Make a request. The requested mobile terminal needs to be directly connected between the two mobile terminals after the user clicks to confirm, as shown in FIG. 1 , for file transfer. Wherein, the direct connection refers to the direct communication connection.

因此,本申请实施例提供了一种文件分享方法,根据移动终端的运动状态进行直连,从而进行文件分享,省去中间寻找和确认的操作,操作简单,提高了用户体验。下面将结合附图并通过具体的实施例对本申请实施例提供的网而言信息删除方法及装置进行说明。Therefore, the embodiment of the present application provides a file sharing method, which performs direct connection according to the motion state of the mobile terminal, thereby performing file sharing, eliminating the need for intermediate search and confirmation operations, simple operation, and improved user experience. The method and device for deleting network information provided by the embodiments of the present application will be described below with reference to the accompanying drawings and through specific embodiments.

第一实施例first embodiment

请参阅图2,本申请第一实施例提供了一种文件分享方法,用于移动终端之间进行直连通信连接后文件分享。在具体的实施例中,所述文件分享方法应用于如图5所示的文件分享装置以及对应有文件分享装置400的移动终端600(图7、图8)。上述的文件分享方法具体可以包括以下步骤:Please refer to FIG. 2 , the first embodiment of the present application provides a file sharing method, which is used for file sharing after direct communication connection between mobile terminals. In a specific embodiment, the file sharing method is applied to the file sharing device shown in FIG. 5 and the corresponding mobile terminal 600 ( FIG. 7 and FIG. 8 ) corresponding to the file sharing device 400 . The above file sharing method may specifically include the following steps:

步骤S110:第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息。Step S110: When the first mobile terminal detects that the file sharing function is enabled and the exercise state is the first preset exercise state, it obtains identification information of other mobile terminals through a preset connection method.

当用户需要将文件分享给其他移动终端时,可以通过移动终端的文件分享功能进行分享。具体的,该文件分享功能可以对应有功能开关按键,用户点击该功能开关按键可以将文件分享功能开启。When the user needs to share the file with other mobile terminals, the file sharing function of the mobile terminal can be used for sharing. Specifically, the file sharing function may correspond to a function switch button, and the user may click the function switch button to enable the file sharing function.

并且,用户可以使需要进行文件分享的移动终端之间具有相关联的运动状态,如第一移动终端以及第二移动终端之间相互碰撞,当然该碰撞力度并不限制,可以仅仅使彼此之间进行力气较小的轻碰;将第一移动终端以及第二移动终端在预设时间范围内分别模拟进行碰撞时的运动状态等。第一移动终端以及第二移动终端之间相关联的运动状态即相互碰撞时彼此对应的运动状态,或者模拟碰撞时的运动状态。可以将相关联的运动状态中,第一移动终端的运动状态定义为第一预设运动状态,将第二移动终端的运动状态定义为第二预设运动状态。Moreover, the user can make the mobile terminals that need to share files have an associated motion state, such as the first mobile terminal and the second mobile terminal collide with each other. Of course, the collision force is not limited, and only the mutual Carrying out a light touch with less force; simulating the motion state of the first mobile terminal and the second mobile terminal respectively during the collision within a preset time range. The associated motion state between the first mobile terminal and the second mobile terminal is the motion state corresponding to each other when they collide with each other, or the motion state when the collision is simulated. Among the associated motion states, the motion state of the first mobile terminal may be defined as a first preset motion state, and the motion state of the second mobile terminal may be defined as a second preset motion state.

在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,表明用户可能想要与其他移动终端之间进行文件分享,且正在试图与其他移动终端建立直连通信连接,此时可以对其他移动终端进行识别信息的获取,以根据识别信息确定要直连的移动终端。When it is detected that the file sharing function is enabled and the motion state is the first preset motion state, it indicates that the user may want to share files with other mobile terminals and is trying to establish a direct communication connection with other mobile terminals. At this time, the identification information of other mobile terminals may be obtained, so as to determine the mobile terminal to be directly connected according to the identification information.

具体的,对于文件分享功能开启以及运动状态的检测,可以是,第一移动终端在检测到文件分享功能开启的情况下,监测运动状态。或者是,所述第一移动终端在检测到移动终端的运动状态为第一预设运动状态时,监测文件分享功能是否开启。Specifically, for the detection of the activation of the file sharing function and the motion state, the first mobile terminal may monitor the motion state when detecting that the file sharing function is enabled. Alternatively, when the first mobile terminal detects that the motion state of the mobile terminal is the first preset motion state, it monitors whether the file sharing function is enabled.

其中,第一移动终端的运动状态具体可以通过第一移动终端内置的传感器进行检测,如加速度计、陀螺仪、振动传感器等。Wherein, the motion state of the first mobile terminal may specifically be detected by a built-in sensor of the first mobile terminal, such as an accelerometer, a gyroscope, a vibration sensor, and the like.

具体的,由于在使移动终端之间进行碰撞时,通常是移动终端从静止到运动再到接触静止的一个过程,因此,若检测到移动终端的加速度或者速度有突变,可以认为第一移动终端与其他移动终端进行碰撞,该突变可以包括突然变大或者突然变小,或者突然变大紧接着突然变小。例如,可以将在预设时间长度内有预设大小的加速度变化值的运动状态作为第一预设运动状态,该加速度变化值可以为同一方向上的变化值。该预设时间长度以及预设大小在本申请实施例中并不限定,如,可以是移动终端的加速度在0.5秒内增加了1单位。又如,可以将在第一预设时间长度内有第一预设大小的加速度增加值,紧接着第二预设时间长度内加速度有第二预设大小的减小值,的运动状态作为第一预设运动状态。该紧接着为时间间隔很小,如小于0.1秒的一个值,具体时间间隔值在本申请实施例中并不限定。Specifically, since the collision between mobile terminals is usually a process in which the mobile terminals go from stillness to motion and then to contact stillness, if a sudden change in the acceleration or speed of the mobile terminal is detected, it can be considered that the first mobile terminal When colliding with other mobile terminals, the sudden change may include a sudden increase or decrease, or a sudden increase followed by a sudden decrease. For example, a motion state with a preset acceleration change value within a preset time length may be used as the first preset motion state, and the acceleration change value may be a change value in the same direction. The preset time length and preset size are not limited in this embodiment of the present application, for example, it may be that the acceleration of the mobile terminal increases by 1 unit within 0.5 seconds. As another example, the motion state in which there is an acceleration increase value of a first preset size within a first preset time length, followed by a second preset decrease in acceleration within a second preset time length, can be used as the second A preset motion state. This is followed by a very small time interval, such as a value less than 0.1 second, and the specific time interval value is not limited in the embodiment of the present application.

另外,移动终端之间碰撞时,会产生振动,因此,移动终端也可以在检测到振动时判定当前的运动状态为第一预设运动状态。In addition, when the mobile terminals collide with each other, vibration will be generated. Therefore, the mobile terminal may also determine that the current motion state is the first preset motion state when vibration is detected.

在本申请实施例中,对其他移动终端进行识别信息的获取,通过预设连接方式。该预设连接方式为与进行文件分享的直连通信连接不同的连接方式,如蓝牙连接、射频连接、近场通信连接、超声波连接、电磁波连接、移动数据网络或者通过路由器进行连接的无线局域网中的任意一种或多种。In the embodiment of the present application, the identification information of other mobile terminals is acquired through a preset connection mode. The default connection method is a connection method different from the direct communication connection for file sharing, such as Bluetooth connection, radio frequency connection, near field communication connection, ultrasonic connection, electromagnetic wave connection, mobile data network or wireless local area network connected through a router. any one or more of.

在本申请实施例中,若其他移动终端中,有移动终端检测到自身产生了可能与碰撞相关的运动状态且文件分享功能开启时,可以将该碰撞相关的运动状态的相关信息以及是否开启文件分享功能等信息作为自身的识别信息的部分。In this embodiment of the application, if one of the other mobile terminals detects that it has a motion state that may be related to a collision and the file sharing function is enabled, it can provide information about the motion state related to the collision and whether to open the file Information such as sharing functions is used as part of its own identification information.

在一种具体的实施方式中,第一移动终端通过蓝牙连接的方式获取其他移动终端的识别信息。即第一移动终端与其他移动终端蓝牙连接,通过连接的蓝牙彼此交互数据。该蓝牙连接可以是由用户手动打开蓝牙连接按键并配置连接,也可以是,在用户开启文件分享功能时,移动终端自动开启蓝牙连接。In a specific implementation manner, the first mobile terminal acquires identification information of other mobile terminals through a Bluetooth connection. That is, the first mobile terminal is connected to other mobile terminals via Bluetooth, and data is exchanged with each other through the connected Bluetooth. The bluetooth connection may be manually turned on by the user to configure the bluetooth connection button and the connection may be configured, or the mobile terminal may automatically turn on the bluetooth connection when the user turns on the file sharing function.

在另一种具体的实施方式中,第一移动终端通过无线局域网获取其他移动终端的识别信息。具体的,可以是,有移动终端在检测到自身产生了可能与碰撞相关的运动状态且文件分享功能开启时,将识别信息传递到服务器。第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,向服务器请求在同一无线局域网内的移动终端的识别信息,并接收服务器根据该请求返回的识别信息。In another specific implementation manner, the first mobile terminal acquires identification information of other mobile terminals through a wireless local area network. Specifically, it may be that when a mobile terminal detects that it has a motion state that may be related to a collision and the file sharing function is turned on, it transmits the identification information to the server. When the first mobile terminal detects that the file sharing function is enabled and the motion state is the first preset motion state, the first mobile terminal requests the identification information of the mobile terminals in the same wireless local area network from the server, and receives the identification information returned by the server according to the request .

步骤S120:根据所述识别信息,确定所述其他移动终端中的第二移动终端,所述第二移动终端为文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,所述第一预设运动状态与所述第二预设运动状态相互关联。Step S120: According to the identification information, determine the second mobile terminal among the other mobile terminals, the second mobile terminal is the second mobile terminal with the file sharing function turned on and the movement state within the preset time range is the second preset movement state In the mobile terminal, the first preset motion state is associated with the second preset motion state.

第一移动终端获取的识别信息中,可能包括有相应移动终端的运动状态信息以及是否开启文件分享功能等信息,因此,第一移动终端可以根据获得的识别信息判断相应的移动终端是否为需要进行文件分享的第二移动终端。The identification information obtained by the first mobile terminal may include information such as the motion status information of the corresponding mobile terminal and whether the file sharing function is enabled. Therefore, the first mobile terminal can judge whether the corresponding mobile terminal needs to perform A second mobile terminal for file sharing.

具体的,第一移动终端获取到每个其他移动终端的识别信息后,首先可以确定该识别信息中是否有移动终端的运动状态相关信息以及文件分享功能是否开启相关信息,若有,则可以根据识别信息进一步判断该移动终端是否为第二移动终端。若某移动终端的识别信息中不包括移动终端的运动状态相关信息或者文件分享功能是否开启的相关信息,则可以判定该移动终端并非第二移动终端。Specifically, after the first mobile terminal obtains the identification information of each other mobile terminal, it can first determine whether there is information related to the motion state of the mobile terminal and whether the file sharing function is enabled in the identification information. The identification information further determines whether the mobile terminal is the second mobile terminal. If the identification information of a certain mobile terminal does not include information related to the motion state of the mobile terminal or whether the file sharing function is enabled, it can be determined that the mobile terminal is not the second mobile terminal.

根据识别信息判断某其他移动终端是否为第二移动终端时,可以判断该移动终端是否开启文件分享功能,且该移动终端在预设时间范围内的运动状态是否为第二预设运动状态。When judging whether a certain other mobile terminal is the second mobile terminal according to the identification information, it can be judged whether the file sharing function of the mobile terminal is enabled, and whether the movement state of the mobile terminal within the preset time range is the second preset movement state.

具体的,若该移动终端的识别信息中,表明该移动终端开启了文件分享功能,则可以判定该移动终端开启文件分享功能。Specifically, if the identification information of the mobile terminal indicates that the mobile terminal has enabled the file sharing function, it can be determined that the mobile terminal has enabled the file sharing function.

判定该移动终端的运动状态是否为第二预设运动状态,可以判断该移动终端的运动状态是否为与第一移动终端碰撞时对应的运动状态。由于移动终端相碰撞时,其碰撞时间一致,即两个碰撞的移动终端分别检测到碰撞发生的时间相同。因此,识别信息中可以包括运动状态的发生时间,第一移动终端可以确定该运动状态的发生时间是否在第一预设运动状态的发生时间的预设时间范围内,若在,则可以进一步判断该运动状态是否是与第一移动终端碰撞对应的运动状态。其中,预设时间范围并不限定,例如,是一个较小的时间范围,如1秒内。To determine whether the motion state of the mobile terminal is the second preset motion state, it may be determined whether the motion state of the mobile terminal is the motion state corresponding to the collision with the first mobile terminal. When the mobile terminals collide with each other, their collision time is the same, that is, the two colliding mobile terminals respectively detect that the collision occurs at the same time. Therefore, the identification information may include the occurrence time of the exercise state, and the first mobile terminal may determine whether the occurrence time of the exercise state is within the preset time range of the occurrence time of the first preset exercise state, and if so, further judge Whether the motion state is the motion state corresponding to the collision of the first mobile terminal. Wherein, the preset time range is not limited, for example, it is a relatively small time range, such as within 1 second.

作为一种具体的实施方式,由于物体相碰撞时,加速度会变化,第一移动终端判断识别信息中的运动状态是否是与第一移动终端碰撞对应的运动状态,可以判断该运动状态是否是在预设时间长度内有预设大小的加速度变化值的运动状态,若是,可以判定该识别信息对应的移动终端为第二移动终端。该预设时间长度以及预设大小并不作为本申请实施例的限定,与判断第一移动终端的运动状态是否为第一预设运动状态时的参数预设时间长度以及预设大小可以相同,也可以不同。As a specific implementation manner, since the acceleration will change when objects collide with each other, the first mobile terminal can judge whether the motion state in the identification information is the motion state corresponding to the collision of the first mobile terminal, and can judge whether the motion state is in If there is a motion state with a preset acceleration change value within a preset time length, if so, it can be determined that the mobile terminal corresponding to the identification information is the second mobile terminal. The preset time length and preset size are not limited to the embodiments of the present application, and may be the same as the parameter preset time length and preset size when judging whether the motion state of the first mobile terminal is the first preset motion state, It can also be different.

作为一种具体的实施方式,由于碰撞时会振动,识别信息中的运动状态相关信息是碰撞对应的振动信息,可以判定该运动状态为第二预设运动状态,判定该识别信息对应的移动终端为第二移动终端。As a specific implementation manner, since it will vibrate when it collides, the motion state related information in the identification information is the vibration information corresponding to the collision, it can be determined that the motion state is the second preset motion state, and the mobile terminal corresponding to the identification information can be determined is the second mobile terminal.

作为一种具体的实施方式,由于在碰撞时,两个相互碰撞的物体之间受力相同,因此,第一移动终端可以根据在检测到第一预设运动状态时计算自身受力,具体计算方式并不限定,如质量与加速度的乘积获取受力,该加速度可以是移动终端由运动到因碰撞而停止运动时的加速度。另外,第一移动终端获得的识别信息中也可以包括用以确定相应移动终端受力的参数,第一移动终端根据识别信息计算相应移动终端受力,若识别信息对应的移动终端的实力与第一移动终端的受力大小相同方向相反,则可以判定该识别信息中的运动状态为第二预设状态,该识别信息对应的移动终端为第二移动终端。其中,该受力的大小相同,可以并非绝对相同,而是允许具有一定的误差。As a specific implementation, since the force on the two colliding objects is the same during the collision, the first mobile terminal can calculate the force on itself when the first preset motion state is detected, and specifically calculate The method is not limited, for example, the product of the mass and the acceleration can obtain the force, and the acceleration can be the acceleration when the mobile terminal stops moving due to a collision. In addition, the identification information obtained by the first mobile terminal may also include parameters for determining the force of the corresponding mobile terminal. The first mobile terminal calculates the force of the corresponding mobile terminal according to the identification information. If the strength of the mobile terminal corresponding to the identification information is the same as that of the second If the force on a mobile terminal is the same in magnitude and opposite in direction, it can be determined that the motion state in the identification information is the second preset state, and the mobile terminal corresponding to the identification information is the second mobile terminal. Wherein, the magnitude of the force is the same, it may not be absolutely the same, but a certain error is allowed.

在本申请实施例中,判定识别信息中的运动状态是否为第二预设运动状态还可以有其他方式,例如该识别信息中运动状态相关信息包括相应移动终端的动量,第一移动终端根据识别信息中的运动状态以及自身的第一预设运动状态,判断识别信息中动量是否满足与自身相碰撞对应的动量;或者如通过速度变化等,在本申请实施例中并不限定。In this embodiment of the present application, there may be other ways to determine whether the motion state in the identification information is the second preset motion state. For example, the motion state related information in the identification information includes the momentum of the corresponding mobile terminal. The motion state in the information and the first preset motion state of the self determine whether the momentum in the identification information satisfies the momentum corresponding to the collision with itself; or through speed changes, etc., which are not limited in this embodiment of the application.

步骤S130:与所述第二移动终端直连通信连接并进行文件分享。Step S130: directly communicate with the second mobile terminal and perform file sharing.

当从具有预设连接方式的其他移动终端中分辨出第一移动终端后,可以与该第二移动终端建立直连通信连接,该直连通信连接为第一移动终端与第二移动终端之间点对点的通信连接,如点对点的无线保真通信连接,即Wi-Fi(Wireless Fidelity)直连。After distinguishing the first mobile terminal from other mobile terminals with a preset connection mode, a direct communication connection can be established with the second mobile terminal. The direct communication connection is between the first mobile terminal and the second mobile terminal. A point-to-point communication connection, such as a point-to-point wireless fidelity communication connection, that is, a Wi-Fi (Wireless Fidelity) direct connection.

第一移动终端与第二移动终端直连后,则可以通过该直连将文件分享给第二移动终端,第二移动终端也可以通过该直连将文件分享给第一移动终端。After the first mobile terminal is directly connected to the second mobile terminal, the file can be shared with the second mobile terminal through the direct connection, and the second mobile terminal can also be shared with the first mobile terminal through the direct connection.

在本申请实施例中,第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,从其他通过预设连接方式连接的移动终端中获取识别信息,通过识别信息从其他移动终端中确定第二移动终端,与第二移动终端之间直连并进行文件分享,操作简单且分享快速。In the embodiment of the present application, when the first mobile terminal detects that the file sharing function is enabled and the exercise state is the first preset exercise state, it obtains identification information from other mobile terminals connected through the preset connection method, and through identification The information determines the second mobile terminal from other mobile terminals, directly connects with the second mobile terminal and performs file sharing, and the operation is simple and the sharing is fast.

第二实施例second embodiment

本申请实施例提供了一种文件分享方法,与第一实施例相比,该方法中还包括根据位置信息对第二移动终端的确定。具体的,请参见图3,该方法包括:The embodiment of the present application provides a file sharing method. Compared with the first embodiment, the method further includes determining the second mobile terminal according to the location information. Specifically, please refer to Figure 3, the method includes:

步骤S210:第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息。Step S210: When the first mobile terminal detects that the file sharing function is enabled and the exercise state is the first preset exercise state, it obtains identification information of other mobile terminals through a preset connection method.

第一移动终端从其他移动终端中确定需要进行文件分享的第二移动终端,具体可以获取具有预设连接方式的其他移动终端的识别信息,根据所述识别信息,确定所述其他移动终端中的第二移动终端。The first mobile terminal determines the second mobile terminal that needs to perform file sharing from other mobile terminals. Specifically, it may obtain identification information of other mobile terminals with a preset connection mode, and determine the second mobile terminal among the other mobile terminals according to the identification information. a second mobile terminal.

步骤S220:根据所述识别信息,从所述其他移动终端中,确定文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端。Step S220: According to the identification information, from the other mobile terminals, determine the mobile terminals whose file sharing function is turned on and whose exercise state is the second preset exercise state within a preset time range.

第二移动终端可以是文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,因此,第一移动终端从其他移动终端中确定文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端。The second mobile terminal may be a mobile terminal whose file sharing function is turned on and whose movement state is the second preset movement state within a preset time range. Therefore, the first mobile terminal determines from other mobile terminals that the file sharing function is turned on and is in the preset Mobile terminals whose motion state is the second preset motion state within the time range.

步骤S230:所述识别信息中还包括位置信息,根据所述位置信息,从确定的移动终端中,确定与所述第一移动终端位置差别小于预设距离值的移动终端作为第二移动终端。Step S230: The identification information further includes location information, and according to the location information, determine a mobile terminal whose location difference from the first mobile terminal is less than a preset distance value from among the determined mobile terminals as a second mobile terminal.

由于进行文件分享的两个移动终端之间,相互碰撞,因此距离较近,为避免将并非与第一移动终端碰撞的移动终端误识别,因此,可以进一步通过位置信息判断,从所述其他移动终端中,确定与所述第一移动终端位置差别小于预设距离值的移动终端作为第二移动终端。也就是说,可以从上述步骤确定的移动终端中,进一步确定与自身位置差别小于预设距离值的移动终端,作为进行直连文件交互的第二移动终端。Since the two mobile terminals for file sharing collide with each other, the distance is relatively short. In order to avoid misidentifying the mobile terminal that is not colliding with the first mobile terminal, it can be further judged by position information, from the other mobile terminals. Among the terminals, a mobile terminal whose position difference from the first mobile terminal is less than a preset distance value is determined as the second mobile terminal. That is to say, from the mobile terminals determined in the above steps, it is possible to further determine a mobile terminal whose location is less than a preset distance value from itself as the second mobile terminal for direct file interaction.

其中,该预设距离值的具体数在本申请实施例中并不限定,如小于1米。另外该预设距离值也可以由位置信息的精度确定,若位置信息的精度过大,如位置信息的精度大于1米,则可以确定与第一移动终端在同一位置的移动终端为第二移动终端。Wherein, the specific number of the preset distance value is not limited in the embodiment of the present application, such as less than 1 meter. In addition, the preset distance value can also be determined by the accuracy of the location information. If the accuracy of the location information is too large, such as the accuracy of the location information is greater than 1 meter, then it can be determined that the mobile terminal at the same location as the first mobile terminal is the second mobile terminal. terminal.

步骤S240:与所述第二移动终端直连通信连接并进行文件分享。Step S240: directly communicate with the second mobile terminal and perform file sharing.

在本申请实施例中,通过位置信息进一步确定相互碰撞的移动终端,减小误判,使文件分享更加安全,快捷、方便。In the embodiment of the present application, the mobile terminals colliding with each other are further determined through the location information, so as to reduce misjudgment and make file sharing safer, faster and more convenient.

第三实施例third embodiment

本实施例提供了一种文件分享方法,请参见图4,该方法包括:This embodiment provides a file sharing method, please refer to Figure 4, the method includes:

步骤S310:第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息。Step S310: When the first mobile terminal detects that the file sharing function is enabled and the exercise state is the first preset exercise state, it obtains identification information of other mobile terminals through a preset connection method.

步骤S320:第二移动终端在检测到文件分享功能开启且运动状态为碰撞对应的运动状态的情况下,生成识别信息,发送给通过预设连接方式的第一移动终端。Step S320: When the second mobile terminal detects that the file sharing function is enabled and the motion state is the motion state corresponding to the collision, it generates identification information and sends it to the first mobile terminal through the preset connection mode.

第一移动终端以及第二移动终端在互相碰撞时,分别检测到自身运动状态为碰撞对应的运动状态。第一移动终端检测到自身运动状态为碰撞对应的运动状态时,确定自身的运动状态为第一预设运动状态。第二移动终端检测到自身运动状态为碰撞对应的运动状态时,确定自身的运动状态为第二预设运动状态,可以理解的,第二移动终端确定自身运动状态时,将与碰撞对应的运动状态确定为第二预设运动状态。具体检测可以通过加速度计、陀螺仪、振动传感器等可以对运动状态进行检测的传感器,在此不做赘述。第二移动终端生成包括运动状态相关信息以及文件分享功能开启信息的识别信息,其中,运动状态相关信息可以是检测到该运动状态的发生时间,即碰撞时间,该运动状态对应的参数,如加速度、加速度变化、速度、速度变化、动量、受力等一个或多个。第一移动终端也可以生成包括运动状态相关信息以及文件分享功能开启信息的识别信息,当然,第一移动终端也可以生成仅包括运动状态相关信息的识别信息。When the first mobile terminal and the second mobile terminal collide with each other, they respectively detect that their own motion states are motion states corresponding to the collision. When the first mobile terminal detects that its own motion state is the motion state corresponding to the collision, it determines that its own motion state is the first preset motion state. When the second mobile terminal detects that its own motion state is the motion state corresponding to the collision, it determines that its own motion state is the second preset motion state. It can be understood that when the second mobile terminal determines its own motion state, it determines the motion state corresponding to the collision The state is determined as the second preset motion state. The specific detection can be through accelerometers, gyroscopes, vibration sensors and other sensors that can detect the motion state, and details will not be described here. The second mobile terminal generates identification information including motion state-related information and file sharing function enabling information, wherein the motion state-related information may be the time when the motion state is detected, that is, the collision time, and the parameters corresponding to the motion state, such as acceleration , acceleration change, velocity, velocity change, momentum, force, etc. one or more. The first mobile terminal may also generate identification information including exercise state related information and file sharing function activation information, and of course, the first mobile terminal may also generate identification information including only exercise state related information.

第一移动终端以及第二移动终端之间通过预设连接方式识别彼此。其中,第一移动终端可以通过预设连接方式获取其他移动终端的识别信息,第二移动终端响应于通过预设连接方式的第一移动终端,将识别信息发送给第一移动中终端。The first mobile terminal and the second mobile terminal identify each other through a preset connection mode. Wherein, the first mobile terminal can obtain identification information of other mobile terminals through a preset connection mode, and the second mobile terminal sends the identification information to the first mobile terminal in response to the first mobile terminal through a preset connection mode.

步骤S330:第一移动终端根据所述识别信息,确定所述其他移动终端中的第二移动终端,所述第二移动终端为文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,所述第一预设运动状态与所述第二预设运动状态相互关联。Step S330: The first mobile terminal determines the second mobile terminal among the other mobile terminals according to the identification information, and the second mobile terminal has the file sharing function turned on and the motion status within the preset time range is the second preset. Assuming a mobile terminal in a motion state, the first preset motion state is associated with the second preset motion state.

第一移动终端获取到第二移动终端的识别信息,根据第二移动终端的识别信息将第二移动终端识别出来,并确定其为第二移动终端。可以理解的,第一移动终端在对第二移动终端进行识别时,判断识别信息中该第二移动终端的运动状态是否是与自身的第一预设运动状态相关联的运动状态,若是,则第一移动终端可以判定该移动终端为需要进行文件分享的、与自身碰撞的第二移动终端。The first mobile terminal acquires the identification information of the second mobile terminal, identifies the second mobile terminal according to the identification information of the second mobile terminal, and determines that it is the second mobile terminal. It can be understood that when the first mobile terminal identifies the second mobile terminal, it judges whether the motion state of the second mobile terminal in the identification information is the motion state associated with its own first preset motion state, and if so, then The first mobile terminal may determine that the mobile terminal is a second mobile terminal that needs to perform file sharing and collides with itself.

步骤S340:第一移动终端向第二移动终端发起直连通信连接请求。Step S340: the first mobile terminal initiates a direct communication connection request to the second mobile terminal.

第一移动终端将向识别出的第二移动终端发起直连通信连接请求,请求用于文件分享的直连通信。The first mobile terminal will initiate a direct connection communication connection request to the identified second mobile terminal, requesting direct connection communication for file sharing.

步骤S350:第二移动终端在检测到文件分享功能开启且运动状态为第二预设运动状态的情况下,接收第一移动终端发送的直连通信连接请求。Step S350: When the second mobile terminal detects that the file sharing function is enabled and the exercise state is the second preset exercise state, the second mobile terminal receives the direct communication connection request sent by the first mobile terminal.

步骤S360:第二移动终端获取所述第一移动终端的识别信息。Step S360: the second mobile terminal obtains the identification information of the first mobile terminal.

第二移动终端若文件分享功能开启,且运动状态为第二预设运动状态,接收第一移动终端发送的直连通信请求,并且对第一移动终端进行身份识别。第二移动终端对第一移动终端的身份识别可以通过第一移动终端的识别信息实现。If the file sharing function is enabled and the motion state of the second mobile terminal is the second preset motion state, the second mobile terminal receives the direct connection communication request sent by the first mobile terminal, and performs identification on the first mobile terminal. The identity identification of the first mobile terminal by the second mobile terminal can be realized through the identification information of the first mobile terminal.

作为一种实施方式,第二移动终端可以通过预设连接方式获取第一移动终端的识别信息。该识别信息可以是第一移动终端在发起直连通信连接请求时主动发送给第二移动终端,也可以由第二移动终端在接收到直连通信连接请求时向第一移动终端要求获取。As an implementation manner, the second mobile terminal may obtain the identification information of the first mobile terminal through a preset connection manner. The identification information may be actively sent to the second mobile terminal by the first mobile terminal when it initiates a direct communication connection request, or may be requested by the second mobile terminal from the first mobile terminal when receiving the direct communication connection request.

作为一种实施方式,第一移动终端可以在直连通信连接请求中携带识别信息,第二移动终端在接收到直连通信连接请求时可以获得第一移动终端的识别信息。As an implementation manner, the first mobile terminal may carry identification information in the direct communication connection request, and the second mobile terminal may obtain the identification information of the first mobile terminal when receiving the direct communication connection request.

步骤S370:第二移动终端根据所述第一移动终端的识别信息判断所述第一移动终端是否文件分享功能开启且在预设时间范围内运动状态为第一预设运动状态,所述第一预设运动状态与所述第二预设运动状态相互关联。Step S370: The second mobile terminal judges according to the identification information of the first mobile terminal whether the file sharing function of the first mobile terminal is enabled and the movement state within the preset time range is the first preset movement state, and the first mobile terminal The preset motion state is associated with the second preset motion state.

第二移动终端对第一移动终端进行识别。具体识别方法可以参照第一移动终端对第二移动终端进行识别。例如,第二移动终端识别第一移动终端的运动状态时,可以通过如速度、加速度、动量、力等任意一种或多种参数判断接收到的识别信息中的运动状态与自身运动状态是否为两个移动终端碰撞时分别对应的运动状态,如果是,则可以判定向第二移动终端发起直连通信连接请求的第一移动终端的运动状态为第一预设运动状态。或者若识别信息中的运动状态为,在预设时间长度内有预设大小的加速度变化值的运动状态,则第二移动终端判定为与自己碰撞的第一移动终端。The second mobile terminal identifies the first mobile terminal. The specific identification method may refer to the first mobile terminal to identify the second mobile terminal. For example, when the second mobile terminal recognizes the motion state of the first mobile terminal, it can use any one or more parameters such as speed, acceleration, momentum, force, etc. to judge whether the motion state in the received identification information is consistent with its own motion state. If the respective corresponding motion states of the two mobile terminals collide, it may be determined that the motion state of the first mobile terminal that initiates a direct communication connection request to the second mobile terminal is the first preset motion state. Alternatively, if the motion state in the identification information is a motion state with a preset acceleration change value within a preset time length, the second mobile terminal is determined to be the first mobile terminal colliding with itself.

步骤S380:若是,第二移动终端根据所述直连通信连接请求与所述第二移动终端直连通信连接并进行文件分享。Step S380: If yes, the second mobile terminal communicates directly with the second mobile terminal according to the direct communication connection request and performs file sharing.

在第二移动终端对第一移动终端识别成功后,第二移动终端与第一移动终端之间可以建立直连通信连接,从而彼此之间可以进行文件分享。After the second mobile terminal successfully identifies the first mobile terminal, a direct communication connection can be established between the second mobile terminal and the first mobile terminal, so that files can be shared with each other.

本申请实施例中,第一移动终端以及第二移动终端相互交互,以确认彼此的身份,正确识别彼此为用户通过对其运动的操作需要进行直连分享的移动终端。当第一移动终端与第二移动终端互相碰撞,或者彼此做模拟互相碰撞的运动,第一移动终端检测到自身运动状态为碰撞对应的运动状态,自身定义为第一预设运动状态,第一移动终端可以生成包括自身运动状态相关信息以及文件分享功能开启的相关信息的识别信息;第二移动终端检测到自身运动状态为碰撞对应的运动状态,自身将其定义为第二预设运动状态,第二移动终端可以生成包括自身运动状态相关信息以及文件分享功能开启的相关信息的识别信息。In the embodiment of the present application, the first mobile terminal and the second mobile terminal interact with each other to confirm each other's identities and correctly identify each other as mobile terminals that need to be directly connected and shared by the user through the operation of the movement. When the first mobile terminal and the second mobile terminal collide with each other, or perform a motion simulating a collision with each other, the first mobile terminal detects that its own motion state is the motion state corresponding to the collision, and defines itself as the first preset motion state. The mobile terminal can generate identification information including information related to its own motion state and information related to the opening of the file sharing function; the second mobile terminal detects that its own motion state is a motion state corresponding to a collision, and defines it as the second preset motion state by itself, The second mobile terminal may generate identification information including information about its own exercise state and information about enabling a file sharing function.

第一移动终端通过预设连接方式获取其他的一个或多个移动终端的识别信息,获取到第二移动终端的识别信息后,根据该识别信息对第二移动终端进行识别。若第一移动终端获取到的识别信息中,表明该识别信息对应的移动终端文件分享功能开启,其运动状态与自身的第一预设运动状态相互关联,该关联表明该移动终端为与自身进行碰撞的移动终端,则第一移动终端认为该识别信息中的运动状态为第二预设运动状态,该移动终端为第二移动终端,可以与其进行直连文件分享。The first mobile terminal acquires identification information of one or more other mobile terminals through a preset connection mode, and after acquiring the identification information of the second mobile terminal, identifies the second mobile terminal according to the identification information. If the identification information obtained by the first mobile terminal indicates that the file sharing function of the mobile terminal corresponding to the identification information is enabled, and its motion state is associated with its own first preset motion state, the association indicates that the mobile terminal is performing If the mobile terminal collides, the first mobile terminal considers the motion state in the identification information to be the second preset motion state, and the mobile terminal is the second mobile terminal, and can perform direct connection file sharing with it.

第二移动终端在接收到第一移动终端的直连通信请求,同样可以对第一移动终端进行识别,判断其是否为与其进行碰撞的移动终端。第二移动终端的识别也可以是获取第一移动终端的识别信息,根据识别信息判断该移动终端是否是与其进行碰撞的移动终端,若是,则第二移动终端可以判定该移动终端是可以进行直连文件分享的第一移动终端,与其进行直连通信,文件分享。After receiving the direct connection communication request from the first mobile terminal, the second mobile terminal can also identify the first mobile terminal and determine whether it is a mobile terminal that collides with it. The identification of the second mobile terminal can also be to obtain the identification information of the first mobile terminal, and judge whether the mobile terminal is a mobile terminal that collides with it according to the identification information, and if so, the second mobile terminal can determine whether the mobile terminal can carry out direct collision. The first mobile terminal for file sharing, direct communication and file sharing with it.

在一种具体的应用中,用户在需要通过第一移动终端快速方便进行文件分享时,可以先选定需要分享的文件,再对该文件进行分享操作。在分享操作时,用户可以开启文件分享功能,此时若预设连接方式未开启,则第一移动终端自动开启预设连接方式。用户再将第一移动终端与要分享的第二移动终端轻碰。第二移动终端的用户在轻碰前或者轻碰后,可以开启文件分享功能,且若预设连接方式未开启,则第二移动终端自动开启预设连接方式。第一移动终端以及第二移动终端通过对自身运动状态的检测以及彼此身份的识别建立直连通信连接,建立成功后,将第一移动终端分享的文件通过该直连通信传输到第二移动终端。另外,建立连接后,第二移动终端也可以向第一移动终端传输文件。In a specific application, when the user needs to quickly and conveniently share files through the first mobile terminal, he can first select the file to be shared, and then perform the sharing operation on the file. During the sharing operation, the user can enable the file sharing function. At this time, if the default connection mode is not enabled, the first mobile terminal will automatically enable the default connection mode. The user touches the first mobile terminal with the second mobile terminal to be shared. The user of the second mobile terminal can enable the file sharing function before or after the light touch, and if the default connection mode is not enabled, the second mobile terminal will automatically enable the default connection mode. The first mobile terminal and the second mobile terminal establish a direct communication connection by detecting their own motion status and identifying each other's identities. After the establishment is successful, the file shared by the first mobile terminal is transmitted to the second mobile terminal through the direct communication. . In addition, after the connection is established, the second mobile terminal may also transmit files to the first mobile terminal.

本申请实施例提供的文件分享方法仅需通过对需要分享的移动终端之间的运动控制,便可实现文件分享,操作简单,分享速度快,极大提高了用户体验。The file sharing method provided by the embodiment of the present application can realize file sharing only by controlling the movement between the mobile terminals that need to be shared, the operation is simple, the sharing speed is fast, and the user experience is greatly improved.

第四实施例Fourth embodiment

本申请实施例提供了一种文件分享装置400,请参见图5,该装置400包括:The embodiment of this application provides a file sharing device 400, please refer to Figure 5, the device 400 includes:

信息获取模块410,用于第一移动终端在检测到文件分享功能开启且运动状态为第一预设运动状态的情况下,通过预设连接方式获取其他移动终端的识别信息。终端确定模块420,用于根据所述识别信息,确定所述其他移动终端中的第二移动终端,所述第二移动终端为文件分享功能开启且在预设时间范围内运动状态为第二预设运动状态的移动终端,所述第一预设运动状态与所述第二预设运动状态相互关联。执行模块430,用于与所述第二移动终端直连通信连接并进行文件分享。The information acquisition module 410 is used for the first mobile terminal to obtain identification information of other mobile terminals through a preset connection mode when the first mobile terminal detects that the file sharing function is enabled and the exercise state is the first preset exercise state. A terminal determining module 420, configured to determine a second mobile terminal among the other mobile terminals according to the identification information, the second mobile terminal has a file sharing function enabled and the motion state is the second preset within a preset time range. Assuming a mobile terminal in a motion state, the first preset motion state is associated with the second preset motion state. The execution module 430 is configured to directly communicate with the second mobile terminal and perform file sharing.

可选的,本申请实施例中,还包括检测模块,用于第一移动终端在检测到文件分享功能开启的情况下,监测运动状态;或第一移动终端在检测到移动终端的运动状态为第一预设运动状态时,监测文件分享功能是否开启。Optionally, in the embodiment of the present application, a detection module is also included, which is used for the first mobile terminal to monitor the motion state when it detects that the file sharing function is enabled; or when the first mobile terminal detects that the motion state of the mobile terminal is In the first preset exercise state, monitor whether the file sharing function is enabled.

可选的,第一预设运动状态以及所述第二预设运动状态可以为两个移动终端碰撞时分别对应的运动状态。Optionally, the first preset motion state and the second preset motion state may be respectively corresponding motion states when two mobile terminals collide.

可选的,所述第一预设运动状态以及所述第二预设运动状态均为在预设时间长度内有预设大小的加速度变化值的运动状态。Optionally, both the first preset motion state and the second preset motion state are motion states with a preset acceleration change value within a preset time length.

可选的,识别信息中还可以包括位置信息,终端确定模块420可以进一步根据所述位置信息,从所述其他移动终端中,确定与所述第一移动终端位置差别小于预设距离值的移动终端作为第二移动终端。Optionally, the identification information may also include location information, and the terminal determining module 420 may further determine from the other mobile terminals according to the location information the mobile terminal whose location difference from the first mobile terminal is less than a preset distance value. The terminal serves as the second mobile terminal.

其中,预设连接方式包括以下任意一种或多种:蓝牙连接、射频连接、近场通信连接、超声波连接或电磁波连接。Wherein, the preset connection mode includes any one or more of the following: Bluetooth connection, radio frequency connection, near field communication connection, ultrasonic connection or electromagnetic wave connection.

其中,直连通信连接可以为与第二移动终端之间点对点的无线保真通信连接。Wherein, the direct communication connection may be a point-to-point wireless fidelity communication connection with the second mobile terminal.

第五实施例fifth embodiment

本申请实施例提供了一种文件分享装置500。请参见图6,所述装置500包括:请求接收模块510,第二移动终端在检测到文件分享功能开启且运动状态为第二预设运动状态的情况下,接收第一移动终端发送的直连通信连接请求。信息获取模块520,用于获取所述第一移动终端的识别信息。判断模块530,用于根据所述第一移动终端的识别信息判断所述第一移动终端是否文件分享功能开启且在预设时间范围内运动状态为第一预设运动状态,所述第一预设运动状态与所述第二预设运动状态相互关联;处理模块540,用于若是,根据所述直连通信连接请求与所述第一移动终端直连通信连接并进行文件分享。The embodiment of the present application provides a file sharing device 500 . Please refer to FIG. 6 , the device 500 includes: a request receiving module 510, when the second mobile terminal detects that the file sharing function is turned on and the motion state is the second preset motion state, it receives the direct connection sent by the first mobile terminal Communication connection request. An information acquiring module 520, configured to acquire the identification information of the first mobile terminal. A judging module 530, configured to judge, according to the identification information of the first mobile terminal, whether the file sharing function of the first mobile terminal is enabled and the motion state within a preset time range is a first preset motion state, and the first preset motion state is It is assumed that the exercise state is related to the second preset exercise state; if yes, the processing module 540 is configured to directly communicate with the first mobile terminal according to the direct communication connection request and perform file sharing.

第六实施例Sixth embodiment

请再次参阅图7,基于上述的文件分享方法及装置,本申请实施例还提供一种移动终端600。如图7所示,该移动终端600包括存储器104及处理器102,所述存储器104耦接到所述处理器102,所述存储器104存储指令,当所述指令由所述处理器102执行时所述处理器102执行上述第一实施例所述的方法、第二实施例所述的方法或者第三实施例所述的方法。Please refer to FIG. 7 again. Based on the above file sharing method and device, the embodiment of the present application further provides a mobile terminal 600 . As shown in Figure 7, the mobile terminal 600 includes a memory 104 and a processor 102, the memory 104 is coupled to the processor 102, the memory 104 stores instructions, and when the instructions are executed by the processor 102 The processor 102 executes the method described in the first embodiment, the method described in the second embodiment, or the method described in the third embodiment.

具体的,如图8所示,该移动终端600可以包括电子本体部10,所述电子本体部10包括壳体12及设置在所述壳体12上的显示屏120。所述壳体12可采用金属、如钢材、铝合金制成。本实施例中,所述显示屏120通常包括显示面板111,也可包括用于响应对所述显示面板111进行触控操作的电路等。所述显示面板111可以为一个液晶显示面板(Liquid CrystalDisplay,LCD),在一些实施例中,所述显示面板111同时为一个触摸屏109。Specifically, as shown in FIG. 8 , the mobile terminal 600 may include an electronic body part 10 , and the electronic body part 10 includes a housing 12 and a display screen 120 disposed on the housing 12 . The housing 12 can be made of metal, such as steel or aluminum alloy. In this embodiment, the display screen 120 generally includes a display panel 111 , and may also include a circuit for responding to a touch operation on the display panel 111 . The display panel 111 may be a liquid crystal display panel (Liquid Crystal Display, LCD), and in some embodiments, the display panel 111 is also a touch screen 109 .

请同时参阅图9,在实际的应用场景中,所述移动终端600可作为智能手机终端进行使用,在这种情况下所述电子本体部10通常还包括一个或多个(图中仅示出一个)处理器102、存储器104、RF(Radio Frequency,射频)模块106、音频电路110、传感器114、输入模块118、电源模块122。本领域普通技术人员可以理解,图9所示的结构仅为示意,其并不对所述电子本体部10的结构造成限定。例如,所述电子本体部10还可包括比图9中所示更多或者更少的组件,或者具有与图9所示不同的对应。Please refer to FIG. 9 at the same time. In an actual application scenario, the mobile terminal 600 can be used as a smartphone terminal. In this case, the electronic main body 10 usually includes one or more (only shown in the figure a) A processor 102 , a memory 104 , an RF (Radio Frequency, radio frequency) module 106 , an audio circuit 110 , a sensor 114 , an input module 118 , and a power module 122 . Those skilled in the art can understand that the structure shown in FIG. 9 is only a schematic diagram, which does not limit the structure of the electronic body part 10 . For example, the electronic body part 10 may also include more or fewer components than those shown in FIG. 9 , or have a different correspondence from that shown in FIG. 9 .

本领域普通技术人员可以理解,相对于所述处理器102来说,所有其他的组件均属于外设,所述处理器102与这些外设之间通过多个外设接口124相耦合。所述外设接口124可基于以下标准实现:通用异步接收/发送装置(Universal Asynchronous Receiver/Transmitter,UART)、通用输入/输出(General Purpose Input Output,GPIO)、串行外设接口(Serial Peripheral Interface,SPI)、内部集成电路(Inter-Integrated Circuit,I2C),但不并限于上述标准。在一些实例中,所述外设接口124可仅包括总线;在另一些实例中,所述外设接口124还可包括其他元件,如一个或者多个控制器,例如用于连接所述显示面板111的显示控制器或者用于连接存储器的存储控制器。此外,这些控制器还可以从所述外设接口124中脱离出来,而集成于所述处理器102内或者相应的外设内。Those skilled in the art can understand that, relative to the processor 102 , all other components belong to peripherals, and the processor 102 is coupled to these peripherals through a plurality of peripheral interfaces 124 . The peripheral interface 124 can be implemented based on the following standards: Universal Asynchronous Receiver/Transmitter (UART), General Purpose Input Output (GPIO), Serial Peripheral Interface (Serial Peripheral Interface) , SPI), inter-integrated circuit (Inter-Integrated Circuit, I2C), but not limited to the above standards. In some examples, the peripheral interface 124 may only include a bus; in other examples, the peripheral interface 124 may also include other components, such as one or more controllers, for example for connecting the display panel 111 display controller or memory controller for connecting memory. In addition, these controllers can also be separated from the peripheral interface 124 and integrated in the processor 102 or corresponding peripherals.

所述存储器104可用于存储软件程序以及模块,所述处理器102通过运行存储在所述存储器104内的软件程序以及模块,从而执行各种功能应用以及数据处理。所述存储器104可包括高速随机存储器,还可包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,所述存储器104可进一步包括相对于所述处理器102远程设置的存储器,这些远程存储器可以通过网络连接至所述电子本体部10或所述显示屏120。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 104 can be used to store software programs and modules, and the processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104 . The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory that is remotely located relative to the processor 102 , and these remote memories may be connected to the electronic main body 10 or the display screen 120 through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

所述RF模块106用于接收以及发送电磁波,实现电磁波与电信号的相互转换,从而与通讯网络或者其他设备进行通讯。所述RF模块106可包括各种现有的用于执行这些功能的电路元件,例如,天线、射频收发器、数字信号处理器、加密/解密芯片、用户身份模块(SIM)卡、存储器等等。所述RF模块106可与各种网络如互联网、企业内部网、无线网络进行通讯或者通过无线网络与其他设备进行通讯。上述的无线网络可包括蜂窝式电话网、无线局域网或者城域网。上述的无线网络可以使用各种通信标准、协议及技术,包括但并不限于全球移动通信系统(Global System for Mobile Communication,GSM)、增强型移动通信技术(Enhanced Data GSM Environment,EDGE),宽带码分多址技术(wideband codedivision multiple access,W-CDMA),码分多址技术(Code division access,CDMA)、时分多址技术(time division multiple access,TDMA),无线保真技术(Wireless,Fidelity,WiFi)(如美国电气和电子工程师协会标准IEEE 802.10A,IEEE 802.11b,IEEE802.11g和/或IEEE 802.11n)、网络电话(Voice over internet protocal,VoIP)、全球微波互联接入(Worldwide Interoperability for Microwave Access,Wi-Max)、其他用于邮件、即时通讯及短消息的协议,以及任何其他合适的通讯协议,甚至可包括那些当前仍未被开发出来的协议。The RF module 106 is used to receive and send electromagnetic waves, realize mutual conversion between electromagnetic waves and electrical signals, and communicate with communication networks or other devices. The RF module 106 may include various existing circuit elements for performing these functions, such as antennas, radio frequency transceivers, digital signal processors, encryption/decryption chips, Subscriber Identity Module (SIM) cards, memory, etc. . The RF module 106 can communicate with various networks such as the Internet, intranet, wireless network or communicate with other devices through the wireless network. The aforementioned wireless network may include a cellular telephone network, a wireless local area network or a metropolitan area network. The above-mentioned wireless network can use various communication standards, protocols and technologies, including but not limited to Global System for Mobile Communication (GSM), Enhanced Data GSM Environment (EDGE), wideband code Division multiple access technology (wideband code division multiple access, W-CDMA), code division multiple access technology (Code division access, CDMA), time division multiple access technology (time division multiple access, TDMA), wireless fidelity technology (Wireless, Fidelity, WiFi) (such as IEEE 802.10A, IEEE 802.11b, IEEE802.11g and/or IEEE 802.11n), VoIP (Voice over internet protocal, VoIP), Worldwide Interoperability for Microwave Access, Wi-Max), other protocols for mail, instant messaging, and short messages, and any other suitable communication protocols, even those that have not yet been developed.

音频电路110、扬声器101、传声器103、麦克风105共同提供用户与所述电子本体部10或所述显示屏120之间的音频接口。The audio circuit 110 , the speaker 101 , the microphone 103 , and the microphone 105 jointly provide an audio interface between the user and the electronic main body 10 or the display screen 120 .

所述传感器114设置在所述电子本体部10内或所述显示屏120内,所述传感器114的实例包括但并不限于:加速度传感器114F、陀螺仪114G、磁力计114H以及其他传感器。The sensor 114 is disposed in the electronic main body 10 or the display screen 120 , examples of the sensor 114 include but not limited to: an acceleration sensor 114F, a gyroscope 114G, a magnetometer 114H and other sensors.

本实施例中,所述输入模块118可包括设置在所述显示屏120上的所述触摸屏109,所述触摸屏109可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在所述触摸屏109上或在所述触摸屏109附近的操作),从而可以获得用户的触摸手势,并根据预先设定的程序驱动相应的连接装置,因此,用户可以通过在显示屏的触控操作选定目标区域。可选的,所述触摸屏109可包括触摸检测装置和触摸控制器。其中,所述触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给所述触摸控制器;所述触摸控制器从所述触摸检测装置上接收触摸信息,并将该触摸信息转换成触点坐标,再送给所述处理器102,并能接收所述处理器102发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现所述触摸屏109的触摸检测功能。除了所述触摸屏109,在其它变更实施方式中,所述输入模块118还可以包括其他输入设备,如按键107。所述按键107例如可包括用于输入字符的字符按键,以及用于触发控制功能的控制按键。所述控制按键的实例包括“返回主屏”按键、开机/关机按键等等。In this embodiment, the input module 118 may include the touch screen 109 arranged on the display screen 120, and the touch screen 109 may collect touch operations of the user on or near it (for example, the user uses a finger, a stylus, etc. Any suitable object or accessory on the touch screen 109 or near the touch screen 109), so that the user's touch gesture can be obtained, and the corresponding connection device can be driven according to the preset program. Therefore, the user can The touch operation of the display screen selects the target area. Optionally, the touch screen 109 may include a touch detection device and a touch controller. Wherein, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, and The touch information is converted into touch point coordinates, and then sent to the processor 102, and can receive and execute commands sent by the processor 102. In addition, the touch detection function of the touch screen 109 can be realized by various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to the touch screen 109 , in other modified implementation manners, the input module 118 may also include other input devices, such as keys 107 . The keys 107 may include, for example, character keys for inputting characters, and control keys for triggering control functions. Examples of the control buttons include a "return to main screen" button, a power on/off button, and the like.

所述显示屏120用于显示由用户输入的信息、提供给用户的信息以及所述电子本体部10的各种图形用户接口,这些图形用户接口可以由图形、文本、图标、数字、视频和其任意组合来构成。在一个实例中,所述触摸屏109可设置于所述显示面板111上从而与所述显示面板111构成一个整体。The display screen 120 is used to display information input by the user, information provided to the user, and various graphical user interfaces of the electronic main body 10. These graphical user interfaces can be composed of graphics, text, icons, numbers, videos and other any combination to form. In one example, the touch screen 109 can be disposed on the display panel 111 so as to form an integral body with the display panel 111 .

所述电源模块122用于向所述处理器102以及其他各组件提供电力供应。具体地,所述电源模块122可包括电源管理系统、一个或多个电源(如电池或者交流电)、充电电路、电源失效检测电路、逆变器、电源状态指示灯以及其他任意与所述电子本体部10或所述显示屏120内电力的生成、管理及分布相关的组件。The power module 122 is used to provide power supply to the processor 102 and other components. Specifically, the power module 122 may include a power management system, one or more power sources (such as batteries or alternating current), a charging circuit, a power failure detection circuit, an inverter, a power status indicator light, and any other components related to the electronic body. Components related to the generation, management and distribution of power in the unit 10 or the display screen 120 .

所述移动终端600还包括定位器119,所述定位器119用于确定所述移动终端600所处的实际位置。本实施例中,所述定位器119采用定位服务来实现所述移动终端600的定位,所述定位服务,应当理解为通过特定的定位技术来获取所述移动终端600的位置信息(如经纬度坐标),在电子地图上标出被定位对象的位置的技术或服务。The mobile terminal 600 further includes a locator 119, and the locator 119 is used to determine the actual location of the mobile terminal 600. In this embodiment, the locator 119 uses a positioning service to realize the positioning of the mobile terminal 600. The positioning service should be understood as obtaining the position information (such as longitude and latitude coordinates) of the mobile terminal 600 through a specific positioning technology. ), a technology or service that marks the position of a positioned object on an electronic map.

应当理解的是,上述的移动终端600并不局限于智能手机终端,其应当指可以在移动中使用的计算机设备。具体而言,移动终端600,是指搭载了智能操作系统的移动计算机设备,移动终端600包括但不限于智能手机、智能手表、平板电脑,等等。It should be understood that the above-mentioned mobile terminal 600 is not limited to a smart phone terminal, but refers to a computer device that can be used on the move. Specifically, the mobile terminal 600 refers to a mobile computer device equipped with an intelligent operating system, and the mobile terminal 600 includes but is not limited to a smart phone, a smart watch, a tablet computer, and the like.

需要说明的是,本说明书中的各个实施例均采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似的部分互相参见即可。对于装置类实施例而言,由于其与方法实施例基本相似,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。对于方法实施例中的所描述的任意的处理方式,在装置实施例中均可以通过相应的处理模块实现,装置实施例中不再一一赘述。It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. For the same and similar parts in each embodiment, refer to each other, that is, Can. As for the device-type embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and for related parts, please refer to part of the description of the method embodiments. Any of the processing methods described in the method embodiments can be implemented by corresponding processing modules in the device embodiments, and details will not be repeated in the device embodiments.

在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本申请的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不必须针对的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任一个或多个实施例或示例中以合适的方式结合。此外,在不相互矛盾的情况下,本领域的技术人员可以将本说明书中描述的不同实施例或示例以及不同实施例或示例的特征进行结合和组合。In the description of this specification, descriptions referring to the terms "one embodiment", "some embodiments", "example", "specific examples", or "some examples" mean that specific features described in connection with the embodiment or example , structure, material or characteristic is included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms are not necessarily directed to the same embodiment or example. Furthermore, the described specific features, structures, materials or characteristics may be combined in any suitable manner in any one or more embodiments or examples. In addition, those skilled in the art can combine and combine different embodiments or examples and features of different embodiments or examples described in this specification without conflicting with each other.

此外,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。在本申请的描述中,“多个”的含义是至少两个,例如两个,三个等,除非另有明确具体的限定。In addition, the terms "first" and "second" are used for descriptive purposes only, and cannot be interpreted as indicating or implying relative importance or implicitly specifying the quantity of indicated technical features. Thus, the features defined as "first" and "second" may explicitly or implicitly include at least one of these features. In the description of the present application, "plurality" means at least two, such as two, three, etc., unless otherwise specifically defined.

流程图中或在此以其他方式描述的任何过程或方法描述可以被理解为,表示包括一个或更多个用于实现特定逻辑功能或过程的步骤的可执行指令的代码的模块、片段或部分,并且本申请的优选实施方式的范围包括另外的实现,其中可以不按所示出或讨论的顺序,包括根据所涉及的功能按基本同时的方式或按相反的顺序,来执行功能,这应被本申请的实施例所属技术领域的技术人员所理解。Any process or method descriptions in flowcharts or otherwise described herein may be understood to represent modules, segments or portions of code comprising one or more executable instructions for implementing specific logical functions or steps of the process , and the scope of preferred embodiments of the present application includes additional implementations in which functions may be performed out of the order shown or discussed, including in substantially simultaneous fashion or in reverse order depending on the functions involved, which shall It should be understood by those skilled in the art to which the embodiments of the present application belong.

在流程图中表示或在此以其他方式描述的逻辑和/或步骤,例如,可以被认为是用于实现逻辑功能的可执行指令的定序列表,可以具体实现在任何计算机可读介质中,以供指令执行系统、装置或设备(如基于计算机的系统、包括处理器的系统或其他可以从指令执行系统、装置或设备取指令并执行指令的系统)使用,或结合这些指令执行系统、装置或设备而使用。就本说明书而言,"计算机可读介质"可以是任何可以包含、存储、通信、传播或传输程序以供指令执行系统、装置或设备或结合这些指令执行系统、装置或设备而使用的装置。计算机可读介质的更具体的示例(非穷尽性列表)包括以下:具有一个或多个布线的电连接部(移动终端),便携式计算机盘盒(磁装置),随机存取存储器(RAM),只读存储器(ROM),可擦除可编辑只读存储器(EPROM或闪速存储器),光纤装置,以及便携式光盘只读存储器(CDROM)。另外,计算机可读介质甚至可以是可在其上打印所述程序的纸或其他合适的介质,因为可以例如通过对纸或其他介质进行光学扫描,接着进行编辑、解译或必要时以其他合适方式进行处理来以电子方式获得所述程序,然后将其存储在计算机存储器中。The logic and/or steps represented in the flowcharts or otherwise described herein, for example, can be considered as a sequenced listing of executable instructions for implementing logical functions, can be embodied in any computer-readable medium, For use with instruction execution systems, devices, or devices (such as computer-based systems, systems including processors, or other systems that can fetch instructions from instruction execution systems, devices, or devices and execute instructions), or in conjunction with these instruction execution systems, devices or equipment used. For the purposes of this specification, a "computer-readable medium" may be any device that can contain, store, communicate, propagate or transmit a program for use in or in conjunction with an instruction execution system, device or device. More specific examples (non-exhaustive list) of computer readable media include the following: electrical connection with one or more wires (mobile terminal), portable computer disk case (magnetic device), random access memory (RAM), Read Only Memory (ROM), Erasable and Editable Read Only Memory (EPROM or Flash Memory), Fiber Optic Devices, and Portable Compact Disc Read Only Memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program can be printed, since the program can be read, for example, by optically scanning the paper or other medium, followed by editing, interpretation or other suitable processing if necessary. processing to obtain the program electronically and store it in computer memory.

应当理解,本申请的各部分可以用硬件、软件、固件或它们的组合来实现。在上述实施方式中,多个步骤或方法可以用存储在存储器中且由合适的指令执行系统执行的软件或固件来实现。例如,如果用硬件来实现,和在另一实施方式中一样,可用本领域公知的下列技术中的任一项或他们的组合来实现:具有用于对数据信号实现逻辑功能的逻辑门电路的离散逻辑电路,具有合适的组合逻辑门电路的专用集成电路,可编程门阵列(PGA),现场可编程门阵列(FPGA)等。It should be understood that each part of the present application may be realized by hardware, software, firmware or a combination thereof. In the embodiments described above, various steps or methods may be implemented by software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented by any one or combination of the following techniques known in the art: Discrete logic circuits, ASICs with suitable combinational logic gates, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.

本技术领域的普通技术人员可以理解实现上述实施例方法携带的全部或部分步骤是可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,该程序在执行时,包括方法实施例的步骤之一或其组合。此外,在本申请各个实施例中的各功能单元可以集成在一个处理模块中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。所述集成的模块如果以软件功能模块的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中。Those of ordinary skill in the art can understand that all or part of the steps carried by the methods of the above embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium. During execution, one or a combination of the steps of the method embodiments is included. In addition, each functional unit in each embodiment of the present application may be integrated into one processing module, each unit may exist separately physically, or two or more units may be integrated into one module. The above-mentioned integrated modules can be implemented in the form of hardware or in the form of software function modules. If the integrated modules are realized in the form of software function modules and sold or used as independent products, they can also be stored in a computer-readable storage medium.

上述提到的存储介质可以是只读存储器,磁盘或光盘等。尽管上面已经示出和描述了本申请的实施例,可以理解的是,上述实施例是示例性的,不能理解为对本申请的限制,本领域的普通技术人员在本申请的范围内可以对上述实施例进行变化、修改、替换和变型。The storage medium mentioned above may be a read-only memory, a magnetic disk or an optical disk, and the like. Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limitations on the present application, and those skilled in the art can make the above-mentioned The embodiments are subject to changes, modifications, substitutions and variations.

最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不驱使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。Finally, it should be noted that: the above 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 foregoing embodiments, those of ordinary skill in the art should understand that: it can still Modifications are made to the technical solutions described in the foregoing embodiments, or equivalent replacements are made to some of the technical features; and these modifications or replacements do not drive the essence of the corresponding technical solutions away from the spirit and scope of the technical solutions of the various embodiments of the present application.

Claims (12)

1. a kind of sharing files method, which is characterized in that the method includes:
First movement terminal detect sharing files function open and motion state be the first predetermined movement state in the case of, The identification information of other mobile terminals is obtained by presetting connection type;
According to the identification information, determine that the second mobile terminal in other described mobile terminals, second mobile terminal are The mobile terminal that sharing files function is opened and motion state is the second predetermined movement state in preset time range, described the One predetermined movement state and the second predetermined movement state are interrelated;
With second mobile terminal it is direct-connected communication connection and carry out sharing files.
2. according to the method described in claim 1, it is characterized in that, described obtain other mobile terminals by default connection type Identification information before, further include:
The first movement terminal monitors motion state in the case where detecting that sharing files function is opened;Or
The first movement terminal is when the motion state for detecting mobile terminal is the first predetermined movement state, monitoring file point Enjoy whether function opens.
3. according to the method described in claim 1, it is characterized in that, the first predetermined movement state and described second default Motion state corresponding motion state when being two mobile terminal collisions.
4. according to the method described in claim 1, it is characterized in that, the first predetermined movement state and described second default Motion state is the motion state for the acceleration change value for having default size in predetermined time period.
5. according to the method described in claim 1, it is characterized in that, further include location information in the identification information, described According to the identification information, determine that the second mobile terminal in other described mobile terminals further includes:
According to the positional information, from other described mobile terminals, determination is less than with the first movement terminal location difference The mobile terminal of pre-determined distance value is as the second mobile terminal.
6. method according to any one of claims 1 to 5, which is characterized in that the default connection type includes following It anticipates one or more:
Bluetooth connection, radio frequency connection, near-field communication connection, ultrasonic wave connection or electromagnetic wave connection.
7. method according to any one of claims 1 to 5, which is characterized in that the direct-connected communication connection is to be moved with second Point-to-point Wireless Fidelity communication connection between dynamic terminal.
8. a kind of sharing files method, which is characterized in that the method includes:
Second mobile terminal detect sharing files function open and motion state be the second predetermined movement state in the case of, Receive the direct-connected communication connection request that first movement terminal is sent;
Obtain the identification information of the first movement terminal;
According to the identification information of the first movement terminal judge the first movement terminal whether sharing files function open and Motion state is the first predetermined movement state in preset time range, and the first predetermined movement state is default with described second Motion state is interrelated;
If so, communicating to connect style of writing part point of going forward side by side according to the direct-connected communication connection request and the first movement terminal are direct-connected It enjoys.
9. a kind of sharing files device, which is characterized in that described device includes:
Data obtaining module is detecting that sharing files function is opened and motion state is first default for first movement terminal In the case of motion state, the identification information of other mobile terminals is obtained by presetting connection type;
Terminal deciding module, for according to the identification information, determining the second mobile terminal in other described mobile terminals, institute It is that sharing files function is opened and motion state is the second predetermined movement state in preset time range to state the second mobile terminal Mobile terminal, the first predetermined movement state and the second predetermined movement state are interrelated;
Execution module, for second mobile terminal it is direct-connected communication connection and carry out sharing files.
10. a kind of sharing files device, which is characterized in that described device includes:
Request receiving module, the second mobile terminal are detecting that sharing files function is opened and motion state is the second predetermined movement In the case of state, the direct-connected communication connection request that first movement terminal is sent is received;
Data obtaining module, the identification information for obtaining the first movement terminal;
Judgment module, for judging the first movement terminal according to the identification information of the first movement terminal, whether file divides Enjoy function open and in preset time range motion state be the first predetermined movement state, the first predetermined movement state with The second predetermined movement state is interrelated;
Processing module, for if so, according to the direct-connected communication connection request and the direct-connected communication connection of first movement terminal And carry out sharing files.
11. a kind of mobile terminal, which is characterized in that including memory and processor, the memory is couple to the processor, The memory store instruction, the processor perform claim requirement 1 to 7 is any when executed by the processor Method described in.
12. a kind of computer readable storage medium for the program code that can perform with processor, which is characterized in that described program Code makes the processor perform claim require 1 to 7 any one of them method.
CN201810470293.8A 2018-05-16 2018-05-16 File sharing method, device, mobile terminal and storage medium Pending CN108616663A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810470293.8A CN108616663A (en) 2018-05-16 2018-05-16 File sharing method, device, mobile terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810470293.8A CN108616663A (en) 2018-05-16 2018-05-16 File sharing method, device, mobile terminal and storage medium

Publications (1)

Publication Number Publication Date
CN108616663A true CN108616663A (en) 2018-10-02

Family

ID=63663576

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810470293.8A Pending CN108616663A (en) 2018-05-16 2018-05-16 File sharing method, device, mobile terminal and storage medium

Country Status (1)

Country Link
CN (1) CN108616663A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112822790A (en) * 2021-01-08 2021-05-18 重庆创通联智物联网有限公司 Data transmission method and device, electronic equipment and computer readable storage medium
CN113051119A (en) * 2021-03-31 2021-06-29 联想(北京)有限公司 Information processing method and device
WO2021238967A1 (en) * 2020-05-29 2021-12-02 华为技术有限公司 Content sharing method, apparatus and system
CN114547100A (en) * 2022-01-13 2022-05-27 Oppo广东移动通信有限公司 Resource information sharing method, electronic equipment and computer storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3192292A1 (en) * 2014-09-08 2017-07-19 Qualcomm Incorporated Automatic authorization for access to electronic device
CN107277756A (en) * 2017-07-18 2017-10-20 广东欧珀移动通信有限公司 A kind of data transmission method, device, terminal and computer-readable recording medium
CN107333225A (en) * 2017-06-20 2017-11-07 腾讯科技(深圳)有限公司 The exchange method and device of wearable electronic
CN107360636A (en) * 2017-07-18 2017-11-17 广东欧珀移动通信有限公司 A kind of data transmission method, device, terminal and computer-readable recording medium
CN108024223A (en) * 2017-12-07 2018-05-11 北京小米移动软件有限公司 Data sharing method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3192292A1 (en) * 2014-09-08 2017-07-19 Qualcomm Incorporated Automatic authorization for access to electronic device
CN107333225A (en) * 2017-06-20 2017-11-07 腾讯科技(深圳)有限公司 The exchange method and device of wearable electronic
CN107277756A (en) * 2017-07-18 2017-10-20 广东欧珀移动通信有限公司 A kind of data transmission method, device, terminal and computer-readable recording medium
CN107360636A (en) * 2017-07-18 2017-11-17 广东欧珀移动通信有限公司 A kind of data transmission method, device, terminal and computer-readable recording medium
CN108024223A (en) * 2017-12-07 2018-05-11 北京小米移动软件有限公司 Data sharing method and device

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021238967A1 (en) * 2020-05-29 2021-12-02 华为技术有限公司 Content sharing method, apparatus and system
US12028300B2 (en) 2020-05-29 2024-07-02 Huawei Technologies Co., Ltd. Method, apparatus, and system for sending pictures after thumbnail selections
CN112822790A (en) * 2021-01-08 2021-05-18 重庆创通联智物联网有限公司 Data transmission method and device, electronic equipment and computer readable storage medium
CN113051119A (en) * 2021-03-31 2021-06-29 联想(北京)有限公司 Information processing method and device
CN114547100A (en) * 2022-01-13 2022-05-27 Oppo广东移动通信有限公司 Resource information sharing method, electronic equipment and computer storage medium
WO2023134389A1 (en) * 2022-01-13 2023-07-20 Oppo广东移动通信有限公司 Resource information sharing method, electronic device, and computer storage medium

Similar Documents

Publication Publication Date Title
KR101450411B1 (en) Device movement user interface gestures for file sharing functionality
JP6467526B2 (en) Communication message transmission method and wearable device
KR102092063B1 (en) Method And Apparatus For Performing Communication Service
KR20210053018A (en) Electronic device and method for performing ranging through uwb
CN108702602B (en) Method, electronic device and system for sharing images
CN108710456B (en) Application icon processing method and device and mobile terminal
WO2017129053A1 (en) Data transmission method and device
CN108616663A (en) File sharing method, device, mobile terminal and storage medium
CN108021642A (en) Application program recommendation method and device, mobile terminal and storage medium
CN108932102B (en) Data processing method, device and mobile terminal
CN108228025A (en) message display method, device, mobile terminal and storage medium
WO2018153028A1 (en) Method and apparatus for establishing wireless local area network connection and terminal
CN108964838A (en) Transmission rate adjusting method and device and electronic device
WO2019140657A1 (en) Method and device for network connection and terminal
CN108650335A (en) Method, device and testing equipment for communication connection with mobile terminal to be tested
CN111031471A (en) Data transmission method, terminal and base station
CN108037990A (en) Task information processing method and device and server
CN108769299A (en) Screen control method, device and mobile terminal
WO2018049970A1 (en) Hotspot network switching method and terminal
CN108924908A (en) WiFi scanning method and device and electronic device
CN112867175A (en) Device connection method, device, electronic device and storage medium
CN108737640A (en) False touch prevention method and device, mobile terminal and storage medium
CN108646967A (en) display switching method, device, mobile terminal and storage medium
CN108803961B (en) Data processing method, device and mobile terminal
CN108965042A (en) Network delay obtaining method and device, terminal equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20181002