<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="et">
	<id>http://courses.cs.taltech.ee/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Irve</id>
	<title>Kursused - Kasutaja kaastöö [et]</title>
	<link rel="self" type="application/atom+xml" href="http://courses.cs.taltech.ee/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Irve"/>
	<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/pages/Eri:Kaast%C3%B6%C3%B6/Irve"/>
	<updated>2026-04-09T08:10:11Z</updated>
	<subtitle>Kasutaja kaastöö</subtitle>
	<generator>MediaWiki 1.35.9</generator>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8955</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8955"/>
		<updated>2019-11-29T13:50:30Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Previous year: [https://courses.cs.ttu.ee/w/index.php?title=ITS8020&amp;amp;oldid=7925 2018]. Historical materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. &lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at GNU/Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== EXAM TIMES ==&lt;br /&gt;
&lt;br /&gt;
* During the lecture: 20. Dec 2019 room U04-103 10:00&lt;br /&gt;
* Secondary exam: 10. Jan 2020 room U04-103 10:00 &lt;br /&gt;
&lt;br /&gt;
== PRACTICE CLASS CHANGE ==&lt;br /&gt;
&lt;br /&gt;
* Now in ITC-401. Tell your friends.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note: Anything up to the lecture may change&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Nonblocking IO (ITS8020)|Nonblocking IO]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is set, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude (that is: within 2019).&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Nonblocking_IO_(ITS8020)&amp;diff=8710</id>
		<title>Nonblocking IO (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Nonblocking_IO_(ITS8020)&amp;diff=8710"/>
		<updated>2019-09-27T08:59:52Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Its8020}}&lt;br /&gt;
&lt;br /&gt;
Practice with nonblocking IO.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= 1. Nonblocking reads from a FIFO =&lt;br /&gt;
&lt;br /&gt;
Goal: To write a program which prints a &amp;#039;.&amp;#039; character every half-a second unless some input is provided on a fifo file.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Hints:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Try to put the terminal into noncanonical mode (you want to turn off line buffering) and remove terminal echo See &amp;#039;[http://linux.die.net/man/3/termios man termios]&amp;#039; or [http://www.google.ee/search?q=noncanonical+mode Google &amp;quot;noncanonical mode&amp;quot;] for that.&lt;br /&gt;
* Note that you should restore the terminal mode before quitting since otherwise the terminal might get messed up (no echo).&lt;br /&gt;
* Working with bits:&lt;br /&gt;
 flags &amp;amp;= ~NEWFLAG   // Clears the bit NEWFLAG on flags&lt;br /&gt;
 flags |= NEWFLAG    // Set the bit NEWFLAG on flags&lt;br /&gt;
 flags ^= NEWFLAG    // Toggle NEWLAG&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= 2. Reading from stidin =&lt;br /&gt;
