Welcome to your journey into hardware programming with Lua! This quick start guide will get you up and running in just a few minutes.
# Check if Lua is installed
lua5.4 -v
# If not installed (Ubuntu/Raspberry Pi):
sudo apt update && sudo apt install lua5.4
# If you're on macOS:
brew install lua
# If you're on Windows:
# Download LuaForWindows from GitHub releases# Clone or download this repository
git clone https://github.com/OpenRockets/luapowered.git
cd luapowered
# Run the LED controller demo
lua5.4 demos/smart_led_controller.luaYou should see a simulation of a smart LED controller with multiple patterns!
Open the Complete Guide and begin with:
- What is Lua? - Learn why Lua is perfect for hardware
- Your First Program - Write your first Lua script
- Hardware Introduction - Start controlling real hardware
Time: 6-8 hours
Goal: Build your first LED controller
-
Lua Basics (3-4 hours)
-
First Hardware Project (2-3 hours)
-
Interactive Hardware (1-2 hours)
Time: 12-15 hours
Goal: Build a complete IoT weather station
- Complete the Beginner path (6-8 hours)
- Advanced Hardware (3-4 hours)
- Intermediate Projects (5-6 hours)
Time: 20+ hours
Goal: Production-ready embedded systems
- Complete previous paths (12-15 hours)
- Advanced Projects (8-12 hours)
Perfect for all beginner projects:
- Raspberry Pi Zero 2 W or Pi 3/4
- MicroSD card (16GB)
- Breadboard
- Jumper wires
- LEDs and resistors
- Push buttons
Everything you need for intermediate projects:
- Raspberry Pi 4 (4GB)
- Sensors (temperature, humidity, light)
- Motors (servo, DC motor)
- Camera module
- Relay modules
- LCD display
For production-level projects:
- Multiple Pi boards
- Industrial sensors
- Motor drivers
- Communication modules
- Power supplies
- Enclosures
See our Hardware Shopping Guide for specific recommendations.
- LED Blinker: Classic "Hello World" of hardware
- Button Controller: Interactive LED patterns
- Temperature Monitor: Read and display sensor data
- Home Automation: Control lights and appliances remotely
- Weather Station: Multi-sensor data collection with web interface
- Security System: Motion detection and alerts
- Robot Controller: Autonomous navigation and control
- IoT Gateway: Connect multiple devices to the internet
- Industrial Monitor: Real-time data logging and analysis
-- Lua is simple and powerful
local temperature = read_sensor()
if temperature > 25 then
turn_on_fan()
send_alert("Temperature high: " .. temperature .. "°C")
end- Easy to learn: Simple, clean syntax
- Fast execution: Perfect for real-time control
- Small footprint: Runs on resource-constrained devices
- Powerful features: Tables, functions, and coroutines
- Great community: Active forums and libraries
- 📖 Complete Guide - Start here for systematic learning
- 🔧 Hardware Setup - Installation and configuration
- 📚 Reference Materials - Links and resources
- 💬 GitHub Issues: Report bugs or ask questions
- 🌐 Lua Community: Join the global Lua programming community
- 📺 Video Tutorials: Coming soon!
- ⚡ Hardware not working? Check connections and power
- 🐛 Code errors? Read error messages carefully
- 🔍 Need examples? Look in the demos folder
- Try the demo: Run
lua5.4 demos/smart_led_controller.lua - Read the guide: Start with guide/README.md
- Build a project: Follow LED Blink Project
- Join the community: Share your projects and get help
- Contribute: Help make this guide even better!
"I had never programmed hardware before, but with this guide I built a complete home automation system in a weekend!" - Sarah, Maker
"Lua's simplicity let me focus on the hardware instead of fighting with the language. Perfect for rapid prototyping." - Mike, Engineer
"The step-by-step projects gave me confidence to tackle my own ideas. Now I'm building IoT devices professionally." - David, Student
Ready to start? 🚀
Happy hardware hacking! 🔧⚡