<?xml version="1.0" encoding="utf-8"?>
<!-- generator="FeedCreator 1.7.2-ppt DokuWiki" -->
<?xml-stylesheet href="http://www.pic24.ru/lib/exe/css.php?s=feed" type="text/css"?>
<rdf:RDF
    xmlns="http://purl.org/rss/1.0/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
    xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel rdf:about="http://www.pic24.ru/feed.php">
        <title>PIC24 en:osa:ref:introduction</title>
        <description></description>
        <link>http://www.pic24.ru/</link>
        <image rdf:resource="http://www.pic24.ru/lib/images/favicon.ico" />
       <dc:date>2023-02-11T21:17:03+03:00</dc:date>
        <items>
            <rdf:Seq>
                <rdf:li rdf:resource="http://www.pic24.ru/doku.php/en/osa/ref/introduction/intro?rev=1285973214"/>
            </rdf:Seq>
        </items>
    </channel>
    <image rdf:about="http://www.pic24.ru/lib/images/favicon.ico">
        <title>PIC24</title>
        <link>http://www.pic24.ru/</link>
        <url>http://www.pic24.ru/lib/images/favicon.ico</url>
    </image>
    <item rdf:about="http://www.pic24.ru/doku.php/en/osa/ref/introduction/intro?rev=1285973214">
        <dc:format>text/html</dc:format>
        <dc:date>2010-10-02T02:46:54+03:00</dc:date>
        <title>OSA : Introduction</title>
        <link>http://www.pic24.ru/doku.php/en/osa/ref/introduction/intro?rev=1285973214</link>
        <description>


&lt;h1&gt;&lt;a name=&quot;osa_introduction&quot; id=&quot;osa_introduction&quot;&gt;OSA : Introduction&lt;/a&gt;&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;OSA : Introduction&quot; [1-36] --&gt;
&lt;h2&gt;&lt;a name=&quot;what_is_osa&quot; id=&quot;what_is_osa&quot;&gt;What is OSA?&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;p&gt;

&lt;strong&gt;&lt;em&gt;OSA&lt;/em&gt;&lt;/strong&gt; is a cooperative multitasking real-time operating system (RTOS) for Microchip PIC-controllers &lt;strong&gt;PIC10&lt;/strong&gt;, &lt;strong&gt;PIC12&lt;/strong&gt;, &lt;strong&gt;PIC16&lt;/strong&gt;, &lt;strong&gt;PIC18&lt;/strong&gt;, &lt;strong&gt;PIC24&lt;/strong&gt;, &lt;strong&gt;dsPIC&lt;/strong&gt;, for Atmel &lt;strong&gt;AVR 8-bit&lt;/strong&gt; controllers, and for STMicroelectronics &lt;strong&gt;STM8&lt;/strong&gt;.
&lt;/p&gt;

&lt;p&gt;
RTOS allows the programmer to focus on problem-oriented tasks (algorithmic, mathematical etc.) and not have to worry about secondary tasks. All secondary tasks are performed by OSA&amp;#039;s kernel:
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; switching between parallel processes (e.g. keyboard scanning, output data to LCD, switching relays);&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; checking timeouts, counting delays;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; finding the ready task with the highest priority and executing it;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; data exchange between different tasks using semaphores, messages, queues etc.&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

A task in OSA is a C-function. This function must contain an infinite loop which has inside it at least one service that switches task context. A simple task can look like this:

&lt;/p&gt;
&lt;pre class=&quot;cpp code cpp&quot; style=&quot;font-family:monospace;&quot;&gt;&lt;span class=&quot;kw4&quot;&gt;void&lt;/span&gt; SimpleTask &lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;kw4&quot;&gt;void&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;br0&quot;&gt;&amp;#123;&lt;/span&gt;
    &lt;span class=&quot;kw1&quot;&gt;for&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;;;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;        &lt;span class=&quot;co1&quot;&gt;// Infinite loop&lt;/span&gt;
    &lt;span class=&quot;br0&quot;&gt;&amp;#123;&lt;/span&gt;
        OS_Yield&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;; &lt;span class=&quot;co1&quot;&gt;// Unconditional context switching&lt;/span&gt;
    &lt;span class=&quot;br0&quot;&gt;&amp;#125;&lt;/span&gt;
