Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds reporting for Hazard Light status for Lexus. #51

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/pacmod3_core.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@ std::shared_ptr<Pacmod3TxMsg> Pacmod3TxMsg::make_message(const uint32_t& can_id)
case GlobalRptMsg::CAN_ID:
return std::shared_ptr<Pacmod3TxMsg>(new GlobalRptMsg);
break;
case HazardLightRptMsg::CAN_ID:
return std::shared_ptr<Pacmod3TxMsg>(new HazardLightRptMsg);
break;
case HeadlightRptMsg::CAN_ID:
return std::shared_ptr<Pacmod3TxMsg>(new HeadlightRptMsg);
break;
Expand Down
3 changes: 3 additions & 0 deletions src/pacmod3_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ ros::Publisher headlight_rpt_pub;
ros::Publisher headlight_aux_rpt_pub;
ros::Publisher horn_rpt_pub;
ros::Publisher wheel_speed_rpt_pub;
ros::Publisher hazards_rpt_pub;
ros::Publisher steering_pid_rpt_1_pub;
ros::Publisher steering_pid_rpt_2_pub;
ros::Publisher steering_pid_rpt_3_pub;
Expand Down Expand Up @@ -494,11 +495,13 @@ int main(int argc, char *argv[])

if (veh_type == VehicleType::LEXUS_RX_450H)
{
hazards_rpt_pub = n.advertise<pacmod_msgs::SystemRptBool>("parsed_tx/hazards_rpt", 20);
steering_pid_rpt_1_pub = n.advertise<pacmod_msgs::SteeringPIDRpt1>("parsed_tx/steer_pid_rpt_1", 20);
steering_pid_rpt_2_pub = n.advertise<pacmod_msgs::SteeringPIDRpt2>("parsed_tx/steer_pid_rpt_2", 20);
steering_pid_rpt_3_pub = n.advertise<pacmod_msgs::SteeringPIDRpt3>("parsed_tx/steer_pid_rpt_3", 20);
steering_pid_rpt_4_pub = n.advertise<pacmod_msgs::SteeringPIDRpt4>("parsed_tx/steer_pid_rpt_4", 20);

pub_tx_list.insert(std::make_pair(HazardLightRptMsg::CAN_ID, hazards_rpt_pub));
pub_tx_list.insert(std::make_pair(SteeringPIDRpt1Msg::CAN_ID, steering_pid_rpt_1_pub));
pub_tx_list.insert(std::make_pair(SteeringPIDRpt2Msg::CAN_ID, steering_pid_rpt_2_pub));
pub_tx_list.insert(std::make_pair(SteeringPIDRpt3Msg::CAN_ID, steering_pid_rpt_3_pub));
Expand Down