Can't able to access serial port on Raspberry pi - Raspberry Pi Forums


when executing code prompting below..
file "check.py", line 2, in <module>
ser=serial.serial('/dev/ttyama0/')
file "/usr/lib/python2.7/dist-packages/serial/serialutil.py", line 260, in __init__
self.open()
file "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 276, in open
raise serialexception("could not open port %s: %s" % (self._port, msg))
serial.serialutil.serialexception: not open port /dev/ttyama0/: [errno 20] not directory: '/dev/ttyama0/'
pls hlp me i'm struggling on here

the device name /dev/ttyama0 not /dev/ttyama0/ remove trailing / name

code: select all

ser=serial.serial('/dev/ttyama0') 


raspberrypi



Comments

Popular posts from this blog

invalid use of void expresion in FlexiTimer2 library

error: a function-definition is not allowed here before '{' token

LED Strip Code