Vehicle crash assistance and communication recovery method and system based on multi-stage state machine
Patent Information
- Application Number
- CN202611179587.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-05
- Publication Date
- 2026-10-30
AI Technical Summary
第一,在汽车领域,现有碰撞报警方案缺乏多阶段可取消的求助状态机
第一,通过多路径碰撞检测,将骑行中碰撞和驻车被撞分为多条独立检测路径,骑行中路径采用加速度、陀螺仪、速度三条件AND逻辑精确过滤非碰撞冲击,驻车路径基于倾角与电锁状态联合判断识别停车状态被撞,既降低了误报率又消除了驻车场景的漏报。
Smart Images

Figure CN123016598A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of intelligent traffic safety and Internet of Things communication technology, specifically to an automatic emergency assistance method and system for vehicles, including but not limited to two-wheeled vehicles, three-wheeled vehicles, and automobiles, after a collision. In particular, it relates to a multi-stage state machine control method after collision detection, a voice-interactive cancellation mechanism, an automatic cancellation mechanism for resuming driving, and a multi-level communication recovery link for the communication module. Background Technology
[0002] With societal development and the increasing prevalence of vehicles in transportation, the number of traffic accidents is rising year by year. Drivers and passengers are easily injured in collisions, and accidents often go unnoticed in time, especially at night or in remote areas; delayed rescue can lead to serious consequences. Current automatic emergency call solutions after vehicle collisions have the following shortcomings: First, in the automotive field, existing collision alarm solutions lack a multi-stage, cancelable emergency call state machine. Solutions with automatic alarm functions (such as in-vehicle E-call systems) directly enter the emergency call process after being triggered, and users cannot cancel it before it is triggered. In non-emergency scenarios, false alarms directly enter the customer service process, which not only wastes resources but also delays the response speed when real assistance is needed.
[0003] Secondly, in the two-wheeled and three-wheeled vehicle sector, existing collision warning solutions typically employ local audible and visual alarms or manual SOS buttons, lacking voice interaction guidance and remote automatic assistance capabilities. Manual SOS becomes completely ineffective when the user loses capacity, making automatic assistance impossible.
[0004] Furthermore, the aforementioned technical deficiencies are not limited to specific vehicle models but are prevalent in all types of vehicles (including but not limited to automobiles, two-wheeled vehicles, three-wheeled vehicles, rail vehicles, engineering vehicles, and other mobile vehicles). Currently, there is no universal collision assistance solution that can be applied to multiple vehicle models simultaneously and possesses a multi-stage cancelable state machine and adaptive communication recovery capabilities.
[0005] Third, there is a lack of an automatic cancellation mechanism when driving resumes after a collision. In existing systems, once a collision alarm is triggered, the alarm continues even after the occupants have resumed normal driving. There is no mechanism to automatically determine and restore normal driving based on the driving status. Users must wait for the alarm process to end automatically or intervene manually, increasing unnecessary operational burden, thus distracting driving attention and increasing safety risks.
[0006] Fourth, the communication module lacks a recovery mechanism in collision scenarios. In vehicle collisions, equipment may suffer severe impacts, leading to communication module deadlock, firmware malfunctions, power supply fluctuations, and other communication failures. Existing solutions lack a progressively escalating recovery mechanism for communication module failures after a collision. Once the communication module enters an abnormal state due to the impact of a collision, it will directly cause subsequent distress signal reporting to fail.
[0007] Fifth, the collision detection scheme is too simplistic and cannot cover all scenarios. Existing solutions typically only design detection logic for collisions while in motion, lacking a separate detection path for collisions while parked (such as being hit from behind while waiting for someone or at a traffic light), leading to missed collisions in parked scenarios. At the same time, some existing solutions use simple conditional OR logic, with different sensor conditions triggering independently, lacking the precise filtering of AND logic, resulting in false alarms in non-collision scenarios such as road bumps and emergency braking.
[0008] The closest existing technologies to this technical solution include: automotive eCall systems, which automatically call emergency services based on airbag deployment and GPS. However, eCall systems establish a voice call directly after a short wait following airbag deployment, lacking multi-stage progressive alarms and multiple cancellation methods. Furthermore, they rely on the vehicle's airbag system, making them unsuitable for other vehicle models. Additionally, manual intervention for confirmation and dispatching rescue is required, increasing response time compared to automatic reporting and potentially delaying optimal rescue opportunities. Smart wearable devices based on collision detection, such as smart helmets, have built-in acceleration sensors that notify a mobile phone via Bluetooth after a collision, but require manual confirmation from the user to trigger the emergency call. This function is unavailable when the user is incapacitated due to an accident. Bluetooth connectivity is limited; the phone may lose range after a collision, leading to reporting failure. Wearable devices also have limited battery life and cannot remain online for extended periods. Collision alarm systems based on in-vehicle terminals typically use GSM SMS or GPRS to report collision events, but lack a recovery mechanism for communication module failures after a collision. If the communication module locks up due to the impact, reporting is impossible. None of the above solutions solve the problem of "providing a cancelable help window through a multi-stage state machine after a vehicle collision, and ensuring reliable reporting of help information through multi-level communication recovery links in the event of a communication failure". Summary of the Invention
[0009] This invention provides a vehicle collision assistance and communication recovery method and system based on a multi-stage state machine. It detects collision events through at least one independent detection path, covering collisions during riding and / or collisions while parked, reducing false alarm and false alarm rates. It further reduces false alarm rates through a multi-stage cancelable state machine, improves user experience through an automatic cancellation mechanism upon resumption of driving, ensures reliable communication after a collision through a cyclical multi-level communication recovery link, and reduces false alarms in the parking state through joint judgment of the electric lock status, thereby improving the accuracy and reliability of automatic assistance after a vehicle collision.
[0010] (I) Technical Solution To achieve the above objectives, the present invention provides the following technical solution: This invention provides a vehicle collision distress call and communication recovery method based on a multi-stage state machine, applicable to vehicles, including but not limited to two-wheeled vehicles, three-wheeled vehicles, and automobiles. The method monitors the vehicle's motion state data in real time, detects collision events through at least one independent detection path, and initiates a multi-stage distress call state machine upon detection of a collision event.
[0011] The independent detection paths include at least one of the following: a collision detection path during riding, triggered when all three conditions are met simultaneously: acceleration exceeding a preset acceleration threshold, vehicle angular velocity exceeding a preset angular velocity threshold, and GPS speed exceeding a preset speed threshold; and a collision detection path while parked, triggered when the vehicle tilt angle exceeds a preset tilt angle threshold and the duration exceeds a preset time threshold, while the vehicle's ignition lock closing time is less than a preset time threshold. Each path operates independently and detects in parallel, covering collisions during riding and / or collisions while parked.
[0012] The multi-stage distress state machine includes at least one cancelable stage and an automatic reporting stage. In the cancelable stage, the user can exit the state machine using a preset cancellation method, thus avoiding false alarms. In the automatic reporting stage, the distress information is reported to the cloud server via the communication module; if the reporting fails, a multi-level communication recovery link is initiated to attempt to restore communication and re-report. During the state machine's operation, the vehicle's driving status is monitored in real time, and the state machine automatically exits when it is determined that the vehicle has resumed driving.
[0013] Preferably, the multi-stage emergency call state machine includes four stages: The first stage is the forced alarm stage, which outputs a high-intensity alarm signal for a first preset duration. This stage cannot be canceled by the user and is used to awaken the user's awareness, attract the attention of those around, and deter the perpetrator. The second stage is the voice inquiry stage, which plays an inquiry voice and waits for a second preset duration. The user can cancel this stage by pressing a physical button, using a remote command, or resuming driving. The third stage is the countdown warning stage, which plays a countdown voice and lasts for a third preset duration. The user can cancel this stage by pressing a physical button, using a remote command, or resuming driving. The fourth stage is the automatic reporting stage, which performs a limited number of retries to report. If the report is successful, the user cannot manually cancel it by pressing a physical button or using a remote command, but the automatic cancellation mechanism is still effective when driving resumes. If the report fails, it enters a loop recovery mode, which the user can cancel by pressing a physical button or resuming driving.
[0014] Preferably, in the third stage, a status report is sent to the cloud server through the communication module every time a countdown number is broadcast, so that the cloud platform and associated user terminals can obtain the countdown progress in real time, which facilitates remote monitoring and intervention.
[0015] Preferably, the determination of vehicle resumption of driving employs a dual-mode detection: the primary mode determines that the vehicle has resumed driving if the speed continuously exceeds a preset speed threshold for a preset time using the GPS system; the backup mode determines that the vehicle has resumed driving if the GPS signal is invalid or the speed is below the threshold, by detecting that the longitudinal acceleration of the vehicle body exceeds a preset acceleration threshold for a preset time using the inertial measurement unit. Dual-mode detection ensures that the vehicle resumption of driving status can still be correctly identified in scenarios where the GPS signal is obstructed, such as tunnels or under overpasses.
[0016] Preferably, the multi-level communication recovery link includes a three-level progressive recovery: the first level performs a complete reset of the communication module via AT commands, including reinitialization of the radio frequency, protocol stack, and user identity module; the second level achieves a complete cold restart by controlling the power-on / off pins of the communication module; and the third level performs a complete power-off and then power-on by controlling the switching elements on the power supply circuit of the communication module. If all three levels of recovery fail, the process returns to the first level and restarts the loop, sequentially performing the first, second, and third levels of recovery, repeating until recovery is successful, the user cancels, or the device is powered off. During the cyclic recovery process, the system continuously monitors for user cancellation operations. The user can issue a cancellation command by briefly pressing a physical button or resuming driving, exiting the cyclic recovery mode and exiting the state machine.
[0017] Preferably, the method further includes a joint determination step for the electric lock status: during collision detection, the vehicle's electric lock status is acquired. If the electric lock is in the closed state and the closing time exceeds a preset threshold, it is determined to be in a parked state and the person has left, without triggering the multi-stage emergency call state machine, and transitioning to a low-level abnormal notification. Specifically, if the device is still powered on, a local broadcast prompt is made and a mobile terminal notification is pushed; if the device has been powered off and entered a sleep state, only a mobile terminal notification is pushed.
[0018] Preferably, the method also includes a manual triggering step: when the device is operating normally, if a physical button is detected to be pressed continuously for more than a preset duration, the system directly enters the fourth stage of automatic reporting, skipping the first to third stages. If the GPS has not yet located the device, the reported information will indicate an unlocated status, and a location update will be sent via the communication module after a valid location is obtained.
[0019] This invention also provides a vehicle collision assistance and communication recovery system based on a multi-stage state machine, comprising: a sensor module for real-time monitoring of vehicle motion state data, including an accelerometer and a gyroscope; a main control module connected to the sensor module and configured to execute the above-described method; a communication module connected to the main control module for data communication with a cloud server; an audio output module connected to the main control module for outputting alarm signals and voice prompts; an electric lock detection module connected to the main control module for detecting the vehicle's electric lock status; and a cloud platform for receiving assistance information reported by the device, pushing notifications to associated user terminals, providing remote cancellation functionality, and deduplicating duplicate assistance information with the same device identifier.
[0020] (ii) Beneficial effects The present invention has the following beneficial effects: First, through multi-path collision detection, collisions during riding and collisions while parking are divided into multiple independent detection paths. The riding path uses a three-condition AND logic of acceleration, gyroscope, and speed to accurately filter non-collision impacts. The parking path is based on the joint judgment of tilt angle and electric lock status to identify collisions while parking, which reduces the false alarm rate and eliminates the missed detection in the parking scenario.
[0021] Second, by using a multi-stage cancelable state machine, it provides four stages after collision detection: mandatory alarm, voice inquiry, countdown warning, and automatic reporting. This balances deterrence, user interaction, and false alarm prevention, significantly reducing the false alarm rate.
[0022] Third, by adopting a dual-mode detection system of GPS speed and inertial measurement unit acceleration, the alarm is automatically canceled when driving resumes after a minor collision, without the need for manual operation, thus improving user experience and driving safety.
[0023] Fourth, the recovery link is restored through a three-level progressive cyclic communication, from software reset to hardware cold restart and then to complete power failure restart, gradually increasing the recovery strength. If all attempts fail, the cycle is restarted and never given up. At the same time, the cycle can be canceled at any time, which takes into account both the continuity of recovery and the user's control.
[0024] Fifth, by jointly judging the electric lock status, it effectively distinguishes between collision accidents and accidental activation when the lock is parked, greatly reducing false alarms when the lock is parked and improving the user experience.
[0025] Sixth, the health status of the communication module is continuously monitored through an independent watchdog task. When communication is abnormal, the recovery link is actively triggered. Even if the help state machine has exited, the long-term stable operation of the communication module can still be guaranteed.
[0026] Seventh, the countdown real-time synchronization mechanism enables the cloud platform and associated user terminals to obtain the countdown progress in real time, facilitating remote monitoring and intervention and improving response efficiency in emergency scenarios.
[0027] Eighth, through an automatic reporting mechanism, the system directly reports the request for help to the cloud server and notifies emergency contacts after a collision, eliminating the need for manual customer service intervention for confirmation and dispatch. This reduces the reliance on manual customer service in the request for help confirmation process and saves operating costs. Attached Figure Description
[0028] Figure 1 This is a simplified flowchart of the automatic emergency call and communication recovery method after a collision provided in Embodiment 1 of the present invention.
[0029] Figure 2 This is a detailed flowchart of the automatic emergency call and communication recovery method after a collision provided in Embodiment 1 of the present invention.
[0030] Figure 3 This is the state transition diagram of the multi-stage help-seeking state machine provided in Embodiment 1 of the present invention.
[0031] Figure 4 This is an execution flowchart of the multi-level communication recovery link provided in Embodiment 2 of the present invention.
[0032] Figure 5 This is a flowchart of the dual-mode detection for resuming driving provided in Embodiment 3 of the present invention.
[0033] Figure 6 This is a system composition block diagram provided in Embodiment 4 of the present invention. Detailed Implementation
[0034] The present invention will be further described below with reference to the accompanying drawings and specific embodiments, but the implementation of the present invention is not limited thereto.
[0035] Example 1 This embodiment provides a vehicle collision assistance and communication recovery method based on a multi-stage state machine, applicable to vehicles, including but not limited to two-wheeled vehicles, three-wheeled vehicles, and automobiles.
[0036] After the device is powered on, it monitors the data from the accelerometer and gyroscope in real time and detects collision events through at least one independent detection path.
[0037] Collision detection path during riding (Path A): A collision event is triggered when the acceleration detected by the accelerometer exceeds a preset acceleration threshold (e.g., 2.0g, the specific threshold can be determined by those skilled in the art based on the vehicle model and installation location through actual vehicle calibration), the angular velocity of the vehicle detected by the gyroscope exceeds a preset angular velocity threshold (e.g., 60 degrees / second, the specific threshold can be set by those skilled in the art based on the actual application scenario), and the speed of the global positioning system exceeds a preset speed threshold (e.g., 5km / h, the specific threshold can be set by those skilled in the art based on the actual application scenario). Specifically, the accelerometer detects the impact intensity, the gyroscope distinguishes between "rotational falls" and "straight-line bumps" (e.g., when crossing manhole covers or speed bumps, the gyroscope angular velocity is close to zero, so no trigger is given), and the global positioning system speed confirms that the vehicle is in a riding state. The AND logic of these three factors ensures that the event is triggered only in real riding collision scenarios, greatly reducing the false alarm rate.
[0038] Parking collision detection path (Path B): When the vehicle tilt angle detected by the gyroscope exceeds a preset tilt angle threshold (e.g., 65 degrees, the specific threshold can be set by those skilled in the art according to the actual application scenario) and the duration exceeds a preset time threshold (e.g., 3 seconds, the specific duration can be selected by those skilled in the art according to the actual application scenario), and the vehicle ignition lock closing time is less than a preset time threshold (e.g., 60 seconds, the specific duration can be selected by those skilled in the art according to the actual application scenario), a parking collision event is triggered. Specifically, tilt angle detection identifies when the vehicle has been knocked down, and the 3-second duration prevents accidental activation due to a brief tilt when the kickstand is lowered. The ignition lock closing time being less than 60 seconds confirms that the driver or passengers have recently turned off the engine and may still be in or near the vehicle, requiring assistance. If the ignition lock closing time exceeds 60 seconds, it is determined that the person has left, and the vehicle being knocked down is only considered property damage; the emergency call state machine is not triggered, and the notification transitions to a low-level anomaly.
[0039] Each detection path runs independently and in parallel; triggering any path will activate a multi-stage help state machine.
[0040] A multi-stage help-seeking state machine consists of four stages: Phase 1 – Forced Alarm Phase: Executed immediately upon entering the state machine, this phase outputs a high-intensity alarm signal via the audio output module (e.g., a continuous, sustained alarm sound driven by a power amplifier, with volume unaffected by the current volume setting, forced to maximum output), for a first preset duration (e.g., 5 seconds; the specific duration can be selected by those skilled in the art based on the actual application scenario). This phase is a forced alarm phase that cannot be canceled by the user, designed to attract the attention of those nearby, deter potential perpetrators, and serve as a "cooling-off period" after the collision, preventing accidental triggering of subsequent phases due to short-term vibration.
[0041] The second stage – voice inquiry stage: This stage automatically begins after the first stage. A voice synthesis module broadcasts an inquiry (e.g., "Collision has occurred, do you want to sound the alarm?"), followed by a second preset duration (e.g., 3 seconds; the specific duration can be selected by those skilled in the art based on the actual application scenario). During this stage, the user can cancel the operation by briefly pressing a physical button (press time less than a preset value, e.g., 500ms), issuing a remote command (e.g., sending a cancellation command via a message queue telemetry transmission protocol), or actively resuming driving. After cancellation, a cancellation confirmation voice (e.g., "Cancelled") is broadcast, restoring normal device operation.
[0042] The third stage – countdown warning stage: If the second stage is not cancelled, it automatically enters the third stage, broadcasting a countdown warning voice (e.g., "Automatic alarm in ten seconds"), followed by a digital countdown (e.g., "10, 9, 8...1"), broadcasting one number per second for a third preset duration (e.g., 10 seconds; the specific duration can be selected by those skilled in the art based on the actual application scenario). Simultaneously with each countdown number broadcast, a status report is sent to the cloud server via the communication module, enabling the cloud platform and associated user terminals to obtain the countdown progress in real time. During this stage, the user can cancel the countdown by short-pressing a physical button, using a remote command, or resuming driving. After cancellation, a cancellation confirmation voice is played and the user exits the state machine.
[0043] Phase Four – Automatic Reporting Phase: If the countdown in Phase Three ends and is not canceled, Phase Four will automatically begin. Upon entry, a limited number of retries for reporting will be performed immediately (e.g., a maximum of 3 times, with a 2-second interval between each retries; the specific number of retries and intervals can be selected by those skilled in the art based on the actual application scenario). Before reporting, the device continuously obtains the latest positioning data from the GPS module. If the device's position has shifted after the collision (e.g., being dragged by the offending vehicle), the latest coordinates will replace the coordinates at the moment of the collision to ensure that the location information in the alarm message reflects the device's current actual location. If the GPS has not yet provided a location, the last known valid location of the device will be used for reporting.
[0044] If any retry is successful, a success confirmation voice message will be played (e.g., "Rest assured, the alarm has been issued and rescue is on its way"), and a continuous alarm sound will be activated (the speaker will sound continuously without automatically stopping until driving resumes or the equipment is powered off). At this time, the user cannot manually cancel the alarm via a physical button or remote command, but the automatic cancellation mechanism will still be effective upon resumption of driving.
[0045] If all retries fail, a failure message will be played (e.g., "Alarm failed, please don't panic, please call 110 and 120"). A continuous alarm sound will also be activated, triggering the multi-level recovery link of the communication module and entering cyclic recovery mode. In cyclic recovery mode, the user can cancel cyclic recovery and exit the state machine by short-pressing a physical button; the automatic cancellation mechanism for resuming driving is also effective, automatically canceling when the vehicle is determined to have resumed driving.
[0046] The vehicle's resumption of driving is determined using a dual-mode detection: In the primary mode, if the vehicle's speed continuously exceeds a preset speed threshold (e.g., 5 km / h, the specific threshold can be selected by those skilled in the art based on the actual application scenario) for a preset duration (e.g., 3 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario), the vehicle is determined to have resumed driving and automatically exits the state machine; In the backup mode, if the GPS signal is invalid or the speed is below the threshold, the vehicle's longitudinal acceleration is detected by the inertial measurement unit to exceed a preset acceleration threshold (e.g., 0.3g, the specific threshold can be selected by those skilled in the art based on the actual application scenario) for a preset duration, the vehicle is determined to have resumed driving and automatically exits the state machine.
[0047] Example 2 This embodiment, based on Embodiment 1, further describes the specific implementation of the multi-level communication recovery link.
[0048] During equipment operation, the independent communication watchdog task periodically (e.g., every 10 seconds, the specific interval can be selected by those skilled in the art based on the actual application scenario) checks the health status of the communication module, including AT command response, network registration status, and message queue telemetry transmission connection status. When a communication anomaly is detected that continues to exceed a preset threshold (e.g., 3 consecutive detection failures, the specific number can be selected by those skilled in the art based on the actual application scenario), or when all retries in the fourth stage of the help request fail, a multi-level recovery link is initiated: Level 1 Recovery – CFUN Full Reset: A full reset of the communication module is performed using the AT command AT+CFUN=1,1, including the reinitialization of the radio frequency, protocol stack, and user identity module. After waiting for a preset time (e.g., 30 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario), the communication module is checked to see if it has recovered. If it has recovered, the message queue telemetry transmission connection is re-established, the latest GPS coordinates are re-reported, and a success message is broadcast; if it has not recovered, proceed to the next level.
[0049] The second-level recovery—PWRKEY cold restart: By controlling the PWRKEY pin of the communication module, a forced shutdown pulse (e.g., pulled low for 3 seconds, not less than the shutdown pulse width required by the module specifications) is output, followed by a power-on pulse (e.g., pulled low for 500ms), achieving a complete cold restart of the communication module, including the entire process of user identity module reinitialization, network registration, and message queue telemetry transmission reconnection. After waiting for a preset time (e.g., 60 seconds, the specific duration can be selected by those skilled in the art according to the actual application scenario), the module is checked to see if it has recovered. If it has recovered, the latest GPS coordinates are re-reported, and a success voice message is broadcast; if it has not recovered, proceed to the next level.
[0050] The third-level recovery—MOSFET power-off restart: By controlling the switching element (such as a P-channel metal-oxide-semiconductor field-effect transistor, the specific model can be selected by those skilled in the art based on the supply current and voltage requirements) on the power supply circuit of the communication module, a complete power-off (e.g., disconnecting the power supply for 5 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario) is performed, followed by power restoration. The control terminal of the switching element is connected to ground with a pull-down resistor to ensure that the switching element remains in the conducting state when the main control module malfunctions, and the communication module continues to be powered. After waiting for a preset time (e.g., 30 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario), the module is checked to see if it has recovered. If it has recovered, the latest GPS coordinates are re-reported, and a success voice message is broadcast.
[0051] If all three levels of recovery fail, the loop restarts from level one, performing level one, level two, and level three recovery sequentially, repeating this cycle for approximately 125 seconds per round. During the recovery loop, the following cancellation condition is continuously monitored: - If the user briefly presses the physical button, the loop resumes, exits the state machine, and announces "Cancelled".
[0052] - If the vehicle resumes driving (GPS speed continuously exceeds 5km / h for 3 seconds, or inertial measurement unit longitudinal acceleration exceeds 0.3g for a preset time), the cycle recovery is automatically canceled and the state machine is exited.
[0053] At the start of each cycle, the current fault state is recorded to non-volatile memory, overwriting the old record and retaining the latest state to prevent loss of state information after the device is unexpectedly powered off and restarted.
[0054] Example 3 Based on Example 1, this embodiment further describes the specific implementation of the automatic cancellation mechanism for resuming driving and the joint judgment of the electric lock status.
[0055] The automatic cancellation mechanism for resuming driving is effective throughout phases 2 and 3 of the state machine. In phase 4, only driving resumption is effective upon successful reporting; driving resumption is also effective if phase 4 reporting fails and the system enters a cyclical recovery mode. Dual-mode detection is employed. Main Mode – GPS Speed Detection: When the GPS speed continuously exceeds a preset speed threshold (e.g., 5 km / h, the specific threshold can be selected by those skilled in the art based on the actual application scenario) for a preset time (e.g., 3 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario), it is determined that the vehicle has resumed driving and automatically exits the state machine. GPS speed detection is suitable for open outdoor scenarios, with a direct and accurate response.
[0056] Backup Mode – Inertial Measurement Unit Acceleration Detection: When the GPS signal is invalid (e.g., positioning status is marked "V") or the speed is below a threshold, the longitudinal acceleration of the vehicle body is detected by the inertial measurement unit. If the longitudinal acceleration of the vehicle body exceeds a preset acceleration threshold (e.g., 0.3g, the specific threshold can be selected by those skilled in the art based on the actual application scenario) and continues for a preset time, it is determined that the vehicle has resumed driving and automatically exits the state machine. Inertial measurement unit acceleration detection is suitable for scenarios where GPS signal is blocked (e.g., tunnels, under viaducts, urban canyons), does not share a signal source with the GPS, and has independent reliability.
[0057] Joint Judgment of Electrified Lock Status: During the collision detection phase, the EV lock status is used as an input condition for the parking collision detection path (Path B) to distinguish between "being hit right after the engine is turned off (the person may be in the car)" and "being knocked down after the engine has been off for a long time (the person has left)". Furthermore, during collision detection, if the vehicle's EV lock is in the closed state and the closing time exceeds a preset threshold (e.g., 60 seconds, the specific duration can be selected by those skilled in the art based on the actual application scenario), it is determined to be in a parked state and the person has left, without triggering the multi-stage emergency call state machine, and transitioning to a low-level abnormal notification. If the device is still powered on (battery not disconnected), a local prompt tone (e.g., three beeps) is played and a mobile terminal notification is pushed; if the device has been powered off and entered sleep mode, only a mobile terminal notification is pushed, without local playback.
[0058] Example 4 This embodiment provides a vehicle collision assistance and communication recovery system based on a multi-stage state machine, including: The sensor module is used to monitor the vehicle's motion status data in real time. The sensor module includes an accelerometer and a gyroscope (the specific model can be selected by those skilled in the art based on accuracy requirements and cost budget), and is connected to the main control module via an I2C bus to output three-axis acceleration and three-axis angular velocity data in real time.
[0059] The main control module, connected to the sensor module, is configured to perform the method described in any one of Embodiments 1 to 3. The main control module integrates a microcontroller and non-volatile memory (the specific model and specifications can be selected by those skilled in the art based on processing performance and storage requirements). The microcontroller is connected to each functional module through general-purpose input / output pins, and the non-volatile memory is used to store configuration parameters, the last known valid location, and fault logs.
[0060] The communication module, connected to the main control module, is used for data communication with the cloud server. The communication module is a cellular IoT communication module (the specific model can be selected by those skilled in the art based on network coverage requirements and cost budget). It connects to the main control module via a serial communication interface. The main control module controls the communication module to establish message queue telemetry transmission connections, publish messages, and subscribe to topics using AT commands.
[0061] The audio output module, connected to the main control module, is used to output alarm signals and voice prompts. The audio output module includes a digital audio amplifier and a speaker (the specific model and specifications can be selected by those skilled in the art based on output power and sound quality requirements), and connects to the main control module via an I2S bus, supporting voice synthesis and alarm tone output.
[0062] The electric lock detection module, connected to the main control module, is used to detect the status of the vehicle's electric lock. The electric lock detection module acquires the electric lock voltage signal through a voltage detection circuit (the specific circuit topology and component parameters can be selected by those skilled in the art based on the vehicle's electric lock voltage range), and outputs a digital level signal to the general-purpose input / output pins of the main control module, which then determines the open / closed state of the electric lock.
[0063] The cloud platform receives distress requests reported by devices, pushes emergency notifications (such as application pop-ups and SMS notifications) to associated user terminals, and provides remote cancellation and alarm confirmation functions. The cloud platform deduplicates duplicate distress requests with the same device identifier to avoid multiple push notifications caused by multiple reports within a short period.
[0064] Example 5 This embodiment, based on Embodiment 1, further describes the specific implementation of the manual triggering and physical button interaction logic.
[0065] The device is equipped with physical buttons (such as waterproof microswitches, the specific model of which can be selected by those skilled in the art according to the protection level requirements), which are connected to the general-purpose input / output pins of the main control module and support two operating modes: Short press mode (press time less than a preset value, such as 500ms; the specific duration can be selected by those skilled in the art based on the actual application scenario): During state machine operation (phase 2 or phase 3), a short press of the button cancels the current state machine, plays a cancellation confirmation voice message, and restores normal device operation. In loop recovery mode, a short press of the button cancels loop recovery and exits the state machine. When the state machine is not running, a short press of the button does not perform any operation or performs other preset functions (such as device status query).
[0066] Long press mode (continuous press time exceeding a preset duration, such as 3 seconds; the specific duration can be selected by those skilled in the art based on the actual application scenario): In normal device operation (non-state machine operation), a long press of the button directly enters the fourth stage of automatic reporting, skipping the first to third stages. If the GPS has not yet located the device, the reported information will be marked with the status "GPS not located". After obtaining a valid location, the location update will be resent through the communication module.
[0067] If the state machine is running, the behavior of long-pressing the button is handled according to the current stage: Stage 1 (forced alarm stage) does not respond to any button operation; in Stage 2 and Stage 3, long press is regarded as cancellation operation (treated as short press); in Stage 4, if the report is successful, no button operation is responded to, and if the report fails and enters the loop recovery mode, a short press of the button cancels the loop recovery.
Claims
1. A vehicle collision distress call and communication recovery method based on a multi-stage state machine, characterized in that, Includes the following steps: Step 1: Monitor the vehicle's motion status data in real time and detect collision events through at least one independent detection path, wherein the at least one independent detection path covers collision scenarios during riding and / or collision scenarios while parked. Step 2: When a collision event is detected, initiate the multi-stage help request state machine; Step 3: The multi-stage help state machine includes at least one cancelable stage. During the cancelable stage, the user can exit the state machine through a preset cancellation method. Step 4: During the automatic reporting phase, the request for help is reported to the cloud server via the communication module; If reporting fails, initiate a multi-level communication recovery link to attempt to restore communication and re-report; Step 5: During the operation of the state machine, the vehicle's driving status is monitored in real time. When it is determined that the vehicle has resumed driving, the state machine is automatically exited.
2. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, The at least one independent detection path includes at least one of the following: (a) Collision detection path during riding: When the acceleration detected by the accelerometer exceeds the preset acceleration threshold, the angular velocity of the vehicle detected by the gyroscope exceeds the preset angular velocity threshold, and the speed of the global positioning system exceeds the preset speed threshold, the collision event during riding is triggered when all three conditions are met simultaneously. (b) Parking collision detection path: When the vehicle body tilt angle detected by the gyroscope exceeds the preset tilt angle threshold and the duration exceeds the preset time threshold, and the vehicle electric lock closing time is less than the preset time threshold, the parking collision event is triggered.
3. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, The multi-stage help-seeking state machine includes the following stages: Phase 1: Forced alarm phase, outputs a high-intensity alarm signal for a first preset duration, which cannot be canceled by the user during this phase; The second stage is the voice inquiry stage, during which the user reads the inquiry voice and waits for the second preset time. During this stage, the user can cancel the process by pressing a physical button briefly, using a remote command, or resuming driving. The third stage: countdown warning stage, the countdown voice is broadcast and continues for the third preset duration. At the same time as each countdown number is broadcast, a status report is sent to the cloud server through the communication module, so that the cloud platform and associated user terminals can obtain the countdown progress in real time. During this stage, users can cancel the countdown by pressing the physical button briefly, using remote commands, or resuming driving. Phase 4: Automatic reporting phase, performing a limited number of retries to report; if the report is successful, the user cannot manually cancel it via physical button or remote command, but the automatic cancellation mechanism remains effective upon resumption of driving; If the report fails, the system enters a loop recovery mode. In this mode, the user can cancel the loop recovery by briefly pressing the physical button or resuming driving and exit the state machine.
4. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, During the automatic reporting phase, the latest positioning data from the Global Positioning System is continuously acquired. If the device's location changes after a collision, the latest coordinates are used to replace the coordinates at the moment of the collision before reporting.
5. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, The determination of resuming driving uses a dual-mode detection method: (a) Main mode: If the speed of the vehicle exceeds the preset speed threshold continuously for a preset time through the global positioning system, it is determined that the vehicle has resumed driving; (b) Backup mode: When the GPS signal is invalid or the GPS speed is lower than the preset speed threshold, the vehicle longitudinal acceleration is detected by the inertial measurement unit to exceed the preset acceleration threshold for a preset time, and it is determined that the vehicle has resumed driving.
6. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, During equipment operation, a dedicated watchdog task periodically checks the health status of the communication module. When a communication anomaly is detected and continues to exceed a preset threshold, or when all retries in the fourth stage of the emergency call fail, a multi-level communication recovery link is initiated. This multi-level communication recovery link includes: Level 1 recovery: Perform a complete reset of the communication module via AT commands, including reinitialization of the radio frequency, protocol stack, and user identity module; If the first-level recovery fails, the second-level recovery is executed: by controlling the power-on and power-off pins of the communication module, a power-off pulse is output and then a power-on pulse is output to achieve a complete cold restart of the communication module; If the second-level recovery fails, the third-level recovery will be executed: by controlling the switching elements on the power supply circuit of the communication module, a complete power-off and then power-on will be performed. If all three levels of recovery fail, the system returns to the first level and restarts the loop, performing the first, second, and third levels of recovery in sequence, repeating this process until recovery is successful, the user cancels, or the device loses power. During the loop recovery process, the system continuously monitors for user cancellation operations. If the user issues a cancellation command by pressing a physical button briefly or resuming driving, the system exits the loop recovery mode and exits the state machine.
7. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, It also includes a joint judgment step for the electric lock status: during the collision detection process, the vehicle electric lock status is obtained. If the electric lock is in the closed state and the closing time exceeds a preset threshold, it is determined to be in a parked state and the person has left. The multi-stage help state machine is not triggered, and it is converted to a low-level abnormal notification. If the device is still powered on, a local broadcast prompt is made and a mobile terminal notification is pushed. If the device has been powered off and entered a sleep state, only a mobile terminal notification is pushed.
8. The vehicle collision assistance and communication recovery method based on a multi-stage state machine according to claim 1, characterized in that, It also includes a manual triggering step: when the device is in normal operation, if the physical button is continuously pressed for more than a preset time, it directly enters the fourth stage as described in claim 3, skipping the first to third stages; if the global positioning system has not yet located the device, the reported information will indicate the unlocated status, and the location update will be sent through the communication module after a valid location is obtained.
9. A vehicle collision assistance and communication recovery system based on a multi-stage state machine, characterized in that, include: The sensor module is used to monitor the vehicle's motion status data in real time. The sensor module includes an accelerometer and a gyroscope. The main control module is connected to the sensor module and configured to perform the method as described in any one of claims 1 to 8; A communication module, connected to the main control module, is used for data communication with the cloud server; An audio output module, connected to the main control module, is used to output alarm signals and voice prompts; An electric lock detection module, connected to the main control module, is used to detect the status of the vehicle's electric lock; The cloud platform is used to receive help requests reported by devices, push notifications to associated user terminals, and provide remote cancellation functionality. The cloud platform also performs deduplication processing on duplicate help requests with the same device identifier.
