Equipment access control method and device, electronic equipment and storage medium
By setting up multiple communication buses in the home host and dynamically adjusting the transmission rate and power consumption mode based on device information, the problem of traditional home hosts being unable to be compatible with different protocols is solved, achieving low-power, high-efficiency device access and network management.
Patent Information
- Application Number
- CN202510965333.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-14
- Publication Date
- 2025-10-31
AI Technical Summary
Traditional home consoles only support a single protocol, making it difficult to accommodate devices with different protocols, leading to increased energy consumption and network congestion.
Three communication buses with different data transmission rates are set up in the home host. The location and type information are determined by responding to device broadcast information, the required transmission rate is matched and connected to the target bus, and the bandwidth parameters and power consumption mode are adjusted in real time to avoid periodic scanning.
It enables low-energy, fast and reliable device access, is compatible with different protocols, reduces network congestion, and improves device access efficiency.
Smart Images

Figure CN120880828A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of Internet of Things (IoT) technology, and in particular to a device access control method, a device access control device, an electronic device, and a computer-readable storage medium. Background Technology
[0002] Traditional home consoles only support a single protocol, making it difficult to connect devices using different protocols. Adding external multi-protocol converters to traditional home consoles increases power consumption. Furthermore, device discovery can cause network congestion. Therefore, current device connectivity solutions suffer from protocol incompatibility, high power consumption, and low efficiency. Summary of the Invention
[0003] In view of the above problems, embodiments of this application are proposed to provide a device access control method, a device access control apparatus, an electronic device, and a computer-readable storage medium that overcome or at least partially solve the above problems.
[0004] To address the aforementioned problems, in a first aspect of this invention, an embodiment of this application discloses a device access control method applied to a home host, wherein the home host is equipped with three communication buses with different data transmission rates, and the method includes:
[0005] In response to a broadcast message sent by the device to be connected, the device location information and device type information are determined based on the broadcast message;
[0006] Based on the device location information and the device type information, the required transmission rate is determined;
[0007] Match the required transmission rate with the data transmission rate to determine the target communication bus from the communication bus;
[0008] Connect the device to be connected to the target communication bus;
[0009] Determine the load status of the target communication bus;
[0010] Adjust the bandwidth parameters of the target communication bus based on the load status.
[0011] Optionally, the method further includes:
[0012] When the load condition is greater than a preset load threshold, the device priority in the target communication bus is determined;
[0013] The devices accessing the target communication bus are sorted in ascending order based on the device priority.
[0014] The devices that were connected to the target communication bus in the first few positions are migrated to other communication buses.
[0015] Optionally, the step of determining the device location information and device type information based on the broadcast information includes:
[0016] Read the device characteristic values from the broadcast information to determine the device type information;
[0017] Based on the broadcast information, ultra-wideband ranging is performed to determine the device's location information.
[0018] Optionally, the communication bus has different power domains, and the method further includes:
[0019] Detect the clock signal of the communication bus;
[0020] The energy consumption mode is determined based on the clock signal;
[0021] The operating state of the power domain is adjusted based on the energy consumption mode.
[0022] Optionally, the step of determining the energy consumption mode based on the clock signal includes:
[0023] If the clock signal times out and reaches a first preset threshold, the power consumption mode is determined to be a light sleep mode.
[0024] If the clock signal times out and reaches the second preset threshold, the power consumption mode is determined to be deep sleep mode;
[0025] Wherein, the first preset threshold is less than the second preset threshold.
[0026] Optionally, the communication bus includes a low-speed bus, a medium-speed bus, and a high-speed bus with sequentially increasing data transmission rates; the step of adjusting the operating state of the power domain based on the energy consumption mode includes:
[0027] In the shallow sleep mode, the power domain of the low-speed bus is turned off;
[0028] In the deep sleep mode, the power domains of the medium-speed bus and the high-speed bus are turned off.
[0029] Optionally, the method further includes:
[0030] Detect the device activity level of the communication bus;
[0031] The clock signal transmission period is adjusted based on the device activity level.
[0032] In a second aspect, embodiments of this application disclose a device access control apparatus applied to a home host computer, wherein the home host computer is equipped with three communication buses with different data transmission rates, and the apparatus includes:
[0033] The response module is used to respond to broadcast information sent by the device to be accessed, and to determine the device location information and device type information based on the broadcast information;
[0034] The calculation module is used to determine the required transmission rate based on the device location information and the device type information;
[0035] The matching module is used to match the required transmission rate with the data transmission rate and determine the target communication bus from the communication bus;
[0036] An access module is used to connect the device to be accessed to the target communication bus;
[0037] A load module is used to determine the load status of the target communication bus;
[0038] An adjustment module is used to adjust the bandwidth parameters of the target communication bus based on the load status.
[0039] In a third aspect of this application, embodiments of this application disclose an electronic device, including a processor, a memory, and a computer program stored in the memory and capable of running on the processor, wherein the computer program, when executed by the processor, implements the steps of the device access control method as described above.
[0040] In a fourth aspect, embodiments of this application disclose a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the device access control method described above.
[0041] The embodiments of this application have the following advantages:
[0042] This embodiment of the application sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. In response to broadcast information sent by the device to be connected, the device's location and type information are determined based on the broadcast information. Based on the device's location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine the target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. The device's location and type information are used to discover and determine the status of the device to be connected, and then connect it to the corresponding target communication bus. This eliminates the need for periodic continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, the bandwidth is adjusted in real time according to the load status of the target communication bus to ensure operational reliability. Attached Figure Description
[0043] Figure 1 This is a flowchart illustrating the steps of an embodiment of a device access control method according to this application;
[0044] Figure 2 This is a flowchart illustrating the steps of another embodiment of the device access control method of this application;
[0045] Figure 3 This is a schematic diagram of a home host system according to this application;
[0046] Figure 4 This is a schematic diagram of a device access method according to this application;
[0047] Figure 5 This is a structural block diagram of an embodiment of a device access control device according to this application;
[0048] Figure 6 This is a structural block diagram of an electronic device provided in an embodiment of this application;
[0049] Figure 7 This is a structural block diagram of a storage medium provided in an embodiment of this application. Detailed Implementation
[0050] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0051] Reference Figure 1The diagram illustrates a flowchart of an embodiment of a device access control method according to this application. The method is applied to a home host system, which has three communication buses with different data transmission rates. These three communication buses employ different communication protocols, have different data transmission rates, and transmit different types of data.
[0052] The device access control method may specifically include the following steps:
[0053] Step 101: In response to the broadcast information sent by the device to be accessed, determine the device location information and device type information based on the broadcast information;
[0054] When a device enters the local area network (LAN) of the home host, it will broadcast a message containing its own parameters. The device's location and type information are determined based on the content of the broadcast message.
[0055] Step 102: Determine the required transmission rate based on the device location information and the device type information;
[0056] Based on the determined device location and device type information, the data type of the device to be connected and the required transmission rate can be read, thus determining the required transmission rate.
[0057] Step 103: Match the required transmission rate with the data transmission rate, and determine the target communication bus from the communication buses;
[0058] The required transmission rate of the device to be connected is matched one by one with the data transmission rate of each of the multiple communication buses, and the communication bus corresponding to the matched data transmission rate is determined as the target communication bus.
[0059] Step 104: Connect the device to be accessed to the target communication bus;
[0060] The device to be connected is connected to the target communication bus, which is then responsible for communication between the home host and the device to be connected.
[0061] Step 105: Determine the load status of the target communication bus;
[0062] After the device to be connected is connected to the target communication bus, the load status of the target communication bus can be monitored in real time.
[0063] Step 106: Adjust the bandwidth parameters of the target communication bus based on the load status.
[0064] Then, by measuring the load status, determine whether the bandwidth parameters of the target communication bus meet the requirements; adjust the bandwidth parameters of the target communication bus based on the load status.
[0065] This embodiment of the application sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. In response to broadcast information sent by the device to be connected, the device's location and type information are determined based on the broadcast information. Based on the device's location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine the target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. The device's location and type information are used to discover and determine the status of the device to be connected, and then connect it to the corresponding target communication bus. This eliminates the need for periodic continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, the bandwidth is adjusted in real time according to the load status of the target communication bus to ensure operational reliability.
[0066] Reference Figure 2 This diagram illustrates a flowchart of another embodiment of the device access control method of this application. The device access control method is applied to a home host, which has three communication buses with different data transmission rates and different power domains. The architecture of the home host can be referenced... Figure 3A home host computer can utilize a three-tiered bus architecture, categorizing buses into high, medium, and low speeds based on data transfer rates: The first type is the high-speed bus (HSB), boasting extremely high data transfer rates and supporting high-speed serial bus protocols such as Wi-Fi 6, Ethernet, PCI-Express 5.0, and CXL. It's suitable for high-bandwidth applications (such as video streaming) and servers requiring large amounts of data exchange. The second type is the medium-speed bus (MSB), with moderate data transfer rates, meeting the communication needs of most common devices. It supports protocols like SATA, connects storage devices such as hard drives, integrates Zigbee 3.0 and Thread protocols, supports multi-hop mesh networking, and supports sensor networks. The third type is the low-speed bus (LSB), with relatively low transfer rates and simple protocols and interfaces. It supports protocols such as USB 2.0, RS485, and BLE 5.2, supports long-distance modes and low-power broadcasting, and integrates the IEEE 802.15.4k sensor protocol, meeting the communication needs between low-speed devices and the host. Furthermore, each communication bus employs independent power and clock domains; for example, the HSB uses a 100MHz clock, and the LSB uses a 16MHz clock, achieving hardware-level isolation to avoid interference between protocols. In home hosts, integrated chips such as the Lattice iCE40 FPGA can be used to offload the protocol stack, supporting parallel processing of Zigbee / BLE / Wi-Fi (IoT type) protocols. A hardware state machine is also integrated to automatically select the optimal communication bus based on device type (e.g., sensor / camera). Additionally, a lightweight protocol stack (e.g., the Zigbee protocol stack occupies only 32KB ROM) is pre-installed in the RISC-V coprocessor, enabling zero-copy data transfer and dynamic loading of the protocol stack via DMA (data transfer bus). Different communication buses have different characteristics. In the HSB, due to the high power consumption of connected devices and their high sensitivity to power supply stability, a stable, low-noise power supply is required to ensure stable power supply under high loads and reduce power supply noise interference with high-speed signal transmission. In addition, a high-precision and stable clock source is provided to ensure a stable high-frequency clock signal for the high-speed bus, guaranteeing that the clock phase and frequency of all devices on the bus are consistent, meeting the stringent timing requirements of high-speed data transmission. In the MSB, a dynamic voltage-frequency regulation (DVFS) power supply scheme is adopted, dynamically adjusting the power supply and frequency according to the load of the devices on the bus. When the device load is high, a higher voltage and frequency are provided to ensure performance; when the load is low, the voltage and frequency are reduced to save power consumption. The clock frequency is dynamically adjusted within a certain range according to device requirements, achieved through circuits such as clock dividers and phase-locked loops (PLLs). By dynamically adjusting the clock frequency, in conjunction with DVFS technology, a balance between performance and power consumption is achieved. In the LSB, power gating technology is used, which manages the power supply of low-speed devices by controlling the power switch.When low-speed devices are idle, their power is cut off to significantly reduce static power consumption; when the devices need to work, the power switch is quickly turned on to restore power. A simple low-frequency clock source is used to provide a basic clock signal. When a device wakes up, its clock is briefly synchronized with the system clock through a clock synchronization circuit to ensure the accuracy of data transmission. Therefore, the protocol stack is offloaded using a Lattice iCE40 FPGA to support millisecond-level bus switching (latency < 5ms). Furthermore, HSB / MSB / LSB are physically isolated using a magnetic isolation chip (such as ADI ADuM5402) to prevent noise coupling. In addition, for the power management unit, the supply voltage is adjusted according to the bus load (HSB: 1.8V→1.2V) using dynamic voltage regulation (DVFS); inactive bus power supplies are turned off (e.g., power is cut off when LSB is idle).
[0067] The device access control method may specifically include the following steps:
[0068] Step 201: In response to the broadcast information sent by the device to be accessed, determine the device location information and device type information based on the broadcast information;
[0069] When a device to be connected is within the coverage area of the home host, it will periodically send broadcast messages. For example, the device to be connected can periodically send broadcast messages via BLE (Bluetooth Low Energy). The basic structure of the broadcast message includes: a 2-byte header containing the broadcast type (e.g., connectable broadcast, non-connectable broadcast) and address type (public address or random address); a 6-byte device address supporting public addresses (IEEE assigned) or random addresses (static or private); broadcast data (AD Structures) consisting of multiple Length-Type-Value (LTV) units carrying the actual data; and a 3-byte CRC (Cyclic Redundancy Check) checksum used to verify data integrity. Common field types for broadcast data (AD Structures) include: Device Name (Type 0x08 / 0x09): Displayed in the scanned device list for easy user identification; Service UUID (Type 0x02 / 0x03): Identifies the services or characteristics provided by the device, ensuring communication uniqueness; and Manufacturer Data (Type 0xFF): Contains the manufacturer ID and custom data. Sensor data: For example, a thermometer directly broadcasts its measured values, allowing data acquisition without a connection. Broadcast message types include: Connectable Non-directional Broadcast (ADV_IND): Allows any device to scan and connect, suitable for general scenarios. Directional Broadcast (ADV_DIRECT_IND): Enables quick connection for specific devices, such as rapid reconnection after a Bluetooth keyboard or mouse disconnects. Scannable Broadcast (ADV_SCAN_IND): Supports scan requests and can send additional data (such as the full device name). Broadcast parameter configuration: Broadcast interval: Range 20ms to 10.24s, step size 0.625ms. The minimum interval for non-connectable broadcast types is 100ms. Channel selection: Traditional broadcasts use three main channels: 37, 38, and 39. Extended broadcasts (BLE 5.0+) can use 37 data channels. Data length extension: Broadcast data can be extended to 254 bytes, supporting more complex application scenarios.
[0070] It can respond to broadcast messages sent by devices to be connected, and read the message content in the broadcast message to determine the device location information and device type information.
[0071] In an optional embodiment of this application, the step of determining device location information and device type information based on the broadcast information includes:
[0072] Sub-step S2011: Read the device characteristic value in the broadcast information to determine the device type information;
[0073] The device type information can be determined by reading the value corresponding to the device type flag in the broadcast message, i.e., the device characteristic value. Based on the device type corresponding to the device characteristic value, the device type information of the device to be accessed can be determined.
[0074] Sub-step S2012: Perform ultra-wideband ranging based on the broadcast information to determine the device location information.
[0075] Based on the time information of broadcast messages, home hubs can perform ultra-wideband (UWB) ranging to determine device location. UWB ranging is a high-precision wireless ranging technology based on nanosecond-level narrow pulse signals and the Time-of-Flight (TOF) method. It calculates distance by measuring the round-trip time difference of the signal between devices. UWB ranging transmits data by sending and receiving nanosecond-level (typically less than 1 nanosecond) non-sinusoidal narrow pulses. These pulses are very sharp in the time domain and exhibit an ultra-wide spectrum in the frequency domain. This signal form enables UWB to achieve positioning accuracy that is difficult to achieve with traditional wireless technologies. UWB ranging is mainly based on the Time-of-Flight (TOF) method, and specific implementations include: One-way ranging (SS-TWR): the device to be connected sends a pulse signal and records the timestamp. The home hub receives the signal and replies, calculating the distance by the round-trip time difference. However, this method requires strict clock synchronization between devices; otherwise, the error will be significant. Two-way ranging (DS-TWR): The device to be connected and the home host send pulse signals to each other and record timestamps. The average value is calculated by the round-trip time of the two devices, which reduces the impact of clock offset and improves ranging accuracy.
[0076] For example, the built-in UWB (Ultra-Wideband) anchor point of the home host can be used to calculate the time difference of arrival (TDoA) of the device to be connected based on the broadcast information, with a positioning accuracy of ±3cm. Then, the RSSI (Received Signal Strength Indication) model is fused and the positioning error of TDoA is corrected by combining the signal strength (RSSI) of the broadcast information. The corrected distance = TDoA distance × (1 + α·ΔRSSI), where α is the environmental attenuation coefficient.
[0077] Step 202: Determine the required transmission rate based on the device location information and the device type information;
[0078] The data transmission requirements of the devices to be connected are determined based on the device location information and device type information, and the required transmission rate is determined based on the transmission requirements.
[0079] Step 203: Match the required transmission rate with the data transmission rate, and determine the target communication bus from the communication buses;
[0080] The required transmission rate is compared with the data transmission rate of the communication bus one by one to determine the matching data transmission rate, and the communication bus is then identified as the target communication bus.
[0081] Step 204: Connect the device to be accessed to the target communication bus;
[0082] The device to be connected is connected to the target communication bus, and the target communication bus performs data transmission.
[0083] To enable those skilled in the art to clearly understand the device access process of the embodiments of this application, please refer to... Figure 4 To illustrate with an example:
[0084] When a device seeks to connect, it broadcasts BLE status information. The home host uses UWB ranging to locate the device; if location fails, it attempts to locate it again based on the broadcast status information. Then, a directional BLE scan is performed to determine the device's location and type information based on the broadcast information, thereby identifying the target communication bus. The device is then connected to the communication bus to complete network access verification, thus enabling device access.
[0085] Step 205: Determine the load status of the target communication bus;
[0086] The load status of the target communication bus can also be determined by detecting its input and output. For example, a load-aware algorithm can be used to calculate the utilization rate of each communication bus in real time as its load status. The formula for calculating the utilization rate is: Utilization Rate = Number of Data Packets / Bus Bandwidth. This allows the load status of the target communication bus to be determined.
[0087] Step 206: Adjust the bandwidth parameters of the target communication bus based on the load status;
[0088] Adjust the bandwidth parameters of the target communication bus according to the load status.
[0089] Step 207: When the load condition is greater than a preset load threshold, determine the device priority in the target communication bus;
[0090] When the load exceeds a preset load threshold, it indicates that the devices on the target communication bus are heavily loaded. To avoid network congestion, the devices can be migrated to free up some resources. The device priority of the devices connected to the target communication bus can be identified.
[0091] Step 208: Sort the devices accessing the target communication bus in ascending order based on the device priority;
[0092] Devices on the target communication bus are sorted in ascending order based on their device priority; that is, devices are sorted from lowest to highest priority. Devices listed earlier in the sequence have lower priority.
[0093] Step 209: Migrate the first few devices connected to the target communication bus to other communication buses;
[0094] According to requirements, the first few devices connected to the target communication bus can be migrated to the other two communication buses, thereby freeing up the resources of the target communication bus, ensuring the operation of priority devices, and ensuring the reliability of operation.
[0095] Step 210: Detect the clock signal of the communication bus;
[0096] It can also provide a clock signal for each communication bus, which can be an RTC signal. The RTC provides a stable clock signal through a built-in crystal oscillator (such as a 32.768kHz crystal oscillator), ensuring the accuracy of time calculations.
[0097] Step 211: Determine the power consumption mode based on the clock signal;
[0098] The power consumption mode for each communication bus is determined based on the interval of the clock signal.
[0099] In an optional embodiment of this application, the step of determining the power consumption mode based on the clock signal includes: determining the power consumption mode as a light sleep mode when the clock signal times out to a first preset threshold; and determining the power consumption mode as a deep sleep mode when the clock signal times out to a second preset threshold; wherein the first preset threshold is less than the second preset threshold.
[0100] When the clock signal times out to a first preset threshold, it indicates that the device has entered a sleep state, and the corresponding communication bus can also enter a moderate sleep state to reduce power consumption. This can be identified as a shallow sleep mode. Conversely, when the clock signal times out to a second preset threshold, it indicates that the device has entered a complete sleep state, and the corresponding communication bus can also enter a deep sleep state to further reduce power consumption. This can be identified as a deep sleep mode.
[0101] Step 212: Adjust the operating state of the power domain based on the energy consumption mode;
[0102] Adjust the operating state of the power domain of the communication bus according to different power consumption modes.
[0103] In an optional embodiment of this application, the step of adjusting the operating state of the power domain based on the energy consumption mode includes: in the shallow sleep mode, turning off the power domain of the low-speed bus; and in the deep sleep mode, turning off the power domain of the medium-speed bus and the power domain of the high-speed bus.
[0104] In shallow sleep mode, the power domain of the low-speed bus is shut down, while the medium-speed and high-speed buses remain operational, ensuring that real-time data processing can continue. In deep sleep mode, the power domains of the medium-speed and high-speed buses are shut down, with only the low-speed bus retained for user wake-up responses. By hibernating the power domains of different communication buses, power consumption is reduced.
[0105] For example, as shown in the table below, timeout triggering based on different PTC clock signals can be divided into deep sleep mode and shallow sleep mode. Deep sleep mode disables the HSB / MSB bus power, retaining only the RTC clock (accuracy ±1 second) and a low-power MCU (such as the STM32L4 series), and can only be woken up by an external interrupt (such as triggering by a human infrared sensor). Shallow sleep mode disables the LSB bus, maintains the BLE 5.2 listening window (10ms / cycle), supports fast scanning of broadcast packets, and can use GaN power transistors to achieve millisecond-level power switching (wake-up time <2ms). When the device sends a device request, it enters active mode to process the request.
[0106] Timeline (s) 0-60 60-63 63-120 model Deep sleep Light sleep Active mode Power consumption (mW) 0.6 3 15 Triggering conditions RTC timeout RTC timeout Device Request
[0107] Table 1
[0108] Step 213: Detect the device activity level of the communication bus;
[0109] It can also detect the device activity level of devices on each communication bus.
[0110] Step 214: Adjust the transmission period of the clock signal based on the device activity level.
[0111] The clock signal transmission period is dynamically adjusted based on device activity. The transmission period can be characterized by the clock wake-up interval, which is calculated as: Wake-up Interval = Base Period × (1 + Device Idle Rate). This enables adaptive wake-up period adjustment. The device idle rate is the remainder of the device activity rate divided by 1.
[0112] For example, if the sensor does not report any data for 3 consecutive hours, the wake-up period is extended from 1 second to 60 seconds.
[0113] This application embodiment sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. The system responds to broadcast information sent by the device to be connected, determining device location and type information based on the broadcast information. Based on the device location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine a target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. When the load status exceeds a preset load threshold, the device priority in the target communication bus is determined. The devices connected to the target communication bus are sorted in ascending order based on the device priority. The top-ranked devices connected to the target communication bus are migrated to other communication buses. The clock signal of the communication bus is detected. The power consumption mode is determined based on the clock signal. The operating state of the power domain is adjusted based on the power consumption mode. The device activity of the communication bus is detected. The transmission period of the clock signal is adjusted based on the device activity. By utilizing device location and type information, the system discovers and determines the status of devices to be connected, and then connects them to the corresponding target communication bus. This eliminates the need for periodic, continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, it adjusts bandwidth in real-time based on the target communication bus's load status to ensure operational reliability. Different bus operating modes are set according to different device usage states, allowing for appropriate bus hibernation, further reducing energy consumption.
[0114] It should be noted that, for the sake of simplicity, the method embodiments are all described as a series of actions. However, those skilled in the art should understand that the embodiments of this application are not limited to the described order of actions, because according to the embodiments of this application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also understand that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of this application.
[0115] Reference Figure 5 The diagram illustrates a structural block diagram of an embodiment of a device access control device according to this application. The device access control device is applied to a home host computer, which has three communication buses with different data transmission rates. Specifically, the device access control device may include the following modules:
[0116] The response module 501 is used to respond to the broadcast information sent by the device to be accessed, and to determine the device location information and device type information based on the broadcast information;
[0117] Calculation module 502 is used to determine the required transmission rate based on the device location information and the device type information;
[0118] Matching module 503 is used to match the required transmission rate with the data transmission rate and determine the target communication bus from the communication bus;
[0119] Access module 504 is used to connect the device to be accessed to the target communication bus;
[0120] Load module 505 is used to determine the load status of the target communication bus;
[0121] The adjustment module 506 is used to adjust the bandwidth parameters of the target communication bus based on the load status.
[0122] In an optional embodiment of this application, the apparatus further includes:
[0123] The device priority determination module is used to determine the device priority in the target communication bus when the load state is greater than a preset load threshold.
[0124] The sorting module is used to sort the devices connected to the target communication bus in ascending order based on the device priority.
[0125] The migration module is used to migrate the first few devices connected to the target communication bus to other communication buses.
[0126] In an optional embodiment of this application, the response module 501 includes:
[0127] The reading submodule is used to read device characteristic values from the broadcast information and determine device type information;
[0128] The ranging submodule is used to perform ultra-wideband ranging based on the broadcast information to determine the device location information.
[0129] In an optional embodiment of this application, the communication bus has a different power domain, and the device further includes:
[0130] A clock module is used to detect the clock signal of the communication bus;
[0131] Energy consumption determination module, used to determine energy consumption mode based on the clock signal;
[0132] An energy consumption adjustment module is used to adjust the operating state of the power domain based on the energy consumption mode.
[0133] In an optional embodiment of this application, the energy consumption determination module includes:
[0134] The shallow sleep submodule is used to determine the energy consumption mode as shallow sleep mode when the clock signal times out and reaches a first preset threshold.
[0135] The deep sleep submodule is used to determine the power consumption mode as deep sleep mode when the clock signal times out and reaches a second preset threshold.
[0136] Wherein, the first preset threshold is less than the second preset threshold.
[0137] In an optional embodiment of this application, the communication bus includes a low-speed bus, a medium-speed bus, and a high-speed bus with sequentially increasing data transmission rates; the energy consumption adjustment module includes:
[0138] The first adjustment submodule is used to shut down the power domain of the low-speed bus in the shallow sleep mode.
[0139] The second adjustment submodule is used to shut down the power domain of the medium-speed bus and the power domain of the high-speed bus in the deep sleep mode.
[0140] In an optional embodiment of this application, the apparatus further includes:
[0141] An activity detection module is used to detect the activity level of devices on the communication bus;
[0142] A clock adjustment module is used to adjust the transmission period of the clock signal based on the activity level of the device.
[0143] This embodiment of the application sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. In response to broadcast information sent by the device to be connected, the device's location and type information are determined based on the broadcast information. Based on the device's location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine the target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. The device's location and type information are used to discover and determine the status of the device to be connected, and then connect it to the corresponding target communication bus. This eliminates the need for periodic continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, the bandwidth is adjusted in real time according to the load status of the target communication bus to ensure operational reliability.
[0144] As the device embodiment is basically similar to the method embodiment, the description is relatively simple, and relevant parts can be found in the description of the method embodiment.
[0145] Reference Figure 6 This application also provides an electronic device, including:
[0146] A processor 601 and a storage medium 602 are provided. The storage medium 602 stores a computer program executable by the processor 601. When the electronic device is controlled to run, the processor 601 executes the computer program to implement the device access control method as described in any of the embodiments of this application. The device access control method is applied to a home host computer, which is equipped with three communication buses with different data transmission rates. The method includes:
[0147] In response to a broadcast message sent by the device to be connected, the device location information and device type information are determined based on the broadcast message;
[0148] Based on the device location information and the device type information, the required transmission rate is determined;
[0149] Match the required transmission rate with the data transmission rate to determine the target communication bus from the communication bus;
[0150] Connect the device to be connected to the target communication bus;
[0151] Determine the load status of the target communication bus;
[0152] Adjust the bandwidth parameters of the target communication bus based on the load status.
[0153] Optionally, the method further includes:
[0154] When the load condition is greater than a preset load threshold, the device priority in the target communication bus is determined;
[0155] The devices accessing the target communication bus are sorted in ascending order based on the device priority.
[0156] The devices that were connected to the target communication bus in the first few positions are migrated to other communication buses.
[0157] Optionally, the step of determining the device location information and device type information based on the broadcast information includes:
[0158] Read the device characteristic values from the broadcast information to determine the device type information;
[0159] Based on the broadcast information, ultra-wideband ranging is performed to determine the device's location information.
[0160] Optionally, the communication bus has different power domains, and the method further includes:
[0161] Detect the clock signal of the communication bus;
[0162] The energy consumption mode is determined based on the clock signal;
[0163] The operating state of the power domain is adjusted based on the energy consumption mode.
[0164] Optionally, the step of determining the energy consumption mode based on the clock signal includes:
[0165] If the clock signal times out and reaches a first preset threshold, the power consumption mode is determined to be a light sleep mode.
[0166] If the clock signal times out and reaches the second preset threshold, the power consumption mode is determined to be deep sleep mode;
[0167] Wherein, the first preset threshold is less than the second preset threshold.
[0168] Optionally, the communication bus includes a low-speed bus, a medium-speed bus, and a high-speed bus with sequentially increasing data transmission rates; the step of adjusting the operating state of the power domain based on the energy consumption mode includes:
[0169] In the shallow sleep mode, the power domain of the low-speed bus is turned off;
[0170] In the deep sleep mode, the power domains of the medium-speed bus and the high-speed bus are turned off.
[0171] Optionally, the method further includes:
[0172] Detect the device activity level of the communication bus;
[0173] The clock signal transmission period is adjusted based on the device activity level.
[0174] This embodiment of the application sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. In response to broadcast information sent by the device to be connected, the device's location and type information are determined based on the broadcast information. Based on the device's location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine the target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. The device's location and type information are used to discover and determine the status of the device to be connected, and then connect it to the corresponding target communication bus. This eliminates the need for periodic continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, the bandwidth is adjusted in real time according to the load status of the target communication bus to ensure operational reliability.
[0175] The memory may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0176] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0177] Reference Figure 7 This application also provides a computer-readable storage medium 701, on which a computer program is stored. When the computer program is run by a processor, it executes the device access control method as described in any one of the embodiments of this application. The device access control method is applied to a home host computer, which is equipped with three communication buses with different data transmission rates. The method includes:
[0178] In response to a broadcast message sent by the device to be connected, the device location information and device type information are determined based on the broadcast message;
[0179] Based on the device location information and the device type information, the required transmission rate is determined;
[0180] Match the required transmission rate with the data transmission rate to determine the target communication bus from the communication bus;
[0181] Connect the device to be connected to the target communication bus;
[0182] Determine the load status of the target communication bus;
[0183] Adjust the bandwidth parameters of the target communication bus based on the load status.
[0184] Optionally, the method further includes:
[0185] When the load condition is greater than a preset load threshold, the device priority in the target communication bus is determined;
[0186] The devices accessing the target communication bus are sorted in ascending order based on the device priority.
[0187] The devices that were connected to the target communication bus in the first few positions are migrated to other communication buses.
[0188] Optionally, the step of determining the device location information and device type information based on the broadcast information includes:
[0189] Read the device characteristic values from the broadcast information to determine the device type information;
[0190] Based on the broadcast information, ultra-wideband ranging is performed to determine the device location information.
[0191] Optionally, the communication bus has different power domains, and the method further includes:
[0192] Detect the clock signal of the communication bus;
[0193] The energy consumption mode is determined based on the clock signal;
[0194] The operating state of the power domain is adjusted based on the energy consumption mode.
[0195] Optionally, the step of determining the energy consumption mode based on the clock signal includes:
[0196] If the clock signal times out and reaches a first preset threshold, the energy consumption mode is determined to be a light sleep mode;
[0197] If the clock signal times out and reaches the second preset threshold, the power consumption mode is determined to be deep sleep mode;
[0198] Wherein, the first preset threshold is less than the second preset threshold.
[0199] Optionally, the communication bus includes a low-speed bus, a medium-speed bus, and a high-speed bus with sequentially increasing data transmission rates; the step of adjusting the operating state of the power domain based on the energy consumption mode includes:
[0200] In the shallow sleep mode, the power domain of the low-speed bus is turned off;
[0201] In the deep sleep mode, the power domains of the medium-speed bus and the high-speed bus are turned off.
[0202] Optionally, the method further includes:
[0203] Detect the device activity level of the communication bus;
[0204] The clock signal transmission period is adjusted based on the device activity level.
[0205] This embodiment of the application sets up three communication buses with different data transmission rates on the home host. When connecting devices, different devices can connect to different communication buses to ensure compatibility with different protocols. In response to broadcast information sent by the device to be connected, the device's location and type information are determined based on the broadcast information. Based on the device's location and type information, the required transmission rate is determined. The required transmission rate is matched with the data transmission rate to determine the target communication bus from the communication buses. The device to be connected is then connected to the target communication bus. The load status of the target communication bus is determined. The bandwidth parameters of the target communication bus are adjusted based on the load status. The device's location and type information are used to discover and determine the status of the device to be connected, and then connect it to the corresponding target communication bus. This eliminates the need for periodic continuous scanning to discover devices, enabling low-power and rapid connection of devices to the target communication bus. Furthermore, the bandwidth is adjusted in real time according to the load status of the target communication bus to ensure operational reliability.
[0206] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.
[0207] Those skilled in the art will understand that embodiments of this application can be provided as methods, apparatus, or computer program products. Therefore, embodiments of this application can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, embodiments of this application can take the form of computer program products implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0208] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0209] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing terminal device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0210] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal equipment, causing a series of operational steps to be performed on the computer or other programmable terminal equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable terminal equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0211] Although preferred embodiments of the present application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the embodiments of the present application.
[0212] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or terminal device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or terminal device. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or terminal device that includes said element.
[0213] The foregoing has provided a detailed description of a device access control method, a device access control device, an electronic device, and a computer-readable storage medium provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A device access control method, characterized in that, Applied to a home computer, the home computer is equipped with three communication buses with different data transmission rates, the method includes: In response to a broadcast message sent by the device to be connected, the device location information and device type information are determined based on the broadcast message; Based on the device location information and the device type information, the required transmission rate is determined; Match the required transmission rate with the data transmission rate, and determine the target communication bus from the communication bus; Connect the device to be connected to the target communication bus; Determine the load status of the target communication bus; Adjust the bandwidth parameters of the target communication bus based on the load status.
2. The method according to claim 1, characterized in that, The method further includes: When the load condition is greater than a preset load threshold, the device priority in the target communication bus is determined; The devices accessing the target communication bus are sorted in ascending order based on the device priority. The devices that were connected to the target communication bus in the first few positions are migrated to other communication buses.
3. The method according to claim 1, characterized in that, The steps of determining device location information and device type information based on the broadcast information include: Read the device characteristic values from the broadcast information to determine the device type information; Based on the broadcast information, ultra-wideband ranging is performed to determine the device's location information.
4. The method according to claim 1, characterized in that, The communication bus has different power domains, and the method further includes: Detect the clock signal of the communication bus; The energy consumption mode is determined based on the clock signal; The operating state of the power domain is adjusted based on the energy consumption mode.
5. The method according to claim 4, characterized in that, The step of determining the energy consumption mode based on the clock signal includes: If the clock signal times out and reaches a first preset threshold, the power consumption mode is determined to be a light sleep mode. If the clock signal times out and reaches the second preset threshold, the power consumption mode is determined to be deep sleep mode; Wherein, the first preset threshold is less than the second preset threshold.
6. The method according to claim 5, characterized in that, The communication bus includes a low-speed bus, a medium-speed bus, and a high-speed bus with data transmission rates increasing sequentially; the step of adjusting the operating state of the power domain based on the energy consumption mode includes: In the shallow sleep mode, the power domain of the low-speed bus is turned off; In the deep sleep mode, the power domains of the medium-speed bus and the high-speed bus are turned off.
7. The method according to claim 4, characterized in that, The method further includes: Detect the device activity level of the communication bus; The clock signal transmission period is adjusted based on the device activity level.
8. A device access control device, characterized in that, An application for a home console, wherein the home console is equipped with three communication buses with different data transmission rates, the device includes: The response module is used to respond to broadcast information sent by the device to be accessed, and to determine the device location information and device type information based on the broadcast information; The calculation module is used to determine the required transmission rate based on the device location information and the device type information; The matching module is used to match the required transmission rate with the data transmission rate and determine the target communication bus from the communication bus; An access module is used to connect the device to be accessed to the target communication bus; A load module is used to determine the load status of the target communication bus; An adjustment module is used to adjust the bandwidth parameters of the target communication bus based on the load status.
9. An electronic device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and capable of running on the processor, wherein the computer program, when executed by the processor, implements the steps of the device access control method as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, which, when executed by a processor, implements the steps of the device access control method as described in any one of claims 1-7.