avrdude: ser_open(): can't open device "\\.\COM4": Access is denied. code example
Example: avrdude: ser_open(): can't open device "/dev/ttyACM0": Permission denied ioctl("TIOCMGET"):
# On a terminal:
#If you use Ubuntu, Debian etc...
sudo adduser <yourname> dialout
# If you user Arch Linux...
sudo gpasswd -a <yourname> dialout
#then
sudo chmod a+rw /dev/ttyACM0