Elixir.XGPS v0.4.0 XGPS.Ports

Summary

Functions

Return the latest position if atteched to GPS

Return all the connected port names

Callback implementation for Supervisor.init/1

Will send one GPS report as no fix. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

Will send one GPS report as the give position. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

Will send one GPS report as the give position. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

Open one port to be consumed. Needs to have one GPS attached to the port to work. To simulate, give port_name = :simulate

Functions

get_one_position()

Return the latest position if atteched to GPS.

get_running_port_names()

Return all the connected port names

init(atom)

Callback implementation for Supervisor.init/1.

reset_simulated_port_state()
send_simulated_no_fix()

Will send one GPS report as no fix. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

send_simulated_no_fix(date_time)
send_simulated_position(lat, lon, alt)

Will send one GPS report as the give position. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

send_simulated_position(lat, lon, alt, date_time)

Will send one GPS report as the give position. Since this will effectively generate both RMC and GGA sentences, the broadcaster will produce two values

start_link()
start_port(port_name)

Open one port to be consumed. Needs to have one GPS attached to the port to work. To simulate, give port_name = :simulate

start_simulator(file_name)
stop_port(port_name_to_stop)
stop_simulator()