Wiring a potentiometer on Trex Jr

I have a Trex Jr. and want to use it to control two motors for a pan/tilt head for a video camera. Using other controllers, the wiring for the potentiometer has been straight forward. I’ve tried several wiring schemes, but am unsure if I’ve wired properly.

I am using a 5k linear pot/joystick from servocity. As with most, if not all pots, there are three terminals, and on the Trex Jr. there is the (- + S) connections. I am unsure as to what the wiring scheme should be, and what jumpers should be enabled or not, besides jumping for analog. It doesn’t make sense, at least to me to enable the BEC jumper, but have tried with on and off. Any help for this noob would be appreciated.

I’m using 12v 2.1A power supply, and 20 RPM precision gear motors rated at 10-24v, and 80mA no load current (both servocity).

I would also note that the board gets extremely hot - enough to burn fingers, and there is no LED activity. :frowning:

Hello.

Unfortunately, It sounds like your motor controller is damaged. Your statement that you’ve “tried several different wiring schemes” concerns me, as this means you’re almost guaranteed to have incorrectly wired your controller at least once. I suspect you now have a short between power and ground somewhere on your board, probably caused by this incorrect wiring.

Connecting a potentiometer to this controller should be the same as on other controllers. One side of the potentiometer connects to ground and the other to power, and the wiper pin connects to the channel’s signal input pin (think of the potentiometer as a variable voltage divider). You can obtain power from the TReX Jr if you use the BEC jumper to connect the power row to 5V. It is very important that you know which potentiometer pin is the wiper; if you connect the wiper to the power or ground pin rather than the signal pin, you could create a short between power and ground through the pot when the wiper is at one extreme.

- Ben

Is there any way to test the board to know that is damaged, or do we just assume that is is now damaged? Would wiring up for serial connection to computer allow me to test the board to confirm that I’ve damaged it?

I’ve got things hooked up now and am getting a blue LED, showing power, but see no other LED activity when moving the potentiometer.

Before trying to get the potentiometer working, let’s determine if the board is actually damaged. Can you disconnect everything except power and let me know what happens? Does the board get hot, and if so, where does it seem hottest? (Please be careful not to burn yourself while trying to locate the source!) Do you the red and green status LEDs do anything when you apply power?

If the board gets hot when only power is applied, then something on it is damaged and shorting out power to ground. The source of the heat might give us a clue as to what the damaged component is. If you don’t see any status LED activity when the board powers up, then the on-board microcontroller is not running properly and there isn’t much point in trying to connect to it serially.

- Ben

With nothing connected, I’m getting blue power LED, and there are not hot spots. The heat that was present before was under the two of the largest chips, near the motor/power block.

Red/green LEDs do nothing when power is applied. (I would note that the first time I powered up out of the box, and before adding pots, I did get blue, but no red/green activity as I’m seeing now.)

G/SO is jumpered
Analog is jumpered
Mix is jumpered
BEC is jumpered

-Trent

The learning-mode jumper (G-SO) should not be there. Does anything change if you remove it and cycle power? What are you using as your power supply? What did you have connected (and how) when the board was getting hot?

- Ben

No changes if G-SO is removed and power cycled - do get blue power LED, no other LEDs light up. Power supply is AC adapter, output 12VDC 2.1A

Motor (12v 80mA) and 5k pot were connected when it got hot, with no BEC jumper. I can’t exactly recall the wiring scheme for pot when it was hot.

Currently I have black to terminal 1 (-), red to terminal 3 (+) and yellow to terminal 2 (signal) on pot

capacitor is wired across (-) and (+) terminals on motor.

I think I’ve figured out the wiring scheme for the pot, but am pretty sure I’ve fried the board. Will place an order to get another.

If I plan to run two motors, both 12v 80mA DC motors, with a joystick to control both motor direction and speed (so analog input),
I should jumper for analog on mode, no learning/G-SO jumper, BEC jumpered to provide power to joystick pots (correctly wired), no mix?

When power is applied with no motors/analog inputs, what should I expect to see on the board? Blue power, any red?

-Trent

You should initially use the learning mode jumper to calibrate the TReX Jr for your joystick pots, and before connecting them, you should use a multimeter to make sure you know which lead is the wiper (two leads will show a fixed resistance between them, no matter what the joystick position is; the third, remaining lead is the wiper). The user’s guide explains how to calibrate the TReX Jr for your joysticks, but please ask if anything is still unclear.

Once you have calibrated the controller, you will want to set up the controller so that only the BEC and analog-mode jumpers are on. Whether you use the mix jumper depends on whether you want channel mixing or not. Without the mix jumper, the joystick on channel 1 will control motor 1 and the joystick on channel 2 controls motor 2. With the mix jumper, the two channels are mixed so that one joystick controls forward/reverse and the other controls left/right (assuming your vehicle is driven by one motor on the left side and another on the right, which is often referred to as differential-drive).

The user’s guide explains the LED behavior. The blue LED is tied directly to power, so you should see it on whenever your supply voltage is connected to VIN. When the controller first starts up, you should see the red and green status LEDs blink. If you are in learning mode, you will get one blinking pattern. If not, they will initially blink five times, once for each channel, to tell you which channels are calibrated and which are not. See the user’s guide for information on what the status LED do while the controller is running normally.

- Ben

the doc states the following:

[quote]Unused channels can impact behavior of the TReX Jr in undesirable ways. You may not plan on using the
flip or override channels, but leaving them disconnected could result in their floating to a value that would
enable flipped mode or serial override. One solution to this problem is to use the “ignored channels”
configuration parameter to set unused analog channels as ignored. The TReX Jr considers ignored channels to
be fixed at their neutral positions. An alternate, purely hardware-based solution would be to short any unused
motor channels to a used one and to tie any unused “enable” channels (4 or 5) to Vcc (the 5-volt line). By
shorting unused motor channels to a used one, you should be able to get past the safe-start portion of the
TReX’s start-up routine.[/quote]

Since I plan to only use two channels, and in a purely hardware-based solution. So if I’m not using channel 3, then I should be shorting that channel to one of the used ones. Since I will be using all three pins for the analog pots for channels one and two, how should channel three be shorted to either of the two used channels? would connecting an unused pot be sufficient? (I may actually add a third motor later for ‘roll’, so this may be the best solution anyway, even if the motor is not yet added). And to tie any unused “enable” channels to the Vcc line, would a jumper from the (-) negative or (+) positive to the Vcc pin do the trick?

New Trex Jr arrived in good order, and having correctly followed directions, it is working as expected. thanks for your help Ben.

Thanks for the update. I’m glad to hear you have things up and running!

- Ben