Skip to content

This project provides Go bindings for libdivecomputer - a cross-platform and open source library for communication with dive computers from various manufacturers.

Notifications You must be signed in to change notification settings

theCarlG/libdivecomputer-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

libdivecomputer-go GoDoc

This project provides Go bindings for libdivecomputer v0.6.0 - a cross-platform and open source library for communication with dive computers from various manufacturers.
All the binding code has automatically been generated with rules defined in core.yml. There are future plans to write a high level wrapper for the bindings

Before start you must install libdivecomputer.

Usage

$ go get github.com/calle-gunnarsson/libdivecomputer-go/core

Demo

These are simple ports of dctool <list,dump,download> and will probably contain some memory leaks or other bugs.

# List all supported devices
$ go get github.com/calle-gunnarsson/libdivecomputer-go/cmd/dc_list
$ dc_list

# Memory dump of device
$ go get github.com/calle-gunnarsson/libdivecomputer-go/cmd/dc_dump
$ dc_dump -name d9 -family suunto -filename dump.bin -devname /dev/ttyS1

# Save dives as json to file
$ go get github.com/calle-gunnarsson/libdivecomputer-go/cmd/dc_download
$ dc_download -name d9 -family suunto -filename dump.json -devname /tmp/ttyS1

Rebuilding the package

You will need to get the c-for-go tool installed first.

$ git clone github.com/calle-gunnarsson/libdivecomputer-go && cd libdivecomputer-go
$ make clean && make

About

This project provides Go bindings for libdivecomputer - a cross-platform and open source library for communication with dive computers from various manufacturers.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published