Geekshed – M1BXF Rotating Header Image

PICAXE-18M & MXD2125 Based Elevation Module

One of the aspects of amateur radio I enjoy is EME.  When I was active on 2m (144MHz) EME I built my own elevation system using a jack-arm but I then needed a way to feedback the angle.  I tried many ways in the past such as potentiometers then Sam G4DDK introduced me to the MXD2125 dual axis accelerometer device.

Elevation_PCB_Bottom_Arrow  Elevation_PCB_Top

This can be used, along with gravity, to measure tilt, the angle vs down.  Comparing both X & Y axis outputs the resolution can be very small, smaller than is required.  Up until now the way I got the angle back was from one of the axis digital outputs by converting it to an analogue voltage by using an RC circuit which my elevation controller could work with, but not very well.  The main problem is the analogue voltage is not pure DC and I have in the past observed inaccurate readings and sometimes it just fails to work, but this maybe wiring also.  To cure this headache I set out to make the system as fully digital as possible so I decided to measure the digital pulses from both X and Y axis’s directly with the PICAXE-18M and then either convert that to a voltage with a DAC/digital pot or send it to the shack by serial and process it there by either re-designing the elevation controller to work with serial feedback or converting the serial to analogue there.

When I searched for info on this idea I came across a webpage by Frederic, F1OAT who has already used a PICAXE-08M with an MXD2125 – info about his circuit is here and at the bottom of this page here.  I also came access some code which uses a PICAXE-18M to control a Maxim DS1803 digital potover I2C, which I have some samples of, so in the end my solution uses that. I built a test circuit using a PICAXE-08M and with the help of Frederics code proved I could get it all to work.

Elevation_Scematic_v2.0

The finished project uses a MXD2125, a PICAXE-18M, and a DS1803 and provides a fully ‘digital’ means of reporting the angle by converting it to a voltage.  I found at 0 degrees I get a voltage of ~0.2v and at 90 degrees ~4.3v out of the DS1803 which is about 0.045v per degree.  The digital pot has a resolution of 0.0195v per bit when fed from 5v.  No calibration is needed at the sensor end, only as much ‘swing’ as possible between 0 degrees and 90 degrees. As the output is linear the LVB Tracker is calibrated for 0 degree voltage and 90 degrees voltage and so knows what the angle is based on these to stored values, being digital it shouldn’t drift over time, something I think is happening with the RC circuit…

Code:

Images:

MXD2125_Elevation_Mounted MXD2125_Elevation_Mounting_Info

MXD2125_Elevation_Boxed MXD2125_Elevation_Closed

Elevation_PCB_Bottom Elevation_PCB_Top_(Boxed)

 

Revision:

240711 – Project posted to web.

2 Comments

  1. EA7UU - Jesus says:

    Hello.

    Do you have RFI problems with this device when you transmit?… I think (I may be wrong) when this acelerometer is exposed to RF camps their measurements will be incorrect.

    Thank you.

    1. m1bxf says:

      Hello Jesus,

      I never seen any issue with the reading on this with RF fields nearby. The digital lines between the MXD2125 and the PICAXE-18M chip are very short also.

      Thanks!

      Gavin.

Leave a Reply

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

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>