ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Query /run/mpa/vvpx4_sys_status in terminal

    Ask your questions right here!
    2
    4
    206
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • W
      wouter
      last edited by

      Hi,
      I like to query the data from /run/mpa/vvpx4_sys_status from inside a docker container.
      I'm running docker with -v /run/mpa/:/run/mpa:rw, so I can see /run/mpa/vvpx4_sys_status
      Is there a way to read the data without using modal_pipe_client?
      I tried cat /run/mpa/vvpx4_sys_status/request but that just stalls.
      I'm running dotnet in the container and tried using NamedPipeClientStream, but that eventually gives a time-out.

      1 Reply Last reply Reply Quote 0
      • ?
        A Former User
        last edited by

        Hi, this is not a plaintext pipe and won't show any viewable data with a cat. The data coming through is in the mavlink packet protocol. We'd strongly recommend using the library that we've set up to manage all the pipes, but it is theoretically possible to use standard unix commands or another interface. The libmodal-pipe pipes are actually more of folders that contain a number of pipes so that the data can be distributed to an arbitrary number of clients. To read the data you should echo a plaintext name into the request pipe, after which the server will create a fifo with that name which could then be catted or opened with a read i.e. echo "test" > /run/mpa/vvpx4_sys_status/request && cat /run/mpa/vvpx4_sys_status/test

        W 1 Reply Last reply Reply Quote 0
        • W
          wouter
          last edited by

          Thanks, this makes a bit more clear.

          I tried running your command, but it returns an error. I tried cat'ing test? and that stalls.

          yocto:~$ echo "test" > /run/mpa/vvpx4_sys_status/request && cat /run/mpa/vvpx4_sys_status/test
          cat: /run/mpa/vvpx4_sys_status/test: No such file or directory
          yocto:~$ ls -alh /run/mpa/vvpx4_sys_status/
          total 4.0K
          drwxr-xr-x.  2 root root 100 Jun  7 04:33 .
          drwxr-xr-x. 12 root root 260 Jan  1  1970 ..
          -rw-r--r--.  1 root root 185 Jan  1  1970 info
          prw-r--r--.  1 root root   0 Jun  7 04:33 request
          prw-r--r--.  1 root root   0 Jun  7 04:33 test?
          yocto:~$ cat /run/mpa/vvpx4_sys_status/test?
          
          
          1 Reply Last reply Reply Quote 0
          • W
            wouter @Guest
            last edited by wouter

            @Alex-Gardner Thank for your reply, could you maybe look at my question I still have?

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Powered by NodeBB | Contributors