Joystick parameter field configuration method and system based on CAN bus
By listening to and parsing parameter configuration commands via the CAN bus, the system enables temporary activation testing and permanent storage of joystick parameters. This solves the problem of poor flexibility in joystick parameter adjustment, reduces maintenance costs, and improves operational safety and reliability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-19
- Publication Date
- 2026-03-17
AI Technical Summary
The existing joystick parameters have poor adjustment flexibility, cannot adapt to temporary needs, have high maintenance costs, and lack user interaction and confirmation mechanisms.
The MCU listens for parameter configuration command frames via the CAN bus, parses and updates the parameters, performs temporary effect testing, generates feedback command frames to confirm the operation results, and stores the parameters in non-volatile memory after user confirmation to ensure that the parameters are valid after power failure.
It enables flexible on-site adjustment of joystick parameters, reduces maintenance costs, improves operational safety and reliability, and provides a real-time feedback mechanism and parameter persistence.
Smart Images

Figure CN121364670B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of joystick parameter field configuration technology, specifically to a joystick parameter field configuration method and system based on CAN bus. Background Technology
[0002] In industries such as industrial control, construction machinery, agricultural machinery, and shipbuilding, joysticks are important human-machine interface input devices and commonly use CAN bus for communication. When joysticks leave the factory, their CAN bus communication parameters, such as baud rate, transmit ID, frame type - standard frame / extended frame, and receive ID, are all preset and stored in the memory by the manufacturer according to the customer's initial requirements.
[0003] For example, patent CN120871724A discloses a dynamic centering and boundary self-calibration method and system for a joystick, including S1: powering on the device and selecting a mode; S2: dead zone calibration; S3: threshold setting; S4: data storage; S5: exit and application. During operation, the joystick sensing unit converts the physical manipulation quantity into a raw electrical signal, and then the signal processing module receives the raw electrical signal and performs signal conditioning to convert the analog signal into a digital signal that can be processed by the microprocessor. Then, the main control unit executes all logical judgments. The user issues commands through the user configuration interface and directly inputs them to the main control unit. The main control unit performs bidirectional data interaction with the non-volatile memory to achieve permanent storage and retrieval of dead zone parameters. After processing all information, the main control unit generates the final control command output to drive the actuator.
[0004] For example, patent CN119882921A discloses a data processing system and method for a joystick. The joystick data processing system includes a joystick input module, an analog-to-digital converter module, a data processing module, and a communication interface module. The operator's input signals are converted into analog signals by the joystick input module. The analog signals are then converted into digital signals by the analog-to-digital converter module. The data processing module performs sliding window de-evaluation and averaging filtering on the digital signals to obtain the actual signal with interference removed. Next, the actual signal is amplified or attenuated through piecewise linear mapping to adapt to different application requirements. Finally, the final smoothed signal is output through the communication interface module. This method effectively reduces noise interference while maintaining the original characteristics of the input signals, significantly improving the accuracy and stability of the joystick and reducing costs. The increased computational complexity improves data processing speed; the flexible parameter configuration allows for reliable and efficient application in various precision control applications. However, some existing joysticks have poor parameter adjustment flexibility and cannot adapt to temporary needs. When users need to change the communication parameters of the joystick due to equipment replacement, system upgrades, or temporary adjustments to operating conditions, the existing joysticks cannot be modified by the users themselves on-site. Users must return the joystick to the original manufacturer or have a professional technician modify the parameters using a special programming tool. This process is time-consuming and labor-intensive, leading to extended equipment downtime and high logistics and labor costs, which greatly affects the user's work efficiency and experience. Furthermore, the parameter modification process is a black box operation for the user, who cannot know in real time whether the parameter modification command has been successfully received and executed, reducing the reliability of the operation and user information.
[0005] To address the aforementioned issues, there is an urgent need for innovative design based on the existing on-site configuration methods for joystick parameters. Summary of the Invention
[0006] The purpose of this invention is to provide a method and system for on-site configuration of joystick parameters based on a CAN bus, in order to solve the problems mentioned in the background art, such as poor flexibility in adjusting some existing joystick parameters, inability to adapt to temporary needs, high maintenance costs, long cycles, and lack of user interaction and confirmation mechanisms.
[0007] To achieve the above objectives, the present invention provides the following technical solution: a method for on-site configuration of joystick parameters based on a CAN bus, the method comprising the following steps:
[0008] Parameter reception and parsing: The joystick main controller listens for and receives parameter configuration command frames from the host computer configuration tool in real time through the CAN bus transceiver. The command frame contains the target parameter information to be modified. The main controller, i.e., the MCU, parses the received command frame and extracts the target parameters.
[0009] For parameter updates and temporary effects, the MCU writes the parsed target parameters into its internal random access memory, overwriting the original operating parameters, and immediately configures the CAN controller based on the new parameters, making the new parameters effective immediately, thus realizing temporary parameter change testing.
[0010] Operation feedback: The MCU generates a feedback command frame containing operation result status information and sends it back to the host computer via the CAN bus to inform the user whether the parameter change operation was successful.
[0011] Parameter storage: After the user confirms that the new parameters are working properly, a specific parameter storage instruction is sent through the host computer. After the MCU receives the instruction, it writes the valid parameters currently stored in RAM into non-volatile memory for permanent storage.
[0012] Power-off protection and power-on loading: When the joystick system is powered off and then powered on again, the MCU's initialization program automatically reads the previously saved parameter configuration from the non-volatile memory, loads it into the RAM, and configures the CAN controller, ensuring that the configuration parameters are not affected after power failure and remain valid.
[0013] Preferably, the host computer configuration tool is the user's operation terminal for parameter configuration, including dedicated software running on a PC and a program embedded in the handheld programmer; the host computer configuration tool is connected to the entire CAN bus network through a USB-CAN adapter and a CAN interface card, and generates and sends parameter configuration command frames and parameter storage command frames, while receiving and displaying feedback information from the joystick.
[0014] Preferably, the CAN bus network is the communication trunk line connecting each node in the joystick system. The nodes include the host computer and the joystick. Configuration commands and feedback information are transmitted through the CAN bus network.
[0015] Preferably, the host computer initiates a parameter change to form a temporary effective test mechanism and a confirmation storage and solidification mechanism; in the temporary effective test mechanism, after the user sends new parameters, the system does not immediately save them permanently, but writes them into RAM to make them temporarily effective. The user can test the joystick and observe whether the target device responds normally according to the new protocol; in the confirmation storage and solidification mechanism, after the user tests and confirms that the new parameters are working completely normally, a storage command is sent, and the MCU receives the command and transfers the parameters in RAM to EEPROM.
[0016] Preferably, the CAN bus network communication is based on a standard frame structure. The key fields of the standard frame are: an arbitration segment, which includes an identifier (ID) and a remote transmission request bit (RTR). The ID of the instruction frame is generated by the host computer according to preset rules, and the ID of the feedback frame is determined by the joystick according to its configuration; a control segment, which includes a data length code (DLC) indicating the number of bytes contained in the data segment; and a data segment, which carries the actual communication data and has a length of 0-8 bytes.
[0017] Preferably, the parameter configuration instruction frame is used to send new parameter values from the host computer to the joystick. The key fields of the parameter configuration instruction frame are: arbitration segment, where the ID of the instruction frame is a pre-agreed configuration instruction address that the joystick will respond to; and data segment, which is 8 bytes long, specifically including: Byte 0 - Command word CMD, defining the operation type; Byte 1 - Parameter type TYPE, specifying the parameter to be modified; and Bytes 2-5 - Parameter value VALUE, a 4-byte space used to store the specific value of the new parameter.
[0018] Preferably, the parameter types are: 0x01 = Baudrate; 0x02 = Transmit ID (Tx ID); 0x03 = Frame Type; 0x04 = Receive ID (Rx ID).
[0019] Preferably, the feedback instruction frame is used to report the result of parameter modification and storage operation from the joystick to the host computer. The key fields of the feedback instruction frame are: arbitration segment, where the ID of the feedback instruction frame is the joystick's sending ID, and the host computer listens for the received feedback ID; the data segment is 8 bytes, specifically including: Byte 0 - Command word CMD, response type; Byte 1 - Original instruction type TYPE, which echoes the parameter type in the received instruction frame, allowing the host computer to sense which instruction received the response; Byte 2 - Status word STATUS, the core indicator of the operation result; Byte 3-7 - Reserved bits RES: unused bytes, filled with 0x00.
[0020] Preferably, the status word specifically includes: 0x00 = Success; 0x01 = Error: CRC / Format Error; 0x02 = Error: Unsupported CMD; 0x03 = Error: Invalid Value.
[0021] A CAN bus-based joystick parameter field configuration system is provided for the aforementioned CAN bus-based joystick parameter field configuration method. The joystick parameter field configuration system includes:
[0022] The main controller, as the control core, is used to execute multiple steps of the on-site configuration method for joystick parameters, including parameter reception and parsing, parameter updating and temporary activation, operation feedback, parameter storage, and power-off protection and power-on loading.
[0023] The joystick module includes a CAN bus interface circuit, random access memory, non-volatile memory, human-machine interface module, and host computer configuration module. The joystick module has built-in sensors to collect mechanical load resistance data, and combines it with the load and parameter matching calculation of the main controller to achieve precise adaptation of the return force parameters, so as to keep the joystick performing precise return to center.
[0024] The CAN bus interface circuit, including the CAN controller and CAN transceiver, is used to communicate with an external CAN network, send and receive command frames, and realize remote parameter configuration and status monitoring.
[0025] Random access memory is used to temporarily store and run currently valid parameters, ensuring that the system can quickly respond to various operations and changes, and guaranteeing the real-time performance and smooth operation of the system.
[0026] Non-volatile memory is used to permanently store user-confirmed parameters, providing power-off protection. It has a large storage capacity, fast read / write speed, and high reliability, meeting the system's requirements for long-term parameter storage.
[0027] The human-computer interaction module, including LED indicators and a buzzer, provides local operation status prompts, allowing users to understand the system's working status in a timely manner and perform corresponding operations and adjustments.
[0028] The host computer configuration module is used to generate and send parameter configuration command frames and parameter storage command frames, and to receive and display feedback information from the joystick.
[0029] Compared with the prior art, the beneficial effects of the present invention are:
[0030] With its high level of convenience and flexibility, users can change the CAN parameters of the joystick at any time on-site as needed, without having to return the equipment to the factory or rely on professional personnel, which greatly saves time and economic costs.
[0031] The operation is safe and reliable, employing a two-step mechanism of temporary effect and confirmation storage. Users can first test whether the new parameters are effective, and then permanently save them after confirming that there are no errors, thus avoiding the risk of system communication failure due to accidental operation.
[0032] The real-time feedback mechanism provides clear success or failure information for each operation, enhancing human-computer interaction, increasing user confidence, and improving system reliability.
[0033] Data persistence utilizes non-volatile memory to store parameters, ensuring that configuration information is not lost after a power outage and restart, and that settings are valid for a long time after a single setup.
[0034] With its high versatility, this method does not depend on a specific model of joystick or MCU, has good portability, and can be widely used in various industrial control devices based on CAN bus. Attached Figure Description
[0035] Figure 1 This is a flowchart illustrating the on-site configuration of the joystick parameters for this invention.
[0036] Figure 2 This is a block diagram of the overall structure of the present invention.
[0037] Figure 3 This is a schematic diagram of the joystick module of the present invention.
[0038] Figure 4 This is a schematic diagram of the feedback instruction frame data structure of the present invention.
[0039] Figure 5 This is a schematic diagram of the general format of the CAN standard frame of the present invention.
[0040] Figure 6 This is a schematic diagram of the parameter configuration instruction frame structure of the present invention.
[0041] Figure 7 This is a flowchart of the method of the present invention. Detailed Implementation
[0042] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0043] This application provides a method for on-site configuration of joystick parameters based on a CAN bus. The core of this method involves the joystick's main controller (MCU) listening in real-time to and receiving parameter configuration command frames from a host computer configuration tool via a CAN bus transceiver. Each command frame contains information about the target parameters to be modified. The MCU parses the received command frames and extracts the target parameters. The MCU writes the parsed target parameters into its internal random access memory, overwriting the existing operating parameters, and immediately configures the CAN controller based on the new parameters, making the new parameters effective immediately and enabling temporary parameter change testing. The MCU generates a feedback command frame containing operation result status information and sends it back to the host computer via the CAN bus, informing the user whether the parameter change operation was successful. Once the user confirms that the new parameters are working correctly, the host computer sends a specific parameter storage command. Upon receiving this command, the MCU writes the currently stored valid parameters in RAM into non-volatile memory for permanent storage. When the joystick system is powered off and then powered on again, the MCU's initialization program automatically reads the previously saved parameter configuration from the non-volatile memory, loads it into RAM, and configures the CAN controller, ensuring that the configuration parameters remain effective even after power failure.
[0044] Example 1: To better understand the above technical solution, the following will provide a detailed description of the technical solution in conjunction with the accompanying drawings and specific implementation methods. (Refer to...) Figures 1-7 As shown in this embodiment of the present application, a method for configuring joystick parameters on-site based on a CAN bus is provided. The method includes the following steps:
[0045] S1. Parameter reception and parsing: The joystick main controller listens for and receives parameter configuration command frames from the host computer configuration tool in real time through the CAN bus transceiver. The command frame contains the target parameter information to be modified. The main controller, i.e., the MCU, parses the received command frame and extracts the target parameters.
[0046] It should be noted that the command frame follows a custom CAN communication protocol. The frame format includes a frame ID (used to identify the joystick device address, supporting simultaneous configuration of multiple devices), a data length code (DLC), a target parameter field (including parameter type identifier, parameter value, and checksum), and a frame tail check bit. After receiving the command frame, the MCU performs three layers of verification: first, frame format verification, verifying whether the DLC matches the actual data length; second, CRC verification, verifying the integrity of data transmission through a preset algorithm to avoid data distortion caused by bus interference; and third, parameter validity verification, comparing the target parameter with the built-in parameter threshold range (such as joystick dead zone threshold 0-100, sensitivity coefficient 0.1-5.0) to determine whether the target parameter is valid. If the verification passes, the MCU parses the parameter type (such as dead zone setting, maximum travel limit, response speed coefficient, etc.) and the corresponding parameter value, providing accurate data support for subsequent update processes. If the verification fails, it directly enters the operation feedback stage and returns an error code to the user.
[0047] In this embodiment, the host computer configuration tool is the user's operation terminal for parameter configuration, including dedicated software running on a PC and a program embedded in the handheld programmer. The host computer configuration tool is connected to the entire CAN bus network through a USB-CAN adapter and a CAN interface card. It generates and sends parameter configuration command frames and parameter storage command frames, and simultaneously receives and displays feedback information from the joystick.
[0048] In this embodiment, the CAN bus network is the communication trunk line connecting each node in the joystick system. The nodes include the host computer and the joystick. Configuration commands and feedback information are transmitted through the CAN bus network.
[0049] It should be noted that the host computer configuration tool, as the core entry point for user interaction with the joystick system, is designed with flexible adaptation and functional closed loop as its core, covering the usage needs of different on-site operation scenarios. Its core carriers fall into two categories: one is dedicated configuration software running on a PC, featuring advanced functions such as a visual interface, parameter library management, configuration history, and fault diagnosis logs. Users can precisely adjust key parameters such as the joystick's sensitivity threshold, travel range, response delay, CAN communication baud rate, and data frame format through intuitive operations like dragging and drop-down selection. The software's built-in parameter verification module verifies the reasonableness of input values in real time (such as providing immediate pop-up prompts when values exceed hardware limits). It also supports importing / exporting parameter configuration files, facilitating batch and unified configuration of multiple joysticks. The other type is a lightweight program embedded in a handheld programmer, designed for on-site operations without a PC (such as industrial equipment debugging and outdoor machinery maintenance). It adopts a simplified operation logic and portable hardware form factor. The handheld terminal is equipped with a small touchscreen or physical buttons, supporting rapid modification, instant testing, and permanent saving of core parameters. Its built-in battery power mode can meet the needs of long-term outdoor operations and adapt to on-site configuration under complex working conditions.
[0050] S2. Parameter update and temporary effect: The MCU writes the parsed target parameters into its internal random access memory, overwriting the original operating parameters, and immediately configures the CAN controller based on the new parameters, so that the new parameters take effect immediately, realizing temporary parameter change testing.
[0051] It should be noted that the CAN bus network, as the nerve center of the entire system, undertakes the task of transmitting all instructions and data between the host computer and the joystick. Its technical characteristics and network architecture directly determine the real-time performance and stability of the configuration system. This bus network adopts a multi-master communication mode, where the host computer and the joystick are both bus nodes with no master-slave dependency. Any node can actively send data, ensuring the rapid issuance of parameter configuration instructions and the immediate uploading of feedback information. Compared with traditional serial communication, the CAN bus can achieve a transmission rate of 1Mbps (communication distance ≤40m). Even in scenarios where multiple nodes communicate simultaneously, data conflicts can be avoided through a non-destructive bus arbitration mechanism, ensuring the real-time performance of instruction transmission and meeting the test requirements for joystick parameter modifications to take effect immediately.
[0052] In terms of hardware architecture, the CAN bus network consists of two differential signal lines, CAN_H and CAN_L, which, together with terminating resistors (usually 120Ω), match the bus impedance to reduce signal reflection interference. Simultaneously, the differential transmission mode provides strong electromagnetic interference resistance, enabling it to withstand electromagnetic noise generated by motor start-up and shutdown, high-voltage equipment operation, etc., in industrial environments, ensuring accurate data transmission in complex industrial settings. The network supports up to 110 nodes, allowing multiple joysticks to communicate simultaneously with the host computer, making it suitable for centralized configuration and management of large equipment clusters (such as multi-axis control systems in automated production lines). Furthermore, the CAN bus's error detection and automatic retransmission mechanism further enhances communication reliability: when bit errors, CRC errors, or other anomalies occur during transmission, the sending node automatically stops transmitting and retryes the transmission. If multiple attempts fail, a fault alarm is triggered, and the host computer configuration tool displays the communication fault status in real time, allowing users to quickly locate problems (such as bus disconnection, node failure, etc.).
[0053] In this embodiment, the host computer initiates a parameter change to form a temporary effective test mechanism and a confirmation storage and solidification mechanism. In the temporary effective test mechanism, after the user sends new parameters, the system does not immediately save them permanently, but writes them into RAM to make them temporarily effective. The user can test the joystick and observe whether the target device responds normally according to the new protocol. In the confirmation storage and solidification mechanism, after the user tests and confirms that the new parameters are working completely normally, he sends a storage command. The MCU receives the command and transfers the parameters in RAM to EEPROM.
[0054] The advantage of the temporary effective test mechanism is that if the parameter settings are incorrect (such as a baud rate mismatch causing communication interruption), the user only needs to resend the correct command to overwrite the incorrect value in RAM, avoiding the risk of directly "bricking" the device due to misoperation, and providing great security and fault tolerance. The advantage of the confirmed storage hardening mechanism is that it realizes the permanent storage of parameters and power failure protection. When the device restarts next time, the MCU will automatically load the parameters from the EEPROM, ensuring the persistence of the configuration.
[0055] It should be noted that the parameter update and temporary activation process allows users to perform multiple temporary parameter adjustments and tests on-site. For example, in engineering machinery operation scenarios, operators can quickly modify the sensitivity parameters of the joystick through the host computer and directly operate the joystick to verify the adjustment effect without restarting the equipment until the optimal parameters suitable for the current working environment are found. The temporary activation mechanism not only meets the flexibility requirements of on-site debugging, but also avoids long-term system anomalies caused by misoperation, providing a safe buffer for parameter verification.
[0056] It should be noted that, at the parameter storage level, the system adopts a dual storage architecture of RAM + non-volatile memory (Flash / EEPROM): RAM is used to temporarily store the currently running parameters, supporting high-speed read / write and real-time modification to meet the flexibility requirements of parameter testing; non-volatile memory is used to permanently store valid parameters confirmed by the user, with an erase / write life of over 100,000 cycles and a data retention time of over 10 years, ensuring that parameters are not lost after power failure; when the user sends a parameter storage command through the host computer, the MCU will initiate the memory writing process, first performing CRC verification on the current parameters in RAM to confirm data integrity, and then writing the parameters to non-volatile memory according to the steps of sector erasure-data writing-verification, avoiding data corruption due to power failure or interference during storage; when the system is powered on and initialized, the MCU will first read the parameter configuration from the non-volatile memory. If the read is successful, it will be loaded into RAM and the CAN controller will be configured; if the read fails (e.g., due to memory failure), the preset default parameters will be automatically loaded to ensure the normal operation of the joystick system's basic functions and improve the system's fault tolerance.
[0057] S3. Operation Feedback: The MCU generates a feedback instruction frame containing operation result status information and sends it back to the host computer via the CAN bus to inform the user whether the parameter change operation was successful.
[0058] It should be noted that after the parameters are updated, the MCU generates a feedback command frame based on the operation result. The frame content includes the operation status code, a snapshot of the currently effective key parameters, and the device status identifier. The feedback command frame is transmitted back to the host computer via the CAN bus. After receiving it, the host computer configuration tool intuitively displays the operation result to the user in the form of pop-up prompts, status indicator light color changes, and parameter list highlighting. At the same time, it records the operation log (including operation time, device number, and parameter change records) to facilitate subsequent traceability and troubleshooting. The feedback mechanism forms a closed loop of "host computer sends command - joystick executes operation - host computer receives result", ensuring that the user can grasp the status of each parameter adjustment in real time and avoid repeated operations or configuration omissions due to information asymmetry.
[0059] In this embodiment, CAN bus network communication is based on a standard frame structure. The key fields of the standard frame are: arbitration segment, which includes an identifier (ID) and a remote transmission request bit (RTR). The ID of the instruction frame is generated by the host computer according to preset rules, and the ID of the feedback frame is determined by the joystick according to its configuration; control segment, which includes a data length code (DLC) indicating the number of bytes contained in the data segment; and data segment, which carries the actual communication data and has a length of 0-8 bytes.
[0060] In this embodiment, the parameter configuration command frame is used to send new parameter values from the host computer to the joystick. The key fields of the parameter configuration command frame are: arbitration segment, where the ID of the command frame is a pre-agreed configuration command address that the joystick will respond to; and data segment, which is 8 bytes long, specifically including: Byte 0 - Command word CMD, defining the operation type; Byte 1 - Parameter type TYPE, specifying the parameter to be modified; Bytes 2-5 - Parameter value VALUE, 4 bytes of space used to store the specific value of the new parameter; the parameter types are specifically: 0x01 = Baudrate; 0x02 = Transmit ID (Tx ID); 0x03 = Frame Type (FrameType); 0x04 = Receive ID (Rx ID).
[0061] In this embodiment, the feedback instruction frame is used to report the result of parameter modification and storage operations from the joystick to the host computer. The key fields of the feedback instruction frame are: arbitration segment, where the ID of the feedback instruction frame is the joystick's sending ID, and the host computer listens for the received feedback ID; the data segment is 8 bytes, specifically including: Byte 0 - Command word CMD, response type; Byte 1 - Original instruction type TYPE, echoing the parameter type in the received instruction frame, allowing the host computer to sense which instruction received the response; Byte 2 - Status word STATUS, the core indicator of the operation result; Byte 3-7 - Reserved bits RES: unused bytes, filled with 0x00; the status word specifically includes: 0x00 = Success; 0x01 = Error: CRC, format error (Error: CRC / Format); 0x02 = Error: Unsupported command (Error: Unsupported CMD); 0x03 = Error: Invalid parameter value (Error: InvalidValue).
[0062] It should be noted that the above data structure design reflects the reliability and interactivity of this invention, with specific advantages including: clarity, as each field has a clear function, avoiding ambiguity in instructions; scalability, as the "command word" and "parameter type" fields allow for easy addition of future configurable parameter types (such as data update rate, output mode, etc.) without changing the basic protocol framework; and strong feedback, as the "status word" in the feedback frame provides clear operation results, which is key to achieving "information feedback for every change," greatly improving user experience and system maintainability.
[0063] In practical implementation, the feedback command frame is the key carrier for the joystick to transmit parameter operation results to the host computer. Its field design needs to achieve three major goals: clear operation results, clear command traceability, and traceable error causes, to help users quickly determine the configuration status and locate problems, as detailed below:
[0064] Arbitration Segment ID: This ID is the node identifier for feedback information and is used in the host computer's monitoring logic. The arbitration segment ID of the feedback command frame is a unique transmission ID for each joystick. This ID can be modified during system initialization via parameter configuration commands (TYPE=0x02) to ensure the uniqueness of feedback information for each joystick. The host computer receives feedback frames from different joysticks in real time through a monitoring ID list. For example, the host computer presets the monitoring ID list to 0x0A1-0x0AA (corresponding to 10 joysticks). When a feedback frame with ID=0x0A3 is received, it can be directly identified as the operation result of joystick number 3, without the need for additional parsing of the node identifier information of the data segment, thus improving information processing efficiency. In multi-node communication scenarios, the host computer can record feedback information using IDs and timestamps. For example, when configuring 10 joysticks in batches, the host computer issues commands sequentially and records the ID of each joystick and the command issuance time. When a feedback frame is received, the ID is matched with the corresponding command record, and the feedback time is used to determine whether the configuration has timed out. If no feedback is received within 500ms, it is considered a communication failure, achieving efficient monitoring of batch operations.
[0065] Data Segment: This segment provides a structured presentation of operation results and adapts to error handling. The 8-byte structured layout of the data segment must cover three core pieces of information: response type, instruction source, and result status. The status code design must correspond to actual fault scenarios to help users quickly locate the cause of the problem. Byte0 - Command Word (CMD): This serves as an identifier for the response type. The value of CMD corresponds one-to-one with the CMD in the parameter configuration instruction frame, enabling precise traceability of instructions and feedback. For example, if the host computer issues an instruction frame with CMD=0x01 (temporary parameter modification), the joystick feedback will have CMD fixed at 0x81 (setting the highest bit based on the original CMD), indicating that the feedback is a response to the temporary parameter modification instruction. The host computer sends a command frame with CMD=0x02 (parameters are permanently stored). When the joystick provides feedback, CMD is fixed at 0x82, ensuring the host computer can quickly distinguish the feedback results of different operations. This design allows the host computer to quickly match the corresponding sent command via CMD when processing multiple operation commands simultaneously, avoiding feedback information confusion. Byte1 - Original Command Type TYPE: Serves as an index for command tracing. TYPE directly echoes the TYPE value in the parameter configuration command frame, helping the host computer clearly identify the parameter type corresponding to the feedback. For example, if TYPE=0x01 in the feedback frame, the host computer can determine that the feedback is a response to a baud rate modification command; if TYPE=0x02, then the corresponding ID is sent. The response to the modification command; when a configuration failure occurs, the user can quickly locate which parameter configuration is problematic through TYPE, without having to check all parameters one by one; Byte2 - Status Word STATUS: As the core indicator of the operation result, the value of STATUS covers all possible operation results of the system, and each value corresponds to a clear processing logic: STATUS=0x00 (Success): indicates that the parameter configuration or storage operation has been completed and the parameter has taken effect (temporary modifications are written to RAM, permanent storage is written to non-volatile memory), the host computer can display configuration success on the interface, prompting the user to perform the next operation (such as testing the parameter effect); STATUS=0x01 (Error) Error: CRC / Format Error): This indicates that the instruction frame received by the joystick has a CRC check failure (such as byte loss during data transmission) or a format error (such as DLC≠8, or an invalid CMD value). In this case, the joystick does not perform any parameter modification operations, and the host computer needs to resend the instruction and check the bus communication status (such as whether there is electromagnetic interference or bus disconnection). STATUS=0x02 (Error: Unsupported Command): This indicates that the CMD value in the instruction frame is not within the system's supported range (such as CMD=0x05, the system only supports 0x01-0x03). In this case, the joystick refuses to execute the operation, and the host computer needs to check whether the instruction configuration is correct and ensure that CMD conforms to the system convention.STATUS=0x03 (Error: Invalid parameter value): This indicates that the parameter value in the instruction frame exceeds the hardware's allowed range or does not meet the parameter type requirements (e.g., when TYPE=0x01, the parameter value is a non-standard baud rate; when TYPE=0x02, the parameter value is a 29-bit extended frame ID). In this case, the joystick refuses to write parameters, and the host computer needs to prompt the user to modify the parameter value to ensure it conforms to the hardware specifications. Byte3-7 - Reserved bit RES: This is reserved space for function expansion. Currently filled with 0x00, information can be added in the future according to system needs: for example, adding feedback on the current parameter value (Byte3-6 stores the current parameter value, and Byte7 stores the parameter unit identifier), or adding fault code details (Byte3-4 stores the specific fault subcode, such as when STATUS=0x03, Byte3=0x01 indicates that the parameter value exceeds the upper limit, and Byte3=0x02 indicates that the parameter value is below the lower limit), further improving the practicality of the feedback information.
[0066] The design of the CAN bus frame structure and command and feedback frames needs to be deeply adapted to the overall requirements of the joystick parameter configuration system. It must ensure both communication reliability and real-time performance while reserving space for functional expansion. Specifically, this is reflected in:
[0067] Communication reliability assurance: Field verification and error handling mechanisms ensure the accuracy of data transmission through multiple layers of verification: First, CRC verification at the CAN bus hardware level (each frame carries a 15-bit CRC code) can detect bit errors, byte loss, and other problems during transmission; second, implicit verification of the instruction frame data segment (such as parameter value and parameter type matching verification) can prevent illegal parameter writing; third, the status code mechanism of the feedback frame can intuitively feed back the verification results to the user; the multi-layer verification mechanism forms a closed loop of transmission-parsing-feedback, which greatly reduces parameter configuration failures caused by communication errors.
[0068] Real-time performance guarantee: The simplified frame structure and optimized parsing efficiency, the design of the standard frame 11-bit ID can shorten the arbitration time, and the fixed length of the 8-byte data segment can reduce the complexity of the parsing logic. The joystick MCU only needs to extract information by byte offset to parse the instruction frame. The whole process takes less than 10 microseconds, ensuring that parameter modifications can take effect within milliseconds, meeting the needs of real-time testing. At the same time, the non-destructive arbitration mechanism of the CAN bus can ensure that parameter configuration instructions are transmitted first in multi-node communication, avoiding instruction delays caused by bus congestion.
[0069] Functional scalability assurance: Reserved fields and flexible configuration, the reserved bits in the frame structure (feedback frame Bytes 3-7) and configurable IDs (joystick send ID, receive ID) provide space for system function expansion: for example, when adding parameter backup / restore functions in the future, the reserved bits can be reused to store the backup identifier; when adding a joystick node, a new send ID can be assigned through parameter configuration instructions without modifying the core logic of the host computer software; this design allows the system to be flexibly upgraded according to business needs and extend its life cycle.
[0070] S4. Parameter storage: After the user confirms that the new parameters are working properly, a specific parameter storage instruction is sent through the host computer. After the MCU receives the instruction, it writes the valid parameters currently stored in RAM into the non-volatile memory for permanent storage.
[0071] In practice, after the user verifies that the new parameters are working properly through actual operation (such as the joystick response accuracy meets the standard, and there is no lag or false triggering), the user sends a specific parameter storage instruction through the "Parameter Save" button of the host computer configuration tool. The frame ID is the device address + preset storage instruction identifier. After the MCU receives the instruction, it first checks the integrity of the currently effective parameters in RAM again, and then starts the writing process of non-volatile memory.
[0072] It should be noted that the writing process adopts a block storage strategy: the parameters are divided into multiple data blocks according to functional modules (such as basic configuration parameters, response characteristic parameters, and security protection parameters). Each data block is attached with an independent check code and is written to a specified address of non-volatile memory in sequence. After the writing is completed, the MCU reads the stored data to perform a readback verification. After confirming that the data is written correctly, it returns a "storage successful" status code to the host computer. If the readback verification fails, a retry mechanism is automatically triggered, with a maximum of 3 retries. If it still fails, an error message is returned to ensure the reliability of the permanent storage of parameters.
[0073] S5. Power-off protection and power-on loading: When the joystick system is powered off and then powered on again, the MCU's initialization program automatically reads the previously saved parameter configuration from the non-volatile memory, loads it into the RAM, and configures the CAN controller to ensure that the configuration parameters are not affected after power failure and remain valid.
[0074] In practice, when the joystick system is powered off, the power-off retention characteristic of the non-volatile memory ensures that the stored parameters are not lost. When the system is powered on again, the MCU starts the initialization program and prioritizes the parameter loading process: first, it initializes the communication interface between the CAN bus transceiver and the non-volatile memory, and then reads the parameter data of each functional module from the non-volatile memory according to the preset address mapping table, and verifies each block (checksum comparison) to ensure that the data has not been tampered with or damaged.
[0075] It should be noted that after the verification is successful, the MCU loads the parameter data into the parameter operation area of RAM, and simultaneously configures the actuators of the CAN controller and joystick (such as the signal acquisition modules of potentiometers and Hall sensors), completing the parameter initialization of the entire system. The entire loading process is completed during the MCU's power-on self-test phase, taking no more than 100 milliseconds, ensuring that the joystick can work normally according to the historical configuration after power-on, without requiring the user to set parameters again, thus ensuring the continuity and stability of equipment operation.
[0076] The control lever body consists of the following components:
[0077] CAN interface circuit: This is the bridge connecting the joystick to the physical CAN bus. It is internally divided into: CAN controller (usually integrated inside the MCU), which is responsible for handling the CAN protocol, such as frame organization, verification, arbitration, etc.; CAN transceiver, which converts the logic level signal output by the CAN controller into a differential signal for transmission on the bus, and vice versa.
[0078] Main Controller (MCU): The brain of the system, responsible for executing core logic, parsing received instructions, updating parameters in RAM, generating feedback information, and executing stored commands.
[0079] Random Access Memory (RAM): Used to temporarily store currently running parameters. When the MCU receives new parameters, it first overwrites the old parameters here and the new parameters take effect immediately, allowing users to test.
[0080] Non-volatile memory (EEPROM / Flash): Used to permanently store user-confirmed parameters. Its characteristic is that data is not lost after power failure, ensuring that the last set parameters can be loaded upon the next power-on.
[0081] (Optional) Sensors: These represent the original functional modules of the joystick itself (such as angle sensors, buttons, etc.), and the data they generate will be sent out according to the configured CAN parameters.
[0082] The data flow process is divided into two main directions: downlink (parameter configuration) and uplink (feedback). Both paths require multiple stages of transmission, either "host computer → CAN bus → joystick internal components" or "joystick internal components → CAN bus → host computer". The functional connection between each stage directly determines the real-time performance and accuracy of data transmission. The data flow process is as follows:
[0083] The core objective of the downlink data stream is to accurately transmit the parameter configuration instruction frame generated by the host computer to the joystick MCU and trigger parameter modification operations. The entire process involves five key steps, each of which requires specific format conversion or protocol processing.
[0084] Downlink (configuration): Host computer → CAN bus → CAN transceiver → CAN controller → MCU (parse and process).
[0085] The host computer configuration tool generates parameter configuration command frame data based on user operations. The host computer converts the command frame data from the USB protocol to the CAN bus protocol through a USB-CAN adapter or CAN interface card. Differential signals are transmitted in the CAN bus, utilizing the differential transmission characteristics of the bus to resist electromagnetic interference. At the same time, the terminating resistor reduces signal reflection, ensuring that the signal remains intact after long-distance transmission. After the joystick's CAN transceiver receives the bus differential signal, it converts it into a logic level and transmits it to the CAN controller inside the MCU. After the CAN controller detects that the frame ID matches the preset receive ID, it completes CRC verification and frame parsing, extracts the data segment information, and notifies the MCU core to process it through an interrupt signal. The MCU core responds to the interrupt, reads the data segment information transmitted by the CAN controller, and completes command parsing, parameter verification, RAM writing, and CAN controller configuration according to the preset logic.
[0086] The core objective of the uplink data stream is to generate feedback command frames from the result of the joystick's parameter operation (success / failure), accurately transmit them to the host computer, and display them intuitively. The entire process is symmetrical to the downlink path and also requires five key steps.
[0087] Uplink (feedback): MCU (generate) → CAN controller → CAN transceiver → CAN bus → host computer (display).
[0088] The MCU assembles the feedback command frame data segment based on the parameter processing results. The MCU then transmits the feedback data segment to the CAN controller. The controller assembles the complete frame according to the CAN standard frame structure. The differential signal of the feedback frame is transmitted on the bus. Since the feedback frame ID has a lower priority than the configuration command frame ID, when both configuration commands and feedback frames exist on the bus, the configuration command will be transmitted first to ensure that the real-time performance of parameter modifications is not affected by feedback. After the USB-CAN adapter connected to the host computer receives the differential signal of the feedback frame on the bus, it converts it to a logic level through an internal transceiver. The adapter chip parses the CAN frame structure, extracts the arbitration segment ID and data segment information, and then encapsulates the data into a USB data packet via the USB protocol and sends it to the PC or handheld programmer. After receiving the USB data packet, the host computer configuration tool parses the ID and data segment information of the feedback frame, matches the corresponding joystick according to the ID, and displays the message "Joystick 1 - Baud Rate Modification - Success" on the interface based on the CMD, TYPE, and STATUS of the data segment. At the same time, it records the operation log to facilitate users to trace the configuration history. If the STATUS is an error value, a pop-up window displays the error reason and prompts the user to reconfigure, completing the entire uplink feedback process.
[0089] Example 2: This application provides a field configuration system for joystick parameters based on a CAN bus. The field configuration system for joystick parameters includes:
[0090] The main controller, as the control core, is used to execute multiple steps of the on-site configuration method for joystick parameters, including parameter reception and parsing, parameter updating and temporary activation, operation feedback, parameter storage, and power-off protection and power-on loading.
[0091] The joystick module includes a CAN bus interface circuit, random access memory, non-volatile memory, human-machine interface module, and host computer configuration module. The joystick module has built-in sensors to collect mechanical load resistance data, and combines it with the load and parameter matching calculation of the main controller to achieve precise adaptation of the return force parameters, so as to keep the joystick performing precise return to center.
[0092] The CAN bus interface circuit, including the CAN controller and CAN transceiver, is used to communicate with an external CAN network, send and receive command frames, and realize remote parameter configuration and status monitoring.
[0093] Random access memory is used to temporarily store and run currently valid parameters, ensuring that the system can quickly respond to various operations and changes, and guaranteeing the real-time performance and smooth operation of the system.
[0094] Non-volatile memory is used to permanently store user-confirmed parameters, providing power-off protection. It has a large storage capacity, fast read / write speed, and high reliability, meeting the system's requirements for long-term parameter storage.
[0095] The human-computer interaction module, including LED indicators and a buzzer, provides local operation status prompts, allowing users to understand the system's working status in a timely manner and perform corresponding operations and adjustments.
[0096] Taking the control lever of construction machinery as an example, the specific implementation process is as follows:
[0097] (1) The user connects the handheld configurator (host computer) to the vehicle's CAN bus.
[0098] (2) The user selects the parameter to be modified on the configurator, such as changing the baud rate from 250kbps to 500kbps, and then clicks "send".
[0099] (3) After receiving the instruction, the MCU of the joystick immediately changes the baud rate register value to 500kbps. At this time, the joystick communicates with the bus at the new rate. At the same time, the MCU sends a feedback frame of "baud rate change successful" and the configurator screen displays "success".
[0100] (4) After the user observes that the system communication is normal, click "Save Settings" on the configurator.
[0101] (5) The MCU receives the storage instruction, writes the value of 500kbps from RAM to EEPROM, and sends the feedback frame "Parameter saved" again.
[0102] (6) After turning off the power supply of the whole machine and turning it back on, the MCU reads the 500kbps setting from the EEPROM and automatically configures the CAN controller. The joystick continues to work normally at a rate of 500kbps.
[0103] The host computer configuration module is used to generate and send parameter configuration command frames and parameter storage command frames, and to receive and display feedback information from the joystick.
[0104] The implementation process for engineering machinery scenarios—send-take effect-verify-save-power-load—embodies a scientific debugging logic of verifying before solidifying. Users can test the actual effects of system communication and operation response after the parameters are temporarily effective, and then permanently store them after confirming that there are no errors. This avoids equipment failure caused by the solidification of incorrect parameters. The automatic loading function after power failure and restart ensures the long-term stability of the parameters, eliminating the need for users to reconfigure and improving the convenience of equipment operation and maintenance.
[0105] The joystick parameters need to be precisely matched with the mechanical load. If the joystick return force parameter is too small when adjusted on-site, while the actual load resistance is large, such as in the control mechanism of heavy machinery, the joystick will not be able to return to center automatically. If the return force parameter is too large, it will increase the operator's workload and accelerate the wear of mechanical parts over time. Therefore, a load status detection unit, parameter verification unit, and closed-loop feedback calibration unit are added to the joystick module to avoid the problem of mismatch between the joystick return force parameter and the mechanical load.
[0106] The load status detection unit can collect mechanical load resistance data in real time, providing an objective basis for parameter configuration and avoiding blindly setting the return force parameter. The load status detection unit includes a torque sensor or pressure sensor deployed in the joystick module, and sensors deployed at the return spring linkage or shaft of the joystick to detect the mechanical load resistance experienced by the joystick during the return process in real time, such as the friction force and load inertia resistance of the heavy machinery operating mechanism. The sensor data is transmitted to the main controller through the CAN bus interface circuit, with a sampling frequency of not less than 100Hz to ensure the real-time performance of the load data. In addition, a load characteristic database is partitioned in non-volatile memory to store load resistance thresholds under different working conditions, such as no-load resistance threshold, rated load resistance threshold, and maximum load resistance threshold, which can be preset by the host computer or calibrated on-site.
[0107] The parameter verification unit includes a load and parameter matching algorithm embedded in the main controller. During the parameter configuration phase, it automatically verifies whether the return force parameter is suitable for the current load, avoiding unreasonable parameter configuration. Before configuration, before the host computer initiates the parameter configuration command, the main controller first triggers a load self-test process, controlling the joystick to complete 1-2 full-stroke return-to-center actions. It collects real-time load resistance values through sensors and compares them with the load threshold in memory to determine the current load level. The host computer configuration module automatically generates recommended values for the return force parameter based on the load level uploaded by the main controller. For example, a high return force parameter is recommended for heavy load conditions, and a low return force parameter is recommended for light load conditions. Operators can fine-tune based on the recommended values instead of setting them from zero. Dual threshold verification is performed during configuration. During the lower limit verification, the minimum value of the return force parameter is ≥ the current load resistance value × 1.1. If the configured parameter is lower than this value, the main controller determines that the return force is insufficient and cannot overcome the load. Resistance is encountered when writing parameters to RAM. An alarm is sent via the human-machine interface module indicating that the parameter is too low or cannot return to center. During upper limit verification, the maximum value of the return force parameter must be ≤ 0.8 times the rated bearing capacity of the joystick's mechanical structure. If the configured parameter is too high, the main controller determines that the return force is overloaded, potentially affecting easily worn parts, and also refuses configuration, sending an alarm indicating that the parameter is too high and the component is at risk. After configuration, a temporary effectiveness test and confirmation are performed. Parameters that pass verification are allowed to be written to RAM temporarily, but a mandatory return-to-center action test is required. The main controller controls the joystick to complete three consecutive return-to-center actions, using sensors to detect the accuracy and time of each return. After the test passes, the main controller sends a test pass feedback to the host computer, allowing the operator to send a parameter storage command to solidify the parameters into non-volatile memory. If the test fails, the temporary parameters in RAM are automatically cleared, the original parameters are restored, and a load mismatch warning is displayed, requesting reconfiguration.
[0108] The closed-loop feedback calibration unit is based on a dynamic calibration mechanism during joystick operation to avoid parameter adaptability failure due to load changes. When the joystick is operating normally, the main controller continuously collects the positioning accuracy and positioning time data of the return-to-center action. If the positioning accuracy error is greater than 3% or the positioning time is greater than the threshold for 5 consecutive times, it is determined that the current positioning force parameter is not matched with the load. An early warning is issued through the human-machine interaction module, and at the same time, abnormal information is pushed to the host computer to remind the operator to recalibrate the parameters.
[0109] For scenarios requiring frequent load switching, an automatic adaptation mode is added to the system. This mode needs to be manually enabled through the host computer configuration module. Once enabled, the main controller will collect load resistance data from torque and pressure sensors at a frequency of no less than 100Hz. When the average value of five consecutive sets of sampled data deviates from the adaptation resistance value corresponding to the current return force parameter by more than ±15%, the parameter fine-tuning process is automatically triggered. If the load resistance data is stable within ±5%, the current parameter remains unchanged to avoid frequent adjustments that could cause system jitter. The main controller automatically fine-tunes the return force parameter within the preset safety parameter range based on real-time load resistance changes, without manual intervention. For example, if the load resistance suddenly increases, the return force parameter is automatically increased to above the lower limit threshold to ensure the return function is normal.
[0110] Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for configuring parameters of a joystick on site based on CAN bus, characterized in that, The joystick parameter field configuration method comprises the following steps: Parameter receiving and analysis: the joystick main controller listens to and receives parameter configuration instruction frames from the upper computer configuration tool in real time through the CAN bus transceiver, the instruction frame contains target parameter information to be modified, and the main controller, i.e., the MCU, analyzes the received instruction frame and extracts the target parameter; Parameter updating and temporary effect: the MCU writes the target parameter obtained through analysis into the random access memory in the MCU, covers the original running parameter, and immediately configures the CAN controller based on the new parameter, so that the new parameter takes effect immediately, realizing temporary parameter change test; Operation feedback: the MCU generates a feedback instruction frame containing operation result state information and sends it back to the upper computer through the CAN bus, informing the user whether the parameter change operation is successful; Parameter storage: when the user confirms that the new parameter works normally, the upper computer sends a specific parameter storage instruction, and the MCU writes the effective parameter currently stored in the RAM into the non-volatile memory for permanent storage after receiving the instruction; Power-off protection and power-on loading: when the joystick system is powered off and then powered on again, the initialization program of the MCU automatically reads the previously saved parameter configuration from the non-volatile memory, loads it into the RAM, and configures the CAN controller, so that the configuration parameter is not affected after power-off and continues to be effective.
2. The method for configuring parameters of a joystick on site based on CAN bus according to claim 1, characterized in that: The upper computer configuration tool is the operation end for parameter configuration by the user, comprising a special software running on a PC and a program embedded in a handheld programmer; The upper computer configuration tool is connected to the entire CAN bus network through a USB-CAN adapter and a CAN interface card, generates and sends parameter configuration instruction frames and parameter storage instruction frames, and receives and displays feedback information from the joystick.
3. The method for configuring parameters of a joystick on site based on CAN bus according to claim 2, characterized in that: The CAN bus network is a communication trunk connecting nodes in the joystick system, and the nodes include the upper computer and the joystick. Configuration instructions and feedback information are transmitted through the CAN bus network.
4. The method for configuring parameters of a joystick on site based on CAN bus according to claim 1, characterized in that: The upper computer initiates parameter change to form a temporary effect test mechanism and a confirmation storage solidification mechanism; Temporary effect test mechanism: after the user sends new parameters, the system does not immediately save them permanently, but writes them into the RAM to make them temporarily effective, so that the user can test the joystick and observe whether the target device responds normally according to the new protocol; Confirmation storage solidification mechanism: after the user confirms that the new parameters work completely normally, the user sends a storage instruction, and the MCU receives the instruction to transfer the parameters in the RAM to the EEPROM.
5. The method for configuring parameters of a joystick on site based on CAN bus according to claim 1, characterized in that: The CAN bus network communication is based on a standard frame structure, and the key fields of the standard frame are: Arbitration segment: contains identifier ID and remote transmission request bit RTR. The ID of the instruction frame is generated by the upper computer according to a preset rule, and the ID of the feedback frame is determined by the joystick according to its configuration; Control segment: contains data length code DLC, which indicates the number of bytes contained in the data segment; Data segment: carries actual communication data, with a length of 0-8 bytes.
6. The method for configuring parameters of a joystick on site based on CAN bus according to claim 1, characterized in that: The parameter configuration instruction frame is used to send new parameter values from the upper computer to the joystick, and the key fields of the parameter configuration instruction frame are: Arbitration segment, the ID of the command frame is a pre-agreed configuration command address to which the joystick will respond; The data segment is 8 bytes, specifically including: Byte 0 - command word CMD, defining the operation type; Byte 1 - parameter type TYPE, specifying the parameter to be modified; Bytes 2-5 - parameter value VALUE, 4 bytes of space for storing the specific value of the new parameter.
7. The method for configuring parameters of a joystick on site based on CAN bus according to claim 6, characterized in that: The parameter type is specifically: 0x01 = baud rate; 0x02 = transmission ID; 0x03 = frame type; 0x04 = reception ID.
8. The method for configuring parameters of a joystick on site based on CAN bus according to claim 1, characterized in that: The feedback command frame is used to report the results of parameter modification and storage operations from the joystick to the upper computer. The key fields of the feedback command frame are: Arbitration segment, the ID of the feedback command frame is the transmission ID of the joystick, and the upper computer listens to the ID to receive feedback; The data segment is 8 bytes, specifically including: Byte 0 - command word CMD, response type; Byte 1 - original instruction type TYPE, echoing the parameter type in the received instruction frame, so that the upper computer can sense which instruction is being responded to; Byte 2 - status word STATUS, the core indication of the operation result; Bytes 3-7 - reserved bits RES: unused bytes filled with 0x00.
9. The method for configuring parameters of a joystick on site based on CAN bus according to claim 8, characterized in that: The status word specifically includes: 0x00 = success; 0x01 = error: CRC, format error; 0x02 = error: unsupported command; 0x03 = error: invalid parameter value.
10. A CAN bus based joystick parameter field configuration system for performing the CAN bus based joystick parameter field configuration method according to any one of claims 1 to 9, characterized in that The joystick parameter field configuration system includes: A main controller serving as the control core for executing multiple steps of the joystick parameter field configuration method, including parameter reception and analysis, parameter update and temporary validation, operation feedback, parameter storage, and power failure protection and power-on loading; A joystick module that internally includes a CAN bus interface circuit, a random access memory, a non-volatile memory, a human-computer interaction module, and an upper computer configuration module. The joystick module's built-in sensors collect mechanical load resistance data, and in combination with the main controller's load and parameter matching algorithm, it achieves precise adaptation of the centering force parameter, ensuring precise centering execution of the joystick; A CAN bus interface circuit including a CAN controller and a CAN transceiver for communicating with an external CAN network, receiving and transmitting instruction frames, and realizing remote parameter configuration and state monitoring; A random access memory for temporarily storing and running the current valid parameters, ensuring that the system can quickly respond to various operations and changes, and guaranteeing the real-time and smooth operation of the system; A non-volatile memory for permanently storing user-confirmed parameters, realizing power failure protection, and having large storage capacity, fast read-write speed, and high reliability, meeting the system's long-term storage parameter requirements; A human-computer interaction module including LED indicator lights and a buzzer for providing operation status prompts locally, allowing users to promptly understand the system's working status and make corresponding operations and adjustments; An upper computer configuration module for generating and sending parameter configuration instruction frames and parameter storage instruction frames, and receiving and displaying feedback information from the joystick.
Citation Information
Patent Citations
Data processing system and data processing method of joystick
CN119882921A
Dynamic neutral position and boundary self-calibration method and system of joystick
CN120871724A
Nuclear power plant field bus communication error rate test device and test method
CN112152883A
Configurable dead zone-based joystick control precision improvement method and system
CN121070130A