package main
import (
    "fmt"
    "syscall"
    "unsafe"
)
func byteArrPtr(buf []byte) uintptr {
	return uintptr(unsafe.Pointer(&buf))
}
func main(){
    fmt.Printf("Hello World!")
	dll := syscall.NewLazyDLL("CommonInterface.dll")
    pOpenDevice := dll.NewProc("OpenDevice")
	pOpenDevice.Call(uintptr(unsafe.Pointer(syscall.StringBytePtr("USB"))), uintptr(unsafe.Pointer(syscall.StringBytePtr("261A0011"))), uintptr(unsafe.Pointer(syscall.StringBytePtr(""))))
	pIdReadCard := dll.NewProc("IdReadCard")
	idCardInfo := make([]byte, 40960)
	pIdReadCard.Call(0, 1, uintptr(unsafe.Pointer(&idCardInfo)), 0)
}