Skip to content

Commit 5f67bf2

Browse files
committed
Working on LUMP implementation
1 parent 92b05e5 commit 5f67bf2

19 files changed

Lines changed: 2723 additions & 975 deletions

.claude/agents/reviewer.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ tools: Read, Bash, Glob, Grep
55
model: sonnet
66
---
77

8-
You are a senior code reviewer for an ESP32/embedded systems project.
8+
You are a senior code reviewer for an ESP32/embedded systems project. You are skilled in C++, Web technologies, Memory management, Undefined behavior and other quirks of the C++ language, the ESP32 platform(WiFi and Bluetooth) and Web technologies.
99

1010
## Your Role
1111
Review code changes and provide constructive, actionable feedback. You cannot edit files - only review and comment.
@@ -25,6 +25,9 @@ Review code changes and provide constructive, actionable feedback. You cannot ed
2525
- Security vulnerabilities
2626
- Blocking code in time-sensitive sections
2727
- Stack overflow risks (large local arrays)
28+
- Misuse of programming language semantics and memory management
29+
- Unwanted undefined behavior
30+
- Performance problems
2831

2932
### Important (should fix)
3033
- Logic errors

.github/workflows/build.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,15 @@ jobs:
1818
python-version: '3.11'
1919
- uses: actions/setup-node@v6
2020
with:
21-
node-version: 24
21+
node-version: 24
2222
- name: Install PlatformIO Core
2323
run: pip install --upgrade platformio
24+
- name: Prepare configuration
25+
run: cp ./config/secrets.ini.template ./config/secrets.ini
26+
- name: Run native unit tests
27+
run: pio test -e native
2428
- name: Build PlatformIO Project
25-
run: |
26-
cp ./config/secrets.ini.template ./config/secrets.ini
27-
pio run
29+
run: pio run
2830
- uses: JamesIves/github-pages-deploy-action@3.7.1
2931
with:
3032
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

CLAUDE.md

Lines changed: 10 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,15 @@ Megahub is an ESP32-based robotics experimentation platform that combines LEGO W
88
- **Frontend**: Web-based IDE built with Vite, Blockly, and vanilla JavaScript
99
- **Libraries**: Custom ESP32 libraries for Bluetooth, UART, IMU, etc.
1010

11-
## Critical Development Guidelines
11+
## Critical Rules
12+
13+
1. **ALWAYS use the `implement-review-loop` agent** for code changes
14+
2. **ALWAYS update README.md** when adding, removing, or changing:
15+
- Configuration options
16+
- User-facing behavior
17+
- Troubleshooting information
18+
3. **NEVER duplicate README content here** - this file is for development context only
19+
5. Always use Context7 MCP when I need library/API documentation, code generation, setup or configuration steps without me having to explicitly ask.
1220

1321
### Memory Management
1422

@@ -64,7 +72,7 @@ Megahub is an ESP32-based robotics experimentation platform that combines LEGO W
6472
### Build System & Project Structure
6573

6674
**PlatformIO Configuration:**
67-
- Build environment: `esp32dev`
75+
- Build environment: `esp-wrover-kit`
6876
- Framework: Arduino + ESP-IDF hybrid
6977
- Custom partition table: [custom_4mb_noota.csv](custom_4mb_noota.csv)
7078
- Pre-build scripts: [gitversion.py](gitversion.py), [buildfrontend.py](buildfrontend.py), [embedfiles.py](embedfiles.py)
@@ -120,35 +128,6 @@ Megahub is an ESP32-based robotics experimentation platform that combines LEGO W
120128
- Test in supported browsers (Chrome, Edge, Opera)
121129
- Use compression (gzip) for embedded files
122130

123-
### Code Review & Implementation
124-
125-
**IMPORTANT: When making code changes to this project:**
126-
127-
For significant code changes or new features, please use the **implement-review-loop** agent. This ensures:
128-
- Code is reviewed before being committed
129-
- Potential issues are caught early
130-
- Changes follow project conventions
131-
- Memory and Bluetooth considerations are validated
132-
133-
To invoke this agent, Claude should use:
134-
```
135-
Task tool with subagent_type="implement-review-loop"
136-
```
137-
138-
Always use Context7 MCP when I need library/API documentation, code generation, setup or configuration steps without me having to explicitly ask.
139-
140-
**When to use implement-review-loop:**
141-
- Adding new features to firmware or frontend
142-
- Modifying Bluetooth communication code
143-
- Changing memory-critical sections
144-
- Refactoring core libraries
145-
- Adding new Lua bindings
146-
147-
**When NOT to use it:**
148-
- Trivial documentation updates
149-
- Simple bug fixes (< 10 lines)
150-
- Configuration file changes
151-
152131
### Common Pitfalls to Avoid
153132

154133
1. **Bluetooth Race Conditions**: Always use proper synchronization when accessing BLE state from multiple tasks
@@ -181,28 +160,6 @@ Always use Context7 MCP when I need library/API documentation, code generation,
181160
- Test files should be in `/test` directory
182161
- Run with `pio test`
183162

184-
### Git Workflow
185-
186-
- Main branch: `main`
187-
- Commit messages should be clear and descriptive
188-
- Include "Co-Authored-By: Claude <noreply@anthropic.com>" when applicable
189-
- Don't commit secrets or credentials (use `config/secrets.ini`)
190-
191-
### External Dependencies
192-
193-
**PlatformIO Libraries:**
194-
- ArduinoJson 7.4.2
195-
- PubSubClient 2.8.0 (MQTT)
196-
- PsychicHttp 2.1.1 (HTTP server)
197-
- SC16IS752 (UART expander)
198-
- MPU6050 (IMU)
199-
- FastLED (LED control)
200-
201-
**Frontend Dependencies:**
202-
- Blockly 12.3.1
203-
- Vite 5.0.0
204-
- Prism.js 1.30.0
205-
206163
### Important Files Reference
207164

208165
- [platformio.ini](platformio.ini) - Build configuration
@@ -238,8 +195,6 @@ Always use Context7 MCP when I need library/API documentation, code generation,
238195
- Lua 5.4 Reference: https://www.lua.org/manual/5.4/
239196
- Blockly Documentation: https://developers.google.com/blockly
240197

241-
---
242-
243198
## Quick Reference for Claude
244199

245200
**Before making changes:**

0 commit comments

Comments
 (0)