Documentation ¶
Index ¶
- func Distance(lat1, lon1, lat2, lon2 float64) float64
- type AccelerationTracker
- type AltitudeTracker
- type BMPReader
- type GPSReader
- type GPSTracker
- type LSMReader
- type RocketInfo
- func (recv *RocketInfo) MarshalJSON() ([]byte, error)
- func (recv *RocketInfo) SetRecording(recording bool, videoFile string)
- func (recv *RocketInfo) UnmarshalJSON(buf []byte) error
- func (recv *RocketInfo) UpdateAcceleration(x, y, z physic.Acceleration)
- func (recv *RocketInfo) UpdateAltitude(temperature float64, pressure float64, altitude float64)
- func (recv *RocketInfo) UpdateGPS(gps nmea.GGA)
- type RocketInfoJSON
- type RocketInfoLog
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Distance ¶
Distance function returns the distance (in meters) between two points of
a given longitude and latitude relatively accurately (using a spherical approximation of the Earth) through the Haversin Distance Formula for great arc distance on a sphere with accuracy for small distances
point coordinates are supplied in degrees and converted into rad. in the func
distance returned is METERS!!!!!! http://en.wikipedia.org/wiki/Haversine_formula
Types ¶
type AccelerationTracker ¶
type AccelerationTracker interface {
UpdateAcceleration(x, y, z physic.Acceleration)
}
type AltitudeTracker ¶
type BMPReader ¶
type BMPReader struct {
// contains filtered or unexported fields
}
func NewBMPReader ¶
func NewBMPReader(i2cBus i2c2.BusCloser, altitudeTracker AltitudeTracker, bmpI2CAddr uint16) *BMPReader
func (*BMPReader) UpdateFromBMPLoop ¶
type GPSReader ¶
type GPSReader struct {
// contains filtered or unexported fields
}
func InitGPSI2CReader ¶
func InitGPSSerialReader ¶
func (*GPSReader) UpdateFromGPSLoop ¶
type GPSTracker ¶
type GPSTracker interface {
UpdateGPS(gpsInfo nmea.GGA)
}
type LSMReader ¶
type LSMReader struct {
// contains filtered or unexported fields
}
func NewLSMReader ¶
func NewLSMReader(i2cBus i2c2.BusCloser, accelerationTracker AccelerationTracker, bmpI2CAddr uint16) *LSMReader
func (*LSMReader) UpdateFromLSMLoop ¶
type RocketInfo ¶
type RocketInfo struct { RocketInfoJSON // contains filtered or unexported fields }
func (*RocketInfo) MarshalJSON ¶
func (recv *RocketInfo) MarshalJSON() ([]byte, error)
func (*RocketInfo) SetRecording ¶
func (recv *RocketInfo) SetRecording(recording bool, videoFile string)
func (*RocketInfo) UnmarshalJSON ¶
func (recv *RocketInfo) UnmarshalJSON(buf []byte) error
func (*RocketInfo) UpdateAcceleration ¶
func (recv *RocketInfo) UpdateAcceleration(x, y, z physic.Acceleration)
func (*RocketInfo) UpdateAltitude ¶
func (recv *RocketInfo) UpdateAltitude(temperature float64, pressure float64, altitude float64)
func (*RocketInfo) UpdateGPS ¶
func (recv *RocketInfo) UpdateGPS(gps nmea.GGA)
type RocketInfoJSON ¶
type RocketInfoLog ¶
type RocketInfoLog interface { BaseAGL() float64 NumRecords() int Record(recordNum int) RocketInfo BaroHeight(recordNum int) float64 BaroHeightAGL(recordNum int) float64 MaxBaroHeight() (float64, RocketInfo) MaxBaroHeightAGL() (float64, RocketInfo) }
func ReadRocketInfoLog ¶
func ReadRocketInfoLog(logFilePath string) (RocketInfoLog, error)
Click to show internal directories.
Click to hide internal directories.