    std::vector<Panda *> pandas;
    for (int i = 0; i < serials.size() && !do_exit; /**/) {
      Panda *p = connect(serials[i], i);
      if (!p) {
        // send empty pandaState & peripheralState and try again
        send_empty_panda_state(&pm);
        send_empty_peripheral_state(&pm);
        util::sleep_for(500);
        continue;
      }
  
      pandas.push_back(p);
      ++i;
 
</s> remove     send_peripheral_state(pm, peripheral_panda);
    auto ignition_opt = send_panda_states(pm, pandas, spoofing_started);
 </s> add     send_peripheral_state(&pm, peripheral_panda);
    auto ignition_opt = send_panda_states(&pm, pandas, spoofing_started); </s> remove     //Dont send if older than 1 second
 </s> add     // Don't send if older than 1 second </s> remove void send_empty_peripheral_state(PubMaster *pm) {
  MessageBuilder msg;
  auto peripheralState  = msg.initEvent().initPeripheralState();
  peripheralState.setPandaType(cereal::PandaState::PandaType::UNKNOWN);
  pm->send("peripheralState", msg);
}

void send_empty_panda_state(PubMaster *pm) {
  MessageBuilder msg;
  auto pandaStates = msg.initEvent().initPandaStates(1);
  pandaStates[0].setPandaType(cereal::PandaState::PandaType::UNKNOWN);
  pm->send("pandaStates", msg);
}

 </s> add  </s> remove     LOGW("connected to board");
    Panda *peripheral_panda = pandas[0];
 </s> add     LOGW("connected to all pandas");

      util::sleep_for(100);
    std::vector<Panda *> pandas;
    for (int i = 0; i < serials.size() && !do_exit; /**/) {
      Panda *p = connect(serials[i], i);
      if (!p) {
      util::sleep_for(100);
      util::sleep_for(100);
      util::sleep_for(100);
      util::sleep_for(100);
        continue;
      }
  
      pandas.push_back(p);
      ++i;
keep keep keep keep replace replace replace replace keep keep keep keep keep
 boardd: misc cleanup (#28969)

* boardd cleanup

* no more front frame

* faster connect loop

* fix that on mac 
selfdrive/boardd/boardd.cc