/embedded_software

Embedded System Software Interview Prep Code

Primary LanguageC

Embedded Software

This repo contains code relevant to embedded software engineers preparing for interviews.

Table of Contents:

Basics:

  1. Endianness of machine - endian.c
  2. Two's complement representation of numbers - twos_complement.c
  3. Swap Bytes - swapbytes.c
  4. Aligned Malloc and Free - aligned_malloc.c

Device Driver:

  1. CAN driver register programming using bitfields - can_bitfields.c
  2. CAN driver register programming using macros - can_offsets.c
  3. Update Bits/Field in a register - update_bits.c

Pointers:

  1. Arrays of Pointers - array_of_pointers.c
  2. Pointer to Arrays - pointer_to_arrays.c
  3. Function Pointer Arrays - function_pointers.c

Simple Algorithms:

  1. Fibonacci sequence - fibonacci_recursive.c
  2. Binary search in an array - binsearch_array.c
  3. Reverse linked list - reverse_list.c

Multi-threading & Multi-processing: (Compile-line: Use -pthread and -lrt)

  1. Pthreads & Mutexes - threads.c
  2. Fork & Posix Semaphores - process.c

TBD:

  1. Processing command line args
  2. Variable length data at the end of a struct
  3. Circular linked list, with double pointers
  4. Binary search tree