LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

write a 3 bit number

Offtopic, @Ben:

 

Your second image looks like spaghetti code to me Smiley Very Happy

 

@Anarki:

Gerd is right: Are you looking for something solved with math or are you looking for string handling?

 

Norbert 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 11 of 17
(531 Views)

could you elaborate a little bit though? quotient and remainder does something like this right? 13/5=2 r5. how does this help me?

0 Kudos
Message 12 of 17
(524 Views)

@Norbert_B wrote:

@Offtopic, @Ben:

 

Your second image looks like spaghetti code to me Smiley Very Happy

 

... 

Norbert 


I ussed to carry crochet needles in my tool box. a "BIOS update" back then required physical rewiring of that back-plane with some of the wirewraps being seven layers deep.

 

Sea-story:

 

After completing school on that critter I was scheduled to do maintenance on one of those beasts. I had an experienced engineer on-site "just in case'. While adjusting a power supply I slipped shorting 15 volts to the 5 volt bus and blowing out boards in the tpae drive the 11-40 front end as well as could of other widgets. When I realized what I had done i wen to teh lunch room where the experienced engineer was reading the news paper and told him what happened. He looked up from the paper then back down and said "You broke it, you fix it.".

 

That was a very long night.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 13 of 17
(522 Views)

Hi anarki,

 

some basic math:

"078" QR 10: Q = "07" and R="8"

" 07" QR 10: Q = "0" and R="7"

"  0" QR 10: Q = "0" and R="0"

 

Wow, you have three remainders which magically are the digits of your 3 digit number. Wow. Simple basic math. Wow.

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 14 of 17
(521 Views)

I simply want to take each digit out of a number and subject it to a certain function. If that means I need to convert the digit to a string because its necessary, that is not a problem. but if the initial number is 7, I need to use 007. that is absolutely necessary

0 Kudos
Message 15 of 17
(519 Views)

ok

 

0 Kudos
Message 16 of 17
(518 Views)

Is it possible it would be easier for you to use an array (or 3-element cluster) of numeric controls, and set the input range for each of them to 0-9?

0 Kudos
Message 17 of 17
(496 Views)