This guide covers how to use Condor and XCSoar for Android over the same wireless network, avoiding the need for a Bluetooth link.
Please note:
-This functionality requires XCSoar 6.1 or later.
-Using Condor and XCSoar for Android over a USB link is possible but requires extra software (TCP forwarding over Android Debug Bridge) - the extra steps required will be added to this guide when time permits.
-This functionality should be available for Windows / Windows CE devices in future (connecting over Wifi or ActiveSync) in a matter of weeks. This guide will be amended with the steps required. when it is possible.
Software required is all free, open-source:
On Android device:
XCSoar 6.1 or later
On PC:
com0com virtual serial port driver
hub4com virtual serial port -> tcp utility
INSTALLATION
1) Install XCSoar 6.1 alpha from 'XCSoar-testing' on the Android market.
2) Download com0com from
http://sourceforge.net/projects/com0com ... p/download (32 bit PC) or
http://sourceforge.net/projects/com0com ... p/download (64 bit PC)
If you don't know which you have, it's probably 32 bit
a: Extract ZIP file to a temporary directory and run setup.exe
b: Leave 'Start Menu Shortcuts' and 'CNCA0<->CNCB0' options ticked
c: Install to a directory of your choice.
d: Untick 'Launch Setup Command Prompt' and 'Show Readme'
e: Finish
f: (Remove temporary directory)
3) Download hub4com from
http://sourceforge.net/projects/com0com ... p/download
a: To install, extract contents of ZIP file to a directory of your
choice (Example C:\Program Files\hub4com)
CONFIGURATION
1) Configure the flight simulation software
a: Set windowed display mode for testing.
Condor: Enter Condor's 'Setup' screen and select 'Windowed'. Set
screen resolution to something low (eg 800x600)
b: Enable NMEA output
Condor: Go to the 'Options' page and in the 'NMEA output' frame, tick
'Enable'. Under 'Port', select 'CNCA0'
2) Obtain your Android device's IP address on the network
a: On your Android device, go to the Android Settings page.
b: Choose the 'Wireless & Networks' option.
c: Verify that 'Wi-Fi' is ticked and that you are connected to the wifi network.
d: Choose 'Wi-Fi settings'
e: In the 'Wi-Fi networks' list, the top entry is the network you are
currently connected to. Tap on it to bring up an information list.
f: Note down the IP address eg 192.168.1.100
3) Configure XCSoar
a: Start XCS-test from the application list
b: Enter 'FLY' mode
c: Double-tap on the center of the screen to bring up the XCSoar menu
d: Tap on 'Config' to display the first page of the Config Menu
e: Tap on 'Config' again to display the second page of the Config menu
f: Tap on 'System Setup'
g: Advance using the arrow buttons to Page 14 'Devices'
h: Configure XCSoar to use Condor as the secondary data source:
- Change 'Device B Name' to 'Condor'
- Under 'Device B Port' select 'TCP Port 4353' (Note: If the number is
not 4353, note it down and use it instead of 4353 later in this
guide)
If you will only use this device with a simulator:
- Under 'Device A Port' choose 'Disabled'.
If you use XCSoar with a real GPS source:
- Keep Device A settings for your real GPS, eg. 'Name: Generic, Port: Built-in GPS'
4) Configure hub4com to connect to your Android device
a: Using Windows Explorer, open the directory you extracted hub4com to.
b: Right click com2tcp.bat and select 'Create shortcut'
c: Right click the shortcut and look for the 'Target' field, which
contains the path to your com2tcp.bat file, eg "C:\Program
Files\hub4com\com2tcp.bat"
d: Append (add to the end) the following text to the 'Target' field:
\\.\CNCB0 ipaddress.of.android.device 4353
The complete target field should read something like:
"C:\Program Files\com2tcp\com2tcp.bat" \\.\CNCB0 192.168.1.100 4353
e: Click OK to save the changes to the shortcut properties.
f: (Optional) Copy the shortcut to a more accessible place.
USING
On Android device:
-Enable Wifi
-Start XCS-Test
On PC:
-Run the shortcut you created to com2tcp.bat.
A black console window should appear with similar appearance to:
Code: Select all
C:\Program Files\hub4com>"hub4com" --create-filter=pin2con --add-filters=0:p
in2con "\\.\CNCB0" --use-driver=tcp --reconnect=1000 "192.168.1.100:4353"
Open("\\.\CNCB0", baud=19200, data=8, parity=no, stop=1, octs=on, odsr=off, ox=o
ff, ix=off, idsr=off, ito=0) - OK
Route data CNCB0(0) --> TCP(1)
Route data TCP(1) --> CNCB0(0)
Route flow control CNCB0(0) --> TCP(1)
Route flow control TCP(1) --> CNCB0(0)
Filters:
_________
\->{pin2con.IN}->
CNCB0(0) | /
_________/<---------------
CNCB0(0) Event(s) 0x10 [DSR] will be monitired
Started CNCB0(0)
Started TCP(1)
If Condor is running in windowed mode, you may notice messages such as this appearing in the console window:
Code: Select all
Socket(0.0.0.0:0) = 760
Connect(760, 192.168.1.100:4353) ...
As soon as the Condor flight begins, the 'GPS not connected' icon should disappear in XCSoar and the position of the aircraft in Condor should be displayed.
CLOSING
-------
The com2tcp.bat window can be left open or closed at any time. If a Condor flight is active it will periodically try to connect to the Android device. If no Condor flight is active, com2tcp.bat is inactive.
TROUBLESHOOTING
This guide was tested on 32-bit Windows XP, and users have reported success on 64-bit Windows 7 also. Please report any problems with this or other configurations.
If you have problems, double-check the IP address and ports. If connection still does not work, please capture the contents of the com2tcp.bat console window:
Right click on the main body of the black console window titled 'com2tcp.bat'.
Select 'Select All', all the text should be highlighted in white.
Then right click again on any of the highlighted area to copy the text to clipboard.
Paste the text into a reply here.