Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

CODESYS RPI2 and serial communication

Damian7546
2017-12-08
2017-12-10
  • Damian7546 - 2017-12-08

    I have a problem with serial communication.
    My CODESYSControl.cfg file is:

    [SysCom]
    Linux.Devicefile=/dev/ttyAMA
    portnum := COM.SysCom.SYS_COMPORT1;
    Linux.Devicefile=/dev/ttyACM
    portnum := COM.SysCom.SYS_COMPORT2;

    On port 1 everythink is ok. It is work, but I have problem with port2.
    I can't even open this port.
    Example on screenshot in attachment.
    Where is the problem ?

    IMG: zdj1.jpg

     
  • eschwellinger

    eschwellinger - 2017-12-08

    Hi,
    this does not work that way.

    use only this
    [SysCom]Linux.Devicefile=/dev/ttyAMA

    and set a symlink in Linux for
    /dev/ttyACM0 -> =/dev/ttyAMA1

    BR
    Edwin

     
  • Damian7546 - 2017-12-09

    I used command:

    sudo ln -s devttyACM0 devttyAMA1

    and it is works, but after reboot AMA1 disapear, what is wrong ?

     
  • eschwellinger

    eschwellinger - 2017-12-10

    Hi,
    guess the proper solution is to add it by udev rules
    would recommen to google for it.
    If you add a symbloc link sure you need to add after rebooting the system..
    BR
    Edwin

     

Log in to post a comment.