diff --git a/modules/common/adapters/adapter_gflags.cc b/modules/common/adapters/adapter_gflags.cc index 9852efcc3e1115c06b42d44a1108ec25b34d938d..99c04c6aa4cbc0a80f5d88eb6080bdd8c68b9472 100644 --- a/modules/common/adapters/adapter_gflags.cc +++ b/modules/common/adapters/adapter_gflags.cc @@ -204,10 +204,18 @@ DEFINE_string(navigation_topic, "/apollo/navigation", "navigation"); DEFINE_string(hmi_status_topic, "/apollo/hmi/status", "HMI status topic name."); DEFINE_string(audio_capture_topic, "/apollo/hmi/audio_capture", "HMI audio capture topic name."); +DEFINE_string(v2x_obu_trafficlight_topic, + "/apollo/v2x/obu/internal/traffic_light", + "v2x obu trafficlight topic name"); DEFINE_string(v2x_obstacle_topic, "/apollo/v2x/obstacles", "v2x obstacles topic name"); DEFINE_string(v2x_trafficlight_topic, "/apollo/v2x/traffic_light", - "v2x trafficlight topic name"); + "v2x traffic light topic name"); +DEFINE_string(v2x_trafficlight_for_hmi_topic, + "/apollo/v2x/traffic_light/for_hmi", + "v2x traffic light topic name for hmi"); +DEFINE_string(v2x_rsi_topic, "/apollo/v2x/rsi", "v2x rsi topic name"); + DEFINE_string(storytelling_topic, "/apollo/storytelling", "Storytelling topic."); DEFINE_string(audio_event_topic, "/apollo/audio_event", diff --git a/modules/common/adapters/adapter_gflags.h b/modules/common/adapters/adapter_gflags.h index fcd2fef43eb6b950b1866ed7afbeb26bd3733dc8..ce6b6150076db588acb71c965f3f7f95e3ceaa49 100644 --- a/modules/common/adapters/adapter_gflags.h +++ b/modules/common/adapters/adapter_gflags.h @@ -102,8 +102,11 @@ DECLARE_string(relative_map_topic); DECLARE_string(navigation_topic); DECLARE_string(hmi_status_topic); DECLARE_string(audio_capture_topic); +DECLARE_string(v2x_obu_trafficlight_topic); DECLARE_string(v2x_obstacle_topic); DECLARE_string(v2x_trafficlight_topic); +DECLARE_string(v2x_trafficlight_for_hmi_topic); +DECLARE_string(v2x_rsi_topic); DECLARE_string(storytelling_topic); DECLARE_string(gnss_raw_data_topic); DECLARE_string(stream_status_topic); diff --git a/modules/v2x/common/v2x_proxy_gflags.cc b/modules/v2x/common/v2x_proxy_gflags.cc index 64d147956ea5522560510e36df2d4c75ae4b1ca6..fe7257054e0c9d4c712a218fbd686b968b2e7e59 100644 --- a/modules/v2x/common/v2x_proxy_gflags.cc +++ b/modules/v2x/common/v2x_proxy_gflags.cc @@ -24,10 +24,14 @@ namespace apollo { namespace v2x { +// IP & PORT DEFINE_string(grpc_client_host, "127.0.0.1", "grpc client host ip"); DEFINE_string(grpc_server_host, "127.0.0.1", "grpc server host ip"); -DEFINE_string(grpc_client_port, "50100", "grpc client port num"); -DEFINE_string(grpc_server_port, "50101", "grpc server port num"); +DEFINE_string(grpc_client_port, "50100", "grpc client port"); +DEFINE_string(grpc_server_port, "50101", "grpc server port"); +DEFINE_string(grpc_debug_server_port, "50102", "grpc server debug port"); + +// Other Flags DEFINE_int64(x2v_trafficlight_timer_frequency, 10, "x2v trafficlight timer frequency"); DEFINE_bool(debug_flag, false, "debug flag"); @@ -36,6 +40,19 @@ DEFINE_int64(v2x_carstatus_timer_frequency, 10, DEFINE_string(hdmap_file_name, "/apollo/modules/map/data/sunnyvale_big_loop/base_map.bin", "hdmap file name"); -DEFINE_double(traffic_light_distance, 1000.0, "traffic light distance"); +DEFINE_double(traffic_light_distance, 250.0, "traffic light distance"); +DEFINE_double(heading_difference, 30.0 / 180.0, "max heading difference"); +DEFINE_int64(list_size, 6, "size of list which stores the traffic light data"); +DEFINE_int64(msg_timeout, 250, "timeout value which getting the msg from OBU"); +DEFINE_int64(sim_sending_num, 10, "the max sending times"); +DEFINE_bool(use_nearest_flag, true, + "use the hdmap interface get_forward_nearest_signals_on_lane flag"); +DEFINE_int64(spat_period, 150, "SPAT message periond"); +DEFINE_double(check_time, 0.5, "SPAT message periond"); +DEFINE_int64(rsu_whitelist_period, 3 * 1000, "get whitelist periond"); // 3s +DEFINE_string(rsu_whitelist_name, + "/apollo/modules/v2x/conf/rsu_whitelist.txt", + "file name for RSU whitelist"); + } // namespace v2x } // namespace apollo diff --git a/modules/v2x/common/v2x_proxy_gflags.h b/modules/v2x/common/v2x_proxy_gflags.h index 001af90e9007c11cc493151dd2f2e9e79213d74b..b2834867c5f3f4ee19b420957989c81f72eef825 100644 --- a/modules/v2x/common/v2x_proxy_gflags.h +++ b/modules/v2x/common/v2x_proxy_gflags.h @@ -26,14 +26,28 @@ namespace apollo { namespace v2x { +// IP & PORT DECLARE_string(grpc_client_host); DECLARE_string(grpc_server_host); DECLARE_string(grpc_client_port); DECLARE_string(grpc_server_port); +DECLARE_string(grpc_debug_server_port); + +// Other Flags DECLARE_int64(x2v_trafficlight_timer_frequency); DECLARE_bool(debug_flag); DECLARE_int64(v2x_carstatus_timer_frequency); DECLARE_string(hdmap_file_name); DECLARE_double(traffic_light_distance); +DECLARE_double(heading_difference); +DECLARE_int64(list_size); +DECLARE_int64(msg_timeout); +DECLARE_int64(sim_sending_num); +DECLARE_bool(use_nearest_flag); +DECLARE_int64(spat_period); +DECLARE_double(check_time); +DECLARE_int64(rsu_whitelist_period); +DECLARE_string(rsu_whitelist_name); + } // namespace v2x } // namespace apollo diff --git a/modules/v2x/conf/v2x.conf b/modules/v2x/conf/v2x.conf index 393ee1b3468582e055a50da11810e24aed5cbb77..fcaa01cb9020f5e9e42fa5a55f2ef651bb8839e9 100644 --- a/modules/v2x/conf/v2x.conf +++ b/modules/v2x/conf/v2x.conf @@ -1,5 +1,7 @@ ---debug_flag=false --x2v_trafficlight_timer_frequency=10 --v2x_carstatus_timer_frequency=10 ---grpc_client_host=192.168.10.123 +--grpc_client_host=192.168.10.21 --grpc_server_host=192.168.10.6 +--hdmap_file_name=/apollo/modules/map/data/sunnyvale_big_loop/base_map.bin +--rsu_whitelist_name=/apollo/modules/v2x/conf/rsu_whitelist.txt +