| PICOS18 > Tutorial |
|
|
PICos18 : Tutorial The goal of this tutorial is to show how it is simple to program with
PICos18. The OSEK standart defines the main features of the kernel itself
and defines also the interface between the kernel and the application. |
![]() |
| Development tools | |
| In this first chapter you will create a entier project based on PICos18. To do so you will use the MPLAB® development environment from Microchip and the C18 compiler. |
| The first task | |
| Now you have successfully compiled the PICos18 project under MPLAB® it's time to create and simulate your first task. You will learn how to write a such task and what is the system tick at 1ms. |
| The preemption | |
| You've just designed an application with only one task, but this application is not really usefull ! By adding a new task you will discover all the mechanisms of the preemption from one task to the others. |
| A multi-task application | |
| This chapter introduces the synchro mecanisms between the tasks in PICos18. A third task comes to complete the application and post an event to another task in order to activate it. We will learn to use the events posted from a task or to share the resources. |
| Interrupts | |
|
By using the PIC18 uC you probably expect to use the internal peripherals.
Doing so it is important to considere the interrupts. |
| Using drivers | |
| You want to communicate through the serial port or the CAN interface ? Now you know how to write interrupts and tasks and you know how to manage alarms and events it will be easy to use and to write a real driver for PICos18. |
| Application example | |
| The tutorial is terminated with this last chapter about PICos18 development. The sources of this typical application are located in the Project/Tutorial directory of PICos18. This example is here to show you how easy it is to develop a complex application with PICos18. |
|
|
Debug |
| This chapter is a special adding to show how to debug your application with PICos18. Simulation, ICD2, HyperTerminal debug message, kernel panic management, Hook routines, ... all the tricks ! |