Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 

64 строки
2.3 KiB

  1. /*******************************************************************************
  2. * *
  3. * Copyright 2010 Rheinmetall Canada Inc. *
  4. * *
  5. * No part of this document may be reproduced, stored in *
  6. * a retrieval system, or transmitted, in any form or by any means, *
  7. * electronic, mechanical, photocopying, recording, or otherwise, *
  8. * without the prior written permission of Rheinmetall Canada Inc. *
  9. * *
  10. *******************************************************************************/
  11. /*
  12. Description:
  13. This is a template file for standard C header file.
  14. */
  15. /* ************************************************************************** */
  16. /* Revision:
  17. 000 20100616 HCAM
  18. Original version.
  19. ### YYYYMMDD Initial, Bug Identification
  20. Change description.
  21. */
  22. #ifndef _INC_UTIL_H
  23. #define _INC_UTIL_H
  24. /* ************************************************************************** */
  25. /* Includes */
  26. /* ************************************************************************** */
  27. /* Defines */
  28. #ifdef ENABLE_DEBUG_LOG
  29. #define DEBUG_LOG_SIZE 300
  30. #endif
  31. /* ************************************************************************** */
  32. /* Type definitions */
  33. /* ************************************************************************** */
  34. /* Prototypes */
  35. short SwapEndianShort(short p_sData);
  36. int SwapEndianEndianInt(int p_iData);
  37. #ifdef ENABLE_DEBUG_LOG
  38. char* GetDebugLogPtr(void);
  39. void ClearDebugLog(void);
  40. #endif
  41. //int AppendCharToStrLeadingZero(char* p_pcString, unsigned char p_cChar, int radix);
  42. //int AppendLongToStrLeadingZero(char* p_pcString, int p_iChar, int radix);
  43. int ConvertIntToStrLeadingZero(char* p_pcString, unsigned int p_iChar, int digit);
  44. int ConvertCharToStrLeadingZero(char* p_pcString, unsigned char p_cChar, int digit);
  45. int ConvertIntToStr(char* p_pcString, unsigned int p_iChar);
  46. int ConvertCharToStr(char* p_pcString, unsigned char p_cChar);
  47. unsigned int ConvertStrToValue(char* p_pcString, int p_iSize, int p_iRadix);
  48. int Crc8(char* answer, int length);
  49. void Delay(unsigned int count);
  50. #endif
  51. //EOF