If you look at the docs a bit more closely you can use this method;
func ParseInt(s string, base int, bitSize int)
https://golang.org/pkg/strconv/#ParseInt
The bitSize
argument says how large the int is so you can do 8
or 16
or 32
for those smaller integer types. Atoi
calls this internally. I believe you're wanting 10
for the base
argument. So like b, err := strconv.ParseInt("5", 10, 8)
for a byte.
EDIT: Just going to add a couple things to the answer here in case the OP is in fact confused how to convert a 16-bit int into a string... If that is your intended goal just use fmt.Sprintf
or you can do a conversion from smaller int to larger int as it will always succeed. Examples of both here; https://play.golang.org/p/UWSVxEmQ1N
package main
import "fmt"
import "strconv"
func main() {
var a int16
a = 5
s := fmt.Sprintf("%d", a)
s2 := strconv.Itoa(int(a))
fmt.Println(s)
fmt.Println(s2)
}