View Full Version : MasterCard/USBExpansion detection
Boeing 747 Flyer
08-23-2010, 12:07 PM
Hiya everyone,
I have three questions in regards to the MasterCard and USBExpansion setup:
1.) Does 5V need to be applied to either card for detection in the main SIOC Window?
2.) In the main SIOC Window, should USBE and Master come up as seperate entries or as one?
3.) Does it matter which port I plug the Master ino on my USBE?
Cheers.
fordgt40
08-23-2010, 12:47 PM
Jack
In reverse order
3) I recommend that you use a motherboard USB port and not a Hub
2) On my overhead, with 1 USB Expansion and two mastercards - it just shows IOCardUSB - Device = xx
1) I can really recommend reading the OC manual for the expnasion card/mastercard - it is very informative on your question and lots of other issues:)
David
colt45
08-23-2010, 01:05 PM
jack,
Regarding question 3, I believe you are asking which port on the USB expansion board do you plug the Mastercard to? If I am right with this assumption than I believe the ports on the USBE are numbered J1 to J4 and you should plug the first MC into J1, the second MC (if you have one) to J2, etc.
Re: question 1, power is supplied to the MC.
Dave
fordgt40
08-23-2010, 01:23 PM
Dave
Quite right, my mistake
David
Jack,
Regarding your question 3)
No I don't think it matters, although it has effect on the numbering of your in- and outputs, see this document (http://www.lekseecon.nl/downloads/numbering.pdf). And in sioc.ini you have to indicate how many MC's there are at a USB Exp card. So J1 is more logical for the first MC...
Nico
Boeing 747 Flyer
08-23-2010, 06:43 PM
Thanks Nico, Dave and David. Your replies have been most helpful:).
Boeing 747 Flyer
08-27-2010, 06:55 AM
I have made my own pin diagrams of the Master Card to replace the somewhat blurry ones provided by Opencockpits. How do you find these:
http://i822.photobucket.com/albums/zz146/Stratuspheric/J.jpg
ANY mistakes please point out.
Hi Jack,
I believe your diagrams are not really needed. There already are enough websites perfectly explaining the pins, like this one for instance (http://personales.ya.com/micabina737/iocards/hard/numi.htm).
Nico
Boeing 747 Flyer
08-29-2010, 05:41 PM
Thanks very much Nico, I have printed that diagram off and will use it regularly.
BTW: Is that diagram definitely correct (the one you linked)? reason I ask, I setup a test script for a few LEDs and they do not illuminate, but do when testing in controlador.exe.
Var 10, Name LED1, Link IOCARD_OUT, Output 11 // LED1
Var 11, Name LED2, Link IOCARD_OUT, Output 13 // LED2
Var 12, Name LED3, Link IOCARD_OUT, Output 15 // LED3
Var 13, Name LED4, Link IOCARD_OUT, Output 17 // LED4
Var 14, Name LED5, Link IOCARD_OUT, Output 19 // LED5
Var 15, Name LED6, Link IOCARD_OUT, Output 23 // LED6
Var 9003, name Speed, Link FSUIPC_IN, Offset $02BC, Length 4 // IAS from Sim
{
L0 = DIV &Speed 128
IF L0 = 10
{
&LED1 = 1
&LED2 = 0
IF L0 = 20
{
&LED1 = 0
&LED2 = 1
&LED3 = 0
IF L0 = 30
{
&LED2 = 0
&LED3 = 1
&LED4 = 0
IF L0 = 40
{
&LED3 = 0
&LED5 = 0
&LED4 = 1
IF L0 = 50
{
&LED4 = 0
&LED6 = 0
&LED5 = 1
IF L0 = 60
{
&LED5 = 0
&LED6 = 0
}
}
}
}
}
}
}
SIOC.ini:
[SIOC]
IOCP_port=8092
IOCP_timeout=4000
Minimized=Yes
toggle_delay=20
CONFIG_FILE=ttt.ssi
[IOCARDS MODULE]
IOCard_disable=No
IOCard_LPT=No
[DEVICE INFORMATION]
USBSERVOS=0,77
deviceUSB=2132
[USBEXPANSION]
USB=Yes
[USBKEYS]
USBKeys=0,67
[MULTIPLE]
MUSB=Yes
[A/D FOR MASTER]
USB_AD=4
[NUMBER MASTERS]
NCards=1
[FSUIPC MODULE]
FSUipcdisable=No
FSUipcRefresh=50
[IOCP CLIENTS MODULES]
IOCPini_delay=3000
IOCPclient0_disable=Yes
IOCPclient0_host=localhost
IOCPclient0_port=8090
IOCPclient1_disable=Yes
IOCPclient1_host=localhost
IOCPclient1_port=8099
[SOUND MODULE]
Sound_disable=Yes
Volume=100
I set everything in accordance to the Opencockpits MasterCard manual.
Your SIOC script is wrong, it will not test your leds.... what will happen IF L0 = 10?
L0 = DIV &Speed 128
IF L0 = 10
{
All your other tests will fail ...
If you want to test leds, just write a simple script writing 1's and 0's to these leds. Do not complicate the test by reading from a FSUIPC offset.
Design principle KISS, Keep It Simple..., Stupid! ;-) ;-)
Nico
Boeing 747 Flyer
08-30-2010, 04:18 AM
Okay, that's good. I was more worried about the SIOC.ini being wrong. I will re-test with something much simpler like an AP switch.
I will re-test with something much simpler like an AP switch.
An AP switch? Why so complicated? Test it like this:
Var 10, Name LED1, Link IOCARD_OUT, Output 11 // LED1
Var 11, Name LED2, Link IOCARD_OUT, Output 13 // LED2
Var 12, Name LED3, Link IOCARD_OUT, Output 15 // LED3
Var 13, Name LED4, Link IOCARD_OUT, Output 17 // LED4
Var 14, Name LED5, Link IOCARD_OUT, Output 19 // LED5
Var 15, Name LED6, Link IOCARD_OUT, Output 23 // LED6
Var 0 Value 0
{
&LED1 = 1
&LED2 = 1
&LED3 = 1
&LED4 = 1
&LED5 = 1
&LED6 = 1
}
Boeing 747 Flyer
08-30-2010, 05:24 AM
Hi Nico,
I have tried your script and unfortunately, the LEDs still do not light. The master card definitely works, I have tested in Controlador.exe. It seems like SIOC is not talking to the master card (in fact, when I tested the AP script, IOCPConsole Log said that LEDs 11, 13, and 15 should be =1; they weren't).
I definitely have the outputs declared right in SIOC.
You miss a MASTER statement in your sioc.ini (that's why...)
I thought you would know that by now ...
Boeing 747 Flyer
08-30-2010, 06:36 AM
Hi Nico,
This isn't mentioned in the USBExpansion Documentation. I filled in the SIOC.ini according to the manual. Where is this statement? The only entries that you are told to apply by the manual are:
- USB=Yes
- Musb=Yes
- USB_AD=4
- NCards=1
Don't know which documentation you are looking into, but that is certainly not correct.
You should look into the SIOC documentation, not the USB expansion card....
Look here (www.opencockpits.com/uploads/manual_ini_eng.pdf).
This is how your sioc.ini should be like:
[SIOC]
IOCP_port=8092
IOCP_timeout=4000
Minimized=Yes
toggle_delay=20
CONFIG_FILE=ttt.ssi
[IOCARDS MODULE]
IOCard_disable=No
IOCard_LPT=No
[MASTERS]
MASTER=0,4,1,1001
[FSUIPC MODULE]
FSUipcdisable=No
FSUipcRefresh=50
[IOCP CLIENTS MODULES]
IOCPini_delay=3000
IOCPclient0_disable=Yes
IOCPclient0_host=localhost
IOCPclient0_port=8090
IOCPclient1_disable=Yes
IOCPclient1_host=localhost
IOCPclient1_port=8099
[SOUND MODULE]
Sound_disable=Yes
Volume=100
Change the number 1001 in the MASTER statement into the Devicenumber of your USB expansion card that is shown in the SIOC main window.
Nico
Boeing 747 Flyer
08-30-2010, 09:17 AM
Thanks very much Nico, that SIOC.ini works great:).
Also, thanks a bunch for that PDF Document. I have been looking for soemthing exactly like that. Rest assured it has been saved and copied to my Hard-Drive:D.
Rest assured it has been saved and copied to my Hard-Drive:D.
You better burn a copy to a CD/DVD as well, hard disks may crash ;-)