go-rkvendorstorage

A pure Golang implementation of Rockchip rknand vendor storage interface.

MIT License

Stars
5

go-rkvendorstorage

A pure Golang implementation of Rockchip rknand vendor storage interface.

Usage

package main

import (
	"fmt"
	"github.com/jamesits/go-rkvendorstorage"
)

func main() {
	size, data, err := rkvendorstorage.Read(rkvendorstorage.IDVendorSN)
	fmt.Printf("size=%d, data=%s, err=%s\n", size, string(data), err)
}

See read_test.go for more examples.

Caveats

  • Linux is the only OS supported for now
  • An artificial 1024-byte limit is applied to the read/write buffer
  • Endianness is hardcoded as little endian

If you have valid use cases that exceed the current limitations, please raise an issue.

Acknowledgements

The following articles are referenced during the development of this library:

Thank Qingping for sponsoring some RK3128 development boards.

Package Rankings
Top 7.67% on Proxy.golang.org
Badges
Extracted from project README
Go Reference