Hide menu

Lab Registration

Please form a group of two and sign up for the labs through the web interface.

The distribution of the deadlines does not exactly correspond to the time required for each chapter to complete. It is a good idea to finish the chapters that are easier for you, before their deadlines.

Please read the lab manual carefully without jumping over any part of it.

Deadlines

  • Grouping up and registering on webreg [important deadline for webreg registration: 04-April kl 23:59]
  • Chapter 0 (warm up) [No demo].
  • Chapter 1 (bit manipulation) [soft deadline: session 2, 05-April].
  • Chapter 2 (mixing c and assembler) [soft deadline: session 5, 23-April] (Aim for 16-April!)
  • Chapter 3 (polling and interrupts) [soft deadline: session 7, 03-May]
  • Chapter 4 (preemptive multithreading) [soft deadline: session 9, 08-May]
  • Chapter 5 (state machines) [soft deadline: session 11, 15-May]
  • Last demonstration occasion [hard deadline: session 13, 21-May]

Lab Documents

Resources

  • C or assembler on host machine (chapter 1, and with slight modifications, chapter 2)
    • Only involves compiling, debugging and running C or X86 code on the host machine.
    • Just needs a C compiler (e.g. gcc) and debugger (e.g., gdb)
  • NASM assembler for i386
  • LibePC running on Qemu (chapters 0, 2, 3, and 4):
    • Short reference to available libepc functions.
    • Longer reference to libepc functions
    • Debugging with qemu (unsupported)
      • see: qemu and gdb.
      • in makeNrun.sh, change: "qemu-system-i386 -drive format=raw,file=floppy.img,if=floppy" to "qemu-system-i386 -S -gdb tcp::9000 -drive format=raw,file=floppy.img,if=floppy"
      • run gdb from another window
      • in gdb run: "target remote localhost:9000". Gdb should connect to qemu.
      • in gdb, add breakpoint to the first instruction you are interested in (after make, you can see in link.map that the first instruction to llmultiply is 0x100 in chap4, and first instruction to SerialPut is 0x130 in chap5). You add a breakpoint to llmultuiply with "b *0x100" if llmultiply starts at address 0x100 in link.map.
      • You can press "c" to continue, "s" for single insruction, "i r" for registers, "i r eax" for register eax, "x/10i $eip" to print 10 instructions starting at $eip (or anther address), "print (int) *0x402008" to print as integer the 4 bytes starting at given address.
      • See qemu and gdb if you want to follow interrupts.
    • Cross compilation.
  • STM32CubeIDE (Chapter 5)
    • The IDE is available in the SU rooms. You can also access it via thinlinc, but then you cannot connect the board to load, run and debug programs.
    • You can install the IDE om your machine (whether Windows, Mac or Linux). Read more here about downloading STM32CubeIDE.
    • A quick start, including debugging, with the IDE can be found here
    • User manual for the STM32L562E-DK can be found here

Page responsible: Ahmed Rezine
Last updated: 2024-04-15