FreeRTOS Emulator with SDL2 Based Graphics and Input Library  1.0
A POSIX wrapper to run FreeRTOS on an x86 machine with some basic input and output libraries aimed at making teaching FreeRTOS simpler.
async_message_queues.c File Reference

Basic example functions on how to use the message queues in the AIO library. More...

#include <stdlib.h>
#include "FreeRTOS.h"
#include "task.h"
#include "gfx_print.h"
#include "async_message_queues.h"

Macros

#define MSG_QUEUE_BUFFER_SIZE   1000
 
#define MSG_QUEUE_MAX_MSG_COUNT   10
 

Functions

void MQHandlerOne (size_t read_size, char *buffer, void *args)
 
void MQHanderTwo (size_t read_size, char *buffer, void *args)
 
void vMQDemoTask (void *pvParameters)
 
int xCreateMessageQueueTasks (void)
 Creates the demo message queue task found in async_message_queues.c. More...
 
void vDeleteMessageQueueTasks (void)
 Deletes the demo message queue task found in async_message_queues.c. More...
 

Variables

const char * mq_one_name = "FreeRTOS_MQ_one_1"
 
const char * mq_two_name = "FreeRTOS_MQ_two_1"
 
aIO_handle_t mq_one = NULL
 
aIO_handle_t mq_two = NULL
 
TaskHandle_t MQDemoTask = NULL
 

Detailed Description

Basic example functions on how to use the message queues in the AIO library.

Author
Alex Hoffman
Date
23 January 2023
----------------------------------------------------------------------
Copyright (C) Alexander Hoffman, 2023
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
----------------------------------------------------------------------

Macro Definition Documentation

◆ MSG_QUEUE_BUFFER_SIZE

#define MSG_QUEUE_BUFFER_SIZE   1000

◆ MSG_QUEUE_MAX_MSG_COUNT

#define MSG_QUEUE_MAX_MSG_COUNT   10

Function Documentation

◆ MQHanderTwo()

void MQHanderTwo ( size_t  read_size,
char *  buffer,
void *  args 
)

◆ MQHandlerOne()

void MQHandlerOne ( size_t  read_size,
char *  buffer,
void *  args 
)

◆ vMQDemoTask()

void vMQDemoTask ( void *  pvParameters)