jpnurmi / libserialport.dart

Serial Port for Dart
https://pub.dev/packages/libserialport
GNU Lesser General Public License v3.0
86 stars 34 forks source link

permission denied errno = 13 #38

Open wrjcs opened 3 years ago

wrjcs commented 3 years ago

Hello, I use this package into my android project. And when I open the port, I got this error permission denied errno = 13 Could you help me? Thanks.

donna6355 commented 2 years ago

I also have this same issue. Is there any solution? How can I have serial port permission for Android?

saguado69 commented 2 years ago

Same issue for me as well, I can open port on macOS but not able to open them on Android emulator or real device connected having a USB C/RS232 port connected.

@donna6355 @wrjcs did you find any solution?

Thanks.

donna6355 commented 2 years ago

I didn't find the proper solution yet, but I found one possible way to allow permission. You need a rooted android phone and connect it to your PC. Open terminal and try this.

$adb shell 
$su
$chmod 666 /dev/ttys0

Though I failed to root my android phone and couldn't try this.... @saguado69 wish you good luck...

saguado69 commented 2 years ago

Thank you for sharing @donna6355, I find a workaround with usbserial library (https://pub.dev/packages/usb_serial), ao the pitty is that I have to use both libraries for my cross-platform project, but it works fine.

Regards,

S.

saguado69 commented 2 years ago

Thank you for sharing @donna6355, I find a workaround with usbserial library (https://pub.dev/packages/usb_serial), ao the pitty is that I have to use both libraries for my cross-platform project, but it works fine.

Regards,

S.

saguado69 commented 2 years ago

Thank you for sharing @donna6355, I find a workaround with usbserial library (https://pub.dev/packages/usb_serial), ao the pitty is that I have to use both libraries for my cross-platform project, but it works fine.

Regards,

S.

saguado69 commented 2 years ago

Thank you for sharing @donna6355, I find a workaround with usbserial library (https://pub.dev/packages/usb_serial), ao the pitty is that I have to use both libraries for my cross-platform project, but it works fine.

Regards,

S.

saguado69 commented 2 years ago

Thank you for sharing @donna6355, I find a workaround with usbserial library (https://pub.dev/packages/usb_serial), ao the pitty is that I have to use both libraries for my cross-platform project, but it works fine.

Regards,

S.