Aufbau, Betrieb, Reparatur und der Entwicklung von Kontrollern oder sonstiger externer Hardware - Assembly, handling, repair and construction of controllers or external hardware.
Last update is relating to the dynamic speed. It seems that a solution has been found. That's why I add a small modification to the tutorial, to present the configuration (from libor). I don't know if it works, and I can't test at the moment. But it worths to try.
Here are the results of french guys who decided to follow this solution (K8055 + Sabertooth) : BIG THANK TO THEM
Interesting concept with NIKO77 : K8055 + Sabertooth + Drill motor !!!
STEPHANED61
CHRIS2
KAMI84
NIKO77
Original concept with NIKO77 : K8055 + Sabertooth + Drill motor !!!
After 6 months of "inactivity", I come back and I'm now working on a new protoype with 2 cards :
- VM110 (K8055) - Sabertooth 2 x 10 A
This kind of configuration should be adapted to use WIPER MOTORS or little kind of DC motors (100W to 250W for example, like "child scooter"). Kind of Motor MY1016 or MY1018 easy to find on internet.
-------------------------------------------------- The aim of this post is to understand the basics of this king of configuration (VM110 + Sabertooth + DC motor). And also how to configure X-sim to make it work (it was my problem but today everything is solved). --------------------------------------------------
COMPLETE TUTORIAL : NEXT POST
Last edited by adbgg on 06.03.2012, 18:02, edited 41 times in total.
...and all others who helped me in this project !!!
PROJECT
My first idea was to understand the basis of a 2 DOF platform and to learn how to configure X-SIM. I decided to start with a prototype, a small platform using 2 little DC motors. But you should know that it is possible to use more powerful DC motors (like wiper motors I suppose) using K8055 + Sabertooth.
MATERIALS
K8055
K8055 Features :
The K8055 board provides electrical inputs and outputs, either analog (the current is variable between 0V and 5V) or digital (ON/OFF, the current is 0V or 5V). It is important to understand the difference between analog and digital possibilities. We will use only analog inputs and outputs in this project, but other people have already used digital options in their projects, because sometimes there are very useful.
Analog outputs :
The analog outputs of the K8055 (DAC1 / DAC2) will be used to send an electrical signal to the Sabertooth, between 0V and 5V. The signal will determine the speed and the direction of the DC motor. It is very important to understand the behaviour of the Sabertooth in its “analog mode”. So, we have to send this kind of signal from analog outputs of the K8055 (DAC1 / DAC2) to the Sabertooth inputs (S1 / S2).
Jumpers :
IMPORTANT : Don’t forget to remove jumpers SK2 and SK3 when trying external potentiometers (number 3 and 4 from the picture). Then, turn in the clockside the 2 pots (number 5 and 6 on the picture), to get the maximum range.
Sabertooth Dual motor
Sabertooth version :
The Sabertooth 2 x 10A version is no longer available. The new version is the Sabertooth 2 x 12A : Same price but features more interesting. The new version may supports 12A continuous and peak until 25A. But I invite you to read the user manual. It is very useful to understand all the possibilities of the Sabertooth, and to avoid any error. Keep the board safe !
Analog mode :
The Sabertooth board can work in several configurations. In this project, we are interested in the “analog mode”. So we have to configure the SWITCH as follow :
SWITCH 1 = ON SWITCH 2 = ON SWITCH 4 = OFF
SWITCH 4 allows “Independant mode” to drive 2 motors. For others SWITCH, please read the user manual (everything is important).
Speed and direction :
The Sabertooth must receive an electrical signal between 0V and 5V to know the speed and the direction of the motors. The motors must support 6V-24V and without exceeding 10A continuously. Check that you have connected a battery to give electrical power 6V-24V to the Sabertooth.
0V will give a full speed in one direction 5V will give a full speed in ohter direction 2,5 V will stop the motor
There is a simple way to understand this rule by using a potentiometer. I invite you to realise this simple test before connecting K8055 with the Sabertooth. You can use a linear potentiometer of 10kohms for this test. Please note that the potentiometer is auto-powered through the Sabertooth (no need to plug another battery of 5V).
IMPORTANT : Motors may move unexpectedly if there is no electrical signal sent to S1 / S2 of the Sabertooth. No signal means 0V and “full speed in one direction”. To stop the motors, you have to send an electrical signal of 2,5V.
Feedback position : Potentiometer or Joystick
X-SIM needs to receive a feedback of the position of your motor / platform. So you need either to plug potentiometer to the K8055, or to plug a "sensor joystick" to the PC (X-SIM will find the joystick).
Joystick :
It is possible to plug a joystick with an accelerometer such as a Logitech Gamepad “sensor” (the logo “sensor” means that there is an accelerometer inside the joystick).
Potentiometers :
My project uses potentiometers to send back the position of the motor or the platform.
You must supply the potentiometer with a battery of 5V, and NOT MORE ! 09/03/2012 : To be more precise, you could supply the potentiometer with a higher voltage than 5V. For instance, I have tried with success to supply with 6V BUT in that case, I had to turn the ATT1 pot on the K8055 to lower the range and keep the signal between 0V and 5V maxi.
I’ve tried with less electrical power (3 x 1,5 V= 4,5V) and it works also, but the range is not so large.
Motors
Of course you need motors.
This project were developped with little DC motors : Solarbotics gear motors, supporting 3V-9V. I have connected a 6V power supply adaptor to the Sabertooth.
I suppose you will be interested to plug wiper motors, and I believe it is possible with this configuration (K8055 + Sabertooth). Indeed, the new Sabertooth model supports 12A continiously and 24V motors. This is the good news, even if until now, I had not the possibility to test with wiper motors.
Full connexions
Here is the full connexions between K8055, Sabertooth, potentiometers and motors. The picture shows only the connexion for 1 motor. To plug a second motor, you can replicate the same connexions with an other potentiometer and other motor.
First test with Velleman Software (K8055 Demo):
A good idea to test your connexion is to try the Velleman software. Plug the K8055 to the PC and launch the software “K8055 Demo”. Try to move the slider DA1 and look at the reaction of the motor :
· If the slider DA1 is at the middle position, the motor should not move (2,5V). If you put the slider at the top, the motor should move at full speed in one direction (5V) etc. · The AD1 slider shows the position of the potentiometer. In this way, you can check if you have a feedback.
XSIM
Test with “interface setting” menu :
The first test I propose is to move the motor through X-Profiler menu. This is a good solution to check all the connexions and to be sure that everthing’s working well. TEST : In the menu of “Interface setting” of X-Profiler, select the analog output from the list “All outputs of found interfaces” (normally DAC1 = Output analog 1), and fill in a percentage into the field between 0 and 100%, click on the button “Set output” and look to the motor reaction.
Please, try the figures below and look directly to the motor effects ;
· 0% will make the motor moves at a full speed in one direction (0V) · 100% will make the motor moves at a full speed in the other direction (5V). · 50% will stop the motor (2,5V) · 60% will make the motor moves slowly in one direction. · 40% will make the motor moves slowly on the other direction. · 50% will stop the motor.
Please read the “speed and direction” section in this tutorial (Sabertooth Dual motor). You can look directly the effects of X-SIM configuration on the motors, through K8055 + Sabertooth boards.
IMPORTANT : Without any information sent to the Sabertooth when launching X-Profiler, motors may move in full speed. I suppose the default value is set à 0%, corresponding to full speed in one direction (0V corresponds to full speed). Calibration :
The calibration can be realised by hand. If you are not able to move the motor by hand, you can use the menu « interface setting ». Select the analog output, and write a percentage of 60%. The corresponding motor will move slowly and you can calibrate maximum and minimum positions, following the instructions below :
· Maximum : Place the motor in order to move the potentiometer at the maximum, and click on the button « maximum ». · Minimum : Place the motor in order to move the potentiometer at the minimum, and click on the button « minimum ».
If there is a problem for calibration, you can click on the button « invert reference input » and repeat the procedure with maximum and minimum positions.
Create profile for Tablet-test
Force-Sender :
Force-Sender proposes several pre-configured game plugins (GTR2, Rfactor, etc…). But I suggest you to start with the TestPlugin, to avoid using a PC game and a joystick. Tablet-test : When you choose the TestPlugin”, the tablet-test will appear :
Please note that the value is set at 1000. The same value will be used in X-Profiler. IMPORTANT : The cursor of the tablet-test could be assimilated as a consign (consign : position to reach). For example, if you place the cursor at the top, the motor should move until the potentiometer reaches the consign (the top). If you place the cursor at the middle, the motor should move until the potentiometer reaches the middle. So each time you move the cursor, the motor should move until the consign is reached, and then the motor should stop. During a race game : if you drive a car and you brake until the car stops, the 2 axis (longitudinal and lateral) should move until the potentiometers reach the middle position (no G-force anymore), and then the motors should stops (no movement). It is also important to calibrate X-SIM first, before to proceed to this kind of test. Create axis in X-SIM Profiler :
Math Setup : First, you must create a new axis, with the menu “Math Setup”. Choose a G-Force (longitudinale or laterale) and double-click to reach this windows :
Ouput setup : Then you can configure the Output setup. I show you how to configure a slow speed in positive, negative and stop windows.
Click on the START button of X-SIM and move the slider of the tablet-test.
As already explained, the cursor of the tablet-test could be assimilated as a consign. So, if you place the cursor at the top, the motor should move until the potentiometer reaches the consign (the top). If you place the cursor at the middle, the motor should move until the potentiometer reaches the middle. So each time you move the cursor, the motor should move until the consign is reached, and then the motor should stop.
Create 2 speeds for the axis :
Repeat the same procedure with a new speed. At the beginning of my tests, I had problem with keeping the consign. It was solved by creating 2 speeds in the X-SIM profile (slow and fast speeds). To summarise, you must configure a "Slow speed" and a "Fast speed" :
Slow speed : positive (60%), negative (40%) and stop (50%) Fast speed : positive (100%), negative (0%) and stop (50%)
Keep in mind that 50% means 2,5V. With 2 speeds, motors will move quickly at the beginning when it is far away from the consign. The motors will move slowly when it will be very close to the consign. Then, the motors will stop at the consign.
A summary :
Fast speed : 100% is full speed in positive direction (5V) 0% is full speed in negative direction (0V) 50% is stop (2,5V), when the consign is reached !
Slow speed : 60% is slow speed in positive direction 40% is slow speed in negative direction 50% is stop, when the consign is reached !
With the picture, you can see the speed of the motor when the initial position has not reached the consign. The motor turns in fast speed when the consign is far away The motor turns in slow speed when the consign is almost reached. Then the motor stop at the consign.
Dynamic speed : Solved ? (06/03/2012)
A simplier solution may exist with the "dynamic speed" of X-SIM profiler. I suppose this will represent an other possibility instead of configuring 2 speeds in the "analog interger" mode of X-SIM profiler. But I did not suceed to configure a profile until now. If someone manages to find a solution with a "dynamic speed", I would be really grateful to use it. Other projects are based on a "dynamic speed", but there are not using Sabertooth board.
06/03/2012 : A Dynamic speed solution has been found (I hope it works, because I can't test at the moment) Look a this solution, proposed by Libory (thanks to him).
Create profile for a game :
If you have understood everything until now, you can try to configure a profile for a game (GTR2 for this example) :
· Select an other plugin in Force-Sender (select GTR2 plugin). · Change the value in the Math Setup, because G-Force effects from GTR2 are inside a range of 10.000 and –10.000 (approximetly). · Launch the game GTR2 through Force-Sender · Click “START” button of X-SIM · Play GTR2 and look at motor effects.
Prepare the WIPER MOTORS :
I would like to thanks Riton, Bigtalltim, Frakk and Mahaow for their helps. Indeed, I though it was easy but it is not so easy as I expected. Here is a wiper motor of 12V (from a CLIO), bought 20€ in a scrap-yard :
There are many cables and I was surprised to discover this rainbow of colors. In fact, there is only 1 cable interesting for us : the RED one. Usually, the RED cable concerns the fast speed, and the GREEN cable concerns the slow speed of the wiper motor. We will let the GREEN cable apart. We need also to isolate the GROUND. For this, we must remove the wiper motor to look inside.
We will use the RED cable (fast speed). But we have to cut the other cable (GROUND) to remove it from the body of the wiper motor and to pull it outside of the body. A BLACK cable would be a nice color to use for it because it corresponds to the GROUND. In this way, we obtain a 2d cable (GROUND).
When the wiper motor is prepared, You can test the direction of the wiper motor. Here is an example with fast speed of the wiper (RED cable):
+ connected to RED and - connected to the GROUND will move in one direction. - connected to RED and + connected to the GROUND will move in the other direction.
A video to show the result :
The motor is able to turn on both side : clockwise and counter-clockwise. The speed can be controlled : variable speed. K8055 is connected to the Sabertooth. The Sabertooth is powered by a PSU (12V molex). Everything is controlled by the software Velleman.
In order to supply the wiper motor, we need a 12V supplier supporting a lot of amp. Normally a simple PSU should do this job : Choose a good PSU. Indeed, I had problem with a cheap one. Start PSU without motherboard :
Anyway, it is easy to start the PSU without motherboard :
Connect the green cable from the 20+4 pins with a black one (ground).
Connecting other stuffs :
I've read many times on the web that it is also better to place a "resistance de puissance" (I don't konw the word in english) linked to a 5V output. Mine is 4,7 Ohm / 10W. It is a kind of minimum charge for the PSU to operate normally and to give a 5V and a 12V stabilized.
To explain the picture :
- MOLEX gives the 5V (red and black cables), and the 12V (yellow and black cables). - SWITCH is connected to green and black cables from the 20+4 pins. - A "resistance de puissance" is connected to the 5V, in order to charge a minimum the PSU (very hot after few miniutes, need a fan). - 12V from the MOLEX (yellow and black cables) is used to supply the Sabertooth.
Here is a picture of what I've done : Be carefull, I'm not a specialist or an electrician. I'm not sure this is the best way or the safe way to use the PSU. Replicate at your own risk.
PLEASE CHECK THE VOLTAGES FROM YOUR PSU :
I suggest you to :
- Check that the K8055 is supplied with a good 5V. - Check that the Sabertooth is supplied with a good 12V (lot of amp available)
My own tests have revealed :
- When the wiper motor is NOT connected, I can pick-up +10,7V and -11,7V output voltage from the Sabertooth (no load). - When the Wiper motor is connected, I can pick-up +9,8V and -10,9V output voltage from the Sabertooth (full speed in both directions).
The voltages were lower until I discover that the 5V from the output DAC1 / K8055 was only 4,4V at its maximum. My K8055 is now supplied by the PSU, and the DAC1 output reaches 4,6V, still under the 5V that I expected but better than the initial 4,4V.
I have realised a test and pick-up Voltage output from the Sabertooth, compared to the % of the "Interface Setting" menu of X-SIM : The middle (0V) was exactly obtained with 55% (it does not appear on the graph).
Last test with a wiper motor and Velleman Software :
Last edited by adbgg on 09.03.2012, 22:34, edited 72 times in total.
Hi - I dont have a definite answer for you, as I have not used your setup... but I do have some stuff that might help you out
you may find 2 things of use in my post " K8055 - Dual Wiper Motor Control with Variable Speed":
In page 1 - in fact in the first post - is the profile I use. That might give you a heads up about the direction and speed control for the k8055.
In page 3 Menix offered a connection diagram showing how to connect a k8055 to a mosfet board. My solution uses relays... anyway, In both solutions a digital channel on the k8055 is used to set the direction. I notice from your photograph that the digital channel LED for channel 1 is set to on - was that intentional?
One last thing that may cause you problems... I don't know whether the PWM frequencies will be compatible; the Sabretooth appears to operate on 32kHz, but the K8055 is hard coded to 23kHz.
Thanks for your reply bigtalltim, My question was especially concerning the X-sim configuration (what should I fill in the menus). But I've already made new tests and it seems to work now. Even if there is an other problem : A kind of "yoyo" problem. The platform moves all the times and has problem to keep the target position. Maybe it is due to the "Logitech extreme sensor" gamepad. I don't know exactly for the moment. So, now I imagine a system with "potar" or ("potentiometre" in french). No longer the Gamepad. I will post a big explanation of my system if I reach to make my platform works as I want. Thansk again. Regards Adbgg (hope you understand my poor english). Don't take care of the led on the picture. The Digital Led "ON" was not expected. I use only "Anlog" input and output for the moment.
One thing that might be causing your yo-yo problem is if the range of movement does not use the full sweep of the senser in your controller... this seems quite likely in fact - I think you will have better luck with a potentiometer, and there are many excellent solutions for setting them up in your build on this site. It will be easier for your setup to hold position if the position indicating device feeds back a range of 1% to 99% rather than a small range like 47% to 53%. Small ranges can give a very jittery position hold (your yo-yo effect) as the device tries to constantly correct the position.
Page 2 of the thread I mentioned before shows how to connect a pot directly to your K8055... I have found this to be most reliable and very convenient as all control is available through one interface... jim in new zealand also uses the inputs on a K8055 for position feedback in his flight sim - you may want to check his site: http://www.jimspage.co.nz/intro.html (Worth mentioning that JimNZ doesnt use the outputs on the K8055 - he has other cards for this.)
There is something you have to remember about removing jumpers to use the input ports on a K8055 - I posted a video on this subject just above the wiring diagram in my thread... from your picture though, it seems that you may have already done this! Basically, if you dont remove the jumpers on SK2 and SK3, the K8055 will ignore the input ports, and return the values of the onboard pots ATT1 and ATT2 instead!
Thanks again for your usefull advices. Yes, I heard about taking away the jumpers in order to use the analog input. That's ok for me, I've already tested and it works. Maybe I'm not so far away from a good setup, and a good platform behavior. You seem to have a good knowledge of X-xim and K8055 card. Thanks for your advices and the web links. I had a look and it is really interesting. I hope I will be back soon, to say : "IT WORKS AND I SHOW YOU HOW I MANAGED TO DO IT !!!!" See you.
I've just found how to connect the K8055 to the sabertooth, as follow : (I've put the figure also in the first post, because I think it is important to start with this)
The output signal from DAC1 is between 0V and 5V, then :
1) When DAC1 reaches 5V, the DC motor turns in one way, 2) When DAC1 is at 0V, the DC motor turns is the other way, 3) When DAC1 is at 2,5V, the DC motor doesn't move anymore.
I'm also able to choose the speed of the DC motor in both directions. For example, if DAC1 is near 2,5V, the motor will turn slowly. And if DAC1 is far away from 2,5V, the motor will turn quickly.
I'VE GOT IT !!! I've tested with X-sim, in the menu "Interface Setting", with "Test on interface output pin", with value between 0% and 100%, and it works well.
Then, we can easily imagine to connect a second motor (DAC2 ---> S2).
Now that you have the motor speed and direction sorted, you just need to connect some control pots and build your frame!
On that point, I have found recently that 10K linear pots work much much better than 100K linear pots for the K8055 input channels. Before changing to 10K, I was having similar problems to your Yo-Yo problem with the pots over running and then correcting their position again and again...
you may find that simply changing the value is helpful to you!