compiler error using sprintf while using adc example on TWRk60N512

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

compiler error using sprintf while using adc example on TWRk60N512

ソリューションへジャンプ
2,068件の閲覧回数
abdullahansari
Contributor III

Hello every one.

I am working on to build a prototype application. That would store the results of adc into file and then to SD card.

Now I am modifying the ADC example given with CW10.5 installer file. The ADC is being trigerred by pdb.

As soon as I am using sprintf function to convert adc integer results to string. The compile is giving me error. I have attached the screen shot along with ADC interrupt service routine.

Any solution?

ラベル(1)
タグ(1)
0 件の賞賛
返信
1 解決策
1,955件の閲覧回数
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello:

I guess that project was created with No I/O support. In this case you cannot use any console related functions. To solve this go to Project -> Properties -> C/C++ Build -> Settings -> Librarian, and from the "Model" drop down menu select "ewl". Also do not forget the #include <stdio.h>. Then your project should compile.

IO_support.png

Hope this is useful!

Jorge Gonzalez

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
1,956件の閲覧回数
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello:

I guess that project was created with No I/O support. In this case you cannot use any console related functions. To solve this go to Project -> Properties -> C/C++ Build -> Settings -> Librarian, and from the "Model" drop down menu select "ewl". Also do not forget the #include <stdio.h>. Then your project should compile.

IO_support.png

Hope this is useful!

Jorge Gonzalez

0 件の賞賛
返信
1,955件の閲覧回数
abdullahansari
Contributor III

Hi Jorge,

Yes you are right! The problem is solved now.

0 件の賞賛
返信