&lt;span class=&quot;br0&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;What is OSA?&quot; [37-1130] --&gt;
&lt;h2&gt;&lt;a name=&quot;compilers&quot; id=&quot;compilers&quot;&gt;Compilers&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Compilers&quot; [1131-1153] --&gt;
&lt;h3&gt;&lt;a name=&quot;pic&quot; id=&quot;pic&quot;&gt;PIC&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;table class=&quot;inline&quot;&gt;
	&lt;tr class=&quot;row0&quot;&gt;
		&lt;th class=&quot;col0 rightalign&quot;&gt;                                          &lt;/th&gt;&lt;th class=&quot;col1 centeralign&quot;&gt;   PIC10/12    &lt;/th&gt;&lt;th class=&quot;col2 centeralign&quot;&gt;  PIC16/12     &lt;/th&gt;&lt;th class=&quot;col3 centeralign&quot;&gt;  PIC16F1xxx    &lt;/th&gt;&lt;th class=&quot;col4 centeralign&quot;&gt;    PIC18      &lt;/th&gt;&lt;th class=&quot;col5 centeralign&quot;&gt;  PIC24/dsPIC  &lt;/th&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row1&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/picc_std.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:picc_std.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/picc_std.png&quot; class=&quot;media&quot; title=&quot;HT-PICC STD&quot; alt=&quot;HT-PICC STD&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col2 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col3 rightalign&quot;&gt;                   &lt;/td&gt;&lt;td class=&quot;col4 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col5 rightalign&quot;&gt;               &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row2&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/picc_pro.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:picc_pro.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/picc_pro.png&quot; class=&quot;media&quot; title=&quot;HT-PICC PRO&quot; alt=&quot;HT-PICC PRO&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/no.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:no.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/no.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;&lt;td class=&quot;col2 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/no.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:no.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/no.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;&lt;td class=&quot;col3 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;      &lt;/td&gt;&lt;td class=&quot;col4 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/no.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:no.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/no.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;&lt;td class=&quot;col5 rightalign&quot;&gt;               &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row3&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/mplabc.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:mplabc.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/mplabc.png&quot; class=&quot;media&quot; title=&quot;Microchip C&quot; alt=&quot;Microchip C&quot; /&gt;&lt;/a&gt;     &lt;/td&gt;&lt;td class=&quot;col1 rightalign&quot;&gt;               &lt;/td&gt;&lt;td class=&quot;col2 rightalign&quot;&gt;               &lt;/td&gt;&lt;td class=&quot;col3 rightalign&quot;&gt;                   &lt;/td&gt;&lt;td class=&quot;col4 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col5 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;       &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row4&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/mikroc_pro.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:mikroc_pro.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/mikroc_pro.png&quot; class=&quot;media&quot; title=&quot;mikroC PRO&quot; alt=&quot;mikroC PRO&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col1 rightalign&quot;&gt;               &lt;/td&gt;&lt;td class=&quot;col2 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col3 rightalign&quot;&gt;                   &lt;/td&gt;&lt;td class=&quot;col4 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col5 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/process.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:process.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/process.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;   &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row5&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/ccs.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:ccs.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/ccs.png&quot; class=&quot;media&quot; title=&quot;CCS PICC&quot; alt=&quot;CCS PICC&quot; /&gt;&lt;/a&gt;           &lt;/td&gt;&lt;td class=&quot;col1 rightalign&quot;&gt;               &lt;/td&gt;&lt;td class=&quot;col2 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col3 rightalign&quot;&gt;                   &lt;/td&gt;&lt;td class=&quot;col4 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col5 rightalign&quot;&gt;               &lt;/td&gt;
	&lt;/tr&gt;
