-
USBServos Software not working?
Hello everyone,
I have recently received my USBServos Card and connected to it a Servo, which I have previously tested with a Servo Tester and it works fine.
The Red LED on the card lights up, the computer recognises the USB connection (when I start USBServos Software it detects it as device "2132"), and finally I tested the Servo pins with a Multimeter and I definitely receive a 5V power supply.
The problem? Well, similar to another user on the forum, when I move the slider along the bottom, or manually enter a value, and click send, the servo does not seem to move at all. I have ensured the Pins and Wires are the correct way around.
I remember somebody posted a link to a site which tells you how to test these Cards, sadly the link does not seem to elaborate on the USBServos Card.
Any ideas?
Thanks alot,
Jack:p
P.S: I apologise for making a new thread, but this is a new issue and separate from my other threads.
-
Re: USBServos Software not working?
Jack
I think we have been expecting this post:) On your servo lead connector what is the sequence of signals? Is it positive(red), signal(yellow), ground(black) ? Presumably you have connected a 5volt supply to the USBServoscard
David
-
Re: USBServos Software not working?
Quote:
Originally Posted by
fordgt40
Jack
I think we have been expecting this post:) On your servo lead connector what is the sequence of signals? Is it positive(red), signal(yellow), ground(black) ? Presumably you have connected a 5volt supply to the USBServoscard
David
Don't worry David, I know my difference between GND, 5V and DATA =).
The software and card seem to be communicating - The Red LED lights up only when I start the USBServos softwware, meaning there is a definitive link.
Yes, the 5V supply is conected (look at first post).
Strange huh?
-
Re: USBServos Software not working?
Jack
So what is the sequence of pin numbers and their associated signals on your servo lead to USBcard connector then?
David
-
Re: USBServos Software not working?
Yes, it is Red -> Orange -> Black, in accordance with the O/C manual.
It is connected the correct way around into Servo slot 1, I also tried 3 and 4 too.
-
Re: USBServos Software not working?
I use IOCP Console with-in SIOC to test my servo's. Write a short script and load it. To me it is much easier to use. I have never used the servo software. Only SIOC.
-
Re: USBServos Software not working?
Okay, as you know I'm not all too experienced with the SIOC lago, but I'll load the following script:
Code:
var 9000, name Servo4, Link USB_SERVOS, Output 1, PosL 0, PosC 511, PosR 1023, Type 2 // Servo Motor
Var 9003, name IAS, Link FSUIPC_INOUT, Offset $02BC, Length 4 // Indicated Air Speed * 128
{
L0 = &IAS / 1.5
&Servo4 = L0 + 213
}
Then I open the IOCP Console, no need to start FSX?
Then, I activate the vars manually through clicks in the IOCP Console, right?
If I'm wrong, please don't attack me, just post a script that I could use. Thanks. In fact, 737NUT, could you jsut post the SIOC testing script you use?
-
Re: USBServos Software not working?
Jack
I was only eliminating the obvious first. By all means try a script but as 737Nut`s advice previously, make sure that the values are within the servo range, else you could burn it out. I assume that you are using iocards_test.exe as your testing programme and that the analogue inputs on the left of the graphics display are fluctuating in value?
David
-
Re: USBServos Software not working?
Quote:
Originally Posted by
fordgt40
Jack
I was only eliminating the obvious first. By all means try a script but as 737Nut`s advice previously, make sure that the values are within the servo range, else you could burn it out. I assume that you are using iocards_test.exe as your testing programme and that the analogue inputs on the left of the graphics display are fluctuating in value?
David
Yes David, that is correct.
-
Re: USBServos Software not working?
Jack,
how will you get the IAS value from FSUIPC if you don't start FSX?
-
Re: USBServos Software not working?
Quote:
Originally Posted by
deering
Jack,
how will you get the IAS value from FSUIPC if you don't start FSX?
You can't, I'm wodnering if there was a way to test the servo without starting FSX.
Regardless, I'd much rather get it working through the testing software first, for the primary reason I could burn the servo.
Also, for me to get SIOC working is a nightmare, I'm just keeping it simple to start with.
-
Re: USBServos Software not working?
Jack, input via IOCP Console is simple enough.
An off topic question for you if I may. At the end of your last thread, Nico supplied a script to get you AP led working. Did you spend some time to work out why that version worked while the previous version didn't?
-
Re: USBServos Software not working?
Yes, a reduction of 4 to 3 variables (removing v1 and replacing with the pre-existing var 9000) worked.
Anyway, back on topic. The USBServos Software should work, so there is no need to use SIOC yet. That is the whole intnded purpose of USBServos Software.
As I said, setting up sioc.ini, mkaing SIOC work and ensuring the Servo doesn't burn out is too much for me. I will use USBServos first, that is the purpose of this thread.
-
Re: USBServos Software not working?
Jack
You are correct, it is much better to use the testing software IOCards_test.exe. On the basis that you have a separate 5 volt supply, the device is recognised, the connections are correct and the appropriate radio button is selected - then if the servo does not follow movement commands from the slider or numeric input. then perhaps the servo should be retested though would that involve changing the connections again? Incidentally, what servo are you using?
David
-
Re: USBServos Software not working?
Not sure of the model number right now, but can confirm it is an "Electonix" one, apparently very similar to the Hitec HS-55, but the wiring is identical to a JR one.
I will-triple-check the wire connections. It is because I had to swap the colouring around, so now they're all different colours, very dangerous & confusing, I'll probably revise the connections on Friday.
-
Re: USBServos Software not working?
Quote:
Originally Posted by
Boeing 747 Flyer
Yes, a reduction of 4 to 3 variables (removing v1 and replacing with the pre-existing var 9000) worked.
.
.
..but, you glossed over the question of why it worked and if you'd spent any time figuring it out.
-
Re: USBServos Software not working?
Jack,
you can check your board without fitting a servo and with no external P/S.
Do the following,
Place a 1000 ohm resistor in series with a LED.
Connect the Anode end of the combo to the center pin of say SERVO 1 connector and connect the cathode of the LED to Ground.
Run only the IOCards_test.exe.
Select servo 1 and adjust the slider,the led should glow bright at 1023 and dims as you go towards 0
Ive tried it on my one and it works ok.
This way you lessen the chance of destroying anything.
Hope this helps
Les
-
Re: USBServos Software not working?
Hiya Iwik,
I will definitely try that after I've connected a different Servo, ensuring it is in correct configurtion for the card.
-
Re: USBServos Software not working?
Okay guys, fantastic news. I have managed to sucessfully get the card working with USBServos Software. I have also found the values I want from the ASI, take a look:
Code:
FAR LEFT (ASI: 103Knots) - 250
FAR RIGHT (ASI: 375Knots) - 700
CENTRE (ASI: 225Knots) - 475
Assuming there is nothing wrong with those values, I am working on implementing it into a SIOC script. However, there are a few problems...
- First of all, I only want the ASI to "pick up" when the FSX ASI reaches 103Knots.
- Secondly, don't want the ASI to exceed 375Knots (700 Value), whilst it is capable of doing up to 400 Knots, I do not want to overstress the Servo. I take it this is where I implement the limiting factors into my SIOC scripts, but what if I exceed 375Knots? Does the ASI just "die"?
Thanks alot,
Jack (getting there!):D
-
Re: USBServos Software not working?
Jack
What was the reason why the servo did not work?
"I take it this is where I implement the limiting factors into my SIOC scripts" - yes, 737NUT gave you a snippet of SIOC code to achieve this in the previous thread
David
-
Re: USBServos Software not working?
Quote:
Originally Posted by
fordgt40
Jack
What was the reason why the servo did not work?
"I take it this is where I implement the limiting factors into my SIOC scripts" - yes, 737NUT gave you a snippet of SIOC code to achieve this in the previous thread
David
I am aware of the fact that he gave me the limiting factors. I asked what would happen if I exceeded 375Knots.
The Servo did not work because of dodgy contacts, everything else was okay. This was the reason the fault bypassed th multimeter test (because the Servo contacts are okay with that, just dodgy with the card). I made an entire new servo to USBServos adapter and all is okay.
Anyway, back on track, how would I get the Servo to "pick up" at 103Knots (ie only detect an output at that speed)?
-
Re: USBServos Software not working?
Jack
"I am aware of the fact that he gave me the limiting factors. I asked what would happen if I exceeded 375Knots" - nothing, the gauge will stop at the limiting value you have given!!!!!!!!
Use the sioc code to test the asi starter value ie 103knots and only move if it is greater.
David
-
Re: USBServos Software not working?
This is my script at the moment:
Code:
var 9000, name Servo4, Link USB_SERVOS, Output 1, PosL 250, PosC 475, PosR 700, Type 2 // Servo Motor
Var 9003, name IAS, Link FSUIPC_INOUT, Offset $02BC, Length 4 // Indicated Air Speed * 128
{
L0 = &IAS / 1.5
&Servo4 = L0 + 213
}
As you can see, it is without limiting factor commands. I tried adding one, but the script didn't compile.
Apart from limiting commands, is there anything OTHER than them I need to add?
-
Re: USBServos Software not working?
Jack
What was your code that would not compile?
Yes, there is more code ammendment required - for example you will need to establish whether the multiplier 1.5 or indeed the + value of 213 is correct
David
-
Re: USBServos Software not working?
This was the script:
Code:
V0000
$servo4=320
var 9000, name Servo4, Link USB_SERVOS, Output 1, PosL 250, PosC 475, PosR 700, Type 2 // Servo Motor
Var 9003, name IAS, Link FSUIPC_INOUT, Offset $02BC, Length 4 // Indicated Air Speed * 128
{
L0 = &IAS / 1.5
&Servo4 = L0 + 213
}
Furthermore, how would I know if the 1.5 Multiplier or the 213 value is correct? What would I have to amend (almost there now, surely!).
-
Re: USBServos Software not working?
Jack
Have you bothered to really comprehend the manuals or follow the examples on Nico`s site, I think not. You have a variable V0000 that is generally only used for setting initial start up values, but it has no curly brackets to contain code. There is also a line "&servo4 = 320" that is not attached to anything! Even if it was syntactically correct it still would not achieve what you want. To have a limiting function, you need to insert some code to check the value of L0 and reset it to the max allowable before sending it to the gauge. Logically, if A is greater than 1000 then a = 1000 (not sioc syntax but this is the logic you need to code) Also you may need to set a lower limit to be on the safe side
Re your second question after you have inserted limiting code, check out the gauge movement by trial and error to see how the gauge resonds to varying asi speeds and adjust the multiplying factor (1.5) and start position addition (213) as necessary. Previous posts have given you the logic behind this
Sorry Jack, but given your level of understanding there is a long way to go yet and I do not propose to join you on the journey
This forum has provided a lot of help, but not apparently matched by your willingness to get to grips with SIOC. As they say in The "Dragons Den" - sorry but I`m out!
David
-
Re: USBServos Software not working?
I understood why the script was incorrect before I posted it. I only posted it because you asked to see it, and I was wondering why you wanted to see a script that was so clearly wrong
I struggle with SIOC. So What? What happened to the little bit of ol' encouragement;). I enjoy learning new things, and post my questions in a simple-as-possible format in the hope for a nice simple answer. I have thanked you for your help so far, and you can if you wish help me further or not.
Quote:
but not apparently matched by your willingness to get to grips with SIOC
Wow! I really am surprised to hear that, after I constantly try to come across as enthusiastic to learn this complex language. I thought I had proven to everyone that I really wanted to learn SIOC, sadly not eh?;)
ANYWAY
You second paragraph in that post was fantsatic, it answered my question quickly. If I cut the last bit out of your post I have a perfect answer, which is exactly what I look for. I asked how would I do this, you answered Trial and Error. Perfect, simple answer!:D
NOW
I do not want this thread to be filled with moans, groans and criticisms!:p I created this thread to gain help, and I have clearly received help in some cases (paragraph 2 on your post for example), which I cannot thank people enough for.
I will try the Trial and Error method, an rectify my mistake (which I knew about remember!;). I may not suceed, but I can at least understand why it doesn't compile.
Thank you,
Jack:p
-
Re: USBServos Software not working?
Jack
You misunderstand
The reason I asked to see your coding was twofold:-
1) If it was close then I was happy to correct it for you
2) It would show me what progress you had made in learning SIOC
David
-
Re: USBServos Software not working?
Okay, fair enough.
Before you made your psot asking to see the code, I tried curly brackets (I know these are required), and it didn't compile. So I thought I may aswell give you that one, as they both didn't compile.
-
Re: USBServos Software not working?
Hi Jack,
This forum is one which encourages learning.Dont get David wrong,he like most of us will help when ever possible.Sioc is a form of programming language
that assumes a certain level of basic programming.A lot of people have played around with the basic language and hence have some basic logic skills.Whic they can apply to SIOC proframming.What alot of us have done is to take for example your master card and connected some switches and pots and used other peoples examples to get results.Then they modify it bit by bit till they get it to work for them.Its is trial and error but much is learnt this way. If the basics are learnt then its amazing what satisfaction is gained.Others wont get frustrated trying to teach you what can easily do yourself.
Ive had basic programming experience but found SIOC quite daunting as there are quite a few differences but the logic skills aquired allowed me to do the basic maths before requiring asistance.
SIOC has certain rules like using the Curly Brackets that must be learnt an dthe best way is by looking at heaps of examples, Nico's site is excellent for this.
Time is what you need to spend to familarise yourself with Sioc.
Hope this helps and please dont be discouraged we all have gone thru this pain.
Hope this helps and good luck with the learning process.
Regards
Les
-
Re: USBServos Software not working?
Well, curly brackets do not seem to work, it just says command outside of place when I apply curly brackets over the code.
I keep getting rather frustrated at the fact that SIOC does not work for me, even AFTER consulting the manuals especially regarding the curly brackets.
If someone could show me what the scurly brackets should look like, I will be extremely interested, because I belive I've tried every combination under the sun.
I learn not through reading manuals, or being told how to do something, I learn by seeing (in this case) a complete example of SIOC script for my Servo, which I would then analyze and understand what each entry means.
I keep getting told what each little fragment of script means, but I think I need to look at the bigger picture. For example, I was told that I would have to insert a L0 entry into the script. I know what this is, but I can't understand what I would need to define with it.
I will try and obtain from somewhere a complete SIOC script for an ASI Servo, and then analyzw what each entry means.
-
Re: USBServos Software not working?
Jack
One last try!
Curly brackets are { }
Please follow the advice you have previously received from Nico, Iwik and others to try some simple coding exercises first using Nico`s site.
There is no "big" picture with SIOC, only a series of little ones
SIOC is not working for you because you are not trying and succeeding with very simple exercises - just jumping into trying to solve a medium complexity issue without understanding the basics
You will not learn by only looking at examples, firstly, you need to understand the following:-
The various commands and what they do
The proper syntax to use the commands
The declaration of variables and associated syntax
The use of "internal" variables
The use of boolean/logical variables
Programme flow - SIOC is unusual insofaras it is an "event" driven language. Nothing happens until a variable changes value - then the code attached to that variable (within curly brackets) is exexcuted. Also any variables within that code, if changed, will prompt the running of their own associated code
Edit to add
Programme flow with the use of IF and ELSE etc
All this and more is within the manuals and Nico`s site. If you persist as per your last post, then you will have a very long journey - even if you find some ASI code, then how will you adapt it for your own use with the knowledge level currently being evidenced?
You ask for advice, please follow it
David
-
Re: USBServos Software not working?
Hiya David,
I know what curly brackets are and how to use them, but they don't seem to work.
I have gotten this far, I've managed to create a semi-useable script but things like the V000 will not compile because they are unfinished/incomplete.
Code:
Var 0000
{
&servo4=250
}
var 9000, name Servo4, Link USB_SERVOS, Output 1, PosL 250, PosC 475, PosR 700, Type 2 // Servo Motor
Var 9003, name IAS, Link FSUIPC_INOUT, Offset $02BC, Length 4 // Indicated Air Speed * 128
{
L0 = &IAS / 1.5
&Servo4 = L0 + 213
}
Getting there?
P.S: Before you ask, I have read what you have said and I udnerstand this post re-glosses over previously posted information.
-
Re: USBServos Software not working?
See, computer are dumb. They need data in the formats they been programmed to handle. They can't take leaps of imagination to interpret what someone's personal way of writing things might mean. And SIOC is particularly rigid in its requirements. Do you see any difference between the statements you have written that don't compile as compared to those that do?
Find that, then you'll still have some learning to do about "event driven".
-
Re: USBServos Software not working?
Jack,
&servo4=250 should read &servo4 = 250
Les
-
Re: USBServos Software not working?
Ah well, another spoonful.
-
Re: USBServos Software not working?
Quote:
Originally Posted by
deering
Ah well, another spoonful.
:roll:
Also, thanks Iwik for the advice. I now get the error "= is expected" but I will try and figure this out. One little step at a time.
I completely udnerstand how SIOC is event driven. Thankfully, this is one thing that IS well documented within SIOC and clearly labelled in the presentation in the form of a diagram. EG: No change in Var = No information supplied
-
Re: USBServos Software not working?
Quote:
Originally Posted by
deering
Ah well, another spoonful.
:roll:
EDIT:
Thank god, progress. The following script *seems* to be okay and compiles well, it is a long way off I know but here's what I've got so far:
Code:
Var 0000
{
&servo4 = 250
}
var 9000, name Servo4, Link USB_SERVOS, Output 1, PosL 198, PosC 446, PosR 693, Type 2 // Servo Motor
Var 9003, name IAS, Link FSUIPC_INOUT, Offset $02BC, Length 4 // Indicated Air Speed * 128
{
L0 = &IAS / 1.5
&Servo4 = L0 + 213
}
Next major step is setting up the SIOC.ini file to handle the Servo3 for ASI and USBServos Card.
-
Re: USBServos Software not working?
Quote:
Originally Posted by
Boeing 747 Flyer
.
I completely [understand] how SIOC is event driven.....
Good to hear.
What's the event that's going to cause:
&servo4 = 250
to be executed?
-
Re: USBServos Software not working?
Ho Hum:roll:
You can take a horse to water and it will not drink
You can hold its nose and it will not drink
You can hold its nose, dunk its head under water and it will still not drink
Ho Hum:roll: