shawnfeng0 / uorb

C++ inter-thread publish/subscribe middleware ported from PX4 and redesigned based on POSIX

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How can I support FreeRTOS?

yihua-wang opened this issue · comments

How can I support FreeRTOS?

**人?
我建议先给freertos移植POSIX封装,然后在此基础上移植uorb。
内部还需要new和delete的实现,需要自定义new,delete实现,使用freertos的内存申请接口。

谢谢你的问题,我意识到了这也许是很多人使用的场景,所以我最近也准备在freertos上移植并写个例子。

好 如果我不想用POSIX封装,只需要用FreeRTOS的API实现uorb中的mutex.h、rw_mutex.h、condition_variable.h,然后用FreeRTOS的内存申请重载new和delete就行了吧?

是的,读写锁也可以用直接用mutex代替。目前也打算把读写锁换成普通锁了,作用不大,没必要增加依赖。