You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.6 KiB

7 years ago
​
​
5 years ago
​
5 years ago
7 years ago
​
​
​
​
​
7 years ago
​
5 years ago
​
​
​
​
5 years ago
​
​
5 years ago
​
5 years ago
​
7 years ago
​
​
​
7 years ago
​
7 years ago
7 years ago
​
5 years ago
​
7 years ago
  1. #ifndef __LRF_CLIENTHANDLER_H_INCL__
  2. #define __LRF_CLIENTHANDLER_H_INCL__
  3. #ifndef PRU_SLAVE
  4. #include "../../data/protocol/protocolLGS3D_server.h"
  5. #include "../../data/net/netClientHandler.h"
  6. #include "LRF_SlimKernel.h"
  7. #include "../../components/base/basicLogCollection.h"
  8. #include "../../components/base/basicMutex.h"
  9. /**
  10. * TODO: Add class description
  11. *
  12. * @author Gagua
  13. */
  14. class LRF_ClientHandler : public networkClientHandler, public protocolLGS3D_Server {
  15. private:
  16. basicLogCollection * m_pLog;
  17. LRF_Kernel * m_pKernelEngine;
  18. LRF_WORK_MODE m_bKernelWM;
  19. CLIENT_WORK_MODE m_bClientWM;
  20. basicMutex m_mWMProtector;
  21. thresholdNode * m_pWorkingSAF;
  22. uint32_t m_nWorkingSAF;
  23. uint32_t m_nCurrentSampleIDofBoardData;
  24. EventsFIFO m_oOutputFIFO;
  25. basicMutex m_mOutputProtector;
  26. ALG_RUN_STATUS m_sRuntimeStatus;
  27. void setWM( CLIENT_WORK_MODE );
  28. CLIENT_WORK_MODE getWM();
  29. protected:
  30. bool packetHandler( protocolPackage *Package );
  31. public:
  32. // Constructor
  33. explicit LRF_ClientHandler( int SockFD, networkServiceEngine *ptr = NULL );
  34. // Destructor
  35. virtual ~LRF_ClientHandler();
  36. virtual bool attachEngine( networkServiceEngine *ptr );
  37. virtual bool getStatus( void );
  38. void dispatchEvent( EVENT_CONTAINER *Evt );
  39. };
  40. #endif // PRU_SLAVE
  41. #endif // __LRF_CLIENTHANDLER_H_INCL__