{"id":22450,"date":"2025-01-28T18:38:59","date_gmt":"2025-01-28T18:38:59","guid":{"rendered":"https:\/\/liquidinstruments.com\/?p=22450"},"modified":"2025-04-18T23:30:05","modified_gmt":"2025-04-18T23:30:05","slug":"analyzing-time-of-flight-data-from-a-lidar-distance-sensor","status":"publish","type":"post","link":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/","title":{"rendered":"Analyzing time-of-flight data from a LiDAR distance sensor","gt_translate_keys":[{"key":"rendered","format":"text"}]},"content":{"rendered":"<p><span style=\"font-weight: 400;\">One method for determining the distance to an unknown object involves reflecting pulses of light off the object and detecting the reflection. The time difference between the transmitted and received pulses is then calculated and multiplied by the speed of light, giving the total distance that the light traveled back and forth from the object. This method, called a time-of-flight measurement, is often used in radar and LiDAR applications.\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400;\">In this application note, we use <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/hardware-platforms\/mokugo\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Moku:Go<\/span><\/a><span style=\"font-weight: 400;\">, an FPGA-based device from Liquid Instruments that offers a reconfigurable suite of test and measurement instruments, in conjunction with a commercial range finder to perform precise time-of-flight measurements. The range finder will emit and detect infrared pulses and provide a stream of serial data to the Moku:Go device. Moku:Go also serves as the power source and the decoder for the serial data provided by the range sensor. We will demonstrate how to visualize this serial data using both the Moku <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/integrated-instruments\/oscilloscope\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Oscilloscope<\/span><\/a><span style=\"font-weight: 400;\"> and <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/integrated-instruments\/logic-analyzer-pattern-generator\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Logic Analyzer \/ Pattern Generator<\/span><\/a><span style=\"font-weight: 400;\"> instruments. Finally, we will automate the measurement using the <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/apis\/python-api\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Moku Python API<\/span><\/a><span style=\"font-weight: 400;\">.\u00a0\u00a0<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Required materials<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">To perform this experiment, you will need the equipment listed below. See Figure 1 for a visual guide.<\/span><\/p>\n<p><b>Moku:Go: <\/b><span style=\"font-weight: 400;\">This setup specifically calls for a <a href=\"https:\/\/liquidinstruments.com\/products\/hardware-platforms\/mokugo\/\">Moku:Go<\/a> device because it offers a built-in programmable power supply. Here, we use it to power the LiDAR distance sensor. If you have different Moku hardware, then you will also need a 5V DC power supply.\u00a0<\/span><\/p>\n<p><b>Two banana-plug-to-alligator-clip wires: <\/b><span style=\"font-weight: 400;\">These will connect to the Moku:Go and provide 5 V of DC power to the range finder.\u00a0<\/span><\/p>\n<p><b>One BNC-to-alligator clip wire: <\/b><span style=\"font-weight: 400;\">This will be used for passing the serial data from the range finder to the input of the Moku:Go.<\/span><\/p>\n<p><b>LiDAR distance sensor: <\/b><span style=\"font-weight: 400;\">The range finder that we are using for this experiment is the <\/span><a href=\"https:\/\/en.benewake.com\/TFLuna\/\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400;\">TF Luna<\/span><\/a><span style=\"font-weight: 400;\"> from Benewake. The TF Luna measures distance by calculating the time-of-flight of a pulse train of infrared light. This data is then sent to the receiver via <a href=\"https:\/\/www.circuitbasics.com\/basics-uart-communication\/\" target=\"_blank\" rel=\"noopener\">UART serial encoding<\/a>. A link to the documentation for this device is available in the References section at the end of the article. The TF Luna has six connecting wires; here, we use only the power, ground, and Tx wires. These connections are labeled in Figure 1.\u00a0<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22452 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-1024x476.png\" alt=\"Equipment required for the time-of-flight demo. Left: TF Luna, with the three connections labeled. Center: BNC-to-alligator connection wire. Right: Banana plug-to-alligator clip connection wires\" width=\"900\" height=\"418\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-1024x476.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-300x139.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-768x357.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-1536x714.png 1536w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM-600x279.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.13.16\u202fAM.png 2036w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\">Figure 1: Equipment required for the time-of-flight demo. Left: <a href=\"https:\/\/en.benewake.com\/TFLuna\/\" target=\"_blank\" rel=\"noopener\">TF Luna<\/a>, with the three connections labeled. Center: BNC-to-alligator connection wire. Right: Banana plug-to-alligator clip connection wires.<\/p>\n<h2><span style=\"font-weight: 400;\">Setting up the equipment<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">These steps outline all of the connections to be made between the instruments. The full schematic is shown in Figure 2.\u00a0<\/span><b><\/b><\/p>\n<ul>\n<li aria-level=\"1\"><b>Prepare the LiDAR range sensor. <\/b><span style=\"font-weight: 400;\">With the TF Luna, you will need to remove one end of the connector, and then use wire strippers to expose a section where the alligator clips can connect. If you are using a<\/span><span style=\"font-weight: 400;\">\u00a0different sensor, make sure you have its documentation on hand when following the subsequent steps.\u00a0<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul>\n<li aria-level=\"1\"><b>Connect the range sensor to the power supply. <\/b><span style=\"font-weight: 400;\">Attach an alligator clip to the Vpp wire (red), and insert the banana plug into Power 1 on the back side of Moku:Go.Repeat with the next wire, fixing the clip to the GND wire (black) and connecting the banana plug into the shared ground between Power 1 and Power 2.\u00a0<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<ul>\n<li aria-level=\"1\"><b>Connect the data transmission cable. <\/b><span style=\"font-weight: 400;\">Plug the BNC end of the data transmission cable into Input 1 on Moku:Go. Connect the red alligator clip (or probe, depending on your cable) to the Tx wire on the range sensor. If there is also a grounding clip on the cable, you can fix it to the GND pin on the range sensor, so that it and the power supply share a common ground.\u00a0<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p style=\"text-align: center;\"><img decoding=\"async\" class=\"aligncenter wp-image-22453 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-1024x568.png\" alt=\"Diagram depicting connection between a LiDAR distance sensor and Moku:Go\" width=\"900\" height=\"499\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-1024x568.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-300x166.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-768x426.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-1536x852.png 1536w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM-600x333.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png 1950w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/>Figure 2: Connections between the range sensor and Moku:Go. The device\u2019s built-in power supply provides a 5 V power signal to the sensor. The Tx pin of the sensor provides serial data to Input 1 on Moku:Go.<\/p>\n<h2><span style=\"font-weight: 400;\">Verifying and viewing the output\u00a0<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">These steps will outline how to set up the Moku <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/integrated-instruments\/oscilloscope\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Oscilloscope<\/span><\/a><span style=\"font-weight: 400;\"> to view the transmitted signal from the range sensor.\u00a0<\/span><\/p>\n<p style=\"padding-left: 40px;\"><b>1.\u00a0 Launch the Moku Oscilloscope. <\/b><span style=\"font-weight: 400;\">From the main screen of the Moku software, click on the Oscilloscope to launch it in single-instrument mode. On the main Oscilloscope screen, there should be no signal on Channel A, as power has not yet been provided to the sensor. <\/span><\/p>\n<p style=\"padding-left: 40px;\"><b>2. Enable the power supply. <\/b><span style=\"font-weight: 400;\">On the Moku screen, click on the menu icon in the upper left corner (three parallel lines). Then click \u201cPower Supply.\u201d A new menu window will appear on-screen. Click the slider next to PPSU 1 to enable it, then change the voltage value to \u201c5.000.\u201d You should see the range sensor begin to draw current (~50 mA) from Moku:Go, as shown in Figure 3. <\/span><\/p>\n<p style=\"padding-left: 40px;\"><b>3. View the output on the Oscilloscope.<\/b> Once power is enabled, return to the Oscilloscope screen. You should see a repeated pattern similar to the example shown in Figure 3. This is the serial data that is being transmitted by the range sensor, encoded in UART format. Each packet contains a number of bits of data, with the value of the bit determined by whether the voltage is high (3.3 V) or low (~200 mV). Having confirmed that the range sensor is functioning correctly, we will now use the Moku Logic Analyzer \/ Pattern Generator to interpret this serial data.<\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22454 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-1024x659.png\" alt=\"The Moku Oscilloscope and Power Supply, showing bursts of UART serial data\" width=\"900\" height=\"579\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-1024x659.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-300x193.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-768x494.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-1536x989.png 1536w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM-600x386.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.19.41\u202fAM.png 1762w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 3: The Moku Oscilloscope and Power Supply, showing bursts of UART serial data.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Decoding the serial output\u00a0<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">We will now set up the Moku <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/integrated-instruments\/logic-analyzer-pattern-generator\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Logic Analyzer \/ Pattern Generator<\/span><\/a><span style=\"font-weight: 400;\"> to decode the UART serial data.\u00a0<\/span><b><\/b><\/p>\n<p style=\"padding-left: 40px;\"><b>1. Launch the Moku Logic Analyzer \/ Pattern Generator <\/b><span style=\"font-weight: 400;\">From the main screen of the Moku software, click on Logic Analyzer \/ Pattern Generator to launch it in single-instrument mode. Since this reconfigures the Moku:Go FPGA, you must re-enable the device\u2019s Power Supply to power the range sensor. To do so, follow the steps outlined in the section above.<\/span><\/p>\n<p style=\"padding-left: 40px;\"><b>2. Set up the acquisition. <\/b><span style=\"font-weight: 400;\">On the right-hand side of the screen, you will see the Acquisition menu. Change the source to \u201cAnalog inputs,\u201d which will bypass the 16-bit digital I\/O and use the analog inputs 1 and 2 as two-bit data. Since UART is a binary format, this is acceptable. Remove the Bit 1 display by clicking the \u201cX\u201d to the right of the plot. Under the \u201cTimebase setting,\u201d set the time span to 1.5 ms and the offset to -300 \ud835\udecds. If the range sensor is powered on, you should see the serial pattern appear on the Bit 0 plot, as shown in Figure 4.<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22455 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995-1024x611.png\" alt=\"The Moku Logic Analyzer \/ Pattern Generator, showing a sequence of UART serial data\" width=\"900\" height=\"537\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995-1024x611.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995-300x179.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995-768x458.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995-600x358.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-3.48.32\u202fPM-e1738002206995.png 1213w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 4: The Moku Logic Analyzer \/ Pattern Generator, showing a sequence of UART serial data, similar to the example shown in Figure 3.<\/span><\/p>\n<p style=\"padding-left: 40px;\"><b>3. Add the protocol decoder. <\/b><span style=\"font-weight: 400;\">The Moku Logic Analyzer \/ Pattern Generator can decode a number of standard protocols, including UART, which converts the serial data into hexadecimal format. To add a decoder, click the plus sign in the top left of the screen, as shown in Figure 5.<\/span><\/p>\n<p><img decoding=\"async\" class=\"wp-image-22461 size-full aligncenter\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738002988514.png\" alt=\"\" width=\"884\" height=\"330\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 5: Adding the protocol decoder for the UART serial data.<\/span><\/p>\n<p style=\"text-align: left; padding-left: 40px;\"><b>4. Configure the protocol decoder. <\/b><span style=\"font-weight: 400;\">For the data to be properly decoded, the instrument must know how many bits of information are contained in the UART sequence, as well as the rate at which the information is arriving (also known as the Baud rate). This will depend on the exact nature of your range finder. If you are using the TF Luna, the configuration is shown in Figure 6. The data width is 8 bits with 1 stop bit, there is no parity check, and the default Baud rate is 115200. If the decoder settings match with those of the transmitter, you will see the hexadecimal numbers appear in the UART decoder line, as shown in Figure 6.<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22459 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-1024x455.png\" alt=\"UART serial data converted to hexadecimal numbers\" width=\"900\" height=\"400\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-1024x455.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-300x133.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-768x341.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-1536x683.png 1536w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM-600x267.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-02-at-4.11.52\u202fPM.png 1645w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 6: UART serial data converted to hexadecimal numbers.\u00a0<\/span><\/p>\n<p style=\"text-align: left; padding-left: 40px;\"><b>7. Interpret the data. <\/b><span style=\"font-weight: 400;\">Refer to the documentation of your range sensor to make sense of the numerical data decoded by Moku:Go. In the case of the TF Luna, the default 9-byte data sequence is shown in Figure 7. The first two bytes are always 59, which is confirmed by the decoded data. Bytes 2 and 3 in this case provide the distance information in centimeters. If you put your hand over the range sensor, you can see this value change appropriately.<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22460\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-1024x413.jpg\" alt=\"TF Luna datasheet excerpt\" width=\"844\" height=\"341\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-1024x413.jpg 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-300x121.jpg 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-768x310.jpg 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-1536x620.jpg 1536w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-2048x827.jpg 2048w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-103209-600x242.jpg 600w\" sizes=\"(max-width: 844px) 100vw, 844px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 7: An excerpt from the TF Luna datasheet helps us interpret the results.\u00a0<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Automating the measurement with Python\u00a0<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Unfortunately, <a href=\"https:\/\/www.techtarget.com\/whatis\/definition\/hexadecimal\" target=\"_blank\" rel=\"noopener\">hexadecimal numbers<\/a> are not intuitive for the perception of distance. In this section, we will use the <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/apis\/python-api\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Moku Python API<\/span><\/a><span style=\"font-weight: 400;\"> to create an automated distance measurement tool that will continuously refresh the data. The following script is available from the Liquid Instruments <\/span><a href=\"https:\/\/github.com\/liquidinstruments\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400;\">Github<\/span><\/a><span style=\"font-weight: 400;\"> page. A tutorial for setting up the Moku Python API is available <\/span><a href=\"https:\/\/apis.liquidinstruments.com\/api\/getting-started\/starting-python.html\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400;\">here<\/span><\/a><span style=\"font-weight: 400;\">.\u00a0<\/span><b><\/b><\/p>\n<p style=\"padding-left: 40px;\"><b>1. Import and connect. <\/b><span style=\"font-weight: 400;\">In addition to any \u201cstandard\u201d imports that are needed, you must import any instruments you plan to deploy onto Moku:Go, as shown in Figure 8. In this example, we create an instance of the Moku Logic Analyzer \/ Pattern Generator and specify the device\u2019s IP address.\u00a0<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22461 size-full\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738003047407.png\" alt=\"Python code to import and connect the Moku Logic Analyzer, specifying the device's IP address. \" width=\"884\" height=\"334\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738003047407.png 884w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738003047407-300x113.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738003047407-768x290.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.54.02\u202fPM-e1738003047407-600x227.png 600w\" sizes=\"(max-width: 884px) 100vw, 884px\" \/><\/p>\n<p style=\"text-align: center;\">Figure 8: Import and connect the code.<\/p>\n<p style=\"padding-left: 40px;\"><strong>2. Set up the power supply.<\/strong> Any function of Moku software can also be performed using the API, including the DC power supply. Specify your desired supply, as well as the maximum voltage and current values, as shown in Figure 9.<\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22462 size-full\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.55.41\u202fPM-e1738003152125.png\" alt=\"Setting up a DC power supply with Python. \" width=\"899\" height=\"279\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.55.41\u202fPM-e1738003152125.png 899w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.55.41\u202fPM-e1738003152125-300x93.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.55.41\u202fPM-e1738003152125-768x238.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-1.55.41\u202fPM-e1738003152125-600x186.png 600w\" sizes=\"(max-width: 899px) 100vw, 899px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 9: Set up the DC power supply.\u00a0<\/span><\/p>\n<p style=\"text-align: left; padding-left: 40px;\"><b>3. Set up the Moku Logic Analyzer \/ Pattern Generator. <\/b><span style=\"font-weight: 400;\">This simply requires using a number of commands to provide the same information to the protocol decoder that we specified earlier, including the data width, stop width, Baud rate, and channel number. Note that \u201cget_data\u201d returns the entire trace of raw data, so we only ask it for the protocol analyzer data, labeled \u2018pa1.\u2019<\/span><\/p>\n<p style=\"text-align: center;\"><img decoding=\"async\" class=\"alignnone wp-image-22463 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM-1024x262.png\" alt=\"Set up a protocol decoder with Python.\" width=\"900\" height=\"230\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM-1024x262.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM-300x77.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM-768x196.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM-600x153.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.01.38\u202fPM.png 1116w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 10: Set up the protocol decoder.<\/span><\/p>\n<p style=\"text-align: left; padding-left: 40px;\"><b>4. Display the data. <\/b><span style=\"font-weight: 400;\">Within the data array, we can see that the state variable alternates between \u201cidle\u201d and \u201cdata.\u201d We want to look at the 3rd data bit, which corresponds to the 5th element in the array. Within this dictionary, we want the value attached to the \u2018data\u2019 key, which gives us our distance value in centimeters. After recovering this value, we use the <\/span><i><span style=\"font-weight: 400;\">tkinter<\/span><\/i><span style=\"font-weight: 400;\"> package to create a display that updates with the most recent measured distance value. The code, along with an example window, is shown in Figure 11. \u00a0 \u00a0<\/span><\/p>\n<p><img decoding=\"async\" class=\"aligncenter wp-image-22464 size-large\" src=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM-1024x425.png\" alt=\"Figure 11: The Python code for an array for a continuously updating display, along with the display itself.\u00a0\" width=\"900\" height=\"374\" srcset=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM-1024x425.png 1024w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM-300x125.png 300w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM-768x319.png 768w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM-600x249.png 600w, https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-03-at-2.09.44\u202fPM.png 1224w\" sizes=\"(max-width: 900px) 100vw, 900px\" \/><\/p>\n<p style=\"text-align: center;\"><span style=\"font-weight: 400;\">Figure 11: The code for a continuously updating display, along with the display itself.\u00a0<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Conclusion<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Moku:Go is a powerful and flexible multi-tool for electronic test and measurement applications. In this demonstration, we used Moku:Go in conjunction with a range sensor to perform a time-of-flight distance measurement. Thanks to the flexibility of Moku:Go, we can power the sensor with the device\u2019s programmable power supply, as well as view and decode the serial data using the Moku Oscilloscope and Logic Analyzer \/ Pattern Generator instruments. We also implemented a continuously updating range measurement script using the Moku Python API.\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400;\">To learn more about the Moku platform, click <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/hardware-platforms\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">here<\/span><\/a><span style=\"font-weight: 400;\">. To explore the instruments cost-free, download our <\/span><a href=\"https:\/\/liquidinstruments.com\/products\/desktop-apps\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">desktop app<\/span><\/a><span style=\"font-weight: 400;\"> and select demo mode.\u00a0<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Questions?<\/span><\/h2>\n<h2><span style=\"font-weight: 400;\">Get answers to FAQs in our Knowledge Base<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">If you have a question about a device feature or instrument function, check out our extensive <\/span><a href=\"https:\/\/knowledge.liquidinstruments.com\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">Knowledge Base<\/span><\/a><span style=\"font-weight: 400;\"> to find the answers you\u2019re looking for. You can also quickly see popular articles and refine your search by product or topic.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Join our User Forum to stay connected<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Want to request a new feature? Have a support tip to share? From use case examples to new feature announcements and more, the <\/span><a href=\"https:\/\/forum.liquidinstruments.com\/\" rel=\"noopener\"><span style=\"font-weight: 400;\">User Forum<\/span><\/a><span style=\"font-weight: 400;\"> is your one-stop shop for product updates, as well as connection to Liquid Instruments and our global user community.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">References<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Benewake TF Luna documentation: <\/span><a href=\"https:\/\/en.benewake.com\/DataDownload\/index_pid_20_lcid_21.html\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400;\">https:\/\/en.benewake.com\/DataDownload\/index_pid_20_lcid_21.html<\/span><\/a><\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"excerpt":{"rendered":"<p>One method for determining the distance to an unknown object involves reflecting pulses of light off the object and detecting the reflection. The time difference between the transmitted and received pulses is then calculated and multiplied by the speed of light, giving the total distance that the light traveled back and forth from the object. [&hellip;]<\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"author":49,"featured_media":22453,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"content-type":"","footnotes":""},"categories":[92],"tags":[],"class_list":["post-22450","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-white-papers","site-category-logic-analyzer-pattern-generator","site-category-mokugo"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.0 (Yoast SEO v27.0) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>How to Analyze Time-of-flight Data From a LiDAR Distance Sensor<\/title>\n<meta name=\"description\" content=\"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments&#039; Python API.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Analyzing time-of-flight data from a LiDAR distance sensor\" \/>\n<meta property=\"og:description\" content=\"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments&#039; Python API.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\" \/>\n<meta property=\"og:site_name\" content=\"Liquid Instruments\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/LiquidInstruments\/\" \/>\n<meta property=\"article:published_time\" content=\"2025-01-28T18:38:59+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-04-18T23:30:05+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1950\" \/>\n\t<meta property=\"og:image:height\" content=\"1082\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Jason Ball\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@liquidinstrmnts\" \/>\n<meta name=\"twitter:site\" content=\"@liquidinstrmnts\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jason Ball\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"11 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\"},\"author\":{\"name\":\"Jason Ball\",\"@id\":\"https:\/\/liquidinstruments.com\/#\/schema\/person\/9e95fcc52e40f7754fd85152937b68fa\"},\"headline\":\"Analyzing time-of-flight data from a LiDAR distance sensor\",\"datePublished\":\"2025-01-28T18:38:59+00:00\",\"dateModified\":\"2025-04-18T23:30:05+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\"},\"wordCount\":1923,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/liquidinstruments.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png\",\"articleSection\":[\"White papers\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\",\"url\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\",\"name\":\"How to Analyze Time-of-flight Data From a LiDAR Distance Sensor\",\"isPartOf\":{\"@id\":\"https:\/\/liquidinstruments.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png\",\"datePublished\":\"2025-01-28T18:38:59+00:00\",\"dateModified\":\"2025-04-18T23:30:05+00:00\",\"description\":\"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments' Python API.\",\"breadcrumb\":{\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage\",\"url\":\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png\",\"contentUrl\":\"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png\",\"width\":1950,\"height\":1082,\"caption\":\"schematic\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/liquidinstruments.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Analyzing time-of-flight data from a LiDAR distance sensor\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/liquidinstruments.com\/#website\",\"url\":\"https:\/\/liquidinstruments.com\/\",\"name\":\"Liquid Instruments\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/liquidinstruments.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/liquidinstruments.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/liquidinstruments.com\/#organization\",\"name\":\"Liquid Instruments\",\"url\":\"https:\/\/liquidinstruments.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/liquidinstruments.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/i0.wp.com\/liquidinstruments.com\/wp-content\/uploads\/2020\/10\/BrandMark-Preferred-RGB-Color.png?fit=1000%2C924&ssl=1\",\"contentUrl\":\"https:\/\/i0.wp.com\/liquidinstruments.com\/wp-content\/uploads\/2020\/10\/BrandMark-Preferred-RGB-Color.png?fit=1000%2C924&ssl=1\",\"width\":1000,\"height\":924,\"caption\":\"Liquid Instruments\"},\"image\":{\"@id\":\"https:\/\/liquidinstruments.com\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/LiquidInstruments\/\",\"https:\/\/x.com\/liquidinstrmnts\",\"https:\/\/www.instagram.com\/liquidinstruments\/\",\"https:\/\/www.linkedin.com\/company\/liquidinstruments\/\",\"https:\/\/www.youtube.com\/c\/LiquidInstruments\",\"https:\/\/vimeo.com\/liquidinstruments\"],\"hasMerchantReturnPolicy\":{\"@type\":\"MerchantReturnPolicy\",\"merchantReturnLink\":\"https:\/\/liquidinstruments.com\/support\/warranty-repairs-and-service\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/liquidinstruments.com\/#\/schema\/person\/9e95fcc52e40f7754fd85152937b68fa\",\"name\":\"Jason Ball\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/liquidinstruments.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/b0e7502ee45ec194baeba408e7aa6836fee5a4bdef40b7b10bd8788a1b32ad6c?s=96&d=wavatar&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/b0e7502ee45ec194baeba408e7aa6836fee5a4bdef40b7b10bd8788a1b32ad6c?s=96&d=wavatar&r=g\",\"caption\":\"Jason Ball\"},\"sameAs\":[\"https:\/\/www.linkedin.com\/in\/jason-ball-quantum\/\"]}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How to Analyze Time-of-flight Data From a LiDAR Distance Sensor","description":"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments' Python API.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/","og_locale":"en_US","og_type":"article","og_title":"Analyzing time-of-flight data from a LiDAR distance sensor","og_description":"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments' Python API.","og_url":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/","og_site_name":"Liquid Instruments","article_publisher":"https:\/\/www.facebook.com\/LiquidInstruments\/","article_published_time":"2025-01-28T18:38:59+00:00","article_modified_time":"2025-04-18T23:30:05+00:00","og_image":[{"width":1950,"height":1082,"url":"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png","type":"image\/png"}],"author":"Jason Ball","twitter_card":"summary_large_image","twitter_creator":"@liquidinstrmnts","twitter_site":"@liquidinstrmnts","twitter_misc":{"Written by":"Jason Ball","Est. reading time":"11 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#article","isPartOf":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/"},"author":{"name":"Jason Ball","@id":"https:\/\/liquidinstruments.com\/#\/schema\/person\/9e95fcc52e40f7754fd85152937b68fa"},"headline":"Analyzing time-of-flight data from a LiDAR distance sensor","datePublished":"2025-01-28T18:38:59+00:00","dateModified":"2025-04-18T23:30:05+00:00","mainEntityOfPage":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/"},"wordCount":1923,"commentCount":0,"publisher":{"@id":"https:\/\/liquidinstruments.com\/#organization"},"image":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage"},"thumbnailUrl":"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png","articleSection":["White papers"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/","url":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/","name":"How to Analyze Time-of-flight Data From a LiDAR Distance Sensor","isPartOf":{"@id":"https:\/\/liquidinstruments.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage"},"image":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage"},"thumbnailUrl":"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png","datePublished":"2025-01-28T18:38:59+00:00","dateModified":"2025-04-18T23:30:05+00:00","description":"Learn how to use the Moku Logic Analyzer to decode serial data from a LiDAR distance sensor using the Liquid Instruments' Python API.","breadcrumb":{"@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#primaryimage","url":"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png","contentUrl":"https:\/\/liquidinstruments.com\/wp-content\/uploads\/2025\/01\/Screenshot-2025-01-27-at-10.15.02\u202fAM.png","width":1950,"height":1082,"caption":"schematic"},{"@type":"BreadcrumbList","@id":"https:\/\/liquidinstruments.com\/white-papers\/analyzing-time-of-flight-data-from-a-lidar-distance-sensor\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/liquidinstruments.com\/"},{"@type":"ListItem","position":2,"name":"Analyzing time-of-flight data from a LiDAR distance sensor"}]},{"@type":"WebSite","@id":"https:\/\/liquidinstruments.com\/#website","url":"https:\/\/liquidinstruments.com\/","name":"Liquid Instruments","description":"","publisher":{"@id":"https:\/\/liquidinstruments.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/liquidinstruments.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/liquidinstruments.com\/#organization","name":"Liquid Instruments","url":"https:\/\/liquidinstruments.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/liquidinstruments.com\/#\/schema\/logo\/image\/","url":"https:\/\/i0.wp.com\/liquidinstruments.com\/wp-content\/uploads\/2020\/10\/BrandMark-Preferred-RGB-Color.png?fit=1000%2C924&ssl=1","contentUrl":"https:\/\/i0.wp.com\/liquidinstruments.com\/wp-content\/uploads\/2020\/10\/BrandMark-Preferred-RGB-Color.png?fit=1000%2C924&ssl=1","width":1000,"height":924,"caption":"Liquid Instruments"},"image":{"@id":"https:\/\/liquidinstruments.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/LiquidInstruments\/","https:\/\/x.com\/liquidinstrmnts","https:\/\/www.instagram.com\/liquidinstruments\/","https:\/\/www.linkedin.com\/company\/liquidinstruments\/","https:\/\/www.youtube.com\/c\/LiquidInstruments","https:\/\/vimeo.com\/liquidinstruments"],"hasMerchantReturnPolicy":{"@type":"MerchantReturnPolicy","merchantReturnLink":"https:\/\/liquidinstruments.com\/support\/warranty-repairs-and-service\/"}},{"@type":"Person","@id":"https:\/\/liquidinstruments.com\/#\/schema\/person\/9e95fcc52e40f7754fd85152937b68fa","name":"Jason Ball","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/liquidinstruments.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/b0e7502ee45ec194baeba408e7aa6836fee5a4bdef40b7b10bd8788a1b32ad6c?s=96&d=wavatar&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/b0e7502ee45ec194baeba408e7aa6836fee5a4bdef40b7b10bd8788a1b32ad6c?s=96&d=wavatar&r=g","caption":"Jason Ball"},"sameAs":["https:\/\/www.linkedin.com\/in\/jason-ball-quantum\/"]}]}},"gt_translate_keys":[{"key":"link","format":"url"}],"_links":{"self":[{"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/posts\/22450","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/users\/49"}],"replies":[{"embeddable":true,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/comments?post=22450"}],"version-history":[{"count":9,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/posts\/22450\/revisions"}],"predecessor-version":[{"id":23877,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/posts\/22450\/revisions\/23877"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/media\/22453"}],"wp:attachment":[{"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/media?parent=22450"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/categories?post=22450"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/liquidinstruments.com\/wp-json\/wp\/v2\/tags?post=22450"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}