scmRTOS 4.0 release

At April, 4 (04.04.2012) scmRTOS 4.0 has been released.

Previous version (3.10 + fixes for known bugs) is saved in scmrtos/tags/3.11.

New version is fixed in scmrtos/tags/4.00 and will be developed further in scmrtos/trunk.

Waht’s new in scmRTOS 4.0 over version 3.11:

  • Type aliases byte, word, dword replaced by uint8_t, uint16_t, uint32_t from stdint.h. In some cases “fast” types like uint_fast8_t used for optimal compilation. stdint.h header included in scmRTOS.h
  • New naming conventions. The user has to rename appropriate functions and type names in his code for using 3.xx-style sources with new OS (see below).
  • architecture/compiler/family hierarchy now used for samples’s repository directories and archive names on scmRTOS download page.
  • Process restart functionality added.
  • Program debug and profiling features added:
    • determining the amount of process’s free stack space,
    • profiling of process execution time,
    • determining the address of service object that the process is waiting for.
  • 4-Debug sample is added for new features demonstration.
  • Class TKernelAgent and OS extensions mechanism. Class TProfiler as extension example.
  • OS class hierarchy changed. All OS services are descendents of the class TService which is descendant of the class TKernelAgent. OS user is able to create it’s own services.
  • STM8/IAR port and STM8/IAR/STM8S samples added.
  • CortexM3/GCC/LPC17xx samples 1-EventFlag and 4-Debug added.
  • Support for devices with more than 128K flash (ATmega256x) added in AVR/GCC and AVR/IAR ports for megaAVR.
  • CortexM3/IAR examples removed from OS because a lack of contributors.
  • Fujitsu MB91 port no longer supported.
  • ARM7/IAR port is currently not supported.

To simplify the scmRTOS 3.xx to 4.xx migration process the special header file is offered: scmRTOS_310_compat.h. The file contains some aliases for old type names and enables compatibility mode in all OS sources. In compatibility mode two types of inline adapter functions defined:

  • For user code: from old-style names to new-style names like from Sleep() to sleep() in new OS code.
  • For OS code: from new-style names to old-style names like from system_timer_user_hook() to SystemTimerUserHook() in old user’s code.

Because of the adapter functions the user just should change process’s Exec() function name to еxec() and old code will work.

scmRTOS_310_compat.h must be included in project-level configuration file scmRTOS_CONFIG.h. Also, add there two typedef definitions — for system tick counter tick_count_t and for timeouts and sleep time timeout_t.

See 3-Channel sample in AVR/GCC and AVR/IAR ports as example of using scmRTOS v3.xx oriented code with scmRTOS v4.00 in compatibility mode.

6 Responses to “scmRTOS 4.0 release”

  1. baton says:

    Дайте якщо є у кого, готовій проект під AVR-gcc із scmRTOSv4.0 а то я своє то щось підправив, а у мене задачі не виконуються. Буду вдячний.

    • ReAl says:

      Так перевірені приклади є разом з самою scmRTOS, там можна взяти. Вони прості, але головне показують.

      Докладне пояснення 1-EventFlag робилося під 3.10, зі старшими можуть не збиратися, але головне — що і як відбувається в системі — не помінялося.

  2. smartly says:

    Хе. Вот бы разработать аналог позикс для микроконтроллерных ОС. Стандартизовать всякие EnterCritical, Sleep, Yield, timeout_t. Остальные примитивы тоже бы неплохо стандартизовать, но эти по прикладной программе (не драйверу, который скорее всего всё равно будет привязан к ОС) встречаются весьма часто. Хочется попробовать другую РТОС – приходится бежать по тексту и подставлять другие имена :).

    • ReAl says:

      Така думка вже виникала (мабуть, вона давно в повітрі і її вітром то в одну голову, то в іншу заносить ;-)).
      Але для цього не вистачає знань, бо треба ж проаналізувати (а для цього непогано покористуватися) кілька різних «відносно легких» мікроконтролерних ОС.
      І не вистачає часу для компенсації нестачі знань.

      • smartly says:

        Думаю, все таки набагато важливішим було б бажання авторів цих легких ОС цим зайнятись.

        • ReAl says:

          Згоден. «Ну хоч не всіх, хоча б половини»…

          Вище я писав про себе.
          Якесь таке бажання було ворухнулося ще коли я надавав консультації по портуванню scmRTOS 1.0 на avr-gcc (пізніше у 2.0 такого порта не було, а на 3.0 я вже робив сам). Але зрозумів, що замало досвіду і навіть просто посидіти/почитати документацію на інші легкі ОС мало.

Leave a Reply

[flagcounter image]