Encoder rev 4.0

This paper will introduce the Encoder electronics from the hardware design standpoint. I will reference the component designators on the schematic and I assume you have a hardcopy of the schematic for reference.


This Encoder is designed around the MicroChip PIC18F8722 micocontroller. The electronics design is very simple because most of the functions needed and IO needed are built into this chip. On the schematic the PIC is divided into ten parts called IC2 plus an appended label indicating the function of each section. I did this to make it easier to draw the schematic, but this is one 80-pin quad flat pack part. This is the only surface mount part on the Encoder PC board. This part has FLASH memory of 128K and 3936 bytes of RAM. The airplane and system configuration memory is stored in the PIC’s FLASH memory. This allows 96 model configurations to be saved.


J1 is the power plug; this Encoder was designed to run on an 8-cell nicad battery pack. I have added a small fuse to prevent the short circuit radio burn up problem. I would recommend using socket pins for this fuse to make it easy to replace. The Encoder has a 5-volt regulator for its logic, this supply is also sent to the RF Deck.


IC3 is a TTL to RS232 level converted that supports two serial ports. One of the ports allows you to connect the MicroStar to a host PC for setup configuration. This port port can also be used along with the PC application to download new versions of software to the Encoder. The second RS232 port is used for the buddy box system. You do not need any additional electronics to connect to your PC, just a cable. J7 contains the RS232 lines as well as the PPM modulation signal.


Connector J6 is the interface to my sensitized RF deck and can also interface to your MP8000 RF deck. The first 3 pins contain the same signals as the 3-pin deans connector on your MP8000.


J3 is the interface to a LCD display. I used a 2 line by 16 character on glass display from Digikey. Most of the LCD displays have a very similar interface and it is easy to change the code to support other displays.


The rest of the electronics is pretty standard and I will let you ask me for more details and I’ll keep this document up to date.


J2 is the interface to the pots and switches in your radio. I organized the connector pins so I could use connectors to interface each pot or switch to the Encoder. This costs a little more but its easier to work on the system. I have also sent a ground to each function. The way the MP8000 is wired is they dasy-chain one ground from switch to switch, nothing wrong with this but I wanted to wire my radio differently. I twist a pair of wires together (signal and ground) and connect them to a two pin connector and plug it into the Encoder. This allows me to move switches and trims around anyway I like. Remember I did all of this inside a Proline case, this case is smaller than the MP8000. The Encoder has three jumpers that allow you to select the supply voltage used on the joystick, trim, and channel 6/7 controls. These jumpers allow you to use battery voltage or regulated 5 volts as the supply these controls. The jumper definitions are shown below:

JP1 Joystick supply voltage

1 – 2 Battery voltage (default)

2 – 3 +5 volt regulated supply

JP2 Trim supply voltage

1 – 2 Battery voltage (default)

2 – 3 +5 volt regulated supply

JP3 Channel 6 and 7 supply voltage

1 – 2 Battery voltage (default)

2 – 3 +5 volt regulated supply

If you change the jumpers from these default setting you will need to use the PC application to define the proper ADC reference setting. Please refer to the PC application for more details.


In addition to these supply voltage selections there are a number of resistors that you can use to reduce the supply voltage to specific potentiometers. Please refer to the schematic for full details, below are the resistors and resistor networks that can be used to lower the voltage on individual potentiometers:

RN1, 4 individual resistor network (100 ohm default) to limit the joystick supply voltages.

RN3, 4 individual resistor network (4,700 ohm default) to limit the trim supply voltages.

R4, used to limit the channel 6 supply voltage (4700 ohm default).

R6, used to limit the channel 7 supply voltage (4700 ohm default).


When would you use these jumpers or change the resistor values? Here are a couple of examples:

  • If you use wheel trim (like those on the Proline Custom Competition radios) or slide pots that use the full pot range then using 5 volts as the supply makes since. In this case you would also need to use the PC application to set the ADC reference for these ADC channels.
  • A good example of changing the resistors is the case of single stick transmitters. In this case the rudder knob used a lot more range than the other joystick channels and you would need to raise the value of RN1C. In this case you would not use the resistor network and install 4 resistors and use the necessary values.


The ADC reference can be set to two different values using the PC interface application; 3 volts unregulated and 5 volts regulated. If you use battery power to supply the control pots you must use the 3 volt reference, if you use the 5 volt regulated supply for the controls you must use the 5 volt reference.