&lt;br /&gt;
Goal: To write a program which echoes characters on screen while typed until button &amp;#039;q&amp;#039; is pressed. Then it quits and prints a newline.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Hints:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Use [http://linux.die.net/man/2/open open()] with O_NONBLOCK flag.&lt;br /&gt;
* If [http://linux.die.net/man/2/read read()] does not have anything to read, it returns with -1 and sets [http://linux.die.net/man/3/errno errno] to constant EAGAIN - you can check that or try messing around with [http://linux.die.net/man/3/select select()] function.&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Named_pipe FIFO] can be made with a &amp;#039;mkfifo fifoname&amp;#039; command and written to using &amp;#039;cat &amp;gt; fifoname&amp;#039;.&lt;br /&gt;
* You have to open fifo &amp;#039;&amp;#039;before&amp;#039;&amp;#039; reading (open two terminal windows).&lt;br /&gt;
* Write your output with [http://linux.die.net/man/2/write write()] function to bypass line buffering (or turn it off).&lt;br /&gt;
* Function usleep() can be used for half-a second pause here.&lt;br /&gt;
&lt;br /&gt;
[[Kategooria:RTOS]]&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Nonblocking_IO_(ITS8020)&amp;diff=8709</id>
		<title>Nonblocking IO (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Nonblocking_IO_(ITS8020)&amp;diff=8709"/>
		<updated>2019-09-27T08:47:09Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;{{Its8020}}  Practice with nonblocking IO.  = 1. Canonical mode =  Goal: To write a program which echoes characters on screen while typed until button &amp;#039;q&amp;#039; is pressed. Then it qui...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Its8020}}&lt;br /&gt;
&lt;br /&gt;
Practice with nonblocking IO.&lt;br /&gt;
&lt;br /&gt;
= 1. Canonical mode =&lt;br /&gt;
&lt;br /&gt;
Goal: To write a program which echoes characters on screen while typed until button &amp;#039;q&amp;#039; is pressed. Then it quits and prints a newline.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Hints:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Try to put the terminal into noncanonical mode and remove terminal echo See &amp;#039;[http://linux.die.net/man/3/termios man termios]&amp;#039; or [http://www.google.ee/search?q=noncanonical+mode Google &amp;quot;noncanonical mode&amp;quot;] for that.&lt;br /&gt;
* Note that you should restore the terminal mode before quitting since otherwise the terminal might get messed up (no echo).&lt;br /&gt;
* Working with bits:&lt;br /&gt;
 flags &amp;amp;= ~NEWFLAG   // Clears the bit NEWFLAG on flags&lt;br /&gt;
 flags |= NEWFLAG    // Set the bit NEWFLAG on flags&lt;br /&gt;
 flags ^= NEWFLAG    // Toggle NEWLAG&lt;br /&gt;
&lt;br /&gt;
= 2. Nonblocking reads from a FIFO =&lt;br /&gt;
&lt;br /&gt;
Goal: To write a program which prints a &amp;#039;.&amp;#039; character every half-a second unless some input is provided on a fifo file.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Hints:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Use [http://linux.die.net/man/2/open open()] with O_NONBLOCK flag.&lt;br /&gt;
* If [http://linux.die.net/man/2/read read()] does not have anything to read, it returns with -1 and sets [http://linux.die.net/man/3/errno errno] to constant EAGAIN - you can check that or try messing around with [http://linux.die.net/man/3/select select()] function.&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Named_pipe FIFO] can be made with a &amp;#039;mkfifo fifoname&amp;#039; command and written to using &amp;#039;cat &amp;gt; fifoname&amp;#039;.&lt;br /&gt;
* You have to open fifo &amp;#039;&amp;#039;before&amp;#039;&amp;#039; reading (open two terminal windows).&lt;br /&gt;
* Write your output with [http://linux.die.net/man/2/write write()] function to bypass line buffering (or turn it off).&lt;br /&gt;
* Function usleep() can be used for half-a second pause here.&lt;br /&gt;
&lt;br /&gt;
[[Kategooria:RTOS]]&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8708</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8708"/>
		<updated>2019-09-27T08:45:01Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Previous year: [https://courses.cs.ttu.ee/w/index.php?title=ITS8020&amp;amp;oldid=7925 2018]. Historical materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. &lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at GNU/Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== PRACTICE CLASS CHANGE ==&lt;br /&gt;
&lt;br /&gt;
* Now in ITC-401. Tell your friends.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note: Anything up to the lecture may change&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Nonblocking IO (ITS8020)|Nonblocking IO]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is set, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude (that is: within 2019).&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8707</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8707"/>
		<updated>2019-09-27T08:44:48Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Previous year: [https://courses.cs.ttu.ee/w/index.php?title=ITS8020&amp;amp;oldid=7925 2018]. Historical materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. &lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at GNU/Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== PRACTICE CLASS CHANGE ==&lt;br /&gt;
&lt;br /&gt;
* Now in ITC-401. Tell your friends.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note: Anything up to the lecture may change&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Nonblocking IO (ITS8020|Nonblocking IO)]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is set, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude (that is: within 2019).&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8609</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8609"/>
		<updated>2019-09-13T06:00:35Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Previous year: [https://courses.cs.ttu.ee/w/index.php?title=ITS8020&amp;amp;oldid=7925 2018]. Historical materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. &lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at GNU/Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== PRACTICE CLASS CHANGE ==&lt;br /&gt;
&lt;br /&gt;
* Now in ITC-401. Tell your friends.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note: Anything up to the lecture may change&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is set, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude (that is: within 2019).&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_02.pdf&amp;diff=8608</id>
		<title>Fail:Rtos 02.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_02.pdf&amp;diff=8608"/>
		<updated>2019-09-13T05:56:15Z</updated>

		<summary type="html">&lt;p&gt;Irve: Irve laadis üles faili &amp;amp;quot;Pilt:Rtos 02.pdf&amp;amp;quot; uue versiooni: removing the arvutiteaduse instituut&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_01.pdf&amp;diff=8520</id>
		<title>Fail:Rtos 01.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_01.pdf&amp;diff=8520"/>
		<updated>2019-09-05T19:13:20Z</updated>

		<summary type="html">&lt;p&gt;Irve: Irve laadis üles faili &amp;amp;quot;Pilt:Rtos 01.pdf&amp;amp;quot; uue versiooni: taltec&amp;gt;taltech&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_01.pdf&amp;diff=8519</id>
		<title>Fail:Rtos 01.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_01.pdf&amp;diff=8519"/>
		<updated>2019-09-05T19:11:46Z</updated>

		<summary type="html">&lt;p&gt;Irve: Irve laadis üles faili &amp;amp;quot;Pilt:Rtos 01.pdf&amp;amp;quot; uue versiooni&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8518</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=8518"/>
		<updated>2019-09-05T18:55:53Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Previous year: [https://courses.cs.ttu.ee/w/index.php?title=ITS8020&amp;amp;oldid=7925 2018]. Historical materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. &lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at GNU/Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note: Anything up to the lecture may change&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is set, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude (that is: within 2019).&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:ITS8020_2018.zip&amp;diff=7929</id>
		<title>Fail:ITS8020 2018.zip</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:ITS8020_2018.zip&amp;diff=7929"/>
		<updated>2018-12-20T16:33:33Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_16.pdf&amp;diff=7928</id>
		<title>Fail:Rtos 16.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_16.pdf&amp;diff=7928"/>
		<updated>2018-12-20T16:31:25Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_15.pdf&amp;diff=7927</id>
		<title>Fail:Rtos 15.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_15.pdf&amp;diff=7927"/>
		<updated>2018-12-20T16:31:11Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_14.pdf&amp;diff=7926</id>
		<title>Fail:Rtos 14.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_14.pdf&amp;diff=7926"/>
		<updated>2018-12-20T16:31:00Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7925</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7925"/>
		<updated>2018-12-20T16:30:48Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;First Exam&amp;#039;&amp;#039;&amp;#039; - 21.12.2018 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, no registration needed&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Second Exam&amp;#039;&amp;#039;&amp;#039; - 09.01.2019 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, registration in OIS needed&lt;br /&gt;
&lt;br /&gt;
The last day for any show of huffman is 21.12 after the exam.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
[[Media:ITS8020_2018.zip|ITS8020_2018.zip]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7924</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7924"/>
		<updated>2018-12-20T16:30:12Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;First Exam&amp;#039;&amp;#039;&amp;#039; - 21.12.2018 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, no registration needed&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Second Exam&amp;#039;&amp;#039;&amp;#039; - 09.01.2019 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, registration in OIS needed&lt;br /&gt;
&lt;br /&gt;
The last day for any show of huffman is 21.12 after the exam.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
# Localization [[Media:Rtos_14.pdf|PDF]]&lt;br /&gt;
# Real Time Operating Systems [[Media:Rtos_15.pdf|PDF]]&lt;br /&gt;
# Summary [[Media:Rtos_16.pdf|PDF]]&lt;br /&gt;
# [[Media:ITS8020_2018.zip|ITS8020_2018.zip]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7923</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7923"/>
		<updated>2018-12-20T15:01:13Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;First Exam&amp;#039;&amp;#039;&amp;#039; - 21.12.2018 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, no registration needed&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Second Exam&amp;#039;&amp;#039;&amp;#039; - 09.01.2019 10:00 in room &amp;#039;&amp;#039;&amp;#039;SOC-212&amp;#039;&amp;#039;&amp;#039;, registration in OIS needed&lt;br /&gt;
&lt;br /&gt;
The last day for any show of huffman is 21.12 after the exam.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_13.pdf&amp;diff=7829</id>
		<title>Fail:Rtos 13.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_13.pdf&amp;diff=7829"/>
		<updated>2018-11-30T09:45:05Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_12.pdf&amp;diff=7828</id>
		<title>Fail:Rtos 12.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_12.pdf&amp;diff=7828"/>
		<updated>2018-11-30T09:44:53Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_11a.pdf&amp;diff=7827</id>
		<title>Fail:Rtos 11a.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_11a.pdf&amp;diff=7827"/>
		<updated>2018-11-30T09:44:39Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_11.pdf&amp;diff=7826</id>
		<title>Fail:Rtos 11.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_11.pdf&amp;diff=7826"/>
		<updated>2018-11-30T09:44:25Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_10.pdf&amp;diff=7825</id>
		<title>Fail:Rtos 10.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_10.pdf&amp;diff=7825"/>
		<updated>2018-11-30T09:44:12Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7824</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7824"/>
		<updated>2018-11-30T09:44:02Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
# Optimization [[Media:Rtos_10.pdf|PDF]]&lt;br /&gt;
# Networking [[Media:Rtos_11.pdf|PDF]] and Bit-Fields [[Media:Rtos_11a.pdf|PDF]]&lt;br /&gt;
# Compilation and Utilities [[Media:Rtos_12.pdf|PDF]]&lt;br /&gt;
# Security [[Media:Rtos_13.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7823</id>
		<title>Optimization (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7823"/>
		<updated>2018-11-30T09:37:17Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Hints */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;Optimization of a program&amp;#039;&amp;#039;&lt;br /&gt;
== Programm ==&lt;br /&gt;
&lt;br /&gt;
Write a program which will read a file and outputs its statistics.&lt;br /&gt;
&lt;br /&gt;
* For a &amp;quot;standard&amp;quot; input file with random content, please run:&lt;br /&gt;
 dd if=/dev/urandom of=random_file count=1048576 bs=1&lt;br /&gt;
&lt;br /&gt;
* The output of the program should be 256 human-readable lines of ASCII numbers, which represent the content of the file. The first line should contain the number of occurences of byte with a value of 0x0 (or binary zero) in the file and the last line the number of occurences of byte with value 0xff (or 255 in decimal).&lt;br /&gt;
* Measure the running time of the program with:&lt;br /&gt;
 time programname&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* Does the loop unrolling trick work?&lt;br /&gt;
* Perhaps it is possible to use parallel programming or threads?&lt;br /&gt;
* Does compilation optimization with -O work?&lt;br /&gt;
* Can you replace printf with something faster that you write yourself?&lt;br /&gt;
* Perhaps the keyword inline can be used.&lt;br /&gt;
* (Sadly mmap for file reading fails in dijkstra) Can you speed up the reading of the file with mmap()?&lt;br /&gt;
&lt;br /&gt;
== Example code for base program ==&lt;br /&gt;
&lt;br /&gt;
 #include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
 #include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 long int stats[256];&lt;br /&gt;
 &lt;br /&gt;
 int main() {&lt;br /&gt;
         int i, c;&lt;br /&gt;
        FILE * f; &lt;br /&gt;
 &lt;br /&gt;
         f = fopen(&amp;quot;random_file&amp;quot;, &amp;quot;r&amp;quot;);&lt;br /&gt;
         if(f == NULL) {&lt;br /&gt;
                 perror(&amp;quot;slowstat&amp;quot;);&lt;br /&gt;
                 exit(EXIT_FAILURE);&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         while((c = fgetc(f)) != EOF) {&lt;br /&gt;
                 stats[c]++;&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         for(i = 0; i &amp;lt; 255; i++) {&lt;br /&gt;
                 printf(&amp;quot;%ld\n&amp;quot;, stats[i]);&lt;br /&gt;
         }&lt;br /&gt;
         exit(EXIT_SUCCESS);&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7822</id>
		<title>Optimization (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7822"/>
		<updated>2018-11-30T09:36:54Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Programm */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;Optimization of a program&amp;#039;&amp;#039;&lt;br /&gt;
== Programm ==&lt;br /&gt;
&lt;br /&gt;
Write a program which will read a file and outputs its statistics.&lt;br /&gt;
&lt;br /&gt;
* For a &amp;quot;standard&amp;quot; input file with random content, please run:&lt;br /&gt;
 dd if=/dev/urandom of=random_file count=1048576 bs=1&lt;br /&gt;
&lt;br /&gt;
* The output of the program should be 256 human-readable lines of ASCII numbers, which represent the content of the file. The first line should contain the number of occurences of byte with a value of 0x0 (or binary zero) in the file and the last line the number of occurences of byte with value 0xff (or 255 in decimal).&lt;br /&gt;
* Measure the running time of the program with:&lt;br /&gt;
 time programname&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* Does the loop unrolling trick work?&lt;br /&gt;
* Perhaps it is possible to use parallel programming or threads?&lt;br /&gt;
* Does compilation optimization with -O work?&lt;br /&gt;
* Can you replace printf with something faster that you write yourself?&lt;br /&gt;
* Perhaps the keyword inline can be used.&lt;br /&gt;
* (Sadly mmap for file reading fails in dijkstra) Can you speed up the reading of the file with mmap()? (Note -- mmap not yet explained in the lecture)&lt;br /&gt;
&lt;br /&gt;
== Example code for base program ==&lt;br /&gt;
&lt;br /&gt;
 #include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
 #include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 long int stats[256];&lt;br /&gt;
 &lt;br /&gt;
 int main() {&lt;br /&gt;
         int i, c;&lt;br /&gt;
        FILE * f; &lt;br /&gt;
 &lt;br /&gt;
         f = fopen(&amp;quot;random_file&amp;quot;, &amp;quot;r&amp;quot;);&lt;br /&gt;
         if(f == NULL) {&lt;br /&gt;
                 perror(&amp;quot;slowstat&amp;quot;);&lt;br /&gt;
                 exit(EXIT_FAILURE);&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         while((c = fgetc(f)) != EOF) {&lt;br /&gt;
                 stats[c]++;&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         for(i = 0; i &amp;lt; 255; i++) {&lt;br /&gt;
                 printf(&amp;quot;%ld\n&amp;quot;, stats[i]);&lt;br /&gt;
         }&lt;br /&gt;
         exit(EXIT_SUCCESS);&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7821</id>
		<title>Optimization (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7821"/>
		<updated>2018-11-30T09:36:22Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;Optimization of a program&amp;#039;&amp;#039;&lt;br /&gt;
== Programm ==&lt;br /&gt;
&lt;br /&gt;
Write a program which will read a file and outputs its statistics.&lt;br /&gt;
&lt;br /&gt;
* For a &amp;quot;standard&amp;quot; input file with random content, please run:&lt;br /&gt;
 dd if=/dev/urandom of=random_file count=1048576 bs=1&lt;br /&gt;
&lt;br /&gt;
* The output of the program should be 256 human-readable lines of ASCII numbers, which represent the content of the file. The first line should contain the number of occurences of byte with a value of 0x0 (or binary zero) in the file and the last line the number of occurences of byte with value 0xff (or 256 in decimal).&lt;br /&gt;
* Measure the running time of the program with:&lt;br /&gt;
 time programname&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* Does the loop unrolling trick work?&lt;br /&gt;
* Perhaps it is possible to use parallel programming or threads?&lt;br /&gt;
* Does compilation optimization with -O work?&lt;br /&gt;
* Can you replace printf with something faster that you write yourself?&lt;br /&gt;
* Perhaps the keyword inline can be used.&lt;br /&gt;
* (Sadly mmap for file reading fails in dijkstra) Can you speed up the reading of the file with mmap()? (Note -- mmap not yet explained in the lecture)&lt;br /&gt;
&lt;br /&gt;
== Example code for base program ==&lt;br /&gt;
&lt;br /&gt;
 #include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
 #include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 long int stats[256];&lt;br /&gt;
 &lt;br /&gt;
 int main() {&lt;br /&gt;
         int i, c;&lt;br /&gt;
        FILE * f; &lt;br /&gt;
 &lt;br /&gt;
         f = fopen(&amp;quot;random_file&amp;quot;, &amp;quot;r&amp;quot;);&lt;br /&gt;
         if(f == NULL) {&lt;br /&gt;
                 perror(&amp;quot;slowstat&amp;quot;);&lt;br /&gt;
                 exit(EXIT_FAILURE);&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         while((c = fgetc(f)) != EOF) {&lt;br /&gt;
                 stats[c]++;&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         for(i = 0; i &amp;lt; 255; i++) {&lt;br /&gt;
                 printf(&amp;quot;%ld\n&amp;quot;, stats[i]);&lt;br /&gt;
         }&lt;br /&gt;
         exit(EXIT_SUCCESS);&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7820</id>
		<title>Optimization (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Optimization_(ITS8020)&amp;diff=7820"/>
		<updated>2018-11-30T09:36:12Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;&amp;#039;&amp;#039;Optimization of a program&amp;#039;&amp;#039; (Also available in [http://lambda.ee/w/index.php?title=Optimization_(ITI8510)&amp;amp;oldid=12060 Estonian])  == Programm ==  Write a program which will rea...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;Optimization of a program&amp;#039;&amp;#039; (Also available in [http://lambda.ee/w/index.php?title=Optimization_(ITI8510)&amp;amp;oldid=12060 Estonian])&lt;br /&gt;
&lt;br /&gt;
== Programm ==&lt;br /&gt;
&lt;br /&gt;
Write a program which will read a file and outputs its statistics.&lt;br /&gt;
&lt;br /&gt;
* For a &amp;quot;standard&amp;quot; input file with random content, please run:&lt;br /&gt;
 dd if=/dev/urandom of=random_file count=1048576 bs=1&lt;br /&gt;
&lt;br /&gt;
* The output of the program should be 256 human-readable lines of ASCII numbers, which represent the content of the file. The first line should contain the number of occurences of byte with a value of 0x0 (or binary zero) in the file and the last line the number of occurences of byte with value 0xff (or 256 in decimal).&lt;br /&gt;
* Measure the running time of the program with:&lt;br /&gt;
 time programname&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* Does the loop unrolling trick work?&lt;br /&gt;
* Perhaps it is possible to use parallel programming or threads?&lt;br /&gt;
* Does compilation optimization with -O work?&lt;br /&gt;
* Can you replace printf with something faster that you write yourself?&lt;br /&gt;
* Perhaps the keyword inline can be used.&lt;br /&gt;
* (Sadly mmap for file reading fails in dijkstra) Can you speed up the reading of the file with mmap()? (Note -- mmap not yet explained in the lecture)&lt;br /&gt;
&lt;br /&gt;
== Example code for base program ==&lt;br /&gt;
&lt;br /&gt;
 #include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
 #include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 long int stats[256];&lt;br /&gt;
 &lt;br /&gt;
 int main() {&lt;br /&gt;
         int i, c;&lt;br /&gt;
        FILE * f; &lt;br /&gt;
 &lt;br /&gt;
         f = fopen(&amp;quot;random_file&amp;quot;, &amp;quot;r&amp;quot;);&lt;br /&gt;
         if(f == NULL) {&lt;br /&gt;
                 perror(&amp;quot;slowstat&amp;quot;);&lt;br /&gt;
                 exit(EXIT_FAILURE);&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         while((c = fgetc(f)) != EOF) {&lt;br /&gt;
                 stats[c]++;&lt;br /&gt;
        } &lt;br /&gt;
 &lt;br /&gt;
         for(i = 0; i &amp;lt; 255; i++) {&lt;br /&gt;
                 printf(&amp;quot;%ld\n&amp;quot;, stats[i]);&lt;br /&gt;
         }&lt;br /&gt;
         exit(EXIT_SUCCESS);&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7819</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7819"/>
		<updated>2018-11-30T09:35:42Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
* [[Optimization (ITS8020)|Optimization]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Network_Sockets_(ITS8020)&amp;diff=7757</id>
		<title>Network Sockets (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Network_Sockets_(ITS8020)&amp;diff=7757"/>
		<updated>2018-11-16T09:42:46Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Connection */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;The goal is to try sending and receiving data over the socket interface&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
You will use socket(), connect(), bind(), listen(), accept() and socket addresses for the task.&lt;br /&gt;
&lt;br /&gt;
==Task==&lt;br /&gt;
&lt;br /&gt;
There are two separate tasks.&lt;br /&gt;
&lt;br /&gt;
=== Connection ===&lt;br /&gt;
&lt;br /&gt;
Write a program which tries connecting to a specified machine on specified port so the following command:&lt;br /&gt;
 connect www.lambda.ee 80&lt;br /&gt;
would connect to www.lambda.ee on port 80. Write&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;GET / HTTP/1.0\r\n\r\n&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
to the socket and display any resulting data on screen. Terminate when connection is closed.&lt;br /&gt;
&lt;br /&gt;
=== Listening ===&lt;br /&gt;
&lt;br /&gt;
Write a server program which shows on screen whatever data is received from the network. The command line:&lt;br /&gt;
 listen 3333&lt;br /&gt;
would listen on port 3333 and display any received connections.&lt;br /&gt;
&lt;br /&gt;
When connection is made, display the address of the other connection, then display the data until connection is closed.&lt;br /&gt;
&lt;br /&gt;
== Bonus ==&lt;br /&gt;
&lt;br /&gt;
If the former part of the exercises does not provide you with sufficient brain-stimulation. Please try the following: Create a program which outputs the output of &amp;quot;ls -l&amp;quot; to the network on the given socket  when connected; using dup() or dup2() functions. For running a progam you could use fork() and execv(). It could work as follows:&lt;br /&gt;
 lsner 3333&lt;br /&gt;
&lt;br /&gt;
And then you could try it out using netcat for example.&lt;br /&gt;
&lt;br /&gt;
== Tips ==&lt;br /&gt;
&lt;br /&gt;
Use netcat for connecting and listening to your program:&lt;br /&gt;
 nc www.lambda.ee 80&lt;br /&gt;
 nc -l 8080&lt;br /&gt;
&lt;br /&gt;
Note that you can only listen to ports starting from 1024. In addition to that, the Dijkstra server has an external firewall which prevents connections from &amp;#039;&amp;#039;&amp;#039;outside&amp;#039;&amp;#039;&amp;#039; unless you listen on ports 7400-8000 .&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Network_Sockets_(ITS8020)&amp;diff=7756</id>
		<title>Network Sockets (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Network_Sockets_(ITS8020)&amp;diff=7756"/>
		<updated>2018-11-16T09:39:32Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;&amp;#039;&amp;#039;The goal is to try sending and receiving data over the socket interface&amp;#039;&amp;#039;  You will use socket(), connect(), bind(), listen(), accept() and socket addresses for the task.  ==Ta...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;The goal is to try sending and receiving data over the socket interface&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
You will use socket(), connect(), bind(), listen(), accept() and socket addresses for the task.&lt;br /&gt;
&lt;br /&gt;
==Task==&lt;br /&gt;
&lt;br /&gt;
There are two separate tasks.&lt;br /&gt;
&lt;br /&gt;
=== Connection ===&lt;br /&gt;
&lt;br /&gt;
Write a program which tries connecting to a specified machine on specified port so the following command:&lt;br /&gt;
 connect www.lambda.ee 80&lt;br /&gt;
would connect to www.lambda.ee on port 80. Write&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;GET http://courses.cs.ttu.ee/pages/Esileht/ HTTP/1.0\r\n\r\n&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
to the socket and display any resulting data on screen. Terminate when connection is closed.&lt;br /&gt;
&lt;br /&gt;
=== Listening ===&lt;br /&gt;
&lt;br /&gt;
Write a server program which shows on screen whatever data is received from the network. The command line:&lt;br /&gt;
 listen 3333&lt;br /&gt;
would listen on port 3333 and display any received connections.&lt;br /&gt;
&lt;br /&gt;
When connection is made, display the address of the other connection, then display the data until connection is closed.&lt;br /&gt;
&lt;br /&gt;
== Bonus ==&lt;br /&gt;
&lt;br /&gt;
If the former part of the exercises does not provide you with sufficient brain-stimulation. Please try the following: Create a program which outputs the output of &amp;quot;ls -l&amp;quot; to the network on the given socket  when connected; using dup() or dup2() functions. For running a progam you could use fork() and execv(). It could work as follows:&lt;br /&gt;
 lsner 3333&lt;br /&gt;
&lt;br /&gt;
And then you could try it out using netcat for example.&lt;br /&gt;
&lt;br /&gt;
== Tips ==&lt;br /&gt;
&lt;br /&gt;
Use netcat for connecting and listening to your program:&lt;br /&gt;
 nc www.lambda.ee 80&lt;br /&gt;
 nc -l 8080&lt;br /&gt;
&lt;br /&gt;
Note that you can only listen to ports starting from 1024. In addition to that, the Dijkstra server has an external firewall which prevents connections from &amp;#039;&amp;#039;&amp;#039;outside&amp;#039;&amp;#039;&amp;#039; unless you listen on ports 7400-8000 .&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7755</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7755"/>
		<updated>2018-11-16T09:38:13Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
* [[Network Sockets (ITS8020)|Network Sockets]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_09.pdf&amp;diff=7617</id>
		<title>Fail:Rtos 09.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_09.pdf&amp;diff=7617"/>
		<updated>2018-11-02T15:43:26Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7616</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7616"/>
		<updated>2018-11-02T15:43:18Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
# Programming an Operating System [[Media:Rtos_09.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Writing_and_Reading_Binary_Data_(ITS8020)&amp;diff=7600</id>
		<title>Writing and Reading Binary Data (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Writing_and_Reading_Binary_Data_(ITS8020)&amp;diff=7600"/>
		<updated>2018-11-02T09:29:17Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;This practice is about writing data in binary format.   == Task ==  There are two tasks; the first one is simple fread() fwrite() to get the general idea accross, the second need...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This practice is about writing data in binary format. &lt;br /&gt;
&lt;br /&gt;
== Task ==&lt;br /&gt;
&lt;br /&gt;
There are two tasks; the first one is simple fread() fwrite() to get the general idea accross, the second needs some thinking.&lt;br /&gt;
&lt;br /&gt;
=== Runtimes ===&lt;br /&gt;
&lt;br /&gt;
* Write a program which counts and prints how many times it has been run.&lt;br /&gt;
** Save the amount of runs into a file named runtimes.dat&lt;br /&gt;
** If the file is missing, write a binary 1 into the file, save and exit.&lt;br /&gt;
** If the file exists, read the count from the file, increment it, print it and write the new count into the file before exiting.&lt;br /&gt;
&lt;br /&gt;
=== Array to file and from file ===&lt;br /&gt;
&lt;br /&gt;
Here we could also learn using [http://linux.die.net/man/3/getopt getopt()] function, if task seems too simple.&lt;br /&gt;
&lt;br /&gt;
* If the program starts without command line options, show help&lt;br /&gt;
* If program is run with&lt;br /&gt;
  table -c filename.dat -n 10&lt;br /&gt;
: Create 10x10 element 2d array (okay to create just a multiplication table here) and write it into file named filename.dat (save size, then elements)&lt;br /&gt;
* If program is run with&lt;br /&gt;
  table -r filename.dat&lt;br /&gt;
: Open the file, read the array dimensions if stored, show the array on the screen.&lt;br /&gt;
äidake tabel ekraanile.&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* It is advisable to store the table so that the first 4 bytes of the file hold the table dimensions, then the array elements would follow.&lt;br /&gt;
* If the numbers in file are human-readable you are doing the binary wrong.&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7599</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7599"/>
		<updated>2018-11-02T09:28:36Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
* [[Writing and Reading Binary Data (ITS8020)|Writing and Reading Binary Data]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Huffman_Encoder_(ITS8020)&amp;diff=7516</id>
		<title>Huffman Encoder (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Huffman_Encoder_(ITS8020)&amp;diff=7516"/>
		<updated>2018-10-26T09:07:24Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;&amp;#039;&amp;#039;The Huffman encoder assignment helps to discover the wonderful world of pointers, debugging and segmentation faults.&amp;#039;&amp;#039;  Your task is to implement an Hufmann encoder for statist...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;The Huffman encoder assignment helps to discover the wonderful world of pointers, debugging and segmentation faults.&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
Your task is to implement an Hufmann encoder for statistical compression in C. The task is described on [http://deepthought.ttu.ee/it/vorgutarkvara/wav3050/lab1.html this old page]; ignore its presentation guidelines with Tanel Tammet: send them to me.&lt;br /&gt;
&lt;br /&gt;
[http://deepthought.ttu.ee/it/vorgutarkvara/wav3050/lab1_hufmann.html The description of the algorithm].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Grades ==&lt;br /&gt;
&lt;br /&gt;
If you want to predict your grade you might find following helpful:&lt;br /&gt;
* 10p: Compresses and decompresses some regular text files (this is mandatory)	the .c file of your program for example&lt;br /&gt;
* 10p Compresses and decompresses most input	you can have occasional errors with binary files&lt;br /&gt;
* 5p: Compresses and decompresses almost everything	program can work with all non-tricky inputs&lt;br /&gt;
* 5p: Compresses and decompresses even the wierd files	program can work with tricky inputs&lt;br /&gt;
* 5p: Accepts stdin/stdout when no options or -d are present&lt;br /&gt;
    myhuf &amp;lt; asd &amp;gt; asd.out&lt;br /&gt;
    myhuf -d &amp;lt; asd.out &amp;gt; asd2&lt;br /&gt;
* OR accepts file name arguments for both input and output files&lt;br /&gt;
    myhuf asd asd.out&lt;br /&gt;
    myhuf -d asd.out asd2&lt;br /&gt;
* 1p: Has a working makefile (or &amp;quot;make programname&amp;quot; works)&lt;br /&gt;
* 1p: Returns 0 on successful exit; nonzero on any errors&lt;br /&gt;
* 1p: Sends error messages to stderr	&lt;br /&gt;
* 1p: Program is not slow	&lt;br /&gt;
* 1p: program does not crash	&lt;br /&gt;
+1p per week up to 3, when presented earlier than the deadline&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7515</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7515"/>
		<updated>2018-10-26T09:07:10Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Homework */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
* [[Huffman Encoder (ITS8020)|Huffman Encoder]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7514</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7514"/>
		<updated>2018-10-26T08:42:43Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Exam ==&lt;br /&gt;
&lt;br /&gt;
The first exam will be held in last lecture, the second one in the second week of January.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
&lt;br /&gt;
== Homework ==&lt;br /&gt;
&lt;br /&gt;
The homework for the course is a file encoder/decoder using a Huffman algorithm. The deadline for the task is November 9, but if you show your progress weekly, it can be extended without penalty depending on the amount of progress shown. The encoder needs to be shown and defended before the lectures conclude.&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_04.pdf&amp;diff=7513</id>
		<title>Fail:Rtos 04.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_04.pdf&amp;diff=7513"/>
		<updated>2018-10-26T08:39:31Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_08.pdf&amp;diff=7512</id>
		<title>Fail:Rtos 08.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_08.pdf&amp;diff=7512"/>
		<updated>2018-10-26T08:39:12Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_07.pdf&amp;diff=7511</id>
		<title>Fail:Rtos 07.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_07.pdf&amp;diff=7511"/>
		<updated>2018-10-26T08:38:24Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_06.pdf&amp;diff=7510</id>
		<title>Fail:Rtos 06.pdf</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Fail:Rtos_06.pdf&amp;diff=7510"/>
		<updated>2018-10-26T08:38:13Z</updated>

		<summary type="html">&lt;p&gt;Irve: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7509</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7509"/>
		<updated>2018-10-26T08:38:05Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
# Threads [[Media:Rtos_06.pdf|PDF]]&lt;br /&gt;
# Scheduling, Processes [[Media:Rtos_07.pdf|PDF]]&lt;br /&gt;
# File IO, file and directory management [[Media:Rtos_08.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=File_Attributes_(ITS8020)&amp;diff=7508</id>
		<title>File Attributes (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=File_Attributes_(ITS8020)&amp;diff=7508"/>
		<updated>2018-10-26T08:36:01Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;&amp;#039;&amp;#039;We practice using structures in standard library and read file information&amp;#039;&amp;#039;  == Task ==   Write a program, which takes a filename as an argument and then tries to show the att...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;We practice using structures in standard library and read file information&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
== Task == &lt;br /&gt;
&lt;br /&gt;
Write a program, which takes a filename as an argument and then tries to show the attributes of the file: basically calls the stat() function.&lt;br /&gt;
&lt;br /&gt;
When the file is a directory, the program shows the files in that directory (don&amp;#039;t show hidden files). When the user runs the program without extra arguments, just show the contents of the working directory. For symbolic links, show the data about the target, not the link itself.&lt;br /&gt;
&lt;br /&gt;
Only show these attributes:&lt;br /&gt;
* File size&lt;br /&gt;
* Can the owner read?&lt;br /&gt;
* Can the owner write?&lt;br /&gt;
* Can the owner execute?&lt;br /&gt;
&lt;br /&gt;
== Hints ==&lt;br /&gt;
&lt;br /&gt;
* File existence can be checked with function [http://linux.die.net/man/2/access access()].&lt;br /&gt;
* You can get the file attributes using [http://linux.die.net/man/2/stat man stat()] function.&lt;br /&gt;
* The owner permissions are easier to understand using [http://linux.die.net/man/2/chmod man chmod()] (or man stat in the terminal), which provides you with the list of constants which can be compared using if and &amp;amp; to check for the particurlar permission.&lt;br /&gt;
* File is hidden if it starts with a dot.&lt;br /&gt;
* For the directory you can use [http://linux.die.net/man/3/opendir opendir()] and [http://linux.die.net/man/3/readdir readdir()] functions.&lt;br /&gt;
&lt;br /&gt;
=== A Philosophical Detour ===&lt;br /&gt;
&lt;br /&gt;
You may note that the file size attribute has off_t as a type. How to print its contents? Which character should one use with % sign for printf()?&lt;br /&gt;
&lt;br /&gt;
Since off_t can depend on the system, the most rational choice would be to print an unsigned long int and to convert off_t into the corresponding long int using a (&amp;#039;&amp;#039;cast&amp;#039;&amp;#039;).&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7507</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7507"/>
		<updated>2018-10-26T08:35:03Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
* [[File Attributes (ITS8020)|File Attributes]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Processes_(ITS8020)&amp;diff=7456</id>
		<title>Processes (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Processes_(ITS8020)&amp;diff=7456"/>
		<updated>2018-10-19T08:40:26Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;{{its8020}} &amp;#039;&amp;#039;We look at ways to execute a program&amp;#039;&amp;#039;  The goal of the lab is to use three different programs to see how to execute programs. It&amp;#039;s really simple this time.  == Tas...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{its8020}}&lt;br /&gt;
&amp;#039;&amp;#039;We look at ways to execute a program&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
The goal of the lab is to use three different programs to see how to execute programs. It&amp;#039;s really simple this time.&lt;br /&gt;
&lt;br /&gt;
== Task ==&lt;br /&gt;
&lt;br /&gt;
Write three programs.&lt;br /&gt;
&lt;br /&gt;
First one -- execute -- runs the program &amp;quot;stopper&amp;quot; (you can find it in the prototype below) with argument &amp;quot;-s&amp;quot; from the same directory where it is located (use only exec()).&lt;br /&gt;
&lt;br /&gt;
The second -- runner -- runs program &amp;quot;stopper&amp;quot; with argument &amp;quot;-s&amp;quot; from the same directory where it is located and waits for it to finish. After the program has concluded, it prints &amp;quot;runner: Stopped&amp;quot;. (fork() + exec() + wait())&lt;br /&gt;
&lt;br /&gt;
Third program -- backgrounder -- runs the program &amp;quot;stopper&amp;quot; with an argument of &amp;quot;-s&amp;quot;, but does not wait for it to conclude; it exits. This would be analogous to the Daemon pattern explained in the lecture.&lt;br /&gt;
&lt;br /&gt;
Backgrounder should print the PID of itself and the child when it runs.&lt;br /&gt;
&lt;br /&gt;
NB! If you want to compile only the first program, write &amp;quot;make stopper&amp;quot; or &amp;quot;make runner&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Prototype ==&lt;br /&gt;
&lt;br /&gt;
The prototype can be found at /export/kursused/iti8510/ (or [http://dijkstra.cs.ttu.ee/iti8510/processes.tar.gz] )&lt;br /&gt;
To copy the file to the current directory:&lt;br /&gt;
 cp /export/kursused/iti8510/processes.tar.gz .&lt;br /&gt;
&lt;br /&gt;
Untar it:&lt;br /&gt;
 tar -xzvf processes.tar.gz&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7455</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7455"/>
		<updated>2018-10-19T08:39:59Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020)|Processes]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7454</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7454"/>
		<updated>2018-10-19T08:39:51Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
* [[Processes (ITS8020|Processes)]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7387</id>
		<title>ITS8020</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=ITS8020&amp;diff=7387"/>
		<updated>2018-10-12T08:42:21Z</updated>

		<summary type="html">&lt;p&gt;Irve: /* Practice */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=ITS8020 Systems Programming=&lt;br /&gt;
&lt;br /&gt;
[https://ois.ttu.ee/portal/page?_pageid=37,674581&amp;amp;_dad=portal&amp;amp;_schema=PORTAL&amp;amp;p_msg=&amp;amp;p_public=1&amp;amp;p_what=1&amp;amp;p_lang=ET&amp;amp;p_open_node2=&amp;amp;p_session_id=70505303&amp;amp;p_id=117259&amp;amp;p_mode=1&amp;amp;p_pageid=OKM_AINE_WEB_OTSING&amp;amp;n_disp_result=1&amp;amp;n_export=0&amp;amp;_init=1&amp;amp;_nextsearch=1&amp;amp;_nextorder=1&amp;amp;_orfn_1=AINER_KOOD&amp;amp;_ordi_1=ASC&amp;amp;_disp_ainer_kood=1&amp;amp;_where_ainer_kood=&amp;amp;_ainer_kood=ITS8020&amp;amp;_disp_ainer_nimetus=1&amp;amp;_where_ainer_nimetus=&amp;amp;_ainer_nimetus=&amp;amp;_disp_ainer_nimetus_en=1&amp;amp;_where_ainer_nimetus_en=&amp;amp;_ainer_nimetus_en=&amp;amp;_disp_ainer_oppejoud=1&amp;amp;_where_ainer_oppejoud=&amp;amp;_ainer_oppejoud=&amp;amp;_disp_ainer_eap=1&amp;amp;_where_ainer_eap=&amp;amp;_ainer_eap=&amp;amp;_where_ainer_eap_vahemik=&amp;amp;_ainer_eap_vahemik=&amp;amp;__ainer_eap_vahemik=&amp;amp;_where_ainer_opj_keel=&amp;amp;_ainer_opj_keel=&amp;amp;_disp_ainer_opetsem=1&amp;amp;_where_ainer_opetsem=&amp;amp;_ainer_opetsem=&amp;amp;_disp_ainer_kodulehe_autor=1&amp;amp;_where_ainer_kodulehe_autor=&amp;amp;_ainer_kodulehe_autor=&amp;amp;_where_ainer_std_id=&amp;amp;_ainer_std_id=&amp;amp;_where_ainer_e_taismaht=&amp;amp;_ainer_e_taismaht=&amp;amp;_where_ainer_e_maht=&amp;amp;_ainer_e_maht=&amp;amp;_where_ainer_e_tase=&amp;amp;_ainer_e_tase=&amp;amp;_where_ainer_e_kinn_kp=&amp;amp;_ainer_e_kinn_kp=&amp;amp;_where_ainer_e_k_maht=&amp;amp;_ainer_e_k_maht=&amp;amp;_where_ainer_e_k_tase=&amp;amp;_ainer_e_k_tase=&amp;amp;_where_ainer_e_k_kinn_kp=&amp;amp;_ainer_e_k_kinn_kp=&amp;amp;_vformaat=VFORMAAT_HTML&amp;amp;n_lov_offset=1&amp;amp;n_row_count=&amp;amp;n_row_pos= Course Card]&amp;lt;br&amp;gt;&lt;br /&gt;
Lecturer: Jaagup Irve &amp;lt;jaagup.irve@ttu.ee&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For reference: last year materials can be found at [http://lambda.ee/wiki/Real-Time_Operating_Systems_and_Systems_Programming Real-Time Operating Systems and Systems Programming]. Most of it is still relevant.&lt;br /&gt;
&lt;br /&gt;
== Elevator pitch ==&lt;br /&gt;
&lt;br /&gt;
The course is basically an advanced C course which delves into the intricacies of hardware, memory management and operating system design. It looks at basic operating system components (scheduling, mutexes) and also at Linux standard library. You will be expected to program difficult tasks and it will be englightening. The course has been enjoyed by numerous smart students over the years.&lt;br /&gt;
&lt;br /&gt;
== Grading ==&lt;br /&gt;
&lt;br /&gt;
Grading is based on points earned during the course.&lt;br /&gt;
&lt;br /&gt;
90+ points earns a grade of 5, and 50+ lets you pass. Exam can earn you up to 60 points and is difficult. Programming independently (lab) is worth 40 points max. There are 10 bonus points for attending and working on the labs. It is possible to agree on a different course project during the course.&lt;br /&gt;
&lt;br /&gt;
== Lectures ==&lt;br /&gt;
# Introduction (course overview, grades, operator precedence, real time overview) [[Media:Rtos_01.pdf|PDF]]&lt;br /&gt;
# Stack Exploration, Long Jump [[Media:Rtos_02.pdf|PDF]]&lt;br /&gt;
# Heap [[Media:Rtos_03.pdf|PDF]]&lt;br /&gt;
# Hardware, interrupts, basic IO: [https://www.youtube.com/playlist?list=PLMQzXA1f24AdzOb5kRBfN2SkXNrSbdb5L Please watch the videos] [[Media:Rtos_04.pdf|PDF]]&lt;br /&gt;
# Signals, System Calls [[Media: Rtos_05.pdf|PDF]]&lt;br /&gt;
&lt;br /&gt;
== Practice ==&lt;br /&gt;
* [http://lambda.ee/wiki/Basic_Linux_command-line_and_utilities_for_accessing_it_(ITI8510) Basic command line and compilation]&lt;br /&gt;
* [[Stack Exploration (ITS8020)|Stack Exploration]]&lt;br /&gt;
* [[Exploring Debugger (ITS8020)|Exploring Debugger]]&lt;br /&gt;
* [[Signals (ITS8020)|Signals]]&lt;br /&gt;
* [[Threads (ITS8020)|Threads]]&lt;br /&gt;
&lt;br /&gt;
== Links==&lt;br /&gt;
&lt;br /&gt;
* [http://www.edn.com/design/automotive/4423428/Toyota-s-killer-firmware--Bad-design-and-its-consequences Toyota killer firmware]&lt;br /&gt;
* [http://blog.regehr.org/archives/1091 Use of Assertions]&lt;br /&gt;
* [https://matt.sh/howto-c How to C in 2016] - or why the lecturer should be deprecated&lt;br /&gt;
* [https://avicoder.me/2016/02/01/smashsatck-revived/ Smashing the Stack for Fun and Profit Redone] - a take on a classic&lt;br /&gt;
* [https://github.com/s-matyukevich/raspberry-pi-os Raspberry Pi Os] - an opsystem from scratch&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
	<entry>
		<id>http://courses.cs.taltech.ee/w/index.php?title=Threads_(ITS8020)&amp;diff=7386</id>
		<title>Threads (ITS8020)</title>
		<link rel="alternate" type="text/html" href="http://courses.cs.taltech.ee/w/index.php?title=Threads_(ITS8020)&amp;diff=7386"/>
		<updated>2018-10-12T08:42:07Z</updated>

		<summary type="html">&lt;p&gt;Irve: Uus lehekülg: &amp;#039;{{Its8020}} This lab will deal with threads, their creation and common data protection. For (more than thorough) explanation on threads, you can read [https://computing.llnl.gov/...&amp;#039;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Its8020}}&lt;br /&gt;
This lab will deal with threads, their creation and common data protection. For (more than thorough) explanation on threads, you can read [https://computing.llnl.gov/tutorials/pthreads/ POSIX Threads Programming]. Threads and mutexes can be used for experimenting with concurrency with sharing of the memory space: something which could happen while programming a chip.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
You will note that using &lt;br /&gt;
 #include &amp;lt;pthread.h&amp;gt;&lt;br /&gt;
in your program is not enough. It will still not compile. This is due to the fact that gcc needs additional library information and should be executed with -pthread option.&lt;br /&gt;
&lt;br /&gt;
It would be helpful to use a makefile for further compilation. Create a file named Makefile in the directory of the program with contents similar to following (assuming that you named your program &amp;quot;threaded_hello.c&amp;quot;):&lt;br /&gt;
 all: threaded_hello&lt;br /&gt;
 &lt;br /&gt;
 threaded_hello: threaded_hello.c&lt;br /&gt;
         gcc -pthread threaded_hello.c -o threaded_hello.o&lt;br /&gt;
&lt;br /&gt;
Use [tab] button for indentation. For compilation, write &amp;quot;make&amp;quot; or &amp;quot;make threaded_hello&amp;quot;. For further information, refer to [http://www.opussoftware.com/tutorial/TutMakefile.htm Makefile tutorial].&lt;br /&gt;
&lt;br /&gt;
== Task ==&lt;br /&gt;
&lt;br /&gt;
As before you should make some test programs to run with threads. Keep the main() function as simple as possible, doing most of the &amp;quot;work&amp;quot; in threads.&lt;br /&gt;
&lt;br /&gt;
1. Write and run a threaded &amp;quot;Hello, World&amp;quot; program. You need thread creation pthread_create() and pthread_join() commands.&lt;br /&gt;
&lt;br /&gt;
2. Write a program which uses two threads which both run 100000 times while adding 1 to a single shared variable (global variable). It will (hopefully) not count correctly due to race conditions.&lt;br /&gt;
&lt;br /&gt;
3. Modity the program to use &amp;#039;&amp;#039;detached&amp;#039;&amp;#039; threads. Note that you might want to call pthread_exit() from the main function to let the threads finish.&lt;br /&gt;
&lt;br /&gt;
4. We need to protect the shared variable using a mutex. Use [http://sourceware.org/pthreads-win32/manual/pthread_mutex_init.html pthread_mutex_*] functions. The logic to mutex is that you have to acquire mutex before doing work with shared data and have to release it after finishing with it. While the mutex is in the hands of a thread, the other threads who want to lock it block (wait) until the lock is released. &amp;#039;&amp;#039;Show it&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
5. For the last task, we explore how you could pass several arguments to a thread. Improve your program by adding two arguments for a thread that will run: the arguments should be the arguments to the program (to main()); pass them to the thread using an argument to the pthread_create() function. Running your program as follows:&lt;br /&gt;
 threadexperiment test1 test2&lt;br /&gt;
The output should be as follows:&lt;br /&gt;
 Hello, test1 test2&lt;br /&gt;
If there are less than 2 arguments, exit. &amp;#039;&amp;#039;Show it&amp;#039;&amp;#039;&lt;/div&gt;</summary>
		<author><name>Irve</name></author>
	</entry>
</feed>