Aviation and Erlang
Upcoming SlideShare
Loading in...5
×
 

Aviation and Erlang

on

  • 1,409 views

"Aviation and Erlang" is a presentation that I gave during BarCamp Shanghai on June 12, 2010. I talked about two fields that I am interested in and I tried to link them together. For the second part ...

"Aviation and Erlang" is a presentation that I gave during BarCamp Shanghai on June 12, 2010. I talked about two fields that I am interested in and I tried to link them together. For the second part of the presentation I was showing some code examples, that are not part of the slide show itself.

Statistics

Views

Total Views
1,409
Views on SlideShare
1,405
Embed Views
4

Actions

Likes
0
Downloads
15
Comments
0

1 Embed 4

http://www.linkedin.com 4

Accessibility

Upload Details

Uploaded via as Apple Keynote

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />

Aviation and Erlang Aviation and Erlang Presentation Transcript

  • Aviation and Erlang Thomas Karsten barcamp Shanghai, 2010-06-12
  • About me • Thomas Karsten • Hometown: Berlin, Germany • Current location: Shanghai, China • Developer and scrum master at The NetCircle • Aviation, long distance cycling
  • Introduction • Aviation • Wind Correction Angle • Glidepath • Erlang Server • TCP Connection • Erlang Interface • Aviation and Erlang • Storage Application View slide
  • 1 Aviation • All about aircrafts • Design, Operation, Navigation View slide
  • 1 Aviation Wind Correction Angle (wca)
  • 1 Aviation Wind Correction Angle (wca)
  • 1 Aviation Wind Correction Angle (wca) vw v
  • 1 Aviation Wind Correction Angle (wca) vw v
  • 1 Aviation Wind Correction Angle (wca) vw wca v
  • 1 Aviation Wind Correction Angle (wca) vw wca=atan(vw/v) with v=150kt, vw=20kt: wca=7.6 wca v
  • 1 Aviation Wind Correction Angle (wca) vw v
  • 1 Aviation Wind Correction Angle (wca) vw v
  • 1 Aviation Wind Correction Angle (wca) vw vw90 vw90=sin(wta)*vw v
  • 1 Aviation Wind Correction Angle (wca) vw vw90 wca=atan(vw90/v) v
  • 1 Aviation Glidepath
  • 1 Aviation Glidepath 120kt=120nm/h=2nm/min t=10.3nm/2nm/min t=5.15min
  • 1 Aviation Glidepath 5000ft/5.15min=971ft/min
  • 1 Aviation Glidepath 5000ft/5.15min=971ft/min
  • 1 Aviation Glidepath (5000ft-1416ft)/5.15min=696ft/min
  • 1 Aviation
  • 2 Erlang Server Erlang • Developed at Ericsson 1986 • Open source since 1998 • Distributed, fault-tolerant applications • Processes are lightweight • RabbitMQ, ejabberd
  • 2 Erlang Server TCP Connection -module(server). -export([start/0, stop/0]). -export([listen/0]). listen() -> case gen_tcp:listen(Port, ?TCP_OPTIONS) of {ok, LSocket} -> NewState=State#state{lsocket=LSocket}, case gen_tcp:accept(LSocket) of {ok, Socket} -> do_something(Socket), {error, Reason} -> {error, Reason} end {ok, NewState}; {error, Reason} -> {stop, Reason} end.
  • 2 Erlang Server Erlang Interface -module(listen). -export([start/0, stop/0]). -export([listen/0]). start() -> register(?MODULE, spawn(fun() -> listen() end)). stop() -> ?MODULE ! stop. listen() -> receive {Pid, Request} -> io:format("From: ~p~nReceived: ~p~n", [Pid, Request]); Any -> io:format("Received: ~p~n", [Any]) end.
  • 2 Erlang Server Erlang Interface int main(int ac, char** av) { erl_init(NULL, 0); if (erl_connect_init(1, cookie, 0) == -1) erl_err_quit("err_connect_init"); if ((fd=erl_connect(node)) < 0) erl_err_quit("erl_connect: Cannot connect to node"); tuple=create_tuple(); erl_reg_send(fd, RECIPIENT, tuple); return 0; }
  • 3 Aviation and Erlang Code examples
  • 4 Storage Application Code examples
  • Lessons learned • How to land an airplane in cross-wind • Different communication types in Erlang • How to program a server in Erlang
  • Aviation and Erlang Thank you very much for listening Any questions?