@@ -10,85 +10,145 @@ declare namespace sfloat {
1010 /**
1111 * Add two soft floats
1212 */
13- //% blockId=sfloat_add block="Add two SoftFloats x %x|and y %y" shim=sfloat::add
13+ //% blockId=sfloat_add block="[SF] add x %x|and y %y" shim=sfloat::add
1414 function add ( x : number , y : number ) : number ;
1515
1616 /**
1717 * Multiply two soft floats
1818 */
19- //% blockId=sfloat_multiply block="Multiply x %x|and y %y" shim=sfloat::multiply
19+ //% blockId=sfloat_add_f block="[F] add x %x|and y %y" shim=sfloat::add_f
20+ function add_f ( x : number , y : number ) : number ;
21+
22+ /**
23+ * Multiply two soft floats
24+ */
25+ //% blockId=sfloat_multiply block="[SF] multiply x %x|and y %y" shim=sfloat::multiply
2026 function multiply ( x : number , y : number ) : number ;
2127
28+ /**
29+ * Multiply two soft floats
30+ */
31+ //% blockId=sfloat_multiply_f block="[F] multiply x %x|and y %y" shim=sfloat::multiply_f
32+ function multiply_f ( x : number , y : number ) : number ;
33+
2234 /**
2335 * Subtract two soft floats
2436 */
25- //% blockId=sfloat_minus block="subtract x %x |from y %y " shim=sfloat::minus
37+ //% blockId=sfloat_minus block="[SF] subtract y %y |from x %x " shim=sfloat::minus
2638 function minus ( x : number , y : number ) : number ;
2739
2840 /**
29- * Divide two integers
41+ * Subtract two soft floats
3042 */
31- //% blockId=sfloat_div_float block="divide x %x|by y %y (using floats) " shim=sfloat::div_float
32- function div_float ( x : number , y : number ) : number ;
43+ //% blockId=sfloat_minus_f block="[F] subtract y %y|from x %x " shim=sfloat::minus_f
44+ function minus_f ( x : number , y : number ) : number ;
3345
3446 /**
3547 * Divide two soft floats
3648 */
37- //% blockId=sfloat_div block="divide x %x|by y %y" shim=sfloat::div
49+ //% blockId=sfloat_div_f block="[F] divide x %x|by y %y" shim=sfloat::div_f
50+ function div_f ( x : number , y : number ) : number ;
51+
52+ /**
53+ * Divide two soft floats
54+ */
55+ //% blockId=sfloat_div block="[SF] divide x %x|by y %y" shim=sfloat::div
3856 function div ( x : number , y : number ) : number ;
3957
4058 /**
4159 * Get sine of a soft float
4260 */
43- //% blockId=sfloat_sin block="sine of radians %x" shim=sfloat::sin
61+ //% blockId=sfloat_sin block="[SF] sine of radians %x" shim=sfloat::sin
4462 function sin ( x : number ) : number ;
4563
64+ /**
65+ * Get sine of a soft float
66+ */
67+ //% blockId=sfloat_sin_f block="[F] sine of radians %x" shim=sfloat::sin_f
68+ function sin_f ( x : number ) : number ;
69+
4670 /**
4771 * Get cosine of a soft float
4872 */
49- //% blockId=sfloat_cos block="cosine of radians %x" shim=sfloat::cos
73+ //% blockId=sfloat_cos block="[SF] cosine of radians %x" shim=sfloat::cos
5074 function cos ( x : number ) : number ;
5175
76+ /**
77+ * Get cosine of a soft float
78+ */
79+ //% blockId=sfloat_cos_f block="[F] cosine of radians %x" shim=sfloat::cos_f
80+ function cos_f ( x : number ) : number ;
81+
5282 /**
5383 * Get tangens of a soft float
5484 */
55- //% blockId=sfloat_sin block="tangens of radians %x" shim=sfloat::tan
85+ //% blockId=sfloat_tan block="[SF] tangens of radians %x" shim=sfloat::tan
5686 function tan ( x : number ) : number ;
5787
88+ /**
89+ * Get tangens of a soft float
90+ */
91+ //% blockId=sfloat_tan_f block="[F] tangens of radians %x" shim=sfloat::tan_f
92+ function tan_f ( x : number ) : number ;
93+
5894 /**
5995 * Get square root of a soft float
6096 */
61- //% blockId=sfloat_sin block="sqrt of x %x" shim=sfloat::sqrt
97+ //% blockId=sfloat_sqrt block="[SF] sqrt of x %x" shim=sfloat::sqrt
6298 function sqrt ( x : number ) : number ;
6399
100+ /**
101+ * Get square root of a soft float
102+ */
103+ //% blockId=sfloat_sqrt_f block="[F] sqrt of x %x" shim=sfloat::sqrt_f
104+ function sqrt_f ( x : number ) : number ;
105+
64106 /**
65107 * Get arcus sine of a soft float
66108 */
67- //% blockId=sfloat_sin block="arcsin of x %x" shim=sfloat::asin
109+ //% blockId=sfloat_asin block="[SF] arcsin of x %x" shim=sfloat::asin
68110 function asin ( x : number ) : number ;
69111
112+ /**
113+ * Get arcus sine of a soft float
114+ */
115+ //% blockId=sfloat_asin_f block="[F] arcsin of x %x" shim=sfloat::asin_f
116+ function asin_f ( x : number ) : number ;
117+
70118 /**
71119 * Get arcus cosine of a soft float
72120 */
73- //% blockId=sfloat_sin block="arccos of x %x" shim=sfloat::acos
121+ //% blockId=sfloat_acos block="[SF] arccos of x %x" shim=sfloat::acos
74122 function acos ( x : number ) : number ;
75123
124+ /**
125+ * Get arcus cosine of a soft float
126+ */
127+ //% blockId=sfloat_acos_f block="[F] arccos of x %x" shim=sfloat::acos_f
128+ function acos_f ( x : number ) : number ;
129+
76130 /**
77131 * Get arcus tangens of a soft float
78132 */
79- //% blockId=sfloat_atan block="arctan of x %x" shim=sfloat::atan
133+ //% blockId=sfloat_atan block="[SF] arctan of x %x" shim=sfloat::atan
80134 function atan ( x : number ) : number ;
81135
136+ /**
137+ * Get arcus tangens of a soft float
138+ */
139+ //% blockId=sfloat_atan_f block="[F] arctan of x %x" shim=sfloat::atan_f
140+ function atan_f ( x : number ) : number ;
141+
82142 /**
83143 * Get arcus tangens 2 of two soft float
84144 */
85- //% blockId=sfloat_atan2 block="atan2 of y %y|and x %x" shim=sfloat::atan2
145+ //% blockId=sfloat_atan2 block="[SF] atan2 of y %y|and x %x" shim=sfloat::atan2
86146 function atan2 ( y : number , x : number ) : number ;
87147
88148 /**
89149 * Get opposite of a soft float
90150 */
91- //% blockId=sfloat_neg block="opposite of x %x" shim=sfloat::neg
151+ //% blockId=sfloat_neg block="[SF] opposite of x %x" shim=sfloat::neg
92152 function neg ( x : number ) : number ;
93153}
94154
0 commit comments