Programming II

Subject description

The course is divided into two sections: the C programming language and programming a simple microcontroller system. We thoroughly examine the structure of the C language in accordance with the C89 and C99 standards and the techniques used for programming well-known algorithms and data structures. Special emphasis is placed on parts of the language that the standard does not define unambiguously and are often the source of hard-to-trace errors. In the second part of the course, we focus on the basic principles of programming microcontrollers, using the Arduino system as an example. We first address low-level programming operations that allow us to manipulate individual bits in registers or specific parts of memory. Later, we are introduced to the principles of connecting sensors and actuators and the basics of designing teal-time embedded systems. In this context, we also learn about the concept of a finite state machine. We also encounter the concept of software and hardware interrupts.

The subject is taught in programs

Electrical engineering 1st level

Objectives and competences

In-depth knowledge of the fundamentals of the C programming language and familiarization with the basics of embedded systems, the principles of multitasking and real-time systems, and the methods of connecting peripheral devices and communicating with them.

Teaching and learning methods

Two hours of lectures and two hours of hands-on exercises per week, lecture recordings, textbook, homework assignments, individual work with more advanced students.

Expected study results

Upon successfully passing the exam, students should be able to: 

  • List the basic components of a microcontroller system.
  • Describe the operating modes of basic computer components.
  • Explain software issues that arise from the imperfections of hardware.
  • Perform the connection of external units and write the appropriate software code.
  • Develop a simple embedded system.
  • Explain the concepts of real-time and multitasking.
  • Build a reliable system that operates in real time.
  • Evaluate the efficiency of a specific solution in terms of resource consumption, final cost, and the possibility of maintenance and upgrades.

Basic sources and literature

  1. I. Fajfar, J. Olenšek: Osvojimo C – C89, C99 in primeri programiranja mikrokrmilnikov, Založba FE, 2020
  2. S. G. Kochan: Programming in C (4th Edition), 2014
  3. K. N. King: C Programming – A Modern Approach, 2008
  4. H. Schildt: Teach Yourself C, McGraw-Hill, 1997
  5. R. P. Halpern: C for Yourself: Learning C Using Experiments, Oxford University Press, 1997
  6. How C Programming Works (www.howstuffworks.com)
  7. www.cprogramming.com

Stay up to date

University of Ljubljana, Faculty of Electrical Engineering Tržaška cesta 25, 1000 Ljubljana

E:  dekanat@fe.uni-lj.si T:  01 4768 411