{
  "appVersion": "0.10.0",
  "savedAt": "2026-09-29T08:18:17.185Z",
  "workspace": {
    "blocks": {
      "languageVersion": 0,
      "blocks": [
        {
          "type": "controls_whileUntil",
          "id": "9gI5h!We.y?3-Jj|x%9g",
          "x": 228,
          "y": 276,
          "fields": {
            "MODE": "WHILE"
          },
          "inputs": {
            "BOOL": {
              "block": {
                "type": "logic_boolean",
                "id": "Fgwi=3WlAT`}L`*DShEN",
                "fields": {
                  "BOOL": "TRUE"
                }
              }
            },
            "DO": {
              "block": {
                "type": "apm_mini_rpm",
                "id": "eHm9.+]e#l?1F;KTyqsk",
                "inputs": {
                  "LEFT": {
                    "shadow": {
                      "type": "math_number",
                      "id": "Pt!-QQ//Xq:d`0icPZb$",
                      "fields": {
                        "NUM": 30
                      }
                    }
                  },
                  "RIGHT": {
                    "shadow": {
                      "type": "math_number",
                      "id": "qba7[#C@7Pac/?LQb=s-",
                      "fields": {
                        "NUM": 30
                      }
                    }
                  }
                },
                "next": {
                  "block": {
                    "type": "controls_if",
                    "id": "0w-VB`Vo*tnn!mS42=e_",
                    "inputs": {
                      "IF0": {
                        "block": {
                          "type": "logic_operation",
                          "id": "^%$S2JHNm?MBe*DUNo*p",
                          "fields": {
                            "OP": "OR"
                          },
                          "inputs": {
                            "A": {
                              "block": {
                                "type": "logic_compare",
                                "id": "f}:z5aSi~jFe95/g|7/v",
                                "fields": {
                                  "OP": "LT"
                                },
                                "inputs": {
                                  "A": {
                                    "block": {
                                      "type": "apm_mini_sensor",
                                      "id": "wklb_2ezRV]tWuN!d?7G",
                                      "fields": {
                                        "CH": "1"
                                      }
                                    }
                                  },
                                  "B": {
                                    "block": {
                                      "type": "math_number",
                                      "id": "H8P|s(;5FA`fOq-yB@2u",
                                      "icons": {
                                        "comment": {
                                          "text": "根据实际情况调整",
                                          "pinned": false,
                                          "height": 80,
                                          "width": 161.86669921875
                                        }
                                      },
                                      "fields": {
                                        "NUM": 40
                                      }
                                    }
                                  }
                                }
                              }
                            },
                            "B": {
                              "block": {
                                "type": "logic_operation",
                                "id": "}]#Eo#1FO._^@(A}sK0-",
                                "fields": {
                                  "OP": "OR"
                                },
                                "inputs": {
                                  "A": {
                                    "block": {
                                      "type": "logic_compare",
                                      "id": "9%Mu~6G61mvX(HVWj(9A",
                                      "fields": {
                                        "OP": "LT"
                                      },
                                      "inputs": {
                                        "A": {
                                          "block": {
                                            "type": "apm_mini_sensor",
                                            "id": "Ej8.i5.yOqc=_Rg7Ts#T",
                                            "fields": {
                                              "CH": "3"
                                            }
                                          }
                                        },
                                        "B": {
                                          "block": {
                                            "type": "math_number",
                                            "id": "8XfdwyY]r%Gj[l=N3j1K",
                                            "icons": {
                                              "comment": {
                                                "text": "根据实际情况调整",
                                                "pinned": false,
                                                "height": 80,
                                                "width": 161.86669921875
                                              }
                                            },
                                            "fields": {
                                              "NUM": 40
                                            }
                                          }
                                        }
                                      }
                                    }
                                  },
                                  "B": {
                                    "block": {
                                      "type": "logic_compare",
                                      "id": "Z%O$G=#PatXBq12_[H@6",
                                      "fields": {
                                        "OP": "LT"
                                      },
                                      "inputs": {
                                        "A": {
                                          "block": {
                                            "type": "apm_mini_sensor",
                                            "id": "8g^38s6[=jRCxH9=Msa3",
                                            "fields": {
                                              "CH": "5"
                                            }
                                          }
                                        },
                                        "B": {
                                          "block": {
                                            "type": "math_number",
                                            "id": "$saaFnW@Es@!1t.aXyP%",
                                            "icons": {
                                              "comment": {
                                                "text": "根据实际情况调整",
                                                "pinned": false,
                                                "height": 80,
                                                "width": 161.86669921875
                                              }
                                            },
                                            "fields": {
                                              "NUM": 40
                                            }
                                          }
                                        }
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      },
                      "DO0": {
                        "block": {
                          "type": "apm_mini_stop",
                          "id": "0Uw$MrDJWT;TUb-_4xZ{",
                          "fields": {
                            "MOTOR": "0"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      ]
    },
    "variables": [
      {
        "name": "黑线数量",
        "id": "YeD-ml+PJ|I)JF}it|-n"
      }
    ]
  },
  "python": "import drive\nimport light\n\n\nwhile True:\n  drive.drive_rpm(30, 30)\n  if light.get_optical_sensor(1) < 40 or light.get_optical_sensor(3) < 40 or light.get_optical_sensor(5) < 40:\n    drive.stop_rpm(0)\n",
  "programmingMode": "blocks"
}