homecloud computingcloud data Processingclound of networks
cloud of things

From Arduino Programming to C Programming

Duration: 5 Days

Course Background

The course deals with the migration path going from an ability to use Arduino libraries and their various APIs to understanding how such libraries might be implemented in C and how Arduino sketches might be ported to professional embedded C programs.

Course Prerequisites and Target Audience

This course is aimed at engineers technologists and teachers wishing to make the transition from Arduino sketching to full embedded C programming. Attendees are assumed to have a good basic knowledge of Arduino programming and basic C like Arduino programming techniques, as well as the use of the simple C++ constructs found in Arduino.

Course Outline

  • The mechanisms and technology underlying Arduino Sketches
    • Overview of Arduino programming
    • How an Arduino program maps on to a classical event driven embedded C program with interrupts
    • Overview of the Arduino bootloader
    • Programming a bootloader into an Arduino board
  • C programming in depth
    • The Arduino IDE as a C programming IDE
    • An overview of embedded systems IDEs - AVR Studio, Keil, IAR
    • Variables, types and expressions
    • Arithmetic, bit-oriented and logical operators
    • Choice via if - else and switch statements
    • Iteration via for loops, while loops and do while loops
    • Arrays and pointers
    • Introduction to Data structures and modular programming
    • Pointers to data structures
    • Arrays of data structure types and pointers to data structure types
    • Typedefs - as aids to modularity and code readability
    • Circular buffers and their uses
    • Enums and unions
    • Statemachines and event driven programming
      • Switch statement based statemachines
      • Table driven statemachines
    • Hierarchical and extended statemachines
      • Adding variables and conditional transitions
      • Push down automatata
      • Hierarchical finite statemachines
    • Introduction to dynamic data structures - linked lists and binary trees
  • Overview of embedded system peripherals and modular approaches to the implementation of drivers and application libraries
    • Overview of basic arduino libraries
    • How arduino libraries might be realised as pure C libraries
    • Arduino and C peripheral and protocol stack libraries compared and contrasted
      • GPIO
      • A/D and DAC
      • I2C and SPI
      • PWM
      • Timers
      • USB device - fundamentals
      • Ethernet and TCP/IP fundamentals
      • Wireless - Zigbee, WiFi, RFID, GSM
  • Higher level embedded system programming frameworks - an introduction
    • Systematic approaches to multi-tasking
    • Design and implementation of simple schedulers
    • Overview of RTOS - Real Time Operating Systems - for use on PIC32 and ARM Cortex M3/M4 devices