Agent Skillsespressif/esp-claw › take_picture

take_picture

GitHub

用于调用板载摄像头拍摄照片并保存为JPEG文件。需先读取硬件信息确认相机存在,随后执行Lua脚本完成捕获,支持自定义文件名、目录及超时设置。

components/lua_modules/lua_module_camera/skills/take_picture/SKILL.md espressif/esp-claw

触发场景

用户要求拍照或截图 需要保存摄像头静态图像

安装

npx skills add espressif/esp-claw --skill take_picture -g -y
更多选项

非标准路径

npx skills add https://github.com/espressif/esp-claw/tree/master/components/lua_modules/lua_module_camera/skills/take_picture -g -y

不安装直接使用

npx skills use espressif/esp-claw@take_picture

指定 Agent (Claude Code)

npx skills add espressif/esp-claw --skill take_picture -a claude-code -g -y

安装 repo 全部 skill

npx skills add espressif/esp-claw --all -g -y

预览 repo 内 skill

npx skills add espressif/esp-claw --list

SKILL.md

Frontmatter
{
    "name": "take_picture",
    "metadata": {
        "cap_groups": [
            "cap_lua"
        ],
        "manage_mode": "readonly"
    },
    "description": "Take one photo with the board camera and save it as a JPEG file. Requires board_hardware_info skill."
}

Take Picture

Use this skill when the user asks to take a photo, capture a picture, snap an image, or save a camera still from the board camera.

Run exactly one script with lua_run_script after reading board_hardware_info.

If lua_run_script returns an error, report that error directly to the user. Do not retry with changed arguments or run another camera script in the same turn unless the user explicitly asks.

Script Args Schema

{
  "type": "object",
  "properties": {
    "filename": {
      "type": "string",
      "default": "capture.jpg",
      "description": "JPEG filename to create under the storage root or under dir."
    },
    "dir": {
      "type": "string",
      "default": "",
      "description": "Optional single directory name under the storage root."
    },
    "timeout_ms": {
      "type": "integer",
      "default": 3000,
      "minimum": 0
    },
    "skip_frames": {
      "type": "integer",
      "default": 3,
      "minimum": 0,
      "description": "Number of warm-up frames to discard before saving the photo."
    }
  }
}

Path rules:

  • filename must be a simple .jpg or .jpeg filename.
  • filename must not contain /, \, or ...
  • dir is optional and must be a single directory name under the storage root.
  • dir must not contain /, \, or ...

Tool Call Inputs

Take a photo with the default output name:

{"path":"{CUR_SKILL_DIR}/scripts/take_picture.lua","args":{}}

Take a photo with a custom filename:

{"path":"{CUR_SKILL_DIR}/scripts/take_picture.lua","args":{"filename":"photo.jpg"}}

Take a photo into a storage-root-relative directory:

{"path":"{CUR_SKILL_DIR}/scripts/take_picture.lua","args":{"dir":"photos","filename":"latest.jpg","timeout_ms":5000}}

Take a photo after discarding more warm-up frames:

{"path":"{CUR_SKILL_DIR}/scripts/take_picture.lua","args":{"filename":"stable.jpg","skip_frames":5}}

Recommended Flow

  1. Activate the board_hardware_info skill and confirm that a camera device is listed.
  2. If no camera is listed, tell the user that the board does not declare a camera and stop.
  3. Choose a safe filename. Use the default unless the user requested a specific output name.
  4. Run {CUR_SKILL_DIR}/scripts/take_picture.lua with the selected args.
  5. Report the saved path, byte count, resolution, pixel format, skipped warm-up frames, and any error directly from the script output.

版本历史

  • 06eb576 当前 2026-07-24 19:54

同 Skill 集合

components/claw_capabilities/cap_http_request/skills/cap_http_request/SKILL.md
components/claw_capabilities/cap_im_platform/skills/cap_im_platform/SKILL.md
components/claw_capabilities/cap_router_mgr/skills/cap_router_mgr/SKILL.md
components/claw_capabilities/cap_scheduler/skills/cap_scheduler/SKILL.md
components/claw_capabilities/cap_web_search/skills/cap_web_search/SKILL.md
components/claw_modules/claw_memory/skills/memory_ops/SKILL.md
components/claw_modules/claw_memory/skills/profile_memory_ops/SKILL.md
components/common/skill_builder/skills/skill_creator/SKILL.md
components/common/skill_builder/skills/skills_lab_downloader/SKILL.md
components/common/skill_builder/skills/skills_lab_search/SKILL.md
components/lua_modules/lua_driver_touch/skills/read_touch/SKILL.md
components/lua_modules/lua_module_ble_hid/skills/ble_hid/SKILL.md
components/lua_modules/lua_module_ble/skills/ble/SKILL.md
components/lua_modules/lua_module_http_server/skills/http_server_lua_demo/SKILL.md
components/claw_capabilities/cap_llm_inspect/skills/cap_llm_inspect_image/SKILL.md

元信息

文件数
0
版本
74b1870
Hash
786609de
收录时间
2026-07-24 19:54

首页 - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-09-16 13:41
浙ICP备14020137号-1 $访客地图$