{
  "schemaVersion": "1.0",
  "item": {
    "slug": "megasquirt-tuner",
    "name": "MegaSquirt Tuner",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/boblobclaw/megasquirt-tuner",
    "canonicalUrl": "https://clawhub.ai/boblobclaw/megasquirt-tuner",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/megasquirt-tuner",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=megasquirt-tuner",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "README.md",
      "SKILL.md",
      "scripts/analyze_msq.py",
      "references/tunerstudio-reference.md",
      "references/megasquirt-tuning-guide.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Then review README.md for any prerequisites, environment setup, or post-install checks. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Then review README.md for any prerequisites, environment setup, or post-install checks. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/megasquirt-tuner"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/megasquirt-tuner",
    "agentPageUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent",
    "manifestUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Then review README.md for any prerequisites, environment setup, or post-install checks. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Then review README.md for any prerequisites, environment setup, or post-install checks. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Megasquirt ECU Tuning with TunerStudio",
        "body": "Guidance for tuning Megasquirt engine management systems using TunerStudio software."
      },
      {
        "title": "Required Fuel Equation",
        "body": "Megasquirt calculates fuel delivery using:\n\nPulse Width = Required Fuel × VE% × MAP × AFR Target Correction × Air Density × Warmup × Accel Enrichment × Other Corrections\n\nRequired Fuel is the base injector pulse width at 100% VE, 100kPa MAP, standard temperature."
      },
      {
        "title": "Key Tuning Tables",
        "body": "TablePurposeTypical ResolutionVE TableVolumetric efficiency vs RPM/MAP16×16 or 12×12AFR TargetDesired air-fuel ratio vs RPM/MAP12×12Spark AdvanceIgnition timing vs RPM/MAP12×12 or 16×16Warmup EnrichmentFuel correction vs coolant temp10-20 pointsTPS-based AccelAccel enrichment vs TPSdot10-20 pointsMAP-based AccelAccel enrichment vs MAPdot10-20 points"
      },
      {
        "title": "1. Base Configuration",
        "body": "Before tuning, verify:\n\nEngine displacement and cylinder count\nInjector flow rate (cc/min or lb/hr)\nInjector staging (simultaneous, alternating, sequential)\nRequired Fuel calculation matches injector size\nIgnition input/output settings match hardware\nTrigger wheel and ignition mode configured"
      },
      {
        "title": "2. Sensor Calibration",
        "body": "Calibrate sensors before tuning:\n\nCLT (Coolant Temp): Set resistance values at known temps\nIAT (Intake Air Temp): Similar to CLT\nTPS: Set closed and WOT positions (0-100%)\nMAP: Verify atmospheric reading at key-on\nO2 Sensor: Calibrate wideband controller output range"
      },
      {
        "title": "3. VE Table Tuning (Speed Density)",
        "body": "Method 1: Wideband O2 Feedback\n\nEnable EGO correction with moderate authority (±15-20%)\nSet realistic AFR targets\nRun engine at steady state (fixed RPM/load cell)\nAllow EGO to correct, note correction percentage\nAdjust VE by inverse of correction (if +10% correction, increase VE by 10%)\nSave and move to next cell\n\nMethod 2: Calculate from Measured AFR\n\nNew VE = Current VE × (Measured AFR / Target AFR)\n\nTuning Order:\n\nStart with idle region (600-1000 RPM, 30-50kPa)\nLight cruise (1500-2500 RPM, 40-60kPa)\nPart throttle acceleration\nWOT high load\nTransition regions"
      },
      {
        "title": "4. AFR Target Table",
        "body": "Set targets based on application:\n\nConditionTarget AFRLambdaIdle13.5-14.50.92-0.99Light Cruise14.5-15.50.99-1.06Part Throttle13.5-14.50.92-0.99WOT Naturally Aspirated12.5-13.00.85-0.88WOT Turbo/Supercharged11.5-12.50.78-0.85"
      },
      {
        "title": "5. Ignition Timing",
        "body": "Base Settings:\n\nSet cranking advance (typically 10-20° BTDC)\nSet idle advance (typically 15-25° BTDC)\nBuild spark table following engine-specific guidelines\n\nTypical Spark Advance Table (Naturally Aspirated):\n\nLow RPM/High Load: 10-20°\nLow RPM/Low Load: 25-35°\nHigh RPM/High Load: 25-35°\nHigh RPM/Low Load: 35-45°\n\nKnock Considerations:\n\nReduce timing 1-2° at a time if knock detected\nAdd more fuel in knock-prone areas\nUse knock sensor feedback if available"
      },
      {
        "title": "6. Idle Control",
        "body": "Idle Valve PWM Settings:\n\nClosed position: PWM at hot idle (typically 20-40%)\nOpen position: PWM for cold start (typically 60-80%)\nCranking position: PWM during start (typically 50-70%)\n\nIdle Target RPM Table:\n\nHot: 700-900 RPM\nCold (0°C): 1200-1500 RPM\nInterpolate between"
      },
      {
        "title": "7. Warmup Enrichment",
        "body": "Afterstart Enrichment:\n\nDuration: 30-200 cycles (engine revolutions)\nAmount: 20-40% additional fuel\nTaper to zero over duration\n\nWarmup Enrichment Curve:\n\n-40°C: 150-200%\n0°C: 120-140%\n70°C (operating): 100%"
      },
      {
        "title": "8. Acceleration Enrichment",
        "body": "TPS-based (Alpha-N blending):\n\nThreshold: 5-10%/sec TPSdot\nEnrichment: 10-30% added fuel\nDecay: 0.5-2 seconds\n\nMAP-based (for MAP-dot systems):\n\nThreshold: 10-30 kPa/sec\nEnrichment scales with rate of change\n\nCold Multiplier:\n\nIncrease accel enrichment when cold (1.5-3× at -20°C)"
      },
      {
        "title": "Boost Control",
        "body": "Open Loop:\n\nDuty cycle table vs RPM/target boost\n\nClosed Loop (if supported):\n\nPID parameters for wastegate control\nTarget boost table vs RPM/gear"
      },
      {
        "title": "Launch Control",
        "body": "Set RPM limit (typically 4000-6000 RPM)\nConfigure retard timing during launch (0-10° BTDC)\nSet fuel/ignition cut method"
      },
      {
        "title": "Flat Shift",
        "body": "Maintain throttle during shifts\nBrief fuel/ignition cut at shift point\nRetain boost between gears"
      },
      {
        "title": "Key Parameters to Log",
        "body": "ParameterWhat to WatchRPMStability, limiter hitsMAPResponse to throttle, leaksAFR (wideband)Deviation from targetEGO CorrectionShould stay within ±10%CLTReaches operating tempIATHeat soak effectsSpark AdvanceMatches tableInjector PWHeadroom, max duty cycleTPSSmooth operation, TPSdot"
      },
      {
        "title": "Common Issues",
        "body": "Lean at Tip-In:\n\nIncrease TPS-based accel enrichment\nCheck MAPdot sensitivity\n\nRich at Decel:\n\nEnable deceleration fuel cut (DFCO)\nSet appropriate TPS threshold (typically <10%)\nSet RPM threshold above idle\n\nIdle Hunting:\n\nCheck for vacuum leaks\nAdjust idle PID gains\nVerify TPS closed position\nCheck ignition timing stability\n\nKnock at High Load:\n\nReduce spark advance in affected cells\nEnrich mixture (reduce target AFR)"
      },
      {
        "title": "Project Setup",
        "body": "Create new project → select firmware (MS1, MS2, MS3)\nLoad base tune (.msq file) or start from default\nConnect to controller (serial, USB, or Bluetooth)\nSync with controller to load current settings"
      },
      {
        "title": "Tuning Interface",
        "body": "Basic/Customize Tuning: Navigate tables\nTable: View/edit individual tables\nRuntime Data: Real-time monitoring\nDatalog: Record and playback logs"
      },
      {
        "title": "Auto-Tune",
        "body": "Enable VEAL (VE Analyze Live) with wideband\nSet acceptable AFR range\nDrive through as many cells as possible\nReview and accept changes\nDisable when done"
      },
      {
        "title": "Safety Limits",
        "body": "Rev Limiter:\n\nSoft limit: retard timing\nHard limit: fuel/ignition cut\nSet 200-500 RPM above max desired\n\nOverboost Protection:\n\nFuel cut above target pressure\nIgnition cut option\n\nLean Cut:\n\nDisable injectors if AFR exceeds safe threshold\nTypically 15:1+ under load"
      },
      {
        "title": "MSQ Tune File Analysis",
        "body": "The skill can analyze .msq tune files to identify safety issues, optimization opportunities, and configuration problems."
      },
      {
        "title": "Using the Analyzer",
        "body": "Run the analysis script on any MSQ file:\n\npython3 scripts/analyze_msq.py your_tune.msq\n\nOr provide the tune file content directly for analysis."
      },
      {
        "title": "How to Provide the MSQ File",
        "body": "Option 1: Paste the file content (Recommended)\n\nOpen the .msq file in a text editor (it's plain text)\nCopy the entire content\nPaste it directly into the chat: \"Analyze this MSQ file: [paste content]\"\n\nOption 2: Upload the file\n\nIf your chat interface supports file attachments, attach the .msq file directly\nThe skill will read and analyze it\n\nOption 3: Provide a file path (if running locally)\n\npython3 scripts/analyze_msq.py /path/to/your/tune.msq\n\nSecurity Restrictions for Script Usage:\n\nOnly files with .msq extension are accepted\nPath traversal sequences (../) are blocked\nSymbolic links are not allowed\nFile must be a regular text file (not binary)\n\nOption 4: Share key sections\nIf the file is large, paste specific sections you're concerned about:\n\n[veTable1] section for fuel map review\n[sparkTable1] for ignition timing\n[afrTable1] for AFR targets\n[revLimiter] for safety limits"
      },
      {
        "title": "Example Prompts",
        "body": "\"Review this MSQ file for safety issues before I start my engine: [paste content]\"\n\n\"Check my VE table - does anything look suspicious? [paste veTable section]\"\n\n\"Analyze my ignition timing map for knock risk: [paste sparkTable section]\"\n\n\"I just updated my AFR targets, review them: [paste afrTable section]\""
      },
      {
        "title": "What Gets Analyzed",
        "body": "Safety Checks:\n\n🚨 Critical: AFR targets that could cause engine damage, excessive ignition timing\n⚠️ Warnings: Rev limiter not configured, suspicious VE values, high injector duty\n\nConfiguration Review:\n\nRequired fuel calculation sanity check\nVE table range and smoothness\nAFR target appropriateness for NA vs forced induction\nIgnition timing ranges and knock risk assessment\nCranking pulse widths\nWarmup enrichment curve\nSafety limits (rev limiter, overboost)\n\nOptimization Opportunities:\n\nInjector duty cycle headroom\nVE table smoothness (sudden jumps)\nConservative vs aggressive timing maps"
      },
      {
        "title": "Interpreting Results",
        "body": "Example Analysis Output:\n\n📋 VE Table\n----------------------------------------\n  ⚠️ VE table has very low values (15.0) - check for empty/untuned cells\n  📊 12 cells have >30% jumps from neighbors - consider smoothing\n  ✓ VE table range: 15.0 - 105.0 (avg: 62.3)\n\n📋 Ignition Timing\n----------------------------------------\n  ⚠️ High ignition advance (48°) - verify on dyno with knock detection\n  ✓ Spark advance range: 8° - 48° BTDC\n\nSUMMARY\n============================================================\n🚨 CRITICAL ISSUES: 0\n⚠️  WARNINGS: 2\n✓ Suggestions: 4\nℹ️  Notes: 1"
      },
      {
        "title": "Common Issues Detected",
        "body": "High Priority:\n\nNo rev limiter configured\nLean AFR targets under load (>14.0:1 at WOT)\nIgnition timing >45° (severe knock risk)\nEstimated injector duty >90%\n\nMedium Priority:\n\nVE values <20 or >120\nLarge jumps between adjacent cells (>30%)\nMissing warmup enrichment taper\nCranking PW too high/low for conditions\n\nLow Priority:\n\nConservative timing that may leave power on table\nOverly rich AFR targets\nExcessive injector headroom"
      },
      {
        "title": "Tune Review Workflow",
        "body": "Before First Start:\nYou: \"Review this base tune before I start the engine\"\nAI: [Runs analysis, flags safety issues]\n\n\n\nAfter Changes:\nYou: \"I just updated my VE table, check it\"\nAI: [Analyzes for anomalies, suggests smoothing]\n\n\n\nBefore Dyno/Track:\nYou: \"Review my tune before high load testing\"\nAI: [Checks timing, AFR, safety limits, injector headroom]"
      },
      {
        "title": "Reference Materials",
        "body": "For detailed documentation, see:\n\nreferences/tunerstudio-reference.md - Full TunerStudio documentation\nreferences/megasquirt-tuning-guide.md - Comprehensive tuning procedures"
      },
      {
        "title": "Quick Reference Formulas",
        "body": "Injector Duty Cycle:\n\nDC% = (Injector PW / Injection Period) × 100\n\nKeep under 85% for safety margin.\n\nRequired Fuel Calculation:\n\nRequired Fuel (ms) = (Engine CC × 5) / (Number of Injectors × Injector CC/Min) × 2\n\n(The ×2 accounts for 2 rotations per cycle)\n\nAirflow Estimation:\n\nMAF (g/s) ≈ (RPM × Displacement × VE% × MAP/100) / (2 × 60 × R × Temp)"
      },
      {
        "title": "Safety Checklist",
        "body": "Before starting engine:\n\nInjector flow rate correct in settings\n Ignition timing verified with timing light\n Fuel pump primes and holds pressure\n No fuel leaks\n Wideband O2 sensor warmed up\n Emergency fuel/ignition cut accessible\n\nDuring tuning:\n\nMonitor EGT if available\n Listen for detonation/knock\n Watch AFR on transitions\n Keep VE table changes conservative\n Save tune frequently with version notes"
      }
    ],
    "body": "Megasquirt ECU Tuning with TunerStudio\n\nGuidance for tuning Megasquirt engine management systems using TunerStudio software.\n\nCore Concepts\nRequired Fuel Equation\n\nMegasquirt calculates fuel delivery using:\n\nPulse Width = Required Fuel × VE% × MAP × AFR Target Correction × Air Density × Warmup × Accel Enrichment × Other Corrections\n\n\nRequired Fuel is the base injector pulse width at 100% VE, 100kPa MAP, standard temperature.\n\nKey Tuning Tables\nTable\tPurpose\tTypical Resolution\nVE Table\tVolumetric efficiency vs RPM/MAP\t16×16 or 12×12\nAFR Target\tDesired air-fuel ratio vs RPM/MAP\t12×12\nSpark Advance\tIgnition timing vs RPM/MAP\t12×12 or 16×16\nWarmup Enrichment\tFuel correction vs coolant temp\t10-20 points\nTPS-based Accel\tAccel enrichment vs TPSdot\t10-20 points\nMAP-based Accel\tAccel enrichment vs MAPdot\t10-20 points\nTuning Workflow\n1. Base Configuration\n\nBefore tuning, verify:\n\nEngine displacement and cylinder count\nInjector flow rate (cc/min or lb/hr)\nInjector staging (simultaneous, alternating, sequential)\nRequired Fuel calculation matches injector size\nIgnition input/output settings match hardware\nTrigger wheel and ignition mode configured\n2. Sensor Calibration\n\nCalibrate sensors before tuning:\n\nCLT (Coolant Temp): Set resistance values at known temps\nIAT (Intake Air Temp): Similar to CLT\nTPS: Set closed and WOT positions (0-100%)\nMAP: Verify atmospheric reading at key-on\nO2 Sensor: Calibrate wideband controller output range\n3. VE Table Tuning (Speed Density)\n\nMethod 1: Wideband O2 Feedback\n\nEnable EGO correction with moderate authority (±15-20%)\nSet realistic AFR targets\nRun engine at steady state (fixed RPM/load cell)\nAllow EGO to correct, note correction percentage\nAdjust VE by inverse of correction (if +10% correction, increase VE by 10%)\nSave and move to next cell\n\nMethod 2: Calculate from Measured AFR\n\nNew VE = Current VE × (Measured AFR / Target AFR)\n\n\nTuning Order:\n\nStart with idle region (600-1000 RPM, 30-50kPa)\nLight cruise (1500-2500 RPM, 40-60kPa)\nPart throttle acceleration\nWOT high load\nTransition regions\n4. AFR Target Table\n\nSet targets based on application:\n\nCondition\tTarget AFR\tLambda\nIdle\t13.5-14.5\t0.92-0.99\nLight Cruise\t14.5-15.5\t0.99-1.06\nPart Throttle\t13.5-14.5\t0.92-0.99\nWOT Naturally Aspirated\t12.5-13.0\t0.85-0.88\nWOT Turbo/Supercharged\t11.5-12.5\t0.78-0.85\n5. Ignition Timing\n\nBase Settings:\n\nSet cranking advance (typically 10-20° BTDC)\nSet idle advance (typically 15-25° BTDC)\nBuild spark table following engine-specific guidelines\n\nTypical Spark Advance Table (Naturally Aspirated):\n\nLow RPM/High Load: 10-20°\nLow RPM/Low Load: 25-35°\nHigh RPM/High Load: 25-35°\nHigh RPM/Low Load: 35-45°\n\nKnock Considerations:\n\nReduce timing 1-2° at a time if knock detected\nAdd more fuel in knock-prone areas\nUse knock sensor feedback if available\n6. Idle Control\n\nIdle Valve PWM Settings:\n\nClosed position: PWM at hot idle (typically 20-40%)\nOpen position: PWM for cold start (typically 60-80%)\nCranking position: PWM during start (typically 50-70%)\n\nIdle Target RPM Table:\n\nHot: 700-900 RPM\nCold (0°C): 1200-1500 RPM\nInterpolate between\n7. Warmup Enrichment\n\nAfterstart Enrichment:\n\nDuration: 30-200 cycles (engine revolutions)\nAmount: 20-40% additional fuel\nTaper to zero over duration\n\nWarmup Enrichment Curve:\n\n-40°C: 150-200%\n0°C: 120-140%\n70°C (operating): 100%\n8. Acceleration Enrichment\n\nTPS-based (Alpha-N blending):\n\nThreshold: 5-10%/sec TPSdot\nEnrichment: 10-30% added fuel\nDecay: 0.5-2 seconds\n\nMAP-based (for MAP-dot systems):\n\nThreshold: 10-30 kPa/sec\nEnrichment scales with rate of change\n\nCold Multiplier:\n\nIncrease accel enrichment when cold (1.5-3× at -20°C)\nAdvanced Features\nBoost Control\n\nOpen Loop:\n\nDuty cycle table vs RPM/target boost\n\nClosed Loop (if supported):\n\nPID parameters for wastegate control\nTarget boost table vs RPM/gear\nLaunch Control\nSet RPM limit (typically 4000-6000 RPM)\nConfigure retard timing during launch (0-10° BTDC)\nSet fuel/ignition cut method\nFlat Shift\nMaintain throttle during shifts\nBrief fuel/ignition cut at shift point\nRetain boost between gears\nDatalog Analysis\nKey Parameters to Log\nParameter\tWhat to Watch\nRPM\tStability, limiter hits\nMAP\tResponse to throttle, leaks\nAFR (wideband)\tDeviation from target\nEGO Correction\tShould stay within ±10%\nCLT\tReaches operating temp\nIAT\tHeat soak effects\nSpark Advance\tMatches table\nInjector PW\tHeadroom, max duty cycle\nTPS\tSmooth operation, TPSdot\nCommon Issues\n\nLean at Tip-In:\n\nIncrease TPS-based accel enrichment\nCheck MAPdot sensitivity\n\nRich at Decel:\n\nEnable deceleration fuel cut (DFCO)\nSet appropriate TPS threshold (typically <10%)\nSet RPM threshold above idle\n\nIdle Hunting:\n\nCheck for vacuum leaks\nAdjust idle PID gains\nVerify TPS closed position\nCheck ignition timing stability\n\nKnock at High Load:\n\nReduce spark advance in affected cells\nEnrich mixture (reduce target AFR)\nTunerStudio Specific\nProject Setup\nCreate new project → select firmware (MS1, MS2, MS3)\nLoad base tune (.msq file) or start from default\nConnect to controller (serial, USB, or Bluetooth)\nSync with controller to load current settings\nTuning Interface\nBasic/Customize Tuning: Navigate tables\nTable: View/edit individual tables\nRuntime Data: Real-time monitoring\nDatalog: Record and playback logs\nAuto-Tune\nEnable VEAL (VE Analyze Live) with wideband\nSet acceptable AFR range\nDrive through as many cells as possible\nReview and accept changes\nDisable when done\nSafety Limits\n\nRev Limiter:\n\nSoft limit: retard timing\nHard limit: fuel/ignition cut\nSet 200-500 RPM above max desired\n\nOverboost Protection:\n\nFuel cut above target pressure\nIgnition cut option\n\nLean Cut:\n\nDisable injectors if AFR exceeds safe threshold\nTypically 15:1+ under load\nMSQ Tune File Analysis\n\nThe skill can analyze .msq tune files to identify safety issues, optimization opportunities, and configuration problems.\n\nUsing the Analyzer\n\nRun the analysis script on any MSQ file:\n\npython3 scripts/analyze_msq.py your_tune.msq\n\n\nOr provide the tune file content directly for analysis.\n\nHow to Provide the MSQ File\n\nOption 1: Paste the file content (Recommended)\n\nOpen the .msq file in a text editor (it's plain text)\nCopy the entire content\nPaste it directly into the chat: \"Analyze this MSQ file: [paste content]\"\n\nOption 2: Upload the file\n\nIf your chat interface supports file attachments, attach the .msq file directly\nThe skill will read and analyze it\n\nOption 3: Provide a file path (if running locally)\n\npython3 scripts/analyze_msq.py /path/to/your/tune.msq\n\n\nSecurity Restrictions for Script Usage:\n\nOnly files with .msq extension are accepted\nPath traversal sequences (../) are blocked\nSymbolic links are not allowed\nFile must be a regular text file (not binary)\n\nOption 4: Share key sections If the file is large, paste specific sections you're concerned about:\n\n[veTable1] section for fuel map review\n[sparkTable1] for ignition timing\n[afrTable1] for AFR targets\n[revLimiter] for safety limits\nExample Prompts\n\"Review this MSQ file for safety issues before I start my engine: [paste content]\"\n\n\"Check my VE table - does anything look suspicious? [paste veTable section]\"\n\n\"Analyze my ignition timing map for knock risk: [paste sparkTable section]\"\n\n\"I just updated my AFR targets, review them: [paste afrTable section]\"\n\nWhat Gets Analyzed\n\nSafety Checks:\n\n🚨 Critical: AFR targets that could cause engine damage, excessive ignition timing\n⚠️ Warnings: Rev limiter not configured, suspicious VE values, high injector duty\n\nConfiguration Review:\n\nRequired fuel calculation sanity check\nVE table range and smoothness\nAFR target appropriateness for NA vs forced induction\nIgnition timing ranges and knock risk assessment\nCranking pulse widths\nWarmup enrichment curve\nSafety limits (rev limiter, overboost)\n\nOptimization Opportunities:\n\nInjector duty cycle headroom\nVE table smoothness (sudden jumps)\nConservative vs aggressive timing maps\nInterpreting Results\n\nExample Analysis Output:\n\n📋 VE Table\n----------------------------------------\n  ⚠️ VE table has very low values (15.0) - check for empty/untuned cells\n  📊 12 cells have >30% jumps from neighbors - consider smoothing\n  ✓ VE table range: 15.0 - 105.0 (avg: 62.3)\n\n📋 Ignition Timing\n----------------------------------------\n  ⚠️ High ignition advance (48°) - verify on dyno with knock detection\n  ✓ Spark advance range: 8° - 48° BTDC\n\nSUMMARY\n============================================================\n🚨 CRITICAL ISSUES: 0\n⚠️  WARNINGS: 2\n✓ Suggestions: 4\nℹ️  Notes: 1\n\nCommon Issues Detected\n\nHigh Priority:\n\nNo rev limiter configured\nLean AFR targets under load (>14.0:1 at WOT)\nIgnition timing >45° (severe knock risk)\nEstimated injector duty >90%\n\nMedium Priority:\n\nVE values <20 or >120\nLarge jumps between adjacent cells (>30%)\nMissing warmup enrichment taper\nCranking PW too high/low for conditions\n\nLow Priority:\n\nConservative timing that may leave power on table\nOverly rich AFR targets\nExcessive injector headroom\nTune Review Workflow\n\nBefore First Start:\n\nYou: \"Review this base tune before I start the engine\"\nAI: [Runs analysis, flags safety issues]\n\n\nAfter Changes:\n\nYou: \"I just updated my VE table, check it\"\nAI: [Analyzes for anomalies, suggests smoothing]\n\n\nBefore Dyno/Track:\n\nYou: \"Review my tune before high load testing\"\nAI: [Checks timing, AFR, safety limits, injector headroom]\n\nReference Materials\n\nFor detailed documentation, see:\n\nreferences/tunerstudio-reference.md - Full TunerStudio documentation\nreferences/megasquirt-tuning-guide.md - Comprehensive tuning procedures\nQuick Reference Formulas\n\nInjector Duty Cycle:\n\nDC% = (Injector PW / Injection Period) × 100\n\n\nKeep under 85% for safety margin.\n\nRequired Fuel Calculation:\n\nRequired Fuel (ms) = (Engine CC × 5) / (Number of Injectors × Injector CC/Min) × 2\n\n\n(The ×2 accounts for 2 rotations per cycle)\n\nAirflow Estimation:\n\nMAF (g/s) ≈ (RPM × Displacement × VE% × MAP/100) / (2 × 60 × R × Temp)\n\nSafety Checklist\n\nBefore starting engine:\n\n Injector flow rate correct in settings\n Ignition timing verified with timing light\n Fuel pump primes and holds pressure\n No fuel leaks\n Wideband O2 sensor warmed up\n Emergency fuel/ignition cut accessible\n\nDuring tuning:\n\n Monitor EGT if available\n Listen for detonation/knock\n Watch AFR on transitions\n Keep VE table changes conservative\n Save tune frequently with version notes"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/boblobclaw/megasquirt-tuner",
    "publisherUrl": "https://clawhub.ai/boblobclaw/megasquirt-tuner",
    "owner": "boblobclaw",
    "version": "1.0.2",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/megasquirt-tuner",
    "downloadUrl": "https://openagent3.xyz/downloads/megasquirt-tuner",
    "agentUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent",
    "manifestUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/megasquirt-tuner/agent.md"
  }
}