123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187 |
- #pragma once
- #include<string>
- #include <unordered_map>
- #include <vector>
- #define WM_NOTIFY_REP WM_APP+1
- #define WM_NOTIFY_ANSWER WM_APP+2
- #define WM_NOTIFY_REQ WM_APP+3
- //#define WM_NOTIFY_LEAVE WM_APP+3
- #define WM_NOTIFY_CANDIDATE WM_APP+4
- #define WM_NOTIFY_OFFER WM_APP+5
- #define WM_NOTIFY_LEAVE WM_APP+6
- #define WM_ASK_VIDEOREQ WM_APP+8
- template<typename T>
- struct FVector3
- {
- T X;
- T Y;
- T Z;
- };
- typedef FVector3<double> FVector3d;
-
- enum RadarPosition :int32_t
- {
- RADAR_LEFT,
- RADAR_RIGHT,
- RADAR_REAR,
- RADAR_ALL
- };
- enum RenderPosition :int32_t
- {
- FRONT,
- BACK,
- LEFT,
- RIGHT,
- LANCHOR,
- RANCHOR,
-
- ALL
- };
- enum EgoType :int32_t
- {
- None,
- User,
- Car,
- Monitor
- };
- enum CarType
- {
- ZJ,
- KRESS,
- };
- enum ChannelType:int32_t
- {
- CHANNEL_CAR,
-
- CHANNEL_RADAR,
-
- CHANNEL_ENCODE,
-
-
- CHANNEL_ALL,
- };
- enum WorkArea
- {
- Area_A,
- Area_B,
- Area_C,
- Area_D,
- Area_E,
- Area_F,
- Area_G,
- Area_H,
- Area_I,
- Area_J,
- Area_ALL
- };
- enum Metal_Area
- {
- Put_Wait =0,
- Put_1=1,
- Put_2=2,
- Put_3=3,
- Get_Wait=10,
- Get_1=11,
- Get_2=12,
- Get_3=13,
- Out_Area=100
- };
- enum UserState
- {
- Offline=0,
- Idle = 1,
- Remote = 2,
- Automotive = 3,
- AskRemote = 4
- };
- enum MoveDesc
- {
- Move_OK = 0,
- Move_Encode_Fail = 1,
- Move_Unknow_Fail = 2
- };
- enum Lock_Status
- {
- Lock_Open,
- Lock_Closed,
- Lock_CloseInvalid,
- };
- struct UserCamera
- {
- int32_t uid;
- EgoType type;
- UserState state;
- CarType carType;
- std::string name;
- std::string viewurl;
-
- };
- struct UserDriver
- {
- int32_t uid;
- EgoType type;
- UserState state;
- std::string name;
- };
- struct OfferDesc
- {
- char type[16];
- char sdp[4096 * 3-16];
- };
- struct AnswerDesc
- {
- char type[16];
- char sdp[4096 * 3 - 16];
- };
- struct CandidateDesc
- {
- char candidate[4096];
- char sdp_mid[4096];
- int32_t sdp_mline_index;
- };
- #pragma pack(1)
- #define CAN_MSG_LEN 13
- struct cannet_frame
- {
- int8_t dlc;
- int32_t canid;
-
- int8_t data[8];
- };
- #pragma pack()
- enum RobotStatus
- {
- OK,
- Fail,
- };
- class IRender
- {
- public:
- virtual void OnRender(std::unique_ptr<uint8_t>& pBuffer, int32_t width, int32_t height) = 0;
- virtual void Empty() = 0;
- };
- struct FeedData
- {
- int32_t work_pressure;//����ϵͳѹ��
- int32_t brake_pressure; //�ƶ�ϵͳѹ��
- int32_t gearbox_oil_temp;//����������
- int32_t gearbox_oil_pressure; //��������ѹ
- int32_t engine_rpm;//������ת��
- int32_t engine_pressure;
- int32_t speed;
- // int32_t gear;
- int32_t cold_water;
- int32_t steer_angle;
- int32_t left_lock_status;
- int32_t right_lock_status;
- int32_t left_angle;
- int32_t right_angle;
- };
|