βΉοΈ Skipped - page is already crawled
| Filter | Status | Condition | Details |
|---|---|---|---|
| HTTP status | PASS | download_http_code = 200 | HTTP 200 |
| Age cutoff | PASS | download_stamp > now() - 6 MONTH | 0.6 months ago |
| History drop | PASS | isNull(history_drop_reason) | No drop reason |
| Spam/ban | PASS | fh_dont_index != 1 AND ml_spam_score = 0 | ml_spam_score=0 |
| Canonical | PASS | meta_canonical IS NULL OR = '' OR = src_unparsed | Not set |
| Property | Value |
|---|---|
| URL | https://pkg.go.dev/github.com/bmurray/simconnect-go |
| Last Crawled | 2026-03-27 23:20:35 (17 days ago) |
| First Indexed | 2025-02-28 17:00:42 (1 year ago) |
| HTTP Status Code | 200 |
| Meta Title | simconnect package - github.com/bmurray/simconnect-go - Go Packages |
| Meta Description | null |
| Meta Canonical | null |
| Boilerpipe Text | func IsReport[T any](s *client.SimConnect, ppData *client.RecvSimobjectDataByType) (*T, bool)
func RequestData[T any](s *client.SimConnect) error
type Connector
func NewConnector(name string, opts ...ConnectorOption) *Connector
func (c *Connector) Start(ctx context.Context)
func (c *Connector) StartReconnect(ctx context.Context)
type ConnectorError
func (e ConnectorError) Error() string
type ConnectorOption
func WithCycle(cycle time.Duration) ConnectorOption
func WithDLLPath(path string) ConnectorOption
func WithLogger(l *slog.Logger) ConnectorOption
func WithReceiver(r Receiver) ConnectorOption
type Receiver
This section is empty.
This section is empty.
IsReport Convenience function to check if the data is the correct type
RequestData Convenience function to request data
type Connector struct {
}
Connector is the main struct for connecting to SimConnect
func NewConnector(name
string
, opts ...
ConnectorOption
) *
Connector
NewConnector creates a new connector
you can pass options to the connector
Start starts the connector
it will connect to SimConnect and start the receivers
this is BLOCKING, and will terminate at the first disconnect
StartReconnect starts the connector with reconnect
it will connect to SimConnect and start the receivers
this is BLOCKING, and will reconnect on disconnect
This is a simple wrapper around Start that adds a exponential backoff
ConnectorError is the error type for the connector
const (
ErrE_FAIL
ConnectorError
= "E_FAIL"
ErrGetNextDispatch
ConnectorError
= "GetNextDispatch"
)
type ConnectorOption func(*
Connector
)
ConnectorOption is a function that sets options on the Connector
WithCycle sets the cycle time for the connector
the connector will dispatch data every cycle
WithDLLPath sets the path to the SimConnect DLL
if not set, the default DLL will be used
WithLogger sets the logger for the connector
func WithReceiver(r
Receiver
)
ConnectorOption
WithReceiver adds a receiver to the connector
you can add multiple receivers
Receiver is the interface for receiving data from SimConnect |
| Markdown | [](https://go.dev/)
[Skip to Main Content](https://pkg.go.dev/github.com/bmurray/simconnect-go#main-content)

- [Why Go ](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Case Studies](https://go.dev/solutions#case-studies)
Common problems companies solve with Go
- [Use Cases](https://go.dev/solutions#use-cases)
Stories about how and why companies use Go
- [Security](https://go.dev/security/)
How Go can help keep you secure by default
- [Learn](https://go.dev/learn/)
- [Docs ](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Effective Go](https://go.dev/doc/effective_go)
Tips for writing clear, performant, and idiomatic Go code
- [Go User Manual](https://go.dev/doc/)
A complete introduction to building software with Go
- [Standard library](https://pkg.go.dev/std)
Reference documentation for Go's standard library
- [Release Notes](https://go.dev/doc/devel/release)
Learn what's new in each Go release
- [Packages](https://pkg.go.dev/)
- [Community ](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Recorded Talks](https://go.dev/talks/)
Videos from prior events
- [Meetups **](https://www.meetup.com/pro/go)
Meet other local Go developers
- [Conferences **](https://github.com/golang/go/wiki/Conferences)
Learn and network with Go developers from around the world
- [Go blog](https://go.dev/blog)
The Go project's official blog.
- [Go project](https://go.dev/help)
Get help and stay informed from Go
- Get connected
[](https://groups.google.com/g/golang-nuts "Get connected with google-groups (Opens in new window)") [](https://github.com/golang "Get connected with github (Opens in new window)") [](https://twitter.com/golang "Get connected with twitter (Opens in new window)") [](https://www.reddit.com/r/golang/ "Get connected with reddit (Opens in new window)") [](https://invite.slack.golangbridge.org/ "Get connected with slack (Opens in new window)") [](https://stackoverflow.com/collectives/go)
[](https://go.dev/)
- [Why Go **](https://pkg.go.dev/github.com/bmurray/simconnect-go)
[** Why Go](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Case Studies](https://go.dev/solutions#case-studies)
- [Use Cases](https://go.dev/solutions#use-cases)
- [Security](https://go.dev/security/)
- [Learn](https://go.dev/learn/)
- [Docs **](https://pkg.go.dev/github.com/bmurray/simconnect-go)
[** Docs](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Effective Go](https://go.dev/doc/effective_go)
- [Go User Manual](https://go.dev/doc/)
- [Standard library](https://pkg.go.dev/std)
- [Release Notes](https://go.dev/doc/devel/release)
- [Packages](https://pkg.go.dev/)
- [Community **](https://pkg.go.dev/github.com/bmurray/simconnect-go)
[** Community](https://pkg.go.dev/github.com/bmurray/simconnect-go)
- [Recorded Talks](https://go.dev/talks/)
- [Meetups **](https://www.meetup.com/pro/go)
- [Conferences **](https://github.com/golang/go/wiki/Conferences)
- [Go blog](https://go.dev/blog)
- [Go project](https://go.dev/help)
- Get connected
[](https://groups.google.com/g/golang-nuts) [](https://github.com/golang) [](https://twitter.com/golang) [](https://www.reddit.com/r/golang/) [](https://invite.slack.golangbridge.org/) [](https://stackoverflow.com/collectives/go)
1. [Discover Packages](https://pkg.go.dev/)
2. [github.com/bmurray/simconnect-go](https://pkg.go.dev/github.com/bmurray/simconnect-go@v0.1.0)

[](https://go.dev/)
# simconnect
package module

[Version: v0.1.0](https://pkg.go.dev/github.com/bmurray/simconnect-go?tab=versions)
Opens a new window with list of versions in this module.
Latest
Latest

This package is not in the latest version of its module.
[Go to latest](https://pkg.go.dev/github.com/bmurray/simconnect-go)
Published: Dec 9, 2024 License: [MIT](https://pkg.go.dev/github.com/bmurray/simconnect-go?tab=licenses)
Opens a new window with license information.
[Imports: 9](https://pkg.go.dev/github.com/bmurray/simconnect-go?tab=imports)
Opens a new window with list of imports.
[Imported by: 0](https://pkg.go.dev/github.com/bmurray/simconnect-go?tab=importedby)
Opens a new window with list of known importers.
## Details
-  Valid [go.mod](https://github.com/bmurray/simconnect-go/tree/v0.1.0/go.mod) file 
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
-  Redistributable license 
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
-  Tagged version 
Modules with tagged versions give importers more predictable builds.
-  Stable version 
When a project reaches major version v1 it is considered stable.
- [Learn more about best practices](https://pkg.go.dev/about#best-practices)
## Repository
[github.com/bmurray/simconnect-go](https://github.com/bmurray/simconnect-go "https://github.com/bmurray/simconnect-go")
## Links
- [ Open Source Insights](https://deps.dev/go/github.com%2Fbmurray%2Fsimconnect-go/v0.1.0 "View this module on Open Source Insights")
Jump to ...
- [README](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-readme)
- [SimConnect API Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#readme-simconnect-api-connector)
- [Documentation](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-documentation)
- [Index](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-index)
- [Constants](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-constants)
- [Variables](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-variables)
- [Functions](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-functions)
- [IsReport(s, ppData)](https://pkg.go.dev/github.com/bmurray/simconnect-go#IsReport "IsReport(s, ppData)")
- [RequestData(s)](https://pkg.go.dev/github.com/bmurray/simconnect-go#RequestData "RequestData(s)")
- [Types](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-types)
- [type Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector "type Connector")
- [NewConnector(name, opts)](https://pkg.go.dev/github.com/bmurray/simconnect-go#NewConnector "NewConnector(name, opts)")
- [(c) Start(ctx)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.Start "(c) Start(ctx)")
- [(c) StartReconnect(ctx)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.StartReconnect "(c) StartReconnect(ctx)")
- [type ConnectorError](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError "type ConnectorError")
- [(e) Error()](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError.Error "(e) Error()")
- [type ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorOption "type ConnectorOption")
- [WithCycle(cycle)](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithCycle "WithCycle(cycle)")
- [WithDLLPath(path)](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithDLLPath "WithDLLPath(path)")
- [WithLogger(l)](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithLogger "WithLogger(l)")
- [WithReceiver(r)](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithReceiver "WithReceiver(r)")
- [type Receiver](https://pkg.go.dev/github.com/bmurray/simconnect-go#Receiver "type Receiver")
- [Source Files](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-sourcefiles)
- [Directories](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-directories)
##  README [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-readme "Go to Readme")
### SimConnect API Connector
[](https://pkg.go.dev/github.com/bmurray/simconnect-go)
This package provides a convenient way to interact with the SimConnect API that takes the hassle out of dealing with the polling behavior of the API.
This is based on the seemingly abandoned [msfs2020-go](https://github.com/lian/msfs2020-go) package that implemented vfr map. The critical code is extracted, and a new connector API is layered on top to make writing reliable services much easier. This can be easily integrated with other servies, like UIs, APIs, etc.
See the [examples](https://github.com/bmurray/simconnect-go/blob/v0.1.0/examples) for sample code. The [fuelhack example](https://github.com/bmurray/simconnect-go/blob/v0.1.0/examples/fuelhack) provides the simpliest example of the API.
Expand βΎ
Collapse β΄
##  Documentation [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-documentation "Go to Documentation")
### Index [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-index "Go to Index")
- [func IsReport\[T any\](s \*client.SimConnect, ppData \*client.RecvSimobjectDataByType) (\*T, bool)](https://pkg.go.dev/github.com/bmurray/simconnect-go#IsReport)
- [func RequestData\[T any\](s \*client.SimConnect) error](https://pkg.go.dev/github.com/bmurray/simconnect-go#RequestData)
- [type Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector)
- - [func NewConnector(name string, opts ...ConnectorOption) \*Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#NewConnector)
- - [func (c \*Connector) Start(ctx context.Context)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.Start)
- [func (c \*Connector) StartReconnect(ctx context.Context)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.StartReconnect)
- [type ConnectorError](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError)
- - [func (e ConnectorError) Error() string](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError.Error)
- [type ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorOption)
- - [func WithCycle(cycle time.Duration) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithCycle)
- [func WithDLLPath(path string) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithDLLPath)
- [func WithLogger(l \*slog.Logger) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithLogger)
- [func WithReceiver(r Receiver) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithReceiver)
- [type Receiver](https://pkg.go.dev/github.com/bmurray/simconnect-go#Receiver)
### Constants [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-constants "Go to Constants")
This section is empty.
### Variables [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-variables "Go to Variables")
This section is empty.
### Functions [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-functions "Go to Functions")
#### func [IsReport](https://github.com/bmurray/simconnect-go/blob/v0.1.0/utils.go#L10) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#IsReport "Go to IsReport")
```
func IsReport[T any](s *client.SimConnect, ppData *client.RecvSimobjectDataByType) (*T, bool)
```
IsReport Convenience function to check if the data is the correct type
#### func [RequestData](https://github.com/bmurray/simconnect-go/blob/v0.1.0/utils.go#L20) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#RequestData "Go to RequestData")
```
func RequestData[T any](s *client.SimConnect) error
```
RequestData Convenience function to request data
### Types [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#pkg-types "Go to Types")
#### type [Connector](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L31) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector "Go to Connector")
```
type Connector struct {
// contains filtered or unexported fields
}
```
Connector is the main struct for connecting to SimConnect
#### func [NewConnector](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L78) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#NewConnector "Go to NewConnector")
```
func NewConnector(name string, opts ...ConnectorOption) *Connector
```
NewConnector creates a new connector you can pass options to the connector
#### func (\*Connector) [Start](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L93) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.Start "Go to Connector.Start")
```
func (c *Connector) Start(ctx context.Context)
```
Start starts the connector it will connect to SimConnect and start the receivers this is BLOCKING, and will terminate at the first disconnect
#### func (\*Connector) [StartReconnect](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L104) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.StartReconnect "Go to Connector.StartReconnect")
```
func (c *Connector) StartReconnect(ctx context.Context)
```
StartReconnect starts the connector with reconnect it will connect to SimConnect and start the receivers this is BLOCKING, and will reconnect on disconnect This is a simple wrapper around Start that adds a exponential backoff
#### type [ConnectorError](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L184) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError "Go to ConnectorError")
```
type ConnectorError string
```
ConnectorError is the error type for the connector
```
const (
// ErrE_FAIL is the error for E_FAIL
ErrE_FAIL ConnectorError = "E_FAIL"
// ErrGetNextDispatch is the error for GetNextDispatch
ErrGetNextDispatch ConnectorError = "GetNextDispatch"
)
```
#### func (ConnectorError) [Error](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L186) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError.Error "Go to ConnectorError.Error")
```
func (e ConnectorError) Error() string
```
#### type [ConnectorOption](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L43) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorOption "Go to ConnectorOption")
```
type ConnectorOption func(*Connector)
```
ConnectorOption is a function that sets options on the Connector
#### func [WithCycle](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L55) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithCycle "Go to WithCycle")
```
func WithCycle(cycle time.Duration) ConnectorOption
```
WithCycle sets the cycle time for the connector the connector will dispatch data every cycle
#### func [WithDLLPath](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L70) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithDLLPath "Go to WithDLLPath")
```
func WithDLLPath(path string) ConnectorOption
```
WithDLLPath sets the path to the SimConnect DLL if not set, the default DLL will be used
#### func [WithLogger](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L62) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithLogger "Go to WithLogger")
```
func WithLogger(l *slog.Logger) ConnectorOption
```
WithLogger sets the logger for the connector
#### func [WithReceiver](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L47) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithReceiver "Go to WithReceiver")
```
func WithReceiver(r Receiver) ConnectorOption
```
WithReceiver adds a receiver to the connector you can add multiple receivers
#### type [Receiver](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go#L16) [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#Receiver "Go to Receiver")
```
type Receiver interface {
// Start is called when the receiver is started
// it gets called after the connection is established
// and whenever a reconnection happens
// the context is cancelled when the connection is lost
// this may be called multiple times if the connection is lost and re-established
Start(ctx context.Context, sc *client.SimConnect)
// Update is called whenever a new data packet is received
// the context is cancelled when the connection is lost
// this may be called multiple times over the life of the connection
Update(ctx context.Context, sc *client.SimConnect, ppData *client.RecvSimobjectDataByType)
}
```
Receiver is the interface for receiving data from SimConnect
##  Source Files [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-sourcefiles "Go to Source Files")
[View all Source files](https://github.com/bmurray/simconnect-go/tree/v0.1.0)
- [connector.go](https://github.com/bmurray/simconnect-go/blob/v0.1.0/connector.go "connector.go")
- [utils.go](https://github.com/bmurray/simconnect-go/blob/v0.1.0/utils.go "utils.go")
##  Directories [ΒΆ](https://pkg.go.dev/github.com/bmurray/simconnect-go#section-directories "Go to Directories")
Show internal
Expand all
| Path | Synopsis |
|---|---|
| [client](https://pkg.go.dev/github.com/bmurray/simconnect-go@v0.1.0/client) | |
|  examples | |
| [fuelhack](https://pkg.go.dev/github.com/bmurray/simconnect-go@v0.1.0/examples/fuelhack) command | |
Click to show internal directories.
Click to hide internal directories.
[Why Go](https://go.dev/solutions) [Use Cases](https://go.dev/solutions#use-cases) [Case Studies](https://go.dev/solutions#case-studies)
[Get Started](https://learn.go.dev/) [Playground](https://play.golang.org/) [Tour](https://tour.golang.org/) [Stack Overflow](https://stackoverflow.com/questions/tagged/go?tab=Newest) [Help](https://go.dev/help)
[Packages](https://pkg.go.dev/) [Standard Library](https://pkg.go.dev/std) [Sub-repositories](https://pkg.go.dev/golang.org/x) [About Go Packages](https://pkg.go.dev/about)
[About](https://go.dev/project) [Download](https://go.dev/dl/) [Blog](https://go.dev/blog) [Issue Tracker](https://github.com/golang/go/issues) [Release Notes](https://go.dev/doc/devel/release.html) [Brand Guidelines](https://go.dev/brand) [Code of Conduct](https://go.dev/conduct)
[Connect](https://www.twitter.com/golang) [Twitter](https://www.twitter.com/golang) [GitHub](https://github.com/golang) [Slack](https://invite.slack.golangbridge.org/) [r/golang](https://reddit.com/r/golang) [Meetup](https://www.meetup.com/pro/go) [Golang Weekly](https://golangweekly.com/)

- [Copyright](https://go.dev/copyright)
- [Terms of Service](https://go.dev/tos)
- [Privacy Policy](http://www.google.com/intl/en/policies/privacy/)
- [Report an Issue](https://go.dev/s/pkgsite-feedback)
-   
Theme Toggle
- 
Shortcuts Modal
[](https://google.com/)
go.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic. [Learn more.](https://policies.google.com/technologies/cookies)
Okay |
| Readable Markdown | - [func IsReport\[T any\](s \*client.SimConnect, ppData \*client.RecvSimobjectDataByType) (\*T, bool)](https://pkg.go.dev/github.com/bmurray/simconnect-go#IsReport)
- [func RequestData\[T any\](s \*client.SimConnect) error](https://pkg.go.dev/github.com/bmurray/simconnect-go#RequestData)
- [type Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector)
- - [func NewConnector(name string, opts ...ConnectorOption) \*Connector](https://pkg.go.dev/github.com/bmurray/simconnect-go#NewConnector)
- - [func (c \*Connector) Start(ctx context.Context)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.Start)
- [func (c \*Connector) StartReconnect(ctx context.Context)](https://pkg.go.dev/github.com/bmurray/simconnect-go#Connector.StartReconnect)
- [type ConnectorError](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError)
- - [func (e ConnectorError) Error() string](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorError.Error)
- [type ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#ConnectorOption)
- - [func WithCycle(cycle time.Duration) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithCycle)
- [func WithDLLPath(path string) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithDLLPath)
- [func WithLogger(l \*slog.Logger) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithLogger)
- [func WithReceiver(r Receiver) ConnectorOption](https://pkg.go.dev/github.com/bmurray/simconnect-go#WithReceiver)
- [type Receiver](https://pkg.go.dev/github.com/bmurray/simconnect-go#Receiver)
This section is empty.
This section is empty.
IsReport Convenience function to check if the data is the correct type
RequestData Convenience function to request data
```
type Connector struct {
}
```
Connector is the main struct for connecting to SimConnect
```
func NewConnector(name string, opts ...ConnectorOption) *Connector
```
NewConnector creates a new connector you can pass options to the connector
Start starts the connector it will connect to SimConnect and start the receivers this is BLOCKING, and will terminate at the first disconnect
StartReconnect starts the connector with reconnect it will connect to SimConnect and start the receivers this is BLOCKING, and will reconnect on disconnect This is a simple wrapper around Start that adds a exponential backoff
ConnectorError is the error type for the connector
```
const (
ErrE_FAIL ConnectorError = "E_FAIL"
ErrGetNextDispatch ConnectorError = "GetNextDispatch"
)
```
```
type ConnectorOption func(*Connector)
```
ConnectorOption is a function that sets options on the Connector
WithCycle sets the cycle time for the connector the connector will dispatch data every cycle
WithDLLPath sets the path to the SimConnect DLL if not set, the default DLL will be used
WithLogger sets the logger for the connector
```
func WithReceiver(r Receiver) ConnectorOption
```
WithReceiver adds a receiver to the connector you can add multiple receivers
Receiver is the interface for receiving data from SimConnect |
| Shard | 3 (laksa) |
| Root Hash | 12293604993604953403 |
| Unparsed URL | dev,go!pkg,/github.com/bmurray/simconnect-go s443 |