본문으로 건너뛰기
cccskills
무료GitHub에 공개

abs-syntax-reference

Use this reference to write Aily Block Syntax (ABS), a text format for Blockly scripts. It explains block connections, parameter order, statement inputs, values, and variable references, with examples for conditions, loops, and Arduino program structure.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

ABS 语法快速参考:权威 ABS 规则与示例 skill,覆盖块连接类型、参数顺序、语句输入、变量引用与常见示例。触发词:ABS、语法、块脚本

ailyProject/aily-blockly스타 3,860(GitHub 3,860 + cccskills 0)

실행 점수 미검증

설치 방법 보기

이럴 때 유용합니다

  • Check the correct order of block parameters
  • Write conditions and loops in ABS
  • Look up value and variable syntax for Blockly scripts

포함된 파일(1)

  • SKILL.md5.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

ABS (Aily Block Syntax) 快速参考

本 skill 只负责 ABS 语法规则与示例。项目规划、库安装、证据读取、工作区同步和验证流程由当前 host profile、可用工具说明及 blockly-best-practices skill 负责;不要从本语法参考重建那些流程。

使用库块时,参数顺序必须来自该库当前的 readme_ai.md 或 block.json,不能仅根据本文件中的通用示例推断。

Block Connection Types

TypeRoleParameter Style
Value作为值嵌入到其他块参数中所有参数都写在括号内:logic_compare($a, EQ, $b)
Statement独立成行,通过 next 串联普通参数写在括号内,语句输入使用 @NAME:
Hat根入口块,如 arduino_setup、arduino_loop规则与 Statement 相同

Syntax Rules

ElementSyntaxExample
Block callblock_type(param1, param2)serial_println(Serial, text("Hi"))
Empty paramsblock_type()time_millis()
Statement input@NAME: + 换行 + 缩进@DO0:\n action()
Variable ref$varName$count, $sensor

Parameter Types

TypeSyntaxExample
DropdownENUM_VALUESerial, HIGH, EQ, AND
Text"string""hello", "dht"
Number1239600, 13
Variable$name$count, $temp
Value blockblock(args)math_number(10), $var

参数顺序规则

参数顺序必须严格遵循 block.json 中 args0 的定义顺序,字段和输入可能交错出现,不能想当然地把下拉字段放到最前面。

例如 logic_compare 的 args0 顺序是:A(input_value), OP(field_dropdown), B(input_value),因此:

  • 正确:logic_compare($a, EQ, $b)
  • 错误:logic_compare(EQ, $a, $b)

Value Blocks

值块的所有参数都必须写在括号里,不能使用命名输入。

# Comparison: logic_compare(A, OP, B)
logic_compare($a, EQ, math_number(10))
logic_compare($temp, GT, math_number(30))

# Logic: logic_operation(A, OP, B)
logic_operation($sensor1, AND, $sensor2)
logic_operation(logic_compare($a, GT, math_number(0)), OR, logic_compare($a, LT, math_number(100)))

# Math: math_arithmetic(A, OP, B)
math_arithmetic($a, ADD, $b)

# Ternary: logic_ternary(condition, trueValue, falseValue)
logic_ternary(logic_compare($score, GTE, math_number(90)), text("A"), text("B"))

# Negate
logic_negate($flag)

# Boolean
logic_boolean(TRUE)

Statement Blocks with Statement Inputs

语句输入必须使用 @NAME:,并且子块体使用 4 个空格缩进。

# If-Else: statement inputs use @NAME:
controls_if()
    @IF0: logic_compare($temp, GT, math_number(30))
    @DO0:
        serial_println(Serial, text("Hot"))
    @ELSE:
        serial_println(Serial, text("OK"))

# If-ElseIf-Else
controls_if()
    @IF0: logic_compare($v, GT, math_number(100))
    @DO0:
        action1()
    @IF1: logic_compare($v, GT, math_number(50))
    @DO1:
        action2()
    @ELSE:
        action3()

# Loop
controls_repeat_ext(math_number(10))
    serial_println(Serial, text("Loop"))

controls_for($i, math_number(0), math_number(10), math_number(1))
    serial_println(Serial, $i)

Simple Statement Blocks

无语句输入的语句块,同样全部使用括号参数。

serial_begin(Serial, 115200)
serial_println(Serial, text("Hello"))
serial_println(Serial, $count)
time_delay(math_number(1000))
variables_set($count, math_number(0))
math_change($count, math_number(1))

Program Structure

arduino_setup()
    serial_begin(Serial, 115200)

arduino_loop()
    serial_println(Serial, text("Hello"))
    time_delay(math_number(1000))

Variable Reference Context

Target Type$var Becomes
field_variable变量字段,如 variables_set($x, ...)
input_valuevariables_get 表达式,如 serial_println(Serial, $x)

Checklist

  • 必须写括号:block(),不能省略为 block
  • input_value 位置的数字应写成 math_number(n)
  • input_value 位置的文本应写成 text("s")
  • 下拉值使用枚举值,如 HIGH、Serial、EQ、AND
  • 语句体使用 4 空格缩进
  • 只有语句输入才使用命名输入:@IF0:、@DO0:、@ELSE:
  • 值块的所有参数都在括号里,不能写命名输入
  • 参数顺序严格遵循 block.json 的 args0 定义,而不是“字段优先”

调试建议

  1. 读取当前 project.abs 并从具体报错位置开始定位;host 已在提交 turn 前同步可见工作区。
  2. 仅当工作区可能在 turn 开始后发生变化时,才使用 syncAbs action="export" 刷新文件。
  3. 对照相关库 readme_ai.md 或 block.json 的 args0 顺序,修正参数位置、缩进和值块包装方式。
  4. 使用当前 host 同步能力重新导入并验证,依据最近的报错做最小修复。

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Implement or modify Blockly/ABS programs using the project’s current board and installed libraries. Check only relevant library evidence, edit the canonical ABS source, sync it to the workspace, and run focused validation when needed.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Adding a feature to an existing Blockly program
  • Editing ABS source and syncing the workspace
  • Checking a focused build or syntax issue
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

Plan a new Blockly hardware project by discovering suitable board and library packages, then comparing viable combinations. Each plan outlines wiring assumptions, workspace structure, implementation steps, and validation before the user confirms project creation.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Comparing boards for a new Blockly project
  • Planning libraries for a sensor or actuator
  • Reviewing wiring and validation assumptions
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

chronicle

무료

Search indexed chat history to find earlier decisions, tool activity, project summaries, files, and workflow tips. It can also rebuild the local history index when requested or when search results appear out of date.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Find a decision made in an earlier conversation
  • Check which tools were used for past work
  • Summarize recent project sessions
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

handoff

무료

Create a concise handoff document in the operating system’s temporary directory so another agent can continue the work. It summarizes the conversation, suggests relevant skills, references existing artifacts, and redacts sensitive information.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Hand ongoing work to another agent
  • Prepare context for a fresh session
  • Summarize progress without duplicating project artifacts
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

improve

무료

Survey a codebase and turn verified improvement opportunities into prioritized, self-contained implementation plans for another agent. It can assess bugs, security, performance, tests, technical debt, migrations, tooling, and product direction while keeping source code read-only.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Audit a codebase for high impact issues
  • Plan fixes for security or performance findings
  • Create a grounded roadmap for another agent
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

Follow a workflow for converting Arduino and ESP32 libraries into Aily Blockly libraries. The guide covers analyzing public APIs, defining blocks, generating code, configuring toolboxes, initializing Serial, I2C, and SPI, adapting boards, and packaging the result.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Convert an Arduino library for Aily Blockly
  • Design block definitions and generated code
  • Adapt a library to supported development boards
ailyProject/aily-blockly3.9천2026년 10월 26일 업데이트

ailyProject의 스킬 모두 보기

이 스킬의 문제 신고