EM_platform.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /**
  2. * \file EM_platform.h
  3. *
  4. *
  5. */
  6. /*
  7. * Copyright (C) 2013. Mindtree Limited.
  8. * All rights reserved.
  9. */
  10. #ifndef _H_EM_PLATFORM_
  11. #define _H_EM_PLATFORM_
  12. /* --------------------------------------------- Header File Inclusion */
  13. #include <stdio.h>
  14. #include <stdlib.h>
  15. #include <string.h>
  16. #include <stdarg.h>
  17. #include "osal.h"
  18. /* --------------------------------------------- Global Definitions */
  19. #define EM_HAVE_STATIC_DECL
  20. #define EM_HAVE_CONST_DECL
  21. /* --------------------------------------------- Structures/Data Types */
  22. /* --------------------------------------------- Macros */
  23. #define printf(...) {printf (__VA_ARGS__); printf("\r\n"); fflush(stdout);}
  24. #define scanf(...)
  25. /* --------------------------------------------- Internal Functions */
  26. /* --------------------------------------------- API Declarations */
  27. void EM_enter_sleep_pl(void);
  28. void EM_exit_sleep_pl(void);
  29. int _write (int fd, char *ptr, int len);
  30. int _read (int fd, char *ptr, int len);
  31. int _close (int fd);
  32. int _fstat (int fd);
  33. int _isatty (int fd);
  34. int _lseek (int fd);
  35. void HardFault_Handler(void);
  36. void debugHardfault(uint32_t *sp);
  37. #endif /* _H_EM_PLATFORM_ */