Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

psoc tx8 - problem with sending integer

Status
Not open for further replies.

prashantkulkarni

Newbie level 1
Joined
Jul 24, 2009
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
Bangalore
Activity points
1,287
tx8 psoc

Hi all members!!!

I'm a new PSoC Designer. I'm Writing in C.
I want to send an Int value to serial port of computer
In the TX8 toolbox they only talk about displaying a Hex Value.

Help me!!!
Does anyone have some sample code on how to send a Int value?
 

tx8 psoc code

Did you try using the itoa function? It basically converts the integer to ascii form, so that it can be transmitted in ascii but can be displayed as an integer.
 

psoc

because it sends ASCII codein hex format - if you want to send a number you need to convert it first to a string (which is nothing else than table of ascii codes of subsequent characters). As my predecessor said - good thing is to use itoa() function.. or.. if you send only digits try send code evaluated from
Code:
number-'0'
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top