ZiLOG Real-Time Kernel Version 1.2.0

Similar documents
Zilog Real-Time Kernel

An Automatic Temperature Control System Using RZK

Product Update. Errata to Z8 Encore! 8K Series Silicon. Z8 Encore! 8K Series Silicon with Date Codes 0402 and Later

High-Performance 8-Bit Microcontrollers. Up to 8 10-Bit ADC Channels. Two 16-Bit Timers/PWM. Internal Precision Oscillator

Z8 Encore! XP 4K Series with extended Peripherals

ez80 Webserver Write your own EMAC Driver for Metro IPWorks

Zilog TCP/IP Software Suite

Z8 Encore! XP Family of Microcontrollers Development Kits

ez80190 Development Kit Quick Start Guide

Z8 Encore! Z8F642 MCU Evaluation Kit

Efficiency and memory footprint of Xilkernel for the Microblaze soft processor

ZLF645 Crimzon Flash Microcontroller with ZBase Database Industry Leading Universal Infrared Remote Control (UIR) Solution

Character LCD Interface for ez80acclaim! MCUs

EEPROM Emulation with the ez80f91 MCU. Discussion

GLOSSARY. VisualDSP++ Kernel (VDK) User s Guide B-1

ez80f91 Modular Development Kit

DSP/BIOS Kernel Scalable, Real-Time Kernel TM. for TMS320 DSPs. Product Bulletin

Commercial Real-time Operating Systems An Introduction. Swaminathan Sivasubramanian Dependable Computing & Networking Laboratory

REAL TIME OPERATING SYSTEMS: A COMPLETE OVERVIEW

ez80 Family of Microprocessors Zilog File System User Manual UM Copyright 2007 by Zilog, Inc. All rights reserved.

TI-RTOS overview. Nick Lethaby, TI-RTOS and IoT Ecosystem. May 2015

AVR134: Real Time Clock (RTC) Using the Asynchronous Timer. Features. Introduction. AVR 8-bit Microcontrollers APPLICATION NOTE

Flash Loader Utility for the Z8 Encore! XP MCU

Real-Time Programming

Stellaris Robotic Evaluation Board and Micriµm µc/os-iii

Lecture notes Lectures 1 through 5 (up through lecture 5 slide 63) Book Chapters 1-4

ez80f92/f93 Product Brief

Using the FreeRTOS Real Time Kernel

OLED display with pixels resolution Ambient light sensor CPU load Analog filter Quadrature Encoder with push button Digital I/O

Z8 Encore! XP F1680 Series 8-Bit Flash Solution with Extended Peripherals

Challenge. Hardware Circuit Details. Solution. Result. Features and Functions. Z8 Encore! MC

Chapter 19: Real-Time Systems. Operating System Concepts 8 th Edition,

Embedded Operating Systems

Lecture 3: Concurrency & Tasking


Zatara Series ARM ASSP High-Performance 32-bit Solution for Secure Transactions

Set Up a PLL Loop Filter on the ez80f91 MCU

ATECC108/ATSHA204 USER GUIDE. Atmel Firmware Library. Features. Introduction

An SPI Temperature Sensor Interface with the Z8 Encore! SPI Bus

Z8 Encore! XP F0822 Series

S3 Flash In-System Programmer

embos Real-Time Operating System embos plug-in for IAR C-Spy Debugger Document: UM01025 Software Version: 3.1 Revision: 0 Date: May 3, 2018

Programming in the MAXQ environment

Real-time for Windows NT

embos Real-Time Operating System embos plug-in for IAR C-Spy Debugger Document: UM01025 Software Version: 3.0 Revision: 0 Date: September 18, 2017

Micrium µc/os II RTOS Introduction EE J. E. Lumpp

VORAGO VA108xx FreeRTOS port application note

Measuring Interrupt Latency

Nios II. uc/os-ii porting with Nios II Altera Corporation

6/20/2018. Lecture 2: Platforms & RTOS. Outline. Lab Setup (20 min) Labs work. Lecture: Platform + RTOS

High Resolution Digital Weigh-Scale Design Using Z8 Encore! Microcontrollers

SAMA5D2 Quad SPI (QSPI) Performance. Introduction. SMART ARM-based Microprocessor APPLICATION NOTE

Embedded Systems: OS. Jin-Soo Kim Computer Systems Laboratory Sungkyunkwan University

ATAES132A Firmware Development Library. Introduction. Features. Atmel CryptoAuthentication USER GUIDE

Z8 Encore! XP/Z8 Encore! Development Kits

2. Introduction to Software for Embedded Systems

Salvo Compiler Reference Manual IAR Embedded Workbench for ARM

A Predictable RTOS. Mantis Cheng Department of Computer Science University of Victoria

Lecture Topics. Announcements. Today: Advanced Scheduling (Stallings, chapter ) Next: Deadlock (Stallings, chapter

Embedded Systems: OS

AUTOBEST: A United AUTOSAR-OS And ARINC 653 Kernel. Alexander Züpke, Marc Bommert, Daniel Lohmann

RT extensions/applications of general-purpose OSs

OVERVIEW. Last Week: But if frequency of high priority task increases temporarily, system may encounter overload: Today: Slide 1. Slide 3.

Contents. List of Figures... vi. List of Code Listings... viii. List of Tables... xi. List of Notation... xii

Process Scheduling Queues

POSIX in Real-Time. By Kevin M. Obenland 03/15/2001. Daniel Correia nºmec Carlos Guisado nºmec 49099

MLR INSTITUTE OF TECHNOLOGY DUNDIGAL , HYDERABAD QUESTION BANK

Using an ez80 Flash Memory File System

2.5 Timers Continuous Clock Task Timers Application Timers Memory Management

Getting Started with ESPI Interface Using the Z8 Encore! XP F1680

Salvo Compiler Reference Manual Microchip MPLAB C30

Linux Driver and Embedded Developer

Grundlagen Microcontroller Interrupts. Günther Gridling Bettina Weiss

Windows 7 Overview. Windows 7. Objectives. The History of Windows. CS140M Fall Lake 1

UNIT I [INTRODUCTION TO EMBEDDED COMPUTING AND ARM PROCESSORS] PART A

Using the FreeRTOS Real Time Kernel

Express Logic s ThreadX RTOS for RISC-V

Salvo Compiler Reference Manual Microchip MPLAB C32

ZCRMZNICE01ZEMG Crimzon In-Circuit Emulator

Multiprocessor and Real- Time Scheduling. Chapter 10

Exam TI2720-C/TI2725-C Embedded Software

Nios Soft Core Embedded Processor

ezvision 200 Television Controllers with OSD

Tasks. Task Implementation and management

Micriμm. Getting Started with Micriμm s. Matt Gordon, Sr. Applications Engineer. 9L05I Renesas Electronics America Inc.

2 Principal Architect EDU,QuEST Global, Thiruvananthapuram

AC OB S. Multi-threaded FW framework (OS) for embedded ARM systems Torsten Jaekel, June 2014

Multiprocessor and Real-Time Scheduling. Chapter 10

Embedded Systems Dr. Santanu Chaudhury Department of Electrical Engineering Indian Institution of Technology, IIT Delhi

Freescale MQX RTOS for Kinetis SDK Release Notes version beta

What s An OS? Cyclic Executive. Interrupts. Advantages Simple implementation Low overhead Very predictable

Q Kernel. Thread-Metric RTOS Test Suite. Version Q Kernel is a product of Quasarsoft Ltd.

RT3 - FreeRTOS Real Time Programming

Process Monitoring in Operating System Linux

Kinetis KE1xF512 MCUs

EE458 - Embedded Systems Exceptions and Interrupts

AVR1518: XMEGA-A1 Xplained Training - XMEGA Clock System. 8-bit Atmel Microcontrollers. Application Note. Prerequisites.

embos Real Time Operating System CPU & Compiler specifics for Texas Instruments MSP430 CPUs and Rowley compiler for MSP430 Document Rev.

Green Hills Software, Inc.

CSE 4/521 Introduction to Operating Systems. Lecture 29 Windows 7 (History, Design Principles, System Components, Programmer Interface) Summer 2018

Transcription:

ez80acclaim Family of Microcontrollers Version 1.2.0 PRELIMINARY Introduction The (RZK) is a realtime, preemptive, multitasking kernel designed for time-critical embedded applications. It is currently available for use with ZiLOG's ez80acclaim product line. RZK is supplied as a C library module. Features This version of RZK includes the following features, which are described on the following pages: Fast context switching Small memory footprint Modular design Configurable compile options Portable design Interrupt handling Threads with 32 priority levels Support for priority inheritance Interprocess communication, including semaphore, message queue, and event groups Software timer Memory management Device Driver Framework, including several drivers RZK file system These features are tailored to the requirements of typical 8-bit applications. A description of these features follows. Fast Context Switching RZK can context-switch between threads in approximately 12µs (measured on an ez80f91 MCU operating with 1 wait state at 50MHz). This interval includes the time required to identify the next ready-to-run thread as well as the time required to save and restore the context of the two threads, resulting in very low system overhead. Context-switching time exhibits negligible variation as the number of threads increases. Small Memory Footprint RZK offers a very low memory footprint. The basic kernel and thread occupies only 9 KB of ROM. Other objects can be optionally linked in. Additional objects are optimized for minimum memory requirements the full version of RZK occupies about 21 KB of ROM. The minimum RAM required is only about 1KB. Modular Design The modular design of RZK allows minimal footprint increase when using the object library. The RZK binary image file is prepared in such a way so that only objects required by the application are linked. Interdependency between modules is very minimal. Therefore, only the objects that are used in the application are included in the final downloadable image. Configurable Compilation System parameters, such as the number of objects required (threads, semaphores, etc.) can be specified at compile time. RZK allocates memory for object control blocks based on the number of objects specified in the configuration file. Features such as debug support and priority inheritance support can be enabled or disabled at compile time. Additionally, the duration of the RZK system timer ZiLOG Worldwide Headquarters 532 Race Street San Jose, CA 95126 Telephone: 408.558.8500 Fax: 408.558.8300 www.zilog.com

v1.2.0 2 tick is configurable. These compile-time configuration options make RZK fully configurable, thus enabling the developer to fine-tune RZK to application requirements. Portable Design Most of RZK is written in C. To boost RZK performance, a few of the critical routines are written in Assembly. Only these files must be changed when RZK is ported to a new platform. As a result, porting operations are minimized. Interrupt Handling RZK manages all interrupt-related tasks. It provides APIs to install an interrupt service routine (ISR) for a particular peripheral device, and to conditionally enable and disable interrupts. The interrupt-handling mechanism allows ISR execution in a separate thread so as to minimize worst-case system interrupt latency. Worst-case system interrupt latency for RZK is approximately 30 microseconds. Threads with 32 Priority Levels RZK provides preemptive and nonpreemptive threads. The threads can either preempt other threads based on priority, or share the CPU cooperatively among equal-priority threads using roundrobin scheduling. Thread priority can be changed at run-time. Support for Priority Inheritance RZK supports a priority inheritance protocol to solve a priority inversion problem common in binary semaphores. The low-priority blocked thread inherits the priority of the highest-priority thread blocked on that semaphore. RZK provides solutions for both unbounded and bounded priority inversion. Interprocess Communication RZK offers various mechanisms for communication and synchronization between threads, as described below. Semaphore RZK provides both binary and counting semaphore support. A priority inheritance protocol is used to emerge from deadlock scenarios. Message Queue RZK provides message queues for asynchronous communication between threads. It supports buffered message copying. High-priority messages can be placed at the front of the queue. Threads can wait on the queue based on their priority, or FIFO. Event Groups Event Groups are provided for control synchronization and do not contain any information. An event group can accommodate a maximum of 24 events. This mechanism is very useful for synchronizing multiple threads based on specific events. Software Timer RZK provides software timers to invoke tasks at periodic intervals. RZK maintains a system tick with the help of a hardware timer device that enables RZK threads to run the software timer, perform timed blocks on resources, and support clock functions. Memory Management Fixed-size memory pools are provided for deterministic memory allocation, which is very useful for time-critical applications. RZK also supports variable-size memory allocation with features such as finite and infinite blocking. RZK Device Driver Kit A device driver framework is provided to support the development of drivers for most of the peripherals on the ez80acclaim product line. This support includes a board support package consisting of drivers for UART, EMAC, SPI, I 2 C, and RTC in all ez80acclaim and ez80l92 platforms. It also provides the drivers for different NOR Flash devices that provide simple-to-use APIs for interacting with devices equipped with Flash memory.

v1.2.0 3 ZiLOG File System This release includes a file system to manage both RAM and Flash media on ez80acclaim platforms. Using this file system, the application developer can store files in RAM or Flash media, then perform any file-related operation such as read, write, or append to the stored files. The ZiLOG File System also provides full-fledged directory operations, along with power-failure mode support. Network Services A full fledged TCP/IP stack has been developed using RZK, which offers basic as well as advanced networking features for low-cost embedded networking applications. Architecture The architecture follows a layered approach. The lowest layer is the RZK Core, which provides basic kernel services. Above the core layer are the RZK objects, which are used by the application via an application programming interface (API). RZK objects use the kernel services of the RZK Core for resource management. These kernel services provide a set of easy-to-use APIs that allow the end-user application to manage different activities, as shown in Figure 1. The Resource Queue Manager keeps track of threads waiting for resources, and the Time Queue Manager provides facilities such as the Timed Wait and Sleep functions. The Scheduler schedules and dispatches threads based on a scheduling policy. The RZK Core also features hardware-dependent files that are specific to particular architectures. User Application Threads Timers Interprocess Communication Mechanisms Message Queues Semaphores Event Groups Memory Partitions Regions Interrupts Device Driver Framework Resource Queue Manager Scheduler RZK Core Hardware-Dependent Files Time Queue Manager User Device Driver Code Hardware (ez80 Family of MPUs/MCUs) Figure 1. Architecture

v1.2.0 4 The RZK Object Layer library comprises a number of optional RZK objects, such as threads, semaphores, and memory management. The design of individual modules inside the library is extremely modular. Unless and until an application specifically uses an RZK object, it is not included in the final binary image. This modular approach reduces the final footprint of your application. RZK services can be accessed by an application via a set of easy-to-use APIs. The layered architecture of RZK makes it scalable, and new features can be easily plugged in. Version 1.2.0 of RZK provides improved performance through a new interrupt model, as well as a Device Driver Framework (DDF) that includes drivers for a Flash file system and several board interfaces (UART, EMAC, SPI, I 2 C, and RTC). Examples Provided The standard RZK package provides several sample applications that demonstrate various features of the RZK for easy reference. Router Example This application simulates a data router using relevant RZK objects to demonstrate the routing of packets and messages. The following RZK features are shown: Thread communication with message queues Thread synchronization with semaphores and event groups Use of timers Use of memory partitions Interrupt Example This simple application demonstrates the use of an interrupt used within the RZK environment to synchronize and cause the display of a message by an idle thread. This package also contains examples that demonstrate the use of the UART and RTC drivers. It also contains the interactive ZiLOG File System shell that implements file and directory operations that are similar to DOS commands, such as md, cd, dir, del, deldir, deltree, and more. Development Tools RZK is supported by the ZiLOG Developer Studio Integrated Development Environment (ZDSII), which provides compiling, debugging, and projectbuilding tools for the quick and efficient development of embedded applications. ZDSII is included in all ez80acclaim development kits. RZK is also compatible with the IAR Embedded Workbench, a third party C/C++ tool chain. Packaging The standard RZK package for ez80acclaim microcontrollers is supplied as a C object library module plus application examples. Documentation The following documents describe the features, functions, and usage of the ZiLOG Real-Time Kernel and are available in each RZK kit. v1.2 Quick Start Guide (QS0048). Enables the user to install the RZK software and quickly get up and running. It guides the user through a sample application. v1.2 User Manual (UM0075). Offers a detailed explanation of the different RZK configurations and sample applications. It also contains a section that analyzes RZK performance numbers and FAQs. v1.2 Reference Manual (RM0006). Provides a comprehensive explanation of the APIs and data structures provided by RZK.

v1.2.0 5 Ordering Information RZK Package Part Number Description Support Standard Release ez800000100kro Object code/library package Free support via zilog.com Source Release ez800000100krs Full RZK source is provided Full support with 6-month product updates This publication is subject to replacement by a later edition. To determine whether a later edition exists, or to request copies of publications, contact: ZiLOG Worldwide Headquarters 532 Race Street San Jose, CA 95126 Telephone: 408.558.8500 Fax: 408.558.8300 www.zilog.com Document Disclaimer ZiLOG is a registered trademark of ZiLOG Inc. in the United States and in other countries. All other products and/or service names mentioned herein may be trademarks of the companies with which they are associated. ZiLOG is a registered trademark of ZiLOG Inc. in the United States and in other countries. All other products and/or service names mentioned herein may be trademarks of the companies with which they are associated. 2005 by ZiLOG, Inc. All rights reserved. Information in this publication concerning the devices, applications, or technology described is intended to suggest possible uses and may be superseded. ZiLOG, INC. DOES NOT ASSUME LIABILITY FOR OR PROVIDE A REPRESENTATION OF ACCURACY OF THE INFORMATION, DEVICES, OR TECHNOLOGY DESCRIBED IN THIS DOCUMENT. ZiLOG ALSO DOES NOT ASSUME LIABILITY FOR INTELLECTUAL PROPERTY INFRINGEMENT RELATED IN ANY MANNER TO USE OF INFORMATION, DEVICES, OR TECHNOLOGY DESCRIBED HEREIN OR OTHERWISE. Except with the express written approval ZiLOG, use of information, devices, or technology as critical components of life support systems is not authorized. No licenses or other rights are conveyed, implicitly or otherwise, by this document under any intellectual property rights.