Documentation

Technical reference for CircuitQuEEst — architecture, content model, build instructions, and the full topic list.

Overview

CircuitQuEEst is a single-activity Android application built entirely with Kotlin and Jetpack Compose. It teaches Electrical Engineering fundamentals through 42 sequential topics, each consisting of a scrollable lesson and a 7-question quiz.

Architecture

Layer overview

┌─ UI Layer (Jetpack Compose) ──────────────────────────────┐ │ HomeScreen · LessonScreen · QuizScreen · ResultScreen │ │ Components: TopicCard · CategoryHeader · XpProgressBar │ ├─ ViewModel Layer ─────────────────────────────────────────┤ │ HomeViewModel · LessonViewModel · QuizViewModel │ │ StateFlow<T> → collectAsStateWithLifecycle() → recompose UI │ ├─ Repository Layer ────────────────────────────────────────┤ │ ProgressRepository (single source of truth) │ │ Room DAOs: TopicProgressDao · QuizResultDao │ ├─ Data Layer ──────────────────────────────────────────────┤ │ Room DB (CircuitQueestDatabase) │ │ Entities: TopicProgress · QuizResult │ └─ Content Layer (compile-time) ────────────────────────────┘ Kotlin singleton objects — one file per topic │ TopicCategories — maps topicId → category (UI-only) │

A single NavGraph.kt defines all routes using Jetpack Navigation Compose. The repository is injected at the NavGraph level and passed into ViewModel factories.

RouteScreen
homeHomeScreen — category list + search
lesson/{topicId}LessonScreen — scrollable lesson sections
quiz/{topicId}QuizScreen — 7-question quiz
result/{topicId}/{score}/{total}/{xp}ResultScreen — score + XP actually awarded

Content model

All 42 topics are defined as Kotlin singleton objects in data/content/. Each file exposes a single Topic object:

data class Topic(
    val id: String,        // e.g. "ohms_law"
    val title: String,
    val subtitle: String,
    val icon: String,      // emoji
    val order: Int,        // global sort order (1–42)
    val lesson: Lesson,
    val quiz: Quiz
)

data class Lesson(val title: String, val sections: List<LessonSection>)
data class LessonSection(val heading: String, val content: String,
                         val formula: String? = null, val keyPoint: String? = null)

data class Quiz(val title: String, val questions: List<Question>)
sealed class Question {
    data class MultipleChoice(val options: List<String>, val correctIndex: Int, ...) : Question()
    data class NumericInput(val correctAnswer: Double, val tolerance: Double, ...) : Question()
}

Categories are a pure UI concern defined in TopicCategories.kt. No Topic data class field was needed — the mapping is a separate object that the ViewModel joins at runtime.

Progress system

XP is awarded as follows:

A quiz passes at 60%. Only a passing attempt sets TopicProgress.quizCompleted = true, which unlocks the next topic. Unlock order follows the categories on the quest map, top to bottom; each topic's order equals its position in that sequence. Any topic you've already started stays unlocked. The rules live in QuizScoring; the lock logic is in HomeViewModel.

Build Instructions

Requirements

Build steps

# Clone the repository
git clone https://github.com/HighviewOne/CircuitQueest.git
cd CircuitQueest

# Build debug APK
./gradlew assembleDebug

# Output location
# app/build/outputs/apk/debug/app-debug.apk (~10 MB)

If your environment variables aren't set:

JAVA_HOME=/path/to/jdk-17 \
ANDROID_HOME=/path/to/android-sdk \
./gradlew assembleDebug

Install directly to a connected device:

./gradlew installDebug

All 42 Topics

Topics are organized into 9 categories on the HomeScreen. Topics unlock in the numeric sequence below, which follows the categories top to bottom.

⚡

Circuit Fundamentals

(6 topics)
#TopicKey concepts
1Ohm's LawV=IR, power calculations, basic circuit analysis
2Series & Parallel CircuitsResistance combinations, voltage/current division
3Kirchhoff's LawsKCL, KVL, node and loop analysis
4Capacitors & InductorsC=Q/V, V=LdI/dt, RC/RL time constants
5AC CircuitsRMS values, reactance, impedance, RLC resonance
6Thevenin & NortonEquivalent circuits, source transformation, max power
🔌

Semiconductor Devices

(4 topics)
#TopicKey concepts
7Diodes & RectifiersPN junctions, Zener, half/full-wave, LEDs
8Transistors (BJTs)NPN/PNP, beta, operating regions, switching
9MOSFETsNMOS/PMOS, threshold voltage, triode/saturation, CMOS
10Semiconductor PhysicsBand theory, doping, drift/diffusion, carrier transport
〰️

Analog Design

(4 topics)
#TopicKey concepts
11Op-AmpsInverting/non-inverting gain, voltage follower, summing amp
12FiltersLow/high/band-pass, cutoff frequency, roll-off, active filters
13Analog Circuit DesignCurrent mirrors, diff pairs, feedback, bandgap, cascode
14Audio ElectronicsAmplifier classes, DACs, speakers, headphone amp design
💻

Digital Systems

(4 topics)
#TopicKey concepts
15Digital Logic GatesAND/OR/NOT/NAND/NOR/XOR, Boolean algebra, Karnaugh maps
16Digital SystemsFlip-flops, counters, finite state machines, memory
17VLSI DesignCMOS fabrication, RTL-to-GDSII, DRC/LVS, timing, power
18Machine Learning HardwareGPUs, TPUs, quantization, inference engines, edge AI
📊

Signals & Control

(3 topics)
#TopicKey concepts
19Signals & SystemsFourier/Laplace transforms, transfer functions, Bode plots
20Control SystemsFeedback loops, PID controllers, stability, gain/phase margins
21Digital Signal ProcessingSampling theorem, FFT, FIR/IIR filters, quantization noise
🔋

Power & Energy

(6 topics)
#TopicKey concepts
22TransformersTurns ratio, impedance matching, efficiency, losses
23Power ElectronicsLinear regulators, LDOs, buck/boost converters, PWM
24Power SystemsThree-phase power, transmission, power factor, protection
25Renewable EnergySolar cells, MPPT, wind turbines, grid-tie inverters
26Electric VehiclesPowertrains, inverters, regenerative braking, charging
27Battery & Energy StorageLi-ion chemistry, C-rate, CC-CV charging, BMS, supercaps
📡

RF & Communications

(7 topics)
#TopicKey concepts
28ElectromagneticsE/B fields, Faraday's law, Maxwell's equations, EM waves
29Transmission LinesCharacteristic impedance, reflections, VSWR, Smith chart
30Communication SystemsAM/FM modulation, SNR, Nyquist theorem, QAM
31Antenna DesignRadiation patterns, gain, dipole/patch/dish, link budgets
32RF Circuit DesignS-parameters, LNA design, oscillators, mixers, matching
33Fiber Optics & PhotonicsOptical fiber, lasers, photodetectors, WDM systems
34Radar SystemsPulse radar, Doppler effect, phased arrays, automotive radar
🔧

Hardware & Embedded

(5 topics)
#TopicKey concepts
35PCB DesignLayer stackup, trace routing, decoupling, ground planes, Gerbers
36Embedded SystemsMCU peripherals, GPIO, ADC/DAC, UART/SPI/I2C protocols
37Sensors & MeasurementTemperature sensors, Wheatstone bridge, instrumentation amps
38Signal Integrity & EMCCrosstalk, ground bounce, EMI shielding, differential signaling
39IoT & WirelessWi-Fi/BLE/LoRa/Zigbee, mesh networking, low-power design
🏥

Specialized Applications

(3 topics)
#TopicKey concepts
40Electric MachinesDC/AC/stepper motors, torque-speed curves, drives
41MEMSAccelerometers, gyroscopes, pressure sensors, microfabrication
42Biomedical ElectronicsECG/EEG signal acquisition, pacemakers, patient safety