serial comunication krc2

  • hello dears,

    i'm new in krl.

    please help me to start with serial comunication on krc2.

    how to open COM2 and send and receive data to another pc.

    may you send simple example program.

    thanks alot

  • it also depends on the protocol you want to use


    - for sensor communication you want to use the 3964r protocol (it is like tcp)

    - for other communication you want to use XON/XOFF (it is like udp)


    Question: what is your goal?

  • You still didn't mention what generation KRC2 you're using.


    Dug out some old backup files. These are from ed2005s, running KSS 5.4:

    HW_INF.INI:

    Code
    [SERIAL]
    ;ENABLE:  COM is accessible by robot (vxWorks)
    ;DISABLE: COM is accessible by Win95
    ;CONSOLE: for developer only
    COM3=ENABLE    ;[ENABLE, DISABLE, CONSOLE]


    SERIAL.INI contains the settings for the serial port: baud rate, protocol, parity, etc.


    The CWRITE manual contains some information on serial port config.

  • I configured serial.ini with xonxoff proc and comminucation is good .

    But when i change proc to 3649R and send data to laptop i receive 02 02 02 02 15 assci . :thinking_face:

  • But when i change proc to 3649R and send data to laptop i receive 02 02 02 02 15 assci .

    This is actually STX STX STX STX NAK


    The KRC is sending STX in order to start the communication.

    Your other PC is not responding in the specified time and the KRC repeats STX.

    After 3 retrys the KRC stops to send the request and sends NAK



Advertising from our partners