This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
en:examples [2010/02/22 11:30] – mikk.leini | en:examples [Unknown date] (current) – external edit (Unknown date) 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Examples ====== | + | ====== |
- | {{ :images:book: | + | {{ :kit:kodulabor3_komponendid_v.png?600 |}} |
- | Praktilised näited on üles ehitatud | + | Practical examples are built up in uniform style and as concrete as possible. Each example begins with a short introduction of the theory and gives necessary knowledges for completing the following practical part. Practical part contains commented example of the source code of the software. Generally the library of the HomeLab is used in the example of the code, but in some cases the registers are also configured. The first chapter is a little bit different with a bit different goal. It describes installation and set-up of necessary software. The examples are about Windows and Linux operation systems. Chapters and practical examples after the first chapter are suitable for both OS and development software. |
- | ~~PB~~ | + | < |
- | **Ülesehitus** | + | **Buildup** |
- | Praktiliste näidete peatükkide juures on toodud loetelu näite läbimiseks vajalikest eelteadmistest. Loetelus on viited raamatu teistele peatükkidele, mis on tähistatud teemakohaste ikoonidega: | + | There is a list of necessary knowledges to complete the example at each chapter of practical examples. In this list are references to other chapters of the book, which are marked with icons as follows: |
- | * [HW] Näites kasutatud füüsiline moodul | + | * [HW] Physical module used in th example. |
- | * [LIB] Näites kasutatud tarkvara teegi osa | + | * [LIB] Part of the software library used in the example. |
- | * [ELC] Viide elektroonika baasteadmiste peatükile | + | * [ELC] Reference to the chapter Basics of electronics. |
- | * [AVR] Viide AVR mikrokontrolleri mooduli peatükile | + | * [AVR] Reference to the chapter |
- | * [PRT] Viide teisele harjutusele | + | * [PRT] Reference to other exercises. |
- | **Näidete baastarkvara** | + | **Basic software of the examples** |
- | Nagu eespool öeldud, on praktilised koodinäited koostatud Kodulabori teegi baasil. Teeki on kirjutatud enimkasutatavad | + | As mentioned before, practical code samples are composed |
- | **Näidete koodistiil** | + | **Code style of the examples** |
- | Näidisprogrammid on kirjutatud ühes stiilis, et programmikood oleks ülevaatlikum. Ühtne stiil teeb programmi loetavaks ja välistab kergemate süntaksivigade tekkimist. Kindlat stiili on soovitatav järgida ka harjutusülesannete tegemisel. Stiili peamised iseloomustajad: | + | The example programs are written in one style, to achieve more synoptic program code. Uniform style makes the program more readable and prevents making simple syntax mistakes. It is advised to follow a certain style when making exercises. The main characteristics of the style: |
- | * Programm, selle funktsioonid ja muutujad on ingliskeelsed ning väiketähtedega, kus sõnu eraldab alakriips. | + | * Program, all its functions and variables are in English and in small letters, the words are separated with an under-strike. |
- | * Funktsioonid on kujul //objekt_tegevus_subjekt//. | + | * Functions are in following form: //object_action_subject//. |
- | * Olulisemad kohad programmis on kommenteeritud eesti keeles. | + | * more important places in the program are commented. |
- | * Iga C-keele plokk (tähistatud loogeliste sulgudega | + | * Every block in C-language |
- | * Plokid on tabuleeritud tabulaatorklahviga. Reasiseselt tabulaatorit ei kasutata. | + | * Blocks are tabulated with tabulator keys. Tabulator is not used inside rows. |