Let's Make Robots!

T'REX robot controller

 

The T'REX robot controller makes controlling robots easy!

The Arduino compatible controller comes pre-programmed with sample code that lets you control it with a supplied Android app, Radio Control or with an external controller via I²C.

Specifications:

  • Wide voltage range from 6V to 30V.
  • High current power switching FET (110A) allows low current power switches to be used.
  • Switch mode regulator with 6V @ 3A output for servos.
  • ATmega328P MCU using Arduino Nano w/ 328 bootloader.
  • 5V regulator can deliver in excess of 2A for powering external controllers such as the Raspberry Pi, Beagle bone etc.
  • I²C interface with voltage translation can work with external logic from 1.5V to 5V.
  • Can be programmed via USB, FTDI interface or ISP socket.
  • Socket for optional Bluetooth module.
  • Dual FET "H" bridge with electronic braking rated for stall currents up to 40A per motor.
  • PTC self resetting fuses for each motor.
  • 4x servo outputs with 6V power in high voltage mode or direct from battery in low voltage mode.
  • 2x servo headers at 5V that can also be used for RC inputs or encoders.
  • 3-axis accelerometer (±1.5G or ±6G sensitivity) for impact detection, angle and acceleration measurements

The supplied sample code automatically detects the method of control (RC, Bluetooth or I²C) on power up. Bluetooth and RC methods offer quick, easy methods of testing your robot chassis.

The I²C mode offers complete control of all function using only 2 I/O pins making it a perfect choice for interfacing 32bit controllers such as the Raspberry Pi to your robot.

You can download the instruction manual from here:

https://docs.google.com/file/d/0B__O096vyVYqVG50VHJfTzBNTEk/edit?usp=sharing

Please make sure you read the manual before asking questions!
I may have answered your question already so make sure you read the other questions posted here first.

If you have a question then ask it here so everyone can learn. Do not email me because then no one else can read the question or the answer.

 

 

 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Hello,

I am powering my six wheeled Wild Thumper with a three cell lipo through the T'rex controller and I'm worried that I am exceeding the voltage limit for the motors. Do I need to adjust (through the PWM rc lines) the stock code compensate for the voltage or does the stock code compensate on its own?

Also I would like to add a delay in the beginning code when it reads the control method to give my receiver a chance to initialize. Would adding a "delay (3000)" in the first section of the code cause any unforseen consequences? 

Thank you,

Robb

Yes you should limit the maximum PWM to about 170 (2/3).

Adding a delay at the start is ok. Make it the first line in the setup function. Normally I would wait until the transmitter is initialized before turning on the robot.

Poked around a bit more and my problem is fixed. Wish I could tell you what I did but the rover is performing as it should. The three second initial delay works well with my receiver and I now have adjusted down the PWM for the motors. Now to bigger and better things than chasing bugs. 

Also of note... when I have the board connected to my computer one of the motor fault lights is on. From the instructions it indicates that power to the motors and the accelerometer is disconnected when the board is connected this way. I do not know if this is what the fault light is indicating or if it an indication of a larger more expensive problem. Thanks for any help. 

I do not know where I went wrong but after updating the PWM limits under the RCmode tab, every time I start the wild thumper the left set of motors comes on at full reverse. I tried to reload the stock programing but it doesn't matter. I even tried a different rc receiver. Any ideas?

I do turn on the transmitter before powering the T'rex but the receiver I am using has a short delay in connecting to the transmitter. The delay is long enough that the T'rex moves to the bluetooth section of the code.  Thank you for the quick response. 

Hello All,

I was wondering if anyone had schematics available for the T'Rex Controller? I'm experiencing some issues with my board and I would like to and diagnosis it before sending it back to SparkFun.

 

Thanks,

Donny3000

I'm sorry but at this time I cannot give out schematics.

Start a forum post and explain the problem in detail. Include good quality photos of your setup.

I have only built 1 balancing robot. Unless your a clever mathematician then you won't succeed with an acelerometer alone because when you move to correct the angle you need to then know how hard your accelerating to compensate for your compensation.

I found you needed a gyro sensor to measure the rate that the robot is tilting at and then just use the accelerometer to check the angle when rotation is near 0 otherwise the robot tends to fall over very slowly or constantly roll forward/backward depending on the gyro sensitivity.

At this point I will remind you I am not a mathematician nor an expert on balancing robots, I speak only from limited experience.

 

Though I can usually follow a written paper if the variables are defined.

I was hoping that the accelerometer in the TRex controller was good enough that I wouldn't need a gyroscope. I have an Accel/Gryo/Mag that I want to use for this. I can run it off if I2c.

I'm first going to try this with the TRex. If that is't fast enough, then I'll try a Teensy 3.1 handling the control code and the TRex handling the motor code. If that isn't enough, I'll write custom code so I can send much smaller packets.

I plan on using a complementary filter for the gyro/accelerometer, with a kalman filter dealing with the entire mess. In addition there are the wheel encoders and the control design is actually 3 PID loops.

Basically I need 50-100 Control cycles per second with the ability to change the motor's torque as quickly as possible.

Does this sound reasonable?