A small RTOS for ARM Cortex-M3/M4 based Microcontrollers.

Overview

Contributors Forks Stargazers Issues MIT License LinkedIn Build Status Lines of code GitHub release (latest by date)


Logo

A tiny RTOS for ARM Cortex-M3/M4 based Microcontrollers.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents

  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact
  8. Acknowledgements

About The Project

WeeOs is a tiny RTOS for ARM Cortex-M3/M4 processors. It currently supports two scheduling algoriths and four hardware devices.It includes a pre-emptive scheduler that supports round-robin and weighted round-robin scheduling algorithms. WeeOs if fully configurable. The scheduling algorithm and the hardware device can be set in the Makefile.

Supported Hardware

Built With

Getting Started

To get a local copy up and running follow these simple steps.

Prerequisites

Install the prerequisites. Here is how to do it on Arch Linux.

  • GNU ARM Embedded Toolchain
    sudo pacman -S arm-none-eabi-gcc
  • OpenOCD
    sudo pacman -S openocd
  • Packages for building, this is different for every distro. It includes things like GNU Make.
    sudo pacman -S base-devel

Building WeeOs

  1. Clone the repo
    git clone https://github.com/puranjaymohan/wee-os.git
  2. Get inside the wee-os directory
    cd wee-os
  3. Generate the config.mk file
    chmod +x configure.sh
    ./configure.sh
  4. Edit config.mk to choose your hardware and scheduling algorithm.
    #WeeOs Configuration File
    #Please edit this file to configure WeeOs
    
    #Name of the generated elf file
    PROJECT := main
    
    #Device for which the project has to be made
    #Available Devices: stm32l476rg lm3s811 MK64F12 TM4C123GH6PM
    DEVICE := stm32l476rg
    
    #Scheduling Algorithm used in the App
    #Available scheduling algorithms: round-robin weighted-round-robin
    SCHD_ALG := round_robin
  5. Run Make to build the final elf file.
    make
  6. Run OpenOCD in another terminal for your hardware.
    openocd -f /usr/share/openocd/scripts/board/st_nucleo_l476rg.cfg
  7. Run GDB and upload the elf file to the target.
    arm-none-eabi-gdb build/main.elf -x scripts/gdb_commands

Usage

Source Code

The repository is divided into 3 main sub directories: src, device, and scripts. The src directory includes two directories: App and Kernel. The App directory has the main.c file and all other supporting files required for the user's application. The Kernel directory has all the WeeOs files. The device directory has hardware specific filed like linker scripts etc. The scripts directory has some useful scripts.

├── device
│   ├── lm3s811
│   ├── MK64F12
│   ├── stm32l476rg
│   └── TM4C123GH6PM
├── images
│   └── logo.png
├── LICENSE
├── Makefile
├── README.md
├── scripts
│   ├── checkpatch.pl
│   └── gdb_commands
└── src
  ├── App
  └── Kernel

Using it in your project

To use WeeOs in your project just setup WeeOs using the steps above. Add your code to src/App. You can add .c .h or .s files in the src/App folder and they will be compiled, assembled, and linked automatically while running make. To create, add, kill tasks or use any other WeeOs feature, include the #include <weeOs.h> in your source file.

To understand the usage of the WeeOs API have a look at API Documentation.

API DOCUMENTATION

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Puranjay Mohan - [email protected] Abhay Chirania - [email protected]

Project Link: https://github.com/puranjaymohan/wee-os

Acknowledgements

You might also like...
HD44780 peripheral library for stm32 microcontrollers.

stm32-HD44780 This is a peripheral driver library for interfacing stm32 microcontrollers with the HD44780 display driver. The implementation uses the

A Tamagotchi P1 emulator for microcontrollers
A Tamagotchi P1 emulator for microcontrollers

MCUGotchi - A Tamagotchi P1 emulator for microcontrollers Synopsis MCUGotchi is a Tamagotchi P1 emulator for microcontrollers relying on the hardware

This repository is to share the EdgeAI Lab with Microcontrollers Series material to the entire community

This repository is to share the EdgeAI Lab with Microcontrollers Series material to the entire community. We will share documents, presentations and source code of two demo applications.

Gamepad firmware for RP2040 microcontrollers supporting Nintendo Switch, XInput and DirectInput

GP2040 Firmware GP2040 is a gamepad firmware for the RP2040 microcontroller that provides high performance and a rich feature set across multiple plat

Library for STM32 microcontrollers with HAL to communicate with absolute orientation sensor Bosh BNO055.

Bosh BNO055 sensor library fro STM32 with HAL Library for STM32 microcontrollers with HAL to communicate with absolute orientation sensor Bosh BNO055.

Vectron VGA Plus generates a 640x480@60Hz VGA signal and has an interface that works with retro computers or microcontrollers.
Vectron VGA Plus generates a [email protected] VGA signal and has an interface that works with retro computers or microcontrollers.

Vectron VGA Plus Vectron VGA Plus generates a [email protected] VGA signal and has an interface that works with retro computers or microcontrollers. Screen

Gesture-Detecting-Macro-Keyboard - Glorified Bluetooth macro keyboard with machine learning (TensorFlow Lite for Microcontrollers) running on an ESP32.
Gesture-Detecting-Macro-Keyboard - Glorified Bluetooth macro keyboard with machine learning (TensorFlow Lite for Microcontrollers) running on an ESP32.

Gesture detection tldr; Glorified Bluetooth macro keyboard with machine learning (TensorFlow Lite for Microcontrollers) running on an ESP32. Main feat

A place to collaborate on code for the Embedded.fm book club. Currently reading "STM32 ARM Programming for Embedded Systems".

Welcome to the Book Club Code site! This is a place for the Embedded.fm book club to collaborate and learn together. Repo Structure Guide Top-level fo

A lightweight ARM reverse engineering tool.

eydis A lightweight (basic and slow) ARM reverse engineering tool. I. Requierements macOS/Linux, Basics compiling tools, The SQLite3 + readline framew

Comments
  • Kill thread and Add task

    Kill thread and Add task

    Adding kill thread system call. When there is just one thread running, it returns 0. Adding logic for adding task at the first possible empty spot in tcbs array. Potentially fixed yield issue by resetting systick value to 0 every-time we yield.

    opened by Abhay-Chirania 0
  • Kernel: Add weighted round robin algorithm

    Kernel: Add weighted round robin algorithm

    Add support for the round robin algorithm to the scheduler and allow th user to choose the algorithm in Makefile. The API remains same and main application just has to provide parameters required to the algorithm.

    Signed-off-by: Puranjay Mohan [email protected]

    opened by Abhay-Chirania 0
Releases(v1.0)
Owner
Puranjay Mohan
Electronics and Embedded systems developer with experience in ARM and AVR microcontrollers, worked with protocols like USART, I2C, SPI, USB etc.
Puranjay Mohan
X-CUBE-AZRTOS-F7 (Azure RTOS Software Expansion for STM32Cube) provides a full integration of Microsoft Azure RTOS in the STM32Cube environment for the STM32F7 series of microcontrollers.

X-CUBE-AZRTOS-F7 Azure RTOS Software Expansion for STM32Cube With Azure RTOS complementing the extensive STM32Cube ecosystem providing free developmen

STMicroelectronics 7 Nov 17, 2022
An optimized "RTOS" (more than HAL but less than RTOS) for ROV controling and getting sensor data

Nitori-ROV-OS 一个专门为水下机器人(ROV、AUV)进行优化的实时操作系统,暂命名为 Nitori,中文名 荷取 可以通过修改硬件兼容层(Port)进行移植 预计最初版本支持stm32f407和stm32h750,并在实验室目前的水下机器人中进行部署 系统分为四层,六个主要组件: 硬件

Doublues_G 2 Jan 10, 2022
minimal bootloader + app example for ARM Cortex-M

cortex-m-bootloader-sample Based on https://github.com/noahp/pico-c-cortex-m , this project shows a simple bootloader+application configuration for an

Noah Pendleton 5 Jan 9, 2022
A LVGL porting for Cortex-M55 running on an Arm official FPGA prototyping development board called MPS3 (AN547)

A LVGL porting for Cortex-M55 running on an Arm official FPGA prototyping development board called MPS3 (AN547), see Figure 1. It is also possible to run the project template on an emulator called Corstone-300-FVP, which is free.

Gabriel Wang 6 Mar 19, 2022
A minimalistic implmentation of CRT0 for Cortex-M7

CM7_CRT0 A basic CRT0 like bootstrap implementation targeting Cortex-M7 The startup code basicall does: Initialize the system clock Initialize ZI regi

Malek Lamari 3 May 19, 2021
Because why not? Pi Zero bare metal project that ends in an RTOS implementation

PiZeroRTOS Because why not? This repo starts out as a Pi Zero bare metal project and it could very well end up as a viable RTOS implementation with a

null 7 Feb 13, 2022
Embox is a configurable RTOS designed for resource constrained and embedded systems

Embox is a configurable RTOS designed for resource constrained and embedded systems. Embox main idea is using Linux software without Linux.

Embox 860 Nov 20, 2022
Realtime Micro Kernel -- Event-driven Run-to-Completion RTOS with Active Objects, Timed Events, Memory Pools, and Message Queues

Realtime Micro Kernel Features Active Objects Message queues Variable sized, custom messages Periodic and single timed events Memory pools Supported P

null 3 Nov 7, 2022
This package contains the common algorithms in robotic arm, and I have developed it based on universal robot. It will be continuously updateing.

Robotic_Arm_Algorithms It contains the common algorithms in robotic arm, and will be recording the development as soon as I have completed the any one

Mingshan-Beal 84 Nov 13, 2022
LM75A temperature sensor library that you can use with STM32F10x series microcontrollers.

STM32F10x-LM75A-Library LM75A temperature sensor library that you can use with STM32F10x series microcontrollers. Launching the LM75A sensor in your a

null 11 May 2, 2022