Posts: 2
Joined: Thu Jan 05, 2017 10:26 pm

ATmega328 Serial Monitor problem

Thu Jan 05, 2017 10:32 pm

I've read Gordon's blog pages and used the instructions on on the way to setting up my own Raspberry Pi and ATmega328 board but I've run into a problem that I have yet to see a solution to.

Fuses are programmed on the ATmega328 and Arduino IDE launched. The 'Serial Port' menu option is greyed out. The pi user is a member of the tty group.

Several forum posts talk about creating a symlink from /dev/ttyUSB0 to /dev/ttyAMA0 (which exists). I tried this and although it resulted in the menu option being enabled, attempts to use the Arduino Serial Monitor resulted in the following error... Inappropriate ioctl for device in nativeavailable
at Method)

I checked the file /boot/cmdline.txt and it still contains 'console' settings but no tty/AMA0 params...
dwc_otg.lpm_enable=0 console=serial0,115200 root=/dev/mmcblk0p7 rootfstype=ext4 elevator=deadline rootwait

Perhaps I should remove the 'console=serial0' part but I'm not certain. /etc/inittab is empty but "inappropriate ioctl" suggests to me that ttyAMA0 and ttyUSB0 are somehow incompatible. Suggestions gratefully accepted.

Posts: 2
Joined: Thu Jan 05, 2017 10:26 pm

Re: ATmega328 Serial Monitor problem

Fri Jan 06, 2017 6:50 am

After a lot of searching I found the answer on this post here: ... ding-pi-3/

The two key changes I needed to make were:
a) Adding enable_uart=1 into /boot/config.txt and
b) Removing console=serial0,115200 from /boot/cmdline.txt

The symbolic link I referred to in my post was not necessary.

Return to “HATs and other add-ons”