Creating a BaseSequentialStream out of a Buffer

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderator: RoccoMarco

Post Reply
JohnL
Posts: 16
Joined: Mon Nov 11, 2013 12:49 am

Creating a BaseSequentialStream out of a Buffer

Post by JohnL »

Hey Giovanni
What are the steps I would need to make the shell write and read from a buffer instead of the serial port?

I've tried to examine the inheritance scheme, but I'm still at a loss for how to go about implementing it. It looks like I could create something based on memory streams, but to be honest I don't know what is happening with these virtual methods tables


Thank you

John
User avatar
Giovanni
Site Admin
Posts: 14891
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Creating a BaseSequentialStream out of a Buffer

Post by Giovanni »

Under ./os/various there is already a module doing that: memstreams.c/h, how is it different from what you need? it reads/writes buffers.

Giovanni
Post Reply