{"id":3623,"date":"2025-06-11T13:16:57","date_gmt":"2025-06-11T05:16:57","guid":{"rendered":"https:\/\/saludpcb.com\/zh\/?p=3623"},"modified":"2025-09-26T06:15:38","modified_gmt":"2025-09-25T22:15:38","slug":"adaptive-pid-esp32-guide","status":"publish","type":"post","link":"https:\/\/saludpcb.com\/zh\/adaptive-pid-esp32-guide\/","title":{"rendered":"\u7d42\u7d50\u8abf\u53c3\u75db\u82e6\uff01ESP32 \u81ea\u9069\u61c9 Adaptive PID \u63a7\u5236\u5168\u653b\u7565"},"content":{"rendered":"\n<hr class=\"wp-block-separator alignwide has-text-color has-palette-color-1-color has-alpha-channel-opacity has-palette-color-1-background-color has-background is-style-wide\"\/>\n\n\n\n<p><strong>Adaptive PID<\/strong>\uff08\u6bd4\u4f8b-\u7a4d\u5206-\u5fae\u5206\uff09\u81ea\u9069\u61c9 PID\uff0c\u5728\u50b3\u7d71 PID \u63a7\u5236\u5668\u5728\u5de5\u696d\u8207\u5d4c\u5165\u5f0f\u9818\u57df\u61c9\u7528\u5ee3\u6cdb\uff0c\u4f46\u56fa\u5b9a\u53c3\u6578\u96e3\u4ee5\u61c9\u5c0d\u52d5\u614b\u8b8a\u5316\u7684\u7cfb\u7d71\uff0c\u8abf\u53c3\u5f80\u5f80\u8017\u6642\u53c8\u4e0d\u7a69\u3002Adaptive PID \u5247\u900f\u904e\u300c\u6839\u64da\u8aa4\u5dee\u81ea\u52d5\u8abf\u6574\u589e\u76ca\u300d\u4f86\u5f4c\u88dc\u9019\u500b\u554f\u984c\uff0c\u63d0\u4f9b\u66f4\u8070\u660e\u3001\u66f4\u7a69\u5b9a\u7684\u63a7\u5236\u89e3\u6cd5\u3002<\/p>\n\n\n\n<p>\u9019\u6642\u5019\uff0c\u81ea\u9069\u61c9 Adaptive PID \u5c31\u6d3e\u4e0a\u7528\u5834\u4e86\u3002\u800c\u66f4\u68d2\u7684\u662f\uff0c\u6211\u5011\u53ef\u4ee5\u7528 ESP32 \u9019\u9846\u50f9\u683c\u89aa\u6c11\u3001\u529f\u80fd\u5f37\u5927\u7684\u5fae\u63a7\u5236\u5668\u4f86\u5be6\u73fe\u5b83\uff01<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"1024\" src=\"https:\/\/saludpcb.com\/zh\/wp-content\/uploads\/2025\/06\/Master-Adaptive-PID-on-ESP32-A-Complete-Beginners-Guide.jpg\" alt=\"Adaptive PID\" class=\"wp-image-3638\" title=\"\" srcset=\"https:\/\/saludpcb.com\/zh\/wp-content\/uploads\/2025\/06\/Master-Adaptive-PID-on-ESP32-A-Complete-Beginners-Guide.jpg 1024w, https:\/\/saludpcb.com\/zh\/wp-content\/uploads\/2025\/06\/Master-Adaptive-PID-on-ESP32-A-Complete-Beginners-Guide-768x768.jpg 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<div class=\"wp-block-rank-math-toc-block\" id=\"rank-math-toc\"><h2>\u5167\u5bb9<\/h2><nav><ul><li class=\"\"><a href=\"#\u4ec0\u9ebc\u662f-lvgl-render\uff1f\">\u4ec0\u9ebc\u662f\u81ea\u9069\u61c9 Adaptive PID\uff1f<\/a><\/li><li class=\"\"><a href=\"#esp-32-\u7684-spi-dma-\u539f\u7406\u7c21\u4ecb\">Adaptive PID \u5be6\u4f5c\u908f\u8f2f<\/a><\/li><li class=\"\"><a href=\"#\u74b0\">\u958b\u767c\u74b0\u5883<\/a><\/li><li class=\"\"><a href=\"#\u5c08\u6848\u7d50\u69cb\">\u5c08\u6848\u7d50\u69cb<\/a><\/li><li class=\"\"><a href=\"#e\">Adaptive PID \u63a7\u5236\u5668\u7a0b\u5f0f\u78bc<\/a><\/li><li class=\"\"><a href=\"#\u7de8\u8b6f\u548c\u71d2\u9304-1\">\u7de8\u8b6f\u548c\u71d2\u9304<\/a><\/li><li class=\"\"><a href=\"#\u9019\u6bb5\u7a0b\u5f0f\u78bc\u5c55\u793a\u4e86\u5982\u4f55\u5728-esp-32-\u4e0a\u4f7f\u7528-spi-dma-\u50b3\u8f38\u4f86\u63d0\u5347-tft-lcd\uff08\u4f7f\u7528-st-7789-\u63a7\u5236\u5668\uff09\u986f\u793a\u6548\u7387\uff0c\u4e26\u642d\u914d-lvgl-\u7684-render-\u6982\u5ff5\u5960\u5b9a\u5e95\u5c64\u9ad8\u901f\u5237\u65b0\u80fd\u529b\">\u8f38\u51fa\u8aaa\u660e<\/a><\/li><li class=\"\"><a href=\"#\u7d50\u8ad6\">\u7d50\u8ad6<\/a><\/li><\/ul><\/nav><\/div>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u4ec0\u9ebc\u662f-lvgl-render\uff1f\">\u4ec0\u9ebc\u662f\u81ea\u9069\u61c9 Adaptive PID\uff1f<\/h2>\n\n\n\n<p>\u50b3\u7d71 PID \u63a7\u5236\u5668\u7684\u4e09\u500b\u53c3\u6578\uff1aKp\u3001Ki\u3001Kd \u901a\u5e38\u662f\u56fa\u5b9a\u7684\u3002\u800c\u300c\u81ea\u9069\u61c9 PID\u300d\u7684\u6838\u5fc3\u6982\u5ff5\u662f\u2014\u2014<strong>\u8b93 PID \u53c3\u6578\u96a8\u8457\u7cfb\u7d71\u72c0\u614b\u81ea\u52d5\u8abf\u6574<\/strong>\uff0c\u4f8b\u5982\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u8f15\u8ca0\u8f09\u6642\u964d\u4f4e\u589e\u76ca\u907f\u514d\u9707\u76ea<\/li>\n\n\n\n<li>\u8aa4\u5dee\u5927\u6642\u589e\u52a0 Kp \u52a0\u5feb\u97ff\u61c9<\/li>\n\n\n\n<li>\u7a69\u5b9a\u5340\u81ea\u52d5\u6e1b\u5c11 Ki \u4ee5\u907f\u514d\u8d85\u8abf<\/li>\n<\/ul>\n\n\n\n<p>\u9019\u7a2e\u667a\u6167\u5f0f\u8abf\u6574\u65b9\u5f0f\uff0c\u7279\u5225\u9069\u5408\u63a7\u5236\u5c0d\u8c61\u52d5\u614b\u8b8a\u5316\u5287\u70c8\u7684\u5834\u666f\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"esp-32-\u7684-spi-dma-\u539f\u7406\u7c21\u4ecb\">Adaptive PID \u5be6\u4f5c\u908f\u8f2f<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5efa\u7acb PID \u4efb\u52d9\uff08\u4f7f\u7528 FreeRTOS Task\uff09<\/li>\n\n\n\n<li>\u8b80\u53d6\u5be6\u969b\u8f38\u5165\u503c\uff08\u5982\uff1a\u6eab\u5ea6\u3001\u901f\u5ea6\uff09<\/li>\n\n\n\n<li>\u8f38\u51fa\u63a7\u5236\u8a0a\u865f\uff08PWM \u63a7\u5236\u99ac\u9054\u3001\u98a8\u6247\u6216\u52a0\u71b1\u5668\uff09<\/li>\n\n\n\n<li>\u63a7\u5236\u56de\u5708\u9031\u671f\uff08\u53ef\u7528 Timer \u6216 vTaskDelayUntil() \u7cbe\u6e96\u63a7\u5236\uff09<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u74b0\">\u958b\u767c\u74b0\u5883<\/h2>\n\n\n\n<p>\u5728\u958b\u59cb\u7de8\u7a0b\u4e4b\u524d\uff0c\u8acb\u78ba\u4fdd\u5df2\u5b8c\u6210\u4ee5\u4e0b\u6e96\u5099\u5de5\u4f5c\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/saludpcb.com\/zh\/esp32-tutorial-how-to-create-an-esp32-project-with-vscode\/\">\u5b89\u88dd ESP-IDF \u958b\u767c\u74b0\u5883<\/a> (\u81f3\u5c11\u7248\u672c v5.x \u6216\u66f4\u9ad8)\u3002<\/li>\n\n\n\n<li><a href=\"https:\/\/saludpcb.com\/zh\/esp32-devkit-module-pinout\/\">ESP32 \u958b\u767c\u677f<\/a>\u3002<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u5c08\u6848\u7d50\u69cb\"><strong>\u5c08\u6848\u7d50\u69cb<\/strong><\/h2>\n\n\n\n<p>\u5efa\u7acb\u4e00\u500b\u4e7e\u6de8\u7684 ESP-IDF PID Control \u5c08\u6848\u5982\u4e0b\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">adaptive_pid_voltage\/\n\u251c\u2500\u2500 CMakeLists.txt              # Top-level build script\n\u251c\u2500\u2500 sdkconfig                   # Build-generated config file\n\u251c\u2500\u2500 components\/                 # Reusable modules\n\u2502   \u2514\u2500\u2500 pid_controller\/\n\u2502       \u251c\u2500\u2500 CMakeLists.txt      # PID component build script\n\u2502       \u251c\u2500\u2500 pid_controller.c    # PID algorithm\n\u2502       \u2514\u2500\u2500 pid_controller.h    # PID API\n\u251c\u2500\u2500 main\/\n\u2502   \u251c\u2500\u2500 CMakeLists.txt          # Main app build script\n\u2502   \u251c\u2500\u2500 main.c                  # app_main and task setup\n\u2502   \u2514\u2500\u2500 simulation.c            # Controlled system simulation\n\u2514\u2500\u2500 README.md                   # Project overview<\/code><\/pre>\n\n\n\n<p>\u70ba\u4e86\u8b93\u8b80\u8005\u66f4\u5bb9\u6613\u4e0a\u624b\uff0c\u672c\u7bc4\u4f8b\u5c07 PID \u6f14\u7b97\u6cd5\u3001ADC \u8b80\u53d6\u8207 PWM \u63a7\u5236\u6574\u5408\u65bc\u540c\u4e00\u500b\u6a94\u6848\uff08<code>main.c<\/code>\uff09\u4e2d\u3002\u9019\u6a23\u7684\u5beb\u6cd5\u66f4\u52a0\u76f4\u89c0\uff0c\u65b9\u4fbf\u5feb\u901f\u7406\u89e3\u8207\u793a\u7bc4\uff0c\u9069\u5408\u521d\u5b78\u8005\u5feb\u901f\u638c\u63e1\u6838\u5fc3\u6982\u5ff5\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"e\">Adaptive PID \u63a7\u5236\u5668\u7a0b\u5f0f\u78bc<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"cpp\" class=\"language-cpp\">#include &lt;stdio.h&gt;\n#include &lt;math.h&gt;\n#include \"freertos\/FreeRTOS.h\"\n#include \"freertos\/task.h\"\n#include \"esp_log.h\"\n\nstatic const char *TAG = \"VoltagePID\";\n\n\/\/ PID parameters\nfloat Kp = 1.0f, Ki = 0.5f, Kd = 0.1f;\nfloat setpoint = 100.0f;         \/\/ Target motor speed (RPM)\nfloat integral = 0.0f;\nfloat last_error = 0.0f;\n\n\/\/ Simulated control output voltage (0 ~ 3.3V)\nfloat control_voltage = 0.0f;\n\n\/\/ Simulated feedback value (motor speed)\nfloat motor_speed = 0.0f;\n\nvoid update_pid(float input) {\n    float error = setpoint - input;\n    float delta_error = error - last_error;\n\n    \/\/ Adaptive gain tuning based on error magnitude\n    if (fabsf(error) &gt; 50) {\n        Kp = 2.0f; Ki = 0.7f; Kd = 0.2f;\n    } else if (fabsf(error) &gt; 20) {\n        Kp = 1.5f; Ki = 0.6f; Kd = 0.15f;\n    } else {\n        Kp = 1.0f; Ki = 0.5f; Kd = 0.1f;\n    }\n\n    integral += error;\n    float derivative = delta_error;\n\n    float raw_output = Kp * error + Ki * integral + Kd * derivative;\n\n    \/\/ Simulate control voltage output: clamp between 0V and 3.3V\n    control_voltage = raw_output \/ 100.0f;  \/\/ Scale the output (depends on application)\n    if (control_voltage &gt; 3.3f) control_voltage = 3.3f;\n    if (control_voltage &lt; 0.0f) control_voltage = 0.0f;\n\n    last_error = error;\n\n    \/\/ Log output to monitor behavior\n    ESP_LOGI(TAG, \"[PID] Speed: %.2f RPM | Error: %.2f | Kp: %.2f | Ki: %.2f | Kd: %.2f | Output Voltage: %.2f V\",\n             input, error, Kp, Ki, Kd, control_voltage);\n}\n\n\/\/ Simulate motor response with inertia based on control voltage\nvoid pid_task(void *arg) {\n    while (1) {\n        update_pid(motor_speed);\n\n        \/\/ Simulate motor acceleration (e.g., proportional to voltage)\n        float target_speed = control_voltage * 40.0f; \/\/ e.g., 3.3V -&gt; ~132 RPM\n        motor_speed += (target_speed - motor_speed) * 0.05f;  \/\/ Simulate inertia\/delay\n\n        \/\/ Log the simulated speed for visualization\n        ESP_LOGI(TAG, \"[SIM] Target Speed: %.2f RPM | Current Speed: %.2f RPM\",\n                 target_speed, motor_speed);\n\n        vTaskDelay(pdMS_TO_TICKS(100));  \/\/ Control cycle: 100 ms\n    }\n}\n\nvoid app_main(void) {\n    ESP_LOGI(TAG, \"Starting Voltage-Controlled PID Simulation...\");\n    xTaskCreate(pid_task, \"pid_task\", 4096, NULL, 5, NULL);\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u7de8\u8b6f\u548c\u71d2\u9304-1\">\u7de8\u8b6f\u548c\u71d2\u9304<\/h2>\n\n\n\n<p>\u5b8c\u6210\u7a0b\u5f0f\u78bc\u5f8c\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528 <a href=\"https:\/\/www.espressif.com\/en\/products\/sdks\/esp-idf\" target=\"_blank\" rel=\"noopener\">ESP-IDF<\/a> \u63d0\u4f9b\u7684\u547d\u4ee4\u9032\u884c\u7de8\u8b6f\u3001\u71d2\u9304\u548c\u76e3\u63a7\u3002<\/p>\n\n\n\n<p>\u5728 VS Code \u7684\u5de6\u4e0b\u89d2 ESP-IDF \u5de5\u5177\u5217\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u9ede\u9078 <strong>Build project<\/strong><\/li>\n\n\n\n<li>\u9ede\u9078 <strong>Flash device<\/strong><\/li>\n\n\n\n<li>\u9ede\u9078 <strong>Monitor device<\/strong><\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u9019\u6bb5\u7a0b\u5f0f\u78bc\u5c55\u793a\u4e86\u5982\u4f55\u5728-esp-32-\u4e0a\u4f7f\u7528-spi-dma-\u50b3\u8f38\u4f86\u63d0\u5347-tft-lcd\uff08\u4f7f\u7528-st-7789-\u63a7\u5236\u5668\uff09\u986f\u793a\u6548\u7387\uff0c\u4e26\u642d\u914d-lvgl-\u7684-render-\u6982\u5ff5\u5960\u5b9a\u5e95\u5c64\u9ad8\u901f\u5237\u65b0\u80fd\u529b\">\u8f38\u51fa\u8aaa\u660e<\/h2>\n\n\n\n<p>\u4ee5\u4e0b\u662f\u6a21\u64ec\u63a7\u5236\u904e\u7a0b\u4e2d\u7684\u90e8\u4efd log \u8f38\u51fa\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">I (0) VoltagePID: Starting Voltage-Controlled PID Simulation\u2026\nI (100) VoltagePID: [PID] Speed: 0.00 RPM | Error: 100.00 | Kp: 2.00 | Ki: 0.70 | Kd: 0.20 | Output Voltage: 3.30 V\nI (100) VoltagePID: [SIM] Target Speed: 132.00 RPM | Current Speed: 6.60 RPM\nI (200) VoltagePID: [PID] Speed: 6.60 RPM | Error: 93.40 | Kp: 2.00 | Ki: 0.70 | Kd: 0.20 | Output Voltage: 3.30 V\n\u2026\nI (1000) VoltagePID: [PID] Speed: 85.60 RPM | Error: 14.40 | Kp: 1.00 | Ki: 0.50 | Kd: 0.10 | Output Voltage: 1.82 V\nI (1000) VoltagePID: [SIM] Target Speed: 72.80 RPM | Current Speed: 74.00 RPM\n\u2026\nI (2000) VoltagePID: [PID] Speed: 98.20 RPM | Error: 1.80 | Kp: 1.00 | Ki: 0.50 | Kd: 0.10 | Output Voltage: 1.04 V\nI (2000) VoltagePID: [SIM] Target Speed: 41.60 RPM | Current Speed: 97.00 RPM<\/code><\/pre>\n\n\n\n<p>\u5206\u6790\u8207\u8aaa\u660e\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5927\u8aa4\u5dee\u6642\u5feb\u901f\u97ff\u61c9\uff08\u8d77\u59cb\u968e\u6bb5\uff09<br>\u4e00\u958b\u59cb\u99ac\u9054\u5c1a\u672a\u8f49\u52d5\uff0c\u901f\u5ea6\u70ba 0 RPM\uff0c\u8aa4\u5dee\u9054 100\u3002\u6b64\u6642 Adaptive PID \u81ea\u52d5\u5c07\u589e\u76ca\u8abf\u9ad8\uff08Kp=2.0\uff09\uff0c\u4f7f\u8f38\u51fa\u96fb\u58d3\u76f4\u63a5\u98fd\u548c\u5230 3.3V\uff0c\u7cfb\u7d71\u52a0\u901f\u5feb\u901f\uff0c\u7e2e\u77ed\u53cd\u61c9\u6642\u9593\u3002<\/li>\n\n\n\n<li>\u4e2d\u9593\u8aa4\u5dee\u968e\u6bb5\uff0c\u63a7\u5236\u7a69\u5b9a<br>\u7576\u901f\u5ea6\u9032\u5165\u4e2d\u9593\u5340\u6bb5\uff0c\u4f8b\u5982\u8aa4\u5dee\u7d04 20~50 \u6642\uff0c\u589e\u76ca\u5207\u63db\u70ba\u4e2d\u7b49\uff08Kp=1.5\uff09\uff0c\u96fb\u58d3\u8f38\u51fa\u4e5f\u958b\u59cb\u964d\u4f4e\uff0c\u7cfb\u7d71\u63a7\u5236\u9032\u5165\u300c\u5feb\u901f\u6536\u6582\u3001\u4f46\u907f\u514d\u904e\u885d\u300d\u7684\u5e73\u8861\u72c0\u614b\u3002<\/li>\n\n\n\n<li>\u5c0f\u8aa4\u5dee\u6642\u7cbe\u7d30\u5fae\u8abf<br>\u7576\u8aa4\u5dee\u5c0f\u65bc 20\uff08\u5982 10 \u4ee5\u4e0b\uff09\uff0c\u63a7\u5236\u5668\u81ea\u52d5\u8abf\u6574\u56de\u8f03\u5c0f\u589e\u76ca\uff08Kp=1.0\uff09\uff0c\u907f\u514d\u9707\u76ea\u8207\u904e\u8abf\uff0c\u8b93\u99ac\u9054\u5e73\u7a69\u6536\u6582\u81f3\u8a2d\u5b9a\u503c\u9644\u8fd1\uff0c\u63a7\u5236\u96fb\u58d3\u4e5f\u76f8\u5c0d\u66f4\u5e73\u6ed1\u3002<\/li>\n\n\n\n<li>\u81ea\u52d5\u589e\u76ca\u8abf\u6574\u907f\u514d\u624b\u52d5\u8abf\u53c3<br>\u6574\u500b\u904e\u7a0b\u4e2d\uff0c\u7121\u9700\u958b\u767c\u8005\u624b\u52d5\u8abf\u6574 PID \u53c3\u6578\u3002Adaptive PID \u6839\u64da\u8aa4\u5dee\u7bc4\u570d\u52d5\u614b\u8abf\u6574\u53c3\u6578\uff0c\u8b93\u7cfb\u7d71\u65e2\u6709\u97ff\u61c9\u901f\u5ea6\uff0c\u53c8\u80fd\u907f\u514d\u9707\u76ea\u6216\u4e0d\u7a69\u3002<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"\u7d50\u8ad6\">\u7d50\u8ad6<\/h2>\n\n\n\n<p>\u6211\u5011\u900f\u904e ESP32 \u5be6\u4f5c Adaptive PID\uff0c\u4e0d\u50c5\u6210\u529f\u5c55\u793a\u4e86\u81ea\u52d5\u8abf\u6574\u63a7\u5236\u53c3\u6578\u7684\u80fd\u529b\uff0c\u4e5f\u8b49\u660e\u4e86\u5176\u5728\u5feb\u901f\u97ff\u61c9\u8207\u7a69\u5b9a\u6536\u6582\u9593\u53d6\u5f97\u826f\u597d\u5e73\u8861\u3002\u6574\u9ad4\u7cfb\u7d71\u80fd\u5920\u6839\u64da\u8aa4\u5dee\u5927\u5c0f\u52d5\u614b\u8abf\u6574\u589e\u76ca\uff0c\u6709\u6548\u52a0\u901f\u6536\u6582\u4e26\u6291\u5236\u9707\u76ea\uff0c\u8b93\u63a7\u5236\u5668\u5728\u9762\u5c0d\u5be6\u969b\u74b0\u5883\u8b8a\u52d5\u6642\u4f9d\u7136\u4fdd\u6301\u7cbe\u6e96\u63a7\u5236\u3002\u4ee5\u96fb\u58d3\u63a7\u5236\u6a21\u64ec\u99ac\u9054\u8f49\u901f\u70ba\u4f8b\uff0c\u6211\u5011\u770b\u898b\u7cfb\u7d71\u80fd\u6839\u64da\u8aa4\u5dee\u5927\u5c0f\u52d5\u614b\u6539\u8b8a\u589e\u76ca\uff0c\u6709\u6548\u964d\u4f4e\u904e\u885d\u8207\u9707\u76ea\uff0c\u540c\u6642\u52a0\u5feb\u6536\u6582\u901f\u5ea6\u3002\u9019\u7a2e\u81ea\u9069\u61c9\u8abf\u6574\u65b9\u6cd5\uff0c\u4e0d\u50c5\u63d0\u5347\u4e86 PID \u63a7\u5236\u5668\u7684\u5f48\u6027\uff0c\u4e5f\u4f7f\u63a7\u5236\u7cfb\u7d71\u66f4\u9069\u5408\u9762\u5c0d\u5be6\u52d9\u4e2d\u4e0d\u78ba\u5b9a\u7684\u74b0\u5883\u8b8a\u5316\u3002\u672a\u4f86\u53ef\u5c07\u6b64\u67b6\u69cb\u64f4\u5c55\u81f3\u6eab\u5ea6\u3001\u5149\u5f37\u6216\u5176\u4ed6\u7269\u7406\u91cf\u63a7\u5236\uff0c\u4e26\u7d50\u5408\u5be6\u9ad4 ADC \u56de\u6388\u8207 PWM \u8f38\u51fa\uff0c\u9032\u4e00\u6b65\u9a57\u8b49\u4e26\u61c9\u7528\u65bc\u771f\u5be6\u786c\u9ad4\u7cfb\u7d71\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator alignwide has-text-color has-palette-color-1-color has-alpha-channel-opacity has-palette-color-1-background-color has-background is-style-wide\"\/>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Adaptive PID\uff08\u6bd4\u4f8b-\u7a4d\u5206-\u5fae\u5206\uff09\u81ea\u9069\u61c9 PID\uff0c\u5728\u50b3\u7d71 PID \u63a7\u5236\u5668\u5728\u5de5\u696d\u8207\u5d4c\u5165\u5f0f\u9818\u57df\u61c9\u7528\u5ee3\u6cdb\uff0c [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":3638,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,53,83],"tags":[27,21,44,9,11],"class_list":["post-3623","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-module","category-esp32","category-featured","tag-c","tag-ide","tag-programming-language","tag-python","tag-tutorial"],"blocksy_meta":[],"_links":{"self":[{"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/posts\/3623","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/comments?post=3623"}],"version-history":[{"count":20,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/posts\/3623\/revisions"}],"predecessor-version":[{"id":3649,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/posts\/3623\/revisions\/3649"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/media\/3638"}],"wp:attachment":[{"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/media?parent=3623"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/categories?post=3623"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/saludpcb.com\/zh\/wp-json\/wp\/v2\/tags?post=3623"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}