> For the complete documentation index, see [llms.txt](https://gtae.gitbook.io/ifl/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gtae.gitbook.io/ifl/ifl-codebase/vicon-udp-parsing-python.md).

# Vicon UDP Parsing \[Python]

Code author: [Zhiyuan (Nick) Zhang](mailto:nickzhang@gatech.edu) of Professor Panagiotis Tsiotras's [Dynamics and Control Systems Lab](http://dcsl.gatech.edu/).

Direct repo link: <https://github.gatech.edu/GT-AE-Indoor-Flight-Laboratory/Python-Vicon-UDP-Parsing>

Python code for accessing and parsing the UDP stream output by Vicon Tracker.&#x20;

Vicon Tracker outputs a generic UDP stream that can be accessed without using the Vicon DataStream SDK. In embedded applications or where use of this SDK is not possible or undesired, it is possible to simply parse this UDP stream and extract the relevant Vicon data. DataBlock.h, in the Vicon Tracker installation folder (specifically C:\Program Files\Vicon\Tracker3.7\Simulink\UDP in the IFL PCs) describes the format of these UDP messages.

This repo contains 2 simple scripts for accessing and parsing these UDP messages:

1. SimpleSingleObjectUDP.py accesses the UDP stream, parses it to extract an object's 6 position and orientation values, then prints to the terminal.
2. MultithreadAsynchronousUDP.py extends functionality by implementing multi-threading and the ability to handle asynchronous UDP and program execution rates.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://gtae.gitbook.io/ifl/ifl-codebase/vicon-udp-parsing-python.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
