Practical guide unit
Using GPIO ports
BeginnerStep-by-step tutorial: from creating the MPLAB project to simulating an LED controlled by a button — one verifiable action per step.
You will build
A `.ASM` that builds, loads in Proteus, and makes an **LED on RB0** follow a **button on RB1** using TRIS → LAT → PORT.
- 1 Welcome: what you will achieve
- 2 Create project and .ASM file
- 3 LIST and #include
- 4 Course config bits
- 5 Reset vector and sandwich layout
- 6 TRIS: RB0 output, RB1 input
- 7 Wire LED and button in Proteus
- 8 LAT: turn on the LED (first test)
- 9 PORT: button controls the LED
- 10 Review final program and save
- 11 Check what you learned