In addition to the Encoder schematic you will find a number of additional drawings to help you build your transmitter:

  • The Transmitter wiring diagram shows the interconnection of all components that makeup the transmitter.
  • The Details drawing shows all of the interconnection cables needed to install the encoder in your transmitter.


Fabrication of an Encoder


This is not a simple task! I expect the builder to have some skills in the electronics fabrication area. In this section I will outline the steps involved in building an Encoder. You will need the following items:

  1. A good soldering iron with a very small tip.
  2. Solder paste or a flux pen, I prefer the flux pen (Kester #186), what I’m talking about is flux, not the solder/flux mix that is used for surface mount fabrication.
  3. Tweezers, or small pliers
  4. Magnifying glass, very important!
  5. Very small diameter solder
  6. Some kind of de-fluxing cleaner
  7. The PCB load map, this the drawing that show the locations of the parts.
  8. A small variable power supply would be nice, but you can live without it.

This is just a general outline of how I built my systems, the experienced builder is free to ignore these recommendations. The component side, or top side, of the PC board is the side that has the text written in white lettering.


Never drill out any of the holes, the PC boards are through hole plated and drilling will destroy the board.



  1. There is only one surface mount part to install, the PIC. Most likely you bought the PC board with the PIC installed and programmed, if not I recommend you first install the PIC. I like to do this first so that none of the big parts are in the way. The way I like to do this is, use the flux pen to “paint” flux on all the pads, then use the tweezers to hold the part in place. If you wait a couple of minutes after you apply the flux it will get sticky and help hold the PIC in place. Next; I then get a little molten solder on the tip of my iron and touch it to each and the pad. The flux will suck the solder off the tip and wick under the part. If this is done right you will never even pickup your roll of solder!
  2. Install all the resistor networks paying attention to the pin 1 location. You can use individual resistor if networks are not available. Only RN5 and RN6 are bussed, all others are individual resistor networks. Please refer to the schematic if you make your own networks.
  3. Install all remaining resistors.
  4. Install all the capacitors, for the polarized capacitors pay attention to the location of the positive lead. The schematic silk screen indicates the positive pin locations..
  5. Install IC3, noting the location of pin 1.
  6. Install F1 and I recommend you use connector pins for this fuse. You can cut the pins for a good IC socket and use these pins for the fuse.
  7. Install the connectors and jumpers.
  8. Install the buzzer, it is polarized, the + lead goes in the hole near the + symbol. The buzzer may come with a piece of tape over the hole on the top. Leave this tape on even after you wash the PC board, remove it only after its in the radio and the job is finished.
  9. You do not need to install a heat sink on IC1, but make sure the tab on the regulator does not make electrical contact with any traces on the PCB. The regulator on the parts list has an insulated body and is ideal in this application. Bend the leads down about 1/8” past where they exit from the plastic body of the regulator, make sure the flat bottom surface of the regulator is facing the PCB. I like to put a small piece of thick double sticky tape between it and the PCB, or you can use a small dot of RTV. You will want to do this after the board has been cleaned.
  10. I did not mention every part you need to install. Make sure you install all the parts shown on the parts list for the encoder unless otherwise noted.
  11. Inspect everything very closely, use you magnifying glass!
  12. Clean the board with de-flux solution. I used something called Flux-Off from Chemtronics.
  13. You need to install R12 or R13, but not both. Install R13 if you are using the on glass display (Digikey 73-1177-ND), most of the other displays will need R12 installed. I have tested with the two most popular displays. Please contact me if you have a strange display you would like supported. This is pretty easy but its not possible for me to buy one of every display. You will need to send me your encoder and display for me to test and change the software to support your custom display. The 4 line display from Earth Computer Technologies are supported and the wiring details are in another application note. They are a very good deal, and you do not need R12, R13, or R16.
  14. Inspect it again!

The parts list will list parts as a series of designators, like R1,R2,R3 or a range of designators, like R1-R4. R1-R4 means R1 through R4 and it represents 4 resistors. You will find the parts list contains a mix of these representations.


Pre-powerup tests:

  1. Use an ohm meter and check the input power line to make sure you do not have any shorts.
  2. You will need to build your display interface cable before you can test your system. Refer to the transmitter wiring diagram and the details diagrams for the cable details. You will also need a few test switches and cables. Here is what I use for PCB testing:
    1. LCD display
    2. Switches connected Run/Cal, Auto Trim, Preset and Option.
    3. Two 5K or 10K pots with connectors so you can test each channel.
  3. Prepare a power source. If you have a power supply, great! If not get 5 AA dry cells and series them up. This will give you around 7.5 volts. Put a 10 ohm resistor in series with this source to limit the current. The PCB and display will only draw about 20 milliamps and this resistor will limit the current in the case of an error!
  4. Now you need your PIC programmed. If you bought the PC board with a programmed PIC installed you are ready to go if not you need to program the bootloader into the PIC. The bootloader is never erased and allows the PC application to update the PIC without any special programming hardware. If you have a PIC without the bootloader you will need a PIC programmer to program the bootloader or you can set me your board and I’ll do it for free.

Powerup tests:

  1. Connect to your power source and powerup. Monitor the current, it should only draw a few milliamps. If this is not the case then something is install backwards or you have a short.
  2. Measure the plus 5 volt supply.
  3. Measure IC3 pin 6, it should be negative about 10V
  4. Measure IC3 pin 2, it should be positive about 10V
  5. The buzzer should be off .
  6. Put a piece of tape over the buzzer, you will be glad you did this.
  7. Make sure the display and switches are connected, do not connect the pots!
  8. Power it up! Holding the Preset and Option buttons.
  9. If all goes well, you will hear a short beep and the display will have the signon message. If this happens hold the buttons for a few seconds and then let go. The system will enter the IO test mode and the LCD will be displaying the IO ports bits, as 1s and 0s. At this point you can test all of the switches and make sure the bits change. Do not press the Option button, if you do you will advance to the ADC testing screen. So, if it does not work you will need to do more testing. Here are some ideas:
    1. You have a short some where. The best thing to do is to test with an ohm meter, the connections to the display. Make sure they are correct and not shorted to one another or ground.
    2. Test the OSC circuit for the correct values and no shorts
    3. If you have a scope then look at the OSC and make sure its working, look at the crystal pins, it should be 8MHz.
    4. Look at the control signals going to the LCD display. If they are toggling (only just after powerup) then check to see if its miswired.
  10. The display will show ports D and E on the top line in binary format with the most significant bit to the left. You can use the schematic to determine what switch is what bit. The second line displays a couple of ports that will not change. A bit is 1 when the switch is open, or not pressed. Now press the Option button to advance to the ADC testing screen. Here is the assignment of the ADC channels:
    Channel Function Up/Left Center Dwn/Right
    0 CH6 72   3AA
    1 CH7 6D   346
    2 Gnd 0    
    3 Vpos monitor 226    
    4 Aileron 39 164 258
    5 Elevator 31 144 282
    6 Rudder 3F 13D 258
    7 Throttle 04   23C
    8 Aileron trim 11   3FC
    9 Elevator trim 12   3F5
    A Rudder trim 11   39B
    B Throttle trim 13   3FF
    C Test Input 100    
    Each time you press the Option button you will advance to the next channel. After the last channel you will return to the IO test screen. Channels 0,1, and 4 through 11 can be tested with one of your pots. A word of caution here! One end of the pot connects to ground the other to the input supply voltage. The PIC input must never exceed 5 volts or it will draw lots of current and it can be damaged! The power supply voltage will need to increase to 10 volts. After these test are complete its time to bring it up!
  11. Power it off, Press the Preset and the Auto Trim buttons and power it up, after a few seconds (the display should show the signon message) let go of the buttons. It should now be running! Now its time to configure the system and this is best done after its installed in your radio. Pressing the Preset and Auto Trim tells the system to use default model settings.
  12. Your finished!

Its now time to install the Encoder in your radio. There are lots of ways to do this and I have provided a set of drawings for how I did this in my Proline upgrade. Please take a look at this and decide how you would like to proceed.


If you are going to do the in circuit programming option you will need to read the paper describing this and you will need to build the in circuit programmer and use my PC program.


Refer to the programming manual for radio configuration and programming!


Installing the Encoder in your radio


This is a big project! I think its more work than building the Encoder. Please spend some time thinking about the details and study my transmitter and details diagrams as well as the pictures to get an idea of how I did the install. I have no mounting holes on the Encoder, because there are lots of options. Below are a few general comments about the installation:

  1. First determine where you are going to mount the encoder and how. I used a couple of small L brackets and use the two mounting holes in the PCB. When I did this I made the electrical contact with the case, this is important and if your mounting insulates the encoder’s ground from the case, you will need to add a ground wire from the case to the encoders circuit ground.
  2. Next you need to decide if you are going to use connectors or just hardwire the encoder to the pots and switches in your radio. Actually you needed to make this decision as you are building the encoder, because if you are going to hardwire it you will not need, or want, to install J2. You will need J2 for the connectors, but you can use a right angle connector, or a straight one, it depends on the layout on your transmitter. I recommend you use connectors for at least the pots, you will likely need to make a few changes to these as you build the system. None of the connectors on the Encoder are keyed, the load maps will define pin 1. I like to use different colors of heat-shrink tubing on the cable end of the connectors, I use red on pin one. It’s a good idea for you to mark pin one on the encoder with a good marker.
  3. Connecting the switches and pots to the encoder, using connectors or not, can be done a couple of ways. The first radio I built used 26-gauge hook up wire that I twisted together then soldered to the pots or switches on one end and the connector on the other. I used heat shrink tubing on the connector end. I twisted these wires together using a drill, and I made different color codes for different signals. The way I wired this up is; I first connected the twisted wires to the switch or pot (two wires for a switch and 3 for a pot), and left them long enough to reach the encoder. I did not put the connectors on until all the switches and pots were routed to the encoder. I made the wires a bit longer that they needed to be and trimmed them to length after I had all of the cable routing figured out. This is a time consuming task! Another option you can consider is the way I wired the second transmitter. In this case I used multi-colored ribbon cable. I have listed the cable I used on the parts list. This option is a bit less expensive because you can buy this cable by the foot and you only need a few feet to do a transmitter. The cable I used has 25 conductors, if I wanted a pair of wires I would just strip off two of the conductors from the 25 conductor wide ribbon. This is pretty easy to do, use a pair of side cutters to separate the pair at one end, then carefully tear them apart. The rest of the process is the same. I intend to use this method from now on, it is much faster!
  4. I mentioned this earlier but I need to stress and elaborate this issue. The pots are used to tell the PIC the position of the sticks, this is done by putting ground on one end of the pot and the supply voltage on the other. The voltage on the wiper, the center pin, of the pot sends a voltage to the ADC in the PIC. The voltage on the wiper must never be higher than 5 volts or damage to the PIC will happen. The reason the pots have the supply voltage on one end is to get the maximum voltage change on the wiper as the stick is moved. The best way to test this is to install the jumpers JP1, JP2, and JP3 on pins 2 and 3, then apply power. Next measure the voltage on the wiper of each pot, adjust the pots position to get about 0.5 volts on the pot wiper. The pot directions are also important, make sure the voltage goes down when the sticks are moved to the left, or up, or low throttle. This has to be correct for the rest of the radio setup to proceed. If the direction is wrong on a pot, just reverse the two leads on the ends of the pot, if you reverse a pot you will need to readjust the center position. Spend some time on this step and make sure everything is correct before you proceed. When I say UP I mean up like up elevator, pulling back on the stick.
  5. Install the jumpers JP1, JP2, and JP3 in the proper locations, most likely pins 1 to 2 jumpered.
  6. Now you can test the digital inputs. The switches are connected to input ports on the encoder, each input port and a resistor pulling it up to 5 volts. The switches short this IO pin to ground. All switches act the same way, the push button switches are all normally open.
  7. Now apply power and hold Preset and Option buttons on power up to test all the digital and analog IO lines.
  8. Please refer to the programming manual for details on the setup of the encoder. The first thing you may need to do is format the FLASH, when you startup the system without pressing any buttons, you may be prompted to format the FLASH, do so. Next you need to do the joy stick calibration, make sure you do not format after you do the joy stick calibration or any setup work. Formatting will erase all setup information you have entered.

If the radio you are installing the Encoder in does not support all channels or you are not going to use all of the trims, make sure you ground the unused pot wipers inputs. You can do this using shorting jumpers. For example short J2 pin 4 to pin 6 to disable the Ail Trim pot.


The Encoder silk-screened text labels J2 digital inputs with letter codes. The table below decodes these letter codes into their functions. This labeling was done to make it easier to determine witch pins to connect to witch switches!


Code Function

A Aileron dual rate

B Elevator dual rate

C Rudder dual rate

D Preset

E Mix 1

F Mix 2

G Mix 3


RC Run/Cal

I Auto Trim

OP Option



K Alt aircraft

L Snap right

M Snap left


That’s pretty much it, now you can refer to the programming manual for more details on the features of the MicroStar. Please remember this is not a commercial product, its intended for the guy who likes to tinker a bit with RC radio equipment. Please forward bugs you find to me, I will update the PIC firmware as soon as I can. I would also like to hear about features you would like to see added to the radio. Ideas I like will be implemented as fast as I can write and debug the code. You are also welcome to change the software as you like to build your our custom radio, but please do not sell or claim this development as your own, I have lots of work invested in this project.


Encoder Display Options


There has been lots of confusion about the LCD display options for the MicroStar. In this section I will outline what needs to be done to use one of the three supported options. These options should cover most of the displays you will find.

No matter what type of display you use, you will need to build a cable that goes from J3 on the Encoder to the LCD display. Each of the displays I will discuss has a different type of connector and will require different cables to be built and different options on witch parts are installed on the Encoder.

The parts list shows three options and shows you the parts you will need for each of the display options supported.

Optrex DMC-50747NF

This is the display used on the original MicroStar (DigiKey 73-1177-ND. I have referred to this as the “on glass” display. That is because it is built on a piece of glass and its only 2mm thick. This display uses a SED1230 controller. Listed below are the steps you need to do in order to use this display:

  1. Build cable detail B shown on the cable details drawing.
  2. Build the on-glass display interface board.
  3. You will need to order items 33,34,36,44 and 49.
  4. Install the following parts on the encoder; R16 and R12 but do not install R13.

Use SED1230 to program the PIC18F8722.

LCD52, LCD64

This is the display purchased from Allelectronics. This display uses the HD44780 controller, this is the most common control in use today. I show connection details for a similar display I bought from Allelectronics, I one I used is no longer available. The LCD52 is identical except the display has 16 pins instead of 14, to use this display just ignore the last two pins and wire it using cable detail B, the one for the LCD52. This option also supports the Mouser 628-L167200J display. Listed below are the steps you need to do in order to use this display:

  1. Build cable detail B (LCD52) shown on the cable details drawing.
  2. You will need to order items 32,35 and 36.
  3. Install the following parts on the encoder; R16 and R13 but do not install R12.

Use LCD52.HEX to program the PIC18F8722.


This is the 4 line, 12 characters per line, display purchased from Earth Computer Technologies. This is a surplus display originally used in cell phones. The astrictive thing about this display is the price, they are only 3 bucks in quantities of ten. I have a special version of code to support this display but I have not fully exploited all four lines. The details of using this display are described in the file ECMA1010.ppt, this is a PowerPoint file that defines how to modify the display for use on the MicroStar. Listed below are the steps you need to do in order to use this display:

  1. Build the cable detail shown in the PowerPoint document, ECMA1010. This document also defines how the display’s cable need to be modified to fit in the connector.
  2. Install a 100K, 805 size, surface mount resistor on the display in the position show in the PowerPoint document.
  3. Do not install any of the following parts in the Encoder; R12, R13, and R16.
  4. You will need to order the following items; 36,45,46 and the display, 50. You can order from Earth Tech or I will provide them and buy in quantities high enough to get the good price.

Use ECMA1010.HEX to program the PIC18F8722.

Mouser 628-L167200J

The Mouser display is a 2 line by 16 character per line unit. This display uses the HD44780 controller, this is the most common control in use today. Listed below are the steps you need to do in order to use this display:

  1. Build cable detail B (LCD52) shown on the cable details drawing.
  2. You will need to order items 32,35 and 36.
  3. Install the following parts on the encoder; R16 and R13 but do not install R12.

This display has a funny pinout, so make sure and pay attention to the details drawing. This drawing shows the connection details for this display.

Use LCD52.HEX to program the PIC18F8722.


Switch ID Names


One of the new features of the MicroStar is the switch programming. You can assign most any function to any switch, with a few exceptions. For example the Option switch can’t be changed. The power up options are always using the default switch options. The table below will define the switch ID to the default switch name. This default switch name is what you will find on the schematic. When you start working with the MicroStar do not mess with the switch settings, first get use to programming the radio. The switch programming is very powerful but you can confuse yourself with the feature!


Default Name Switch ID Type
Mixer 1 SWE ON/OFF
Mixer 2 SWF ON/OFF
Mixer 3 SWG ON/OFF
Alt Aircraft SWK ON/OFF

My transmitter projects

{vsig_c}0|TransFront.jpg|This is the orginal MicroStar cronversion from A Proline Custom Competition.{/vsig_c}