&lt;/table&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;PIC&quot; [1154-1952] --&gt;
&lt;h3&gt;&lt;a name=&quot;avr&quot; id=&quot;avr&quot;&gt;AVR&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;table class=&quot;inline&quot;&gt;
	&lt;tr class=&quot;row0&quot;&gt;
		&lt;th class=&quot;col0 rightalign&quot;&gt;                                          &lt;/th&gt;&lt;th class=&quot;col1 centeralign&quot;&gt;  AVR 8-bit        &lt;/th&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row1&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/winavr.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:winavr.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/winavr.png&quot; class=&quot;media&quot; title=&quot;WinAVR&quot; alt=&quot;WinAVR&quot; /&gt;&lt;/a&gt;          &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;      &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row2&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/iar.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:iar.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/iar.png&quot; class=&quot;media&quot; title=&quot;IAR&quot; alt=&quot;IAR&quot; /&gt;&lt;/a&gt;                &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;      &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row3&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/cvavr.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:cvavr.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/cvavr.png&quot; class=&quot;media&quot; title=&quot;Code Vision AVR&quot; alt=&quot;Code Vision AVR&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/process.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:process.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/process.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;
	&lt;/tr&gt;
&lt;/table&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;AVR&quot; [1953-2228] --&gt;
&lt;h3&gt;&lt;a name=&quot;stm8&quot; id=&quot;stm8&quot;&gt;STM8&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;table class=&quot;inline&quot;&gt;
	&lt;tr class=&quot;row0&quot;&gt;
		&lt;th class=&quot;col0 rightalign&quot;&gt;                                          &lt;/th&gt;&lt;th class=&quot;col1 centeralign&quot;&gt;     STM8          &lt;/th&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row1&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/cosmic.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:cosmic.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/cosmic.png&quot; class=&quot;media&quot; title=&quot;Cosmic&quot; alt=&quot;Cosmic&quot; /&gt;&lt;/a&gt;          &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/yes.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:yes.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/yes.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;      &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row2&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/iar.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:iar.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/iar.png&quot; class=&quot;media&quot; title=&quot;IAR&quot; alt=&quot;IAR&quot; /&gt;&lt;/a&gt;                &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/process.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:process.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/process.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;
	&lt;/tr&gt;
	&lt;tr class=&quot;row3&quot;&gt;
		&lt;td class=&quot;col0 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/osa/ref/raisonance.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;osa:ref:raisonance.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/osa/ref/raisonance.png&quot; class=&quot;media&quot; title=&quot;Raisonance&quot; alt=&quot;Raisonance&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;&lt;td class=&quot;col1 centeralign&quot;&gt;  &lt;a href=&quot;http://www.pic24.ru/lib/exe/detail.php/en/osa/ref/introduction/process.png?id=en%3Aosa%3Aref%3Aintroduction%3Aintro&quot; class=&quot;media&quot; title=&quot;en:osa:ref:introduction:process.png&quot;&gt;&lt;img src=&quot;http://www.pic24.ru/lib/exe/fetch.php/en/osa/ref/introduction/process.png&quot; class=&quot;media&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;  &lt;/td&gt;
	&lt;/tr&gt;
&lt;/table&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;STM8&quot; [2229-2506] --&gt;
&lt;h2&gt;&lt;a name=&quot;limitations&quot; id=&quot;limitations&quot;&gt;Limitations&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Limitations&quot; [2507-2531] --&gt;
&lt;h3&gt;&lt;a name=&quot;ht-picc_ht-pic18&quot; id=&quot;ht-picc_ht-pic18&quot;&gt;HT-PICC HT-PIC18&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; You should use the services &lt;span class=&quot;important&quot;&gt;&lt;a href=&quot;http://www.pic24.ru/doku.php/en/osa/ref/allservices/os_enterint&quot; class=&quot;wikilink1&quot; title=&quot;en:osa:ref:allservices:os_enterint&quot;&gt;OS_EnterInt&lt;/a&gt;&lt;/span&gt; (saves FSR) and &lt;span class=&quot;important&quot;&gt;&lt;a href=&quot;http://www.pic24.ru/doku.php/en/osa/ref/allservices/os_leaveint&quot; class=&quot;wikilink1&quot; title=&quot;en:osa:ref:allservices:os_leaveint&quot;&gt;OS_LeaveInt&lt;/a&gt;&lt;/span&gt; (restores saved FSR) when entering and leaving an interrupt routine. &lt;span class=&quot;important&quot;&gt;&lt;a href=&quot;http://www.pic24.ru/doku.php/en/osa/ref/allservices/os_enterint&quot; class=&quot;wikilink1&quot; title=&quot;en:osa:ref:allservices:os_enterint&quot;&gt;OS_EnterInt&lt;/a&gt;&lt;/span&gt; must be placed at the beginning of the ISR function, and &lt;span class=&quot;important&quot;&gt;&lt;a href=&quot;http://www.pic24.ru/doku.php/en/osa/ref/allservices/os_leaveint&quot; class=&quot;wikilink1&quot; title=&quot;en:osa:ref:allservices:os_leaveint&quot;&gt;OS_LeaveInt&lt;/a&gt;&lt;/span&gt; at the end.&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;pre class=&quot;cpp code cpp&quot; style=&quot;font-family:monospace;&quot;&gt;&lt;span class=&quot;kw4&quot;&gt;void&lt;/span&gt; interrupt int_routine &lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;kw4&quot;&gt;void&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;br0&quot;&gt;&amp;#123;&lt;/span&gt;
    &lt;span class=&quot;kw4&quot;&gt;char&lt;/span&gt; var1, var2;
    &lt;span class=&quot;kw4&quot;&gt;int&lt;/span&gt; var3;
&amp;nbsp;
    &lt;span class=&quot;co1&quot;&gt;// After definition of local variables we need to save FSR:&lt;/span&gt;
    OS_EnterInt&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;;
    &lt;span class=&quot;coMULTI&quot;&gt;/*...*/&lt;/span&gt;
    &lt;span class=&quot;coMULTI&quot;&gt;/* Interrupt flags checking */&lt;/span&gt;
    &lt;span class=&quot;coMULTI&quot;&gt;/*...*/&lt;/span&gt;
&amp;nbsp;
    &lt;span class=&quot;co1&quot;&gt;// At the end of ISR we need to restore FSR:&lt;/span&gt;
    OS_LeaveInt&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;;
&lt;span class=&quot;br0&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;
These services save and restore the FSR value (FSR0 for htpicc18), since HT-PICC sometimes does not do it.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;HT-PICC HT-PIC18&quot; [2532-3379] --&gt;
&lt;h3&gt;&lt;a name=&quot;microchip_c18&quot; id=&quot;microchip_c18&quot;&gt;Microchip C18&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; You can&amp;#039;t use procedural abstraction optimization&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; You can&amp;#039;t use Stack Model: Multi-bank&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Microchip C18&quot; [3380-3501] --&gt;
&lt;h3&gt;&lt;a name=&quot;microchip_c30&quot; id=&quot;microchip_c30&quot;&gt;Microchip C30&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; You can&amp;#039;t use procedural abstraction optimization (compiler command &amp;quot;-mpa&amp;quot;).&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Microchip C30&quot; [3502-3608] --&gt;
&lt;h3&gt;&lt;a name=&quot;bit_chips&quot; id=&quot;bit_chips&quot;&gt;12-bit chips&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; When using 12-bit controllers (PIC10 and PIC12), the size of pointers to message, simple messages and counting semaphores must be equal to 1 byte.&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;12-bit chips&quot; [3609-3784] --&gt;
&lt;h3&gt;&lt;a name=&quot;mikroc_pro_for_pic16&quot; id=&quot;mikroc_pro_for_pic16&quot;&gt;mikroC PRO for PIC16&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Version 2.50 PRO or higher required for PIC18&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Version 3.00 PRO or higher required for PIC12 and PIC16&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;strong&gt;Dynamic timers&lt;/strong&gt;, &lt;strong&gt;messages&lt;/strong&gt; and &lt;strong&gt;queues of messages&lt;/strong&gt; cannot be allocated in bank2 and bank3 of RAM. The problem is that mikroC PRO can allocate there itself. In this case you should to change the locations of definitions of listed variables. (Soon this limitation will be solved) &lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;mikroC PRO for PIC16&quot; [3785-4219] --&gt;
&lt;h3&gt;&lt;a name=&quot;ccs_picc&quot; id=&quot;ccs_picc&quot;&gt;CCS PICC&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Since version 4.104 the compiler has an &lt;a href=&quot;http://www.ccsinfo.com/forum/viewtopic.php?t=41180&quot; class=&quot;urlextern&quot; title=&quot;http://www.ccsinfo.com/forum/viewtopic.php?t=41180&quot;  rel=&quot;nofollow&quot;&gt;error&lt;/a&gt;. Due to this error, the compiler can&amp;#039;t build a program that uses OSA. Please, use other versions (OSA was checked with: 4.023, 4.069, 4.084, 4.099, 4.102, 4.105)&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;CCS PICC&quot; [4220-4507] --&gt;
&lt;h3&gt;&lt;a name=&quot;iar&quot; id=&quot;iar&quot;&gt;IAR&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Works in C-mode only (not C++). &lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Optimization cross-call should be switched OFF.&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;IAR&quot; [4508-4612] --&gt;
&lt;h3&gt;&lt;a name=&quot;winavr&quot; id=&quot;winavr&quot;&gt;WinAVR&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; OSA foulder and project foulder should be allocated on same logical drive (for example both on &amp;quot;C:\…&amp;quot;).&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;WinAVR&quot; [4613-4741] --&gt;
&lt;h3&gt;&lt;a name=&quot;cosmic&quot; id=&quot;cosmic&quot;&gt;Cosmic&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Only chips with ROM 64K and less are supported&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class=&quot;plugin_uparrow&quot;&gt;
  &lt;a href=&quot;#&quot; title=&quot;Наверх&quot;&gt;
    &lt;img src=&quot;http://www.pic24.ru/lib/plugins/uparrow/images/blue_arrow.png&quot; alt=&quot;Наверх&quot;/&gt;
  &lt;/a&gt;
&lt;/div&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Cosmic&quot; [4742-4820] --&gt;
&lt;h2&gt;&lt;a name=&quot;thanks_to&quot; id=&quot;thanks_to&quot;&gt;Thanks to&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;p&gt;

&lt;strong&gt;Thanks to all who took part in identifying and correcting bugs. Most thanks to &lt;span class=&quot;important&quot;&gt;Vadim Frank&lt;/span&gt; and to &lt;span class=&quot;important&quot;&gt;D. Ivanov&lt;/span&gt; who was a most active assistant and showed patience and perseverance.&lt;/strong&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;Special thanks to &lt;span class=&quot;important&quot;&gt;Roger Burrows&lt;/span&gt; who corrected a lot of my errors in the English documentation.&lt;/strong&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;Also thanks to &lt;span class=&quot;important&quot;&gt;Alex B.&lt;/span&gt; who provided the site for documentation and assistance in its placement on the site.&lt;/strong&gt;
&lt;/p&gt;
&lt;div class=&quot;plugin_uparrow&quot;&gt;
  &lt;a href=&quot;#&quot; title=&quot;Наверх&quot;&gt;
    &lt;img src=&quot;http://www.pic24.ru/lib/plugins/uparrow/images/blue_arrow.png&quot; alt=&quot;Наверх&quot;/&gt;
  &lt;/a&gt;
&lt;/div&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Thanks to&quot; [4821-] --&gt;</description>
    </item>
</rdf:RDF>
