ความพีคคือโปรเจกต์นี้ผู้พัฒนาไม่ได้นั่งพิมพ์โค้ด C++ เองทั้งหมดครับ! เขาใช้วิธีที่เรียกว่า "Vibe coding" โดยการป้อนคำสั่ง (Prompt) อย่างละเอียดให้ AI ร่างโค้ดให้ทั้งหมด นี่คือตัวอย่างโครงสร้างคำสั่งที่คุณสามารถก๊อปปี้ไปประยุกต์ใช้ได้:
AI Prompt (Claude Instructions)
OBD/CAN Monitor
I am going to build a project that uses the OBD port and 12V brake line from a vehicle. The firmware will be written with Arduino/C. ALWAYS ask questions if there are any unknowns or uncertainties.
Here are all of the hardware components:
- Host MCU is Adafruit Feather M4 CAN Express
- Blues Notecarrier F & Notecard WBNA
- 12V to 5V DC Buck Converter
- DFRobot 12V to 3.3V level converter
- LED & 3000 mAh LiPo Battery
Wiring instructions:
- OBD pin 6 (CANH) → Feather CANH
- OBD pin 14 (CANL) → Feather CANL
- DFR9011 Signal Output 1 → Notecarrier F_D10
(etc...)
Phase 1: Scope is limited to CAN bring up only.
Phase 2: Focus on identifying CAN IDs for brake pedal.
Phase 3: Poll OBD port on a cadence and light up LED when accelerator is pressed.
Phase 4: Combine Phase 2 and 3 to alert when brake AND accelerator are pressed.
Phase 5: Gather diagnosing data (Speed, RPM, Load, Fuel) every 30s and sync automatically every 30 mins.
🔥 เจาะลึกและดาวน์โหลด Source Code ฉบับเต็ม! 🔥
เนื่องจากตัวโค้ด Firmware (C/C++) มีความยาวและมีฟังก์ชันการจัดการพลังงาน (Power Management) ที่ซับซ้อนมากๆ เราจึงขอแนะนำให้สาย Dev เข้าไปศึกษาโครงสร้างโค้ดฉบับเต็ม รวมถึงไลบรารีที่จำเป็นได้จาก GitHub ของผู้พัฒนาโดยตรงครับ รับรองว่าได้ความรู้เรื่อง Data Structure ของรถยนต์เต็มๆ!