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

Disabled IPv6 - Failed to send lidar UDP data to destination host #94

Open
Sollimann opened this issue Feb 10, 2022 · 1 comment
Open

Comments

@Sollimann
Copy link

Sollimann commented Feb 10, 2022

In case you're getting this kind of error from the Lidar (OS0-128 in my case), I thought I should share a fix:

image

It could be that you're computer has IPv6 disabled by default. In my case the Intel NuC on the Clearpath Jackal has disabled IPv6 in the GRUB bootloaderen: /etc/default/grub. To fix the issue you can either enable IPv6 or your can make changes to the drivers client.cpp file. I did the latter:

  1. change hints.ai_family to AF_INET (line 77 ish)
    client.cpp
  memset(&hints, 0, sizeof hints);
  // hints.ai_family = AF_INET6;
  hints.ai_family = AF_INET;
  hints.ai_socktype = SOCK_DGRAM;
  hints.ai_flags = AI_PASSIVE;
  1. comment out the following (ish line 103 - 112)
    client.cpp
  // int off = 0;
  // if (setsockopt(
  //     sock_fd, IPPROTO_IPV6, IPV6_V6ONLY, (char *)&off,
  //     sizeof(off)))
  // {
  //   std::cerr << "udp setsockopt(): " << impl::socket_get_error() <<
  //     std::endl;
  //   impl::socket_close(sock_fd);
  //   return SOCKET_ERROR;
  // }

related issue: ouster-lidar/ouster-sdk#185

@zehranrgi
Copy link

zehranrgi commented Aug 5, 2023

hi,
where is cpp files? I couldnt find it in drivers folder? @Sollimann

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants