Re: [Flightgear-devel] Input protocol implementation problem

2009-09-04 Thread Alez Buzin
AC001 wrote:
> First am a newbie to FlightGear and am throughly enjoying the experience ;-)
>
> Am hacking in pyqt experimenting/researching with sockets (to eventually 
> interface with Arudino)
>
> The FG->output to pyqt listening is working great, with no major issues.
>
> However I am having problems with the input side and would appreciate 
> some direction.
>
> The issues are.
> 1)  can I acknowledge/debug that fg is receiving the input from socket
> 2) unsure about the formatting of the 
> 3) unsure how to format the input variable in the correct way..
>
> below are the various elements snipped in parts
>
> my command line is
>
> /home/flight-sim/flight-gear-9/source/src/Main/fgfs \
>   --fg-root=/home/flight-sim/flight-gear-9/data \
>   --httpd=9090 \
>   --aircraft=A380 \
>   --disable-real-weather-fetch --disable-clouds --timeofday=noon 
> --fog-disable \
>   --generic=socket,out,10,127.0.0.1,6789,udp,mash \
>   --generic=socket,in,5,127.0.0.1,6788,udp,mash \
>   --trace-write=/sim/gui/dialogs/autopilot/speed-active
>
> and the mash.xml protocol file
>
> 
> 
> 
> 
> newline
> tab
>
>
> 
> speed-active
> bool
> /sim/gui/dialogs/autopilot/speed-active
> 
> 
>  
> 
> newline
> tab
>
> 
> aileron
> float
> aileron=%03.2f
> /controls/flight/aileron
> 
>   
> 
> elevator
> float
> elevator=%03.2f
> /surface-positions/elevator-pos-norm
> 
>  snipped--
>
>
> the python code
># eg "speed-active=true\n" is sent
> datagram = "speed-active=%s\n" % (val)
> print datagram
> self.udpSocket.writeDatagram(datagram, 
> QtNetwork.QHostAddress(QtNetwork.QHostAddress.Broadcast), 6788)
>
>
> help would be greatly appreciated
> tia
> pedro
> ac001
>
>   
1) Find the property /sim/gui/dialogs/autopilot/speed-active  in 
property tree (via FG menu or in browser at local port 9090 ). If you 
can drive it from external  program than all is fine.

2) As I see you are sending data from python in the form like this:
speed-active=0
speed-active=1
speed-active=1
FG does not accepts variable names and expects input in the form
0
1
1

With respect,
Alex


--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] best way to remotely control flight gear?

2009-07-14 Thread Alez Buzin
Artem Chernodub wrote:
> Hello to everybody!
>
> We are researches from Kiyv and are very interested in this question
> too. We want to create neural network based control of planes.
> We found, that FlightGear can be controlled via Matlab -- but it
> can display internal processes that goes inside of it (landing of the
> Shuttle, for example). How to get access to Flight model from FlightGear?
>
> Ideally, we want the following:
>
> Cycle 1:
>
> We get state variables of the aircraft that characterises it's
> position and motion: latitude/longitude/altitude, velocities, etc.,
> STATE1;
>
> We set it's actuators (elevator, aileron, engine power to some
> position POS1;
>
> Cycle 2:
>
> We get STATE2;
> We send POS2;
>
>   
Read FG_ROOT/docs/readme.io. Connect to FG with native-fdm and 
native-controls.
Like this:
--native-fdm=socket,out,30,machine,5500,udp
--native-controls=socket,in,30,,5501,udp
machine - you PC with control programm


--
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] UFO marker.ac invalid?

2009-06-27 Thread Alez Buzin
James Turner wrote:
> With latest CVS (source and data), I'm seeing the following  
> continuously in the console (with the UFO, obviously):
>
> Instance of model Aircraft/ufo/Models/marker.ac has invalid values
> CullVisitor::apply(Geode&) detected NaN,
>  depth=nan, center=(0 0 35040),
>  matrix={
>   nan nan nan nan
>   nan nan nan nan
>   nan nan nan nan
>   -0.138223 -31.9428 -0.0740258 1
> }
>
> This is with the log level set to INFO - which I'm trying to use for  
> some testing of my own code.
>
> Does it point to a real problem with the marker.ac file, or some other  
> glitch? I could just comment out the relevant logging code locally,  
> but I'd rather mention it here if there's a genuine problem occurring.
>
> James
>   
Hi!
Not sure but can this help.
Try to change ufo.nas .
remove :   geo.Coord.new().set_xyz(0, 0, 0)
write:geo.Coord.new().set_latlon(0,0, 0)

With respect,
 Alex


--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Absolute (calendar) times in properties

2009-06-13 Thread Alez Buzin
Martin Spott wrote:
> Alez Buzin wrote:
>
>   
>> May I have miss something but I have in FG properties
>> "sim/time/gmt" in the form "2009-05-16T12:08:16",
>> "sim/time/gmt-string" as "12:08:16",
>> and sub-trees sim/time/utc/... and sim/time/real/... containing year,
>> day etc as integers. What problems to use this?
>> 
>
> Working with purely numeric values is much easier to deal with in a
> portable, timezone- and localization-independent way, not only for
> internal handling but also if you're planning to interface with
> external applications.
Combine :
sim/time/utc/month
sim/time/utc/day
sim/time/utc/hour
sim/time/utc/minute
sim/time/utc/second

With respect,
Alex





--
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Absolute (calendar) times in properties

2009-06-11 Thread Alez Buzin
Hi
May I have miss something but I have in FG properties
"sim/time/gmt" in the form "2009-05-16T12:08:16",
"sim/time/gmt-string" as "12:08:16",
and sub-trees sim/time/utc/... and sim/time/real/... containing year,
day etc as integers. What problems to use this?

With respect,
Alex


--
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Comm is broken

2009-05-06 Thread Alez Buzin
Michael D. Smith wrote:
> Manuel Bynum wrote:
>   
>> Hello, all. I have noticed in CVS as of late that the communication system 
>> is broken! I keep getting a message that says there are no frequencies for 
>> any airport, even KSFO! A little help, please! 
>>
>>
>> 
>   Yes, I can confirm this with the latest CVS.
>   
Problem is in /src/ATCDCL/ATC.hxx , line 300
To resolve change : "SGGeod::fromRadM" to "SGGeod::fromDegM"
> I posted the same thing here before but never got a reply.
>   
Yes. Now it is normal here. I have posted two bugs at 04/04 ("divide by 
zero" and "access violation" errors) and still no response.

With respect,
Alex

--
The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your
production scanning environment may not be a perfect world - but thanks to
Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700
Series Scanner you'll get full speed at 300 dpi even with all image 
processing features enabled. http://p.sf.net/sfu/kodak-com
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Velocity-XL - kx165.ac, xml and png

2009-05-06 Thread Alez Buzin
Alan Teeder wrote:

>Tortoise CVS (Windows XP) reports the following error with these 3 files
>
>  
>
> Cvs update: move away 
> Aircraft/Velocity-XL/Models/Interior/Panel/Instruments/kx165/KX165.ac,it 
> is in the way
>
>  
>
> Is this perhaps due to an upper-lower case windows file-name conflict?
>

Yes. CVS data at

"Aircraft/Velocity-XL/Models/Interior/Panel/Instruments/" contains 2 subfolders
"kx165" and "KX165". They conflicts in Widows. Someone should resolve this.




--
The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your
production scanning environment may not be a perfect world - but thanks to
Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700
Series Scanner you'll get full speed at 300 dpi even with all image 
processing features enabled. http://p.sf.net/sfu/kodak-com
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel