Repository navigation
feat: add ai_hello minimal LVGL + velaclaw demo - #80
Merged
tanghao-xiaomi merged 1 commit intoDec 2, 2026
Merged
Conversation
A ~300 line C app showing how a native LVGL app talks to ai_agent
through the velaclaw client SDK: tap one of three preset questions,
the app sends it with velaclaw_ask() and shows the answer.
It demonstrates the points a new app has to get right:
- the reply callback runs on an ai_agent thread, so the text is
handed to the LVGL thread through a locked buffer + lv_timer;
- the SDK has no timeout, so the app gives up after 30 s;
- the system role is read from /data/ai_hello_persona.txt on every
ask, so it can be changed with echo without rebuilding.
The UI is English; the default role asks the model to answer in Chinese,
so a CJK TTF font is loaded for the reply label.
Builds with both Make (R528 MIBOX-X1) and CMake (goldfish). Needs the
ai_agent fixes "cmake: build the velaclaw local client SDK" and
"agent_loop: skip working status on the velaclaw local client channel".
Verified on R528 MIBOX-X1 with DeepSeek: three taps, three different
answers in 0.9-1.1 s.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Bowen Wang <wangbowen6@xiaomi.com>
CV-Bowen
force-pushed
the
feat/ai-hello-demo
branch
from
December 2, 2026 03:53
6c66c10 to
88c887a
Compare
yanxingyu17
approved these changes
Dec 2, 2026
tanghao-xiaomi
approved these changes
Dec 2, 2026
tanghao-xiaomi
merged commit Dec 2, 2026
58e9a22
into
open-vela:dev-ai-contest-2026
12 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add
ai_hello, a ~300 line native LVGL app showing how a C app talks to ai_agent through the velaclaw client SDK: tap one of three preset questions, the app sends it withvelaclaw_ask()and shows the answer.mini_memois currently the only SDK user, but it also pulls in voice, storage and JSON parsing.ai_hellokeeps only what a new app has to get right:lv_timer;/data/ai_hello_persona.txton every ask, so it can be changed withechowithout rebuilding.It is used as the hands-on example of the openvela AI workshop (R528 MIBOX-X1).
Depends on open-vela/packages_ai_agent#51 and open-vela/packages_ai_agent#52 (CMake SDK build, local client status message).
Impact
New app behind
CONFIG_AI_HELLO(default n, depends onGRAPHICS_LVGL && EXAMPLES_AI_AGENT_VELA). No change to existing apps.Testing
Host: Ubuntu 22.04 x86_64, prebuilt toolchains from the openvela manifest (dev-ai-contest-2026).
r528s3-mibox-x1, nsh + ai_agent +CONFIG_AI_HELLO=y), Make build, DeepSeek backend: three taps, three different answers in 0.9–1.1 s.goldfish-arm64-v8a-ap(ai_agent defconfig +CONFIG_AI_HELLO=y), CMake build: builds and links; app starts and sends the question to ai_agent.nuttx/tools/checkpatch.sh -f: clean except the license-header path note, same asmini_memo.