20 #include "stringManipulate.h"
39 unsigned int byte_number = ((
unsigned int) n) / 8 + (n % 8 != 0);
40 unsigned long tmp_byte_buf = 0;
52 for(i = 0; i < byte_number*8; i += 8)
55 *int_val = *int_val | tmp_byte_buf;
73 unsigned int tmp_byte_buf = 0;
84 while(tmp_byte_buf & 0x80);
109 Index writerPosition = 0;
112 string_val->
length = str_length;
114 for(i = 0; i < str_length; i++)
126 unsigned int int_val = 0;
131 *nbytes = (
Index) length;
133 if((*binary_val) ==
NULL)
136 for(i = 0; i < length; i++)
139 (*binary_val)[i]=(char) int_val;
149 boolean bool_val = 0;
159 else if(bool_val == 1)
186 dec_val->exponent = 0;
188 while(fract_part > 0)
190 fract_part_rev = fract_part_rev*10 + fract_part%10;
191 fract_part = fract_part/10;
192 dec_val->exponent -= 1;
195 dec_val->mantissa = integr_part;
197 e = dec_val->exponent;
202 dec_val->mantissa *= 10;
206 dec_val->mantissa += fract_part_rev;
210 dec_val->mantissa = -dec_val->mantissa;
239 fl_val->mantissa = mantissa;
240 fl_val->exponent = (
int16_t)exponent;
249 unsigned int monDay = 0;
250 unsigned int timeVal = 0;
251 boolean presence =
FALSE;
261 dt_val->
dateTime.tm_year = (int) year + 100;
272 dt_val->
dateTime.tm_mon = monDay / 32 - 1;
273 dt_val->
dateTime.tm_mday = monDay % 32;
285 dt_val->
dateTime.tm_hour = (timeVal / 64) / 64;
286 dt_val->
dateTime.tm_min = (timeVal / 64) % 64;
287 dt_val->
dateTime.tm_sec = timeVal % 64;
294 unsigned int tmp = 0;
330 unsigned int tzone = 0;