This documentation is out of date.
The new version of the documentation is here: https://cannylogic.com/docs |
Difference between revisions of "Integer to ASCII"
[unchecked revision] | [unchecked revision] |
(Created page with " <div style="float:right;margin:5px;"> {|class="cannytable" width="350px" |- !colspan="2" style="background-color:#AFEEEE;"|Appearance |- |colspan="2" align="center" style="...") |
(→Notes) |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
+ | __NOTOC__ | ||
<div style="float:right;margin:5px;"> | <div style="float:right;margin:5px;"> | ||
Line 6: | Line 7: | ||
!colspan="2" style="background-color:#AFEEEE;"|Appearance | !colspan="2" style="background-color:#AFEEEE;"|Appearance | ||
|- | |- | ||
− | |colspan="2" align="center" style="padding:10px;"|[[ | + | |colspan="2" align="center" style="padding:10px;"|[[File:5_10_6_2.png]] |
|- | |- | ||
!colspan="2" style="background-color:#AFEEEE;"|Symbol | !colspan="2" style="background-color:#AFEEEE;"|Symbol | ||
Line 16: | Line 17: | ||
|colspan="2" align="center"|[[Built-in Function Blocks#Converters | Converters]] | |colspan="2" align="center"|[[Built-in Function Blocks#Converters | Converters]] | ||
|- | |- | ||
− | !colspan="2" style="background-color:#AFEEEE;"| | + | !colspan="2" style="background-color:#AFEEEE;"|Inputs |
|- | |- | ||
− | |style="padding-left:1em;"| | + | |style="padding-left:1em;"|Integer: |
− | |style="padding-left:1em;"|[[ | + | |style="padding-left:1em;"|[[CFD Language#Data|Integer]] |
|- | |- | ||
− | |style="padding-left:1em;"| | + | |style="padding-left:1em;"|Base: |
− | |style="padding-left:1em;"|[[ | + | |style="padding-left:1em;"|[[CFD Language#Data|Integer]] |
|- | |- | ||
!colspan="2" style="background-color:#AFEEEE;"|Outputs | !colspan="2" style="background-color:#AFEEEE;"|Outputs | ||
|- | |- | ||
− | |style="padding-left:1em;"| | + | |style="padding-left:1em;"|Characters 1 & 0: |
− | |style="padding-left:1em;"|[[ | + | |style="padding-left:1em;"|[[#Notes|A pair of ASCII characters]] |
|- | |- | ||
|style="padding-left:1em;"|... | |style="padding-left:1em;"|... | ||
|style="padding-left:1em;"|... | |style="padding-left:1em;"|... | ||
|- | |- | ||
− | |style="padding-left:1em;"| | + | |style="padding-left:1em;"|Characters 15 & 14: |
− | |style="padding-left:1em;"|[[ | + | |style="padding-left:1em;"|[[#Notes|A pair of ASCII characters]] |
|- | |- | ||
!colspan="2" style="background-color:#AFEEEE;"|Version [[CANNY Lab]] | !colspan="2" style="background-color:#AFEEEE;"|Version [[CANNY Lab]] | ||
Line 43: | Line 44: | ||
<div style="min-height:100%;display:block;"> | <div style="min-height:100%;display:block;"> | ||
<div style="float:left;width:70px;"> | <div style="float:left;width:70px;"> | ||
− | [[ | + | [[File:5_10_6_1.png|left|Icon]] |
</div> | </div> | ||
Line 54: | Line 55: | ||
== Features == | == Features == | ||
− | + | Symbols resultаnt, flattened on the right edge of the string representation specified on the input number, are set at the respective outputs in upper register, unused upper bits are filled with the symbols "0". | |
In the case of using an invalid base value, the output value will be set to "0000000000000000". | In the case of using an invalid base value, the output value will be set to "0000000000000000". | ||
Line 61: | Line 62: | ||
{| | {| | ||
|- | |- | ||
− | |[[ | + | |[[File:5_10_6_3.png|thumb|23456 base 2 = «0101101110100000»]] |
− | |[[ | + | |[[File:5_10_6_4.png|thumb|23456 base 10 = «0000000000023456»]] |
|- | |- | ||
− | |[[ | + | |[[File:5_10_6_5.png|thumb|23456 base 16 = «0000000000005BA0»]] |
|} | |} | ||
Line 70: | Line 71: | ||
With the release of CANNY Lab version 1.8 a new data presentation added - "A pair of characters" in which the values are represented by two characters ASCII with the codes given by high and low bytes of displaying 16-bit value . | With the release of CANNY Lab version 1.8 a new data presentation added - "A pair of characters" in which the values are represented by two characters ASCII with the codes given by high and low bytes of displaying 16-bit value . | ||
− | For example, the decimal number | + | For example, the decimal number 19278 corresponding hexadecimal 0x4B4E, displayed a pair of characters «KN», having ASCII-code 0x4B, and 0x4E respectively. |
== See also == | == See also == | ||
Line 83: | Line 84: | ||
[[ASCII to Integer]] | [[ASCII to Integer]] | ||
− | [[ | + | [[Built-in_Function_Blocks | Built-in Function Blocks]] |
Latest revision as of 15:38, 1 June 2018
Appearance | |
---|---|
Symbol | |
ITOA | |
Group | |
Converters | |
Inputs | |
Integer: | Integer |
Base: | Integer |
Outputs | |
Characters 1 & 0: | A pair of ASCII characters |
... | ... |
Characters 15 & 14: | A pair of ASCII characters |
Version CANNY Lab | |
from 1.8 |
Converts a numeric value in to a hexadecimal string representation of the specified base 2, 10 or 16.
Features
Symbols resultаnt, flattened on the right edge of the string representation specified on the input number, are set at the respective outputs in upper register, unused upper bits are filled with the symbols "0".
In the case of using an invalid base value, the output value will be set to "0000000000000000".
Examples
Notes
With the release of CANNY Lab version 1.8 a new data presentation added - "A pair of characters" in which the values are represented by two characters ASCII with the codes given by high and low bytes of displaying 16-bit value .
For example, the decimal number 19278 corresponding hexadecimal 0x4B4E, displayed a pair of characters «KN», having ASCII-code 0x4B, and 0x4E respectively.