Docsity

Embedded systems tutorial, Monografías, Ensayos de Ingeniería Eléctrica y Electrónica

Toggle sidebar
bg1
Embedded System Design Report (tutorial)
Introduction
This report provides a detailed description of the embedded system developed
on the Xilinx Spartan-6 LX9 MicroBoard platform using Xilinx Platform Studio
(XPS) and Xilinx Software Development Kit (SDK). The overall functionality of the
system, hardware structure, and code analysis will be addressed.
System Functionality
The embedded system is designed to control LEDs and read switch states on the
Spartan-6 LX9 MicroBoard. The system allows selecting different LED on/off
sequences while monitoring the state of the switches. Additionally, a timer is
included to provide delay functions in milliseconds.
Hardware
The hardware design is described using an MHS file and a UCF file. The FPGA
includes the following components:
1. MicroBlaze: it is the main processor of the system, with its associated
instruction and data memory (ILMB and DLMB).
2. IP modules:
• proc_sys_reset: handles the system reset management.
• lmb_v10 and lmb_bram_if_cntlr: control the MicroBlaze instruction
and data memory.
• bram_block: provides RAM memory for the MicroBlaze.
• mdm: is a debugging module.
• clock_generator: generates a clock for the system.
• axi_interconnect: is the interconnection bus between the AXI
peripherals and the MicroBlaze.
• axi_gpio: is used to control the LEDs and read the switches' state.
• axi_timer: provides a timer for the system.
• axi_uartlite: is the UART interface for serial communication.
• axi_intc: is an interrupt controller to manage peripheral
interruptions.
3. I/O Connections:
• The pins for the LEDs, switches, UART, and clock are assigned to
the FPGA pins in the UCF file.
pf3

Vista previa parcial del texto

¡Descarga Embedded systems tutorial y más Monografías, Ensayos en PDF de Ingeniería Eléctrica y Electrónica solo en Docsity!

Embedded System Design Report (tutorial)

Introduction This report provides a detailed description of the embedded system developed on the Xilinx Spartan-6 LX9 MicroBoard platform using Xilinx Platform Studio (XPS) and Xilinx Software Development Kit (SDK). The overall functionality of the system, hardware structure, and code analysis will be addressed. System Functionality The embedded system is designed to control LEDs and read switch states on the Spartan-6 LX9 MicroBoard. The system allows selecting different LED on/off sequences while monitoring the state of the switches. Additionally, a timer is included to provide delay functions in milliseconds. Hardware The hardware design is described using an MHS file and a UCF file. The FPGA includes the following components:

  1. MicroBlaze: it is the main processor of the system, with its associated instruction and data memory (ILMB and DLMB).
  2. IP modules:
    • proc_sys_reset: handles the system reset management.
    • lmb_v10 and lmb_bram_if_cntlr: control the MicroBlaze instruction and data memory.
    • bram_block: provides RAM memory for the MicroBlaze.
    • mdm: is a debugging module.
    • clock_generator: generates a clock for the system.
    • axi_interconnect: is the interconnection bus between the AXI peripherals and the MicroBlaze.
    • axi_gpio: is used to control the LEDs and read the switches' state.
    • axi_timer: provides a timer for the system.
    • axi_uartlite: is the UART interface for serial communication.
    • axi_intc: is an interrupt controller to manage peripheral interruptions.
  3. I/O Connections:
    • The pins for the LEDs, switches, UART, and clock are assigned to the FPGA pins in the UCF file.

Software The embedded system software is written in C++ and includes the following files:

  1. main.cc: contains the main function of the program, which initializes the system components, including the UART, LEDs, switches, and timer. Also, it implements a main loop that performs the following functions: - Configure system parameters (Delay and Seq) based on the state of the switches and the commands received through the UART. - Update the LED sequence and wait for the time specified by Delay. - Exit the main loop if the command '0' is received through the UART.
  2. timer.h and timer.cc: These files define the CTimer class, which uses the AXI_Timer module to provide delay functions in milliseconds. The class allows waiting for a specific number of milliseconds before continuing the program execution.
  3. leds.h and leds.cc: These files define the CLeds class, which controls the LEDs connected to the FPGA. The class has two predefined sequences for controlling the LEDs and can switch between sequences based on user input.
  4. switches.h and switches.cc: These files define the CSwitches class, which is used to read the state of the switches connected to the FPGA. The class provides methods to determine if a switch is on and if the switches' state has changed. The embedded system communicates with the user through the UART interface, allowing modifying the LED sequence and the waiting time between changes. Moreover, the user can control the system configuration through the switches, offering an additional form of interaction. Changes in the program (version 2) Compared to the previous program, this new program has some differences in terms of functionality and components used. The most significant changes and how they affect the program's functionality are described below:
  5. A new axi_timer module has been added to the .mhs file. This module is responsible for generating periodic interruptions and provides functions to wait for a specific time. The timer is used in the main.cc file to control the blinking speed of the LEDs.
  6. A new axi_intc interrupt controller module has been added to the .mhs file. This module is used to handle interruptions generated by the timer