Help us shape the future of Go! Take the 2026 Go Developer Survey

memio

package module
v0.0.0-...-08a4320 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2018 License: GPL-2.0, GPL-2.0-or-later Imports: 3 Imported by: 2

README

memory mapped io


© 2015-2018 Platina Systems, Inc. All rights reserved. Use of this source code is governed by this BSD-style LICENSE.

Documentation

Overview

Memory mapped register read/write

Index

Constants

View Source
const Version = "v0.0.0"

Version format :: v<MAJOR>.<MINOR>.<PATCH>[-rc<CANDIDATE>]

Variables

View Source
var (
	BasePointer = basePointer()
	BaseAddress = uintptr(BasePointer)
)

Must point to readable memory since compiler may perform read probes (nil checks) as part of memory addressing.

Functions

func CheckRegAddr

func CheckRegAddr(name string, got, want uint)

func LoadUint16

func LoadUint16(addr uintptr) (data uint16)

func LoadUint32

func LoadUint32(addr uintptr) (data uint32)

Memory-mapped read/write

func LoadUint64

func LoadUint64(addr uintptr) (data uint64)

func MemoryBarrier

func MemoryBarrier()

func StoreUint16

func StoreUint16(addr uintptr, data uint16)

func StoreUint32

func StoreUint32(addr uintptr, data uint32)

func StoreUint64

func StoreUint64(addr uintptr, data uint64)

Types

type U8

type U8 uint8

Generic 8/16/32 bit registers

func (*U8) Offset

func (r *U8) Offset() uintptr

Byte offsets

type U16

type U16 uint16

func (*U16) Offset

func (r *U16) Offset() uintptr

type U32

type U32 uint32

func (*U32) Get

func (r *U32) Get(base uintptr) uint32

func (*U32) Offset

func (r *U32) Offset() uintptr

func (*U32) Set

func (r *U32) Set(base uintptr, x uint32)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL