Using pthreads w/o OS?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Using pthreads w/o OS?

ソリューションへジャンプ
2,387件の閲覧回数
roymessinger
Contributor V

I have a working bare metal project on K64 and need to update it with some extra features.

As it seems, I will need to use threads in my application, and since I'm new with this concept I wanted to ask, can I use posix threads or any other thread library for that matter without migrating my code to OS code? 

It is currently runing at various customer sites with remote update amd boot loader features and I'm afraid doing large changes in the code which will take alot of time to debug.

Thanks.

ラベル(1)
タグ(3)
0 件の賞賛
返信
1 解決策
2,084件の閲覧回数
bobpaddock
Senior Contributor III

Prototreads will run on bare metal C.
Works best with GCC due to its calculated GOTO, which is all hidden from you.

Protothreads - Lightweight, Stackless Threads in C 

You will have to change 'something' no matter what path you take.

元の投稿で解決策を見る

2 返答(返信)
2,085件の閲覧回数
bobpaddock
Senior Contributor III

Prototreads will run on bare metal C.
Works best with GCC due to its calculated GOTO, which is all hidden from you.

Protothreads - Lightweight, Stackless Threads in C 

You will have to change 'something' no matter what path you take.

2,084件の閲覧回数
jingpan
NXP TechSupport
NXP TechSupport

Hi roymessinger,

It seems pthread can't run in bare metal mode. It must base on a unix-like OS, such as FreeBSD, Linux. That is to say, you can't use posix threads or any other thread library for that matter without migrating you code to OS code.

Regards,

Jing

0 件の賞賛
返信