This is a minimal go module that generates a code to unlock a Renault car radio.
package main
import (
"fmt"
"github.com/radcoderen/go-code-autoradio-renault"
)
func main() {
code, ok := autoradio.GenerateCode("A123")
if ok {
fmt.Println(code)
} else {
fmt.Println("The precode is not valid.")
}
}
The documentation is available on pkg.go.dev.
This module also provides an executable that can be used to generate the code.
> go install github.com/radcoderen/go-code-autoradio-renault/cmd/renaultcode
> renaultcode A123
You can download the executable from the releases page.
You can find all codes generated by renaultcode --all
in the codes.txt file.