Reading data from a DXL360 digital level onto your computer

There are some digital levels on the market that are really nice tools to have for a variety of purposes. I grabbed a DXL360 and am really happy with it so far. When I wanted to do an angle vs. time calibration measurement of my Barn Door Startracker over 10s of minutes, I really wanted to get the data from the level into a computer so I could plot and process it a bit.

The level has a USB port but the manual suggests that an optional attachment is required to get it into a computer, at least for this model. However, the manual also states that data comes out of it in RS232 format. I bet I could read that data with some more generic equipment that I have sitting around. And it turned out to be easy. This post shows how I did it.

First, I cut a USB cable in half to tap into the level. As a check, I hooked the data lines up to my oscilloscope. I was greeted with a binary bitstream that changed pleasantly as I rotated the level. Looks promising.

Next, I just plugged the data cables into my extraordinarily useful Adafruit FT232H breakout board, which is basically a universal attachment for these kinds of things. I love this chip. In this case I just plugged the TX line (white in my cable) to the UART RX line on the chip (D1) and GND to GND.

To test it, I just followed Adafruit’s instructions to open up a screen session on my (linux) laptop. I was immediately greeted with and ASCII stream of data in a meaningful format. The FT232H starts up in its UART serial mode by default which is exactly what I needed for this device. Yay: this is an easy project.

Since I didn’t need any advanced features of this chip for this project, I didn’t need to use the Adafruit library or anything. I just wrote a bit of Python 3 code to parse the data:

This code creates a generator that you iterate over very simply for whatever application you need. For my calibration stuff, the plotting code looks like this:

 

That just reads some data and then plots it, like this:Sweeeeeet.

Coupling a computer to this level really makes it an even more awesome and useful instrument.

Update: I open-sourced this software as part of the startracker project on github.

5 thoughts on “Reading data from a DXL360 digital level onto your computer”

  1. hello,
    I am Mechanical engineering student.
    As part of a final project for a degree , I need to work with the DXL360S component.
    I would be happy if you would contact me by email and answer a few questions.
    Regards,

  2. Good day, code is not my strength. I use DXL360s to measure car alignment cambers. Is there a way a dummy like me can get the screen output to display and subsequently record on something like excel, word.

    Thanks!

    1. Hi Phil. The code here is almost all you’d need to do that. You’d run the function and print it out to the screen rather than to a plot like in the 2nd code. But you will need someone to help who can run a python script is all. It’s relatively easy, but does take a certain amount of time commitment to get up and running.

      https://docs.python.org/3/tutorial/index.html

      I think they’re starting to teach this more in high schools and stuff so maybe see if you can find a volunteer there?

  3. Can any one tell what app i nedd to connect the DXL360S with the blue tooth adaptor to my android Mobile please
    Thankyou

Leave a Reply

Your email address will not be published. Required fields are marked *