Floating Point in PSoC Creator 4.2

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
ScEn_283436
Level 5
Level 5
5 sign-ins First solution authored 100 replies posted

Hi,

Have recently upgraded from Creator 3.3 to 4.2 for a new project and none of my floating point formatting methods work. The options configuration looks a little different, so not sure what I'm missing. I'd like to be able to use sprintf if possible but even more basic, I can't store numbers cast as float in memory.

Thoughts?

Nick

0 Likes
1 Solution
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

"I can't store numbers cast as float in memory​" That's quite odd. what usually works is

double MyFloat = (double) 27; // Will store 27

Verify that in "System" view the "Heap size" is set to 0x0200 when formatting floats

Bob

View solution in original post

0 Likes
1 Reply
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

"I can't store numbers cast as float in memory​" That's quite odd. what usually works is

double MyFloat = (double) 27; // Will store 27

Verify that in "System" view the "Heap size" is set to 0x0200 when formatting floats

Bob

0 Likes