Back to the 2023 paper

Module 6: Applications

20237m

Write a C or assembly language program for 8051 microcontroller to create a travelling light pattern connected at port 0 after every 500 ms. Assume there are 8 LEDs connected to 8 pins of port 0. Initially after startup, the LED connected to Pin 0 should be ON. Then after 500 ms, the next LED should be ON. Only one LED should be ON at a time and remaining should stay OFF. Continue this pattern forever. Assume the crystal frequency to be 12 MHz.

Similar questions