https://github.com/diegohce/gogwave
Go language bindings for the ggwave C++ library
https://github.com/diegohce/gogwave
data-over-sound ggwave go golang sound-library ultrasound
Last synced: 2 months ago
JSON representation
Go language bindings for the ggwave C++ library
- Host: GitHub
- URL: https://github.com/diegohce/gogwave
- Owner: diegohce
- License: other
- Created: 2025-04-01T22:09:00.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2025-04-01T22:11:15.000Z (3 months ago)
- Last Synced: 2025-04-02T09:42:09.023Z (3 months ago)
- Topics: data-over-sound, ggwave, go, golang, sound-library, ultrasound
- Language: Go
- Homepage:
- Size: 5.86 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.txt
Awesome Lists containing this project
README
[](https://pkg.go.dev/github.com/diegohce/gogwave) [](https://goreportcard.com/report/github.com/diegohce/gogwave)
# GoGWave
The gogwave package provides Go language bindings for the [ggwave](https://github.com/ggerganov/ggwave) C++ library.
**Note:** At the moment, gogwave supports linux systems only.
For further detail see the [GoDocs](https://pkg.go.dev/github.com/diegohce/gogwave)
## How to use
This example encodes a payload (`[]byte`) into a waveform, stores the waveform as a .wav file, and decodes the waveform back into a payload.
```Go
func main() {
gg := New()
defer gg.Close()waveform, err := gg.Encode([]byte("hola"), ProtocolAudibleNormal, 50)
if err != nil {
panic(err)
}b, err := gg.Decode(waveform)
if err != nil {
panic(err)
}payload := string(b)
fmt.Println("payload:", payload)
}
```## How to build & install ggwave
To install ggwave library follow the [ggwave building/installing instructions](https://github.com/ggerganov/ggwave?tab=readme-ov-file#building)
An alternative is using GoGWave's `Makefile`
Clone this repo:
```bash
git clone https://github.com/diegohce/gogwave
cd gogwave
```Build (linux):
```bash
make
```Install:
```bash
sudo make install
```after building ggwave, from GoGWave's root directory run:
```bash
go test .
```
tests should run fine.**Note:** `ggwave` directory is safe to remove after building and installing.
## License
GoGWave is licensed under the Apache 2.0 license. Copyright (c) 2025 Diego Cena
## ggwave License
ggwave is licensed under the MIT license. Copyright (c) 2020 Georgi Gerganov