Luc Fabresse <luc.fabresse@gmail.com> writes:
2012/11/11 Friedrich Dominicus <frido@q-software-solutions.de>
Luc Fabresse <luc.fabresse@gmail.com> writes:
> > Did you tried: > > sPort := SerialPort new. > sPort close. > sPort openPort: '/dev/ttyS0'. No, but now I did and with a symbolic link from /dev/ttyUSB0 to /dev/ttyS0 Â I get this thing opened?
I do not understand why you need a symlink. Well in the end I want to open /dev/ttyUSB0 and this is what I've done: ls -l ttyS* lrwxrwxrwx 1 root root 7 Nov 8 15:11 ttyS0 -> ttyUSB0
So there is a symbolic link from /dev/ttyUSB0 to /dev/ttyS0 Now if I'm trying: sPort := SerialPort new. sPort close. sPort openPort: '/dev/ttyUSB0'. I get: 11 November 2012 4:26:26.774 pm VM: unix - i686 - linux-gnu - CoInterpreter VMMaker-oscog-EstebanLorenzano.166 uuid: 5773fcb9-2982-4507-8a9e-4308ec33731e Nov 6 2012, StackToRegisterMappingCogit VMMaker-oscog-EstebanLorenzano.166 uuid: 5773fcb9-2982-4507-8a9e-4308ec33731e Nov 6 2012, https://git.gitorious.org/cogvm/blessed.git Commit: a7bf128cd3b9389e77ea0cdec9a515282926a483 Date: 2012-11-02 14:17:44 +0100 By: Esteban Lorenzano <estebanlm@gmail.com> Jenkins build #136 Image: Pharo1.4 [Latest update: #14457] SerialPort(Object)>>error: Receiver: SerialPort(closed, 9600 baud, 8 bits, 1 stopbits, no parity) Arguments and temporary variables: aString: 'Cannot open ''/dev/ttyUSB0''' Receiver's instance variables: port: nil baudRate: 9600 stopBitsType: 1 parityType: 0 dataBits: 8 outputFlowControlType: 0 inputFlowControlType: 0 xOnByte: 19 xOffByte: 24 SerialPort>>openPort: Receiver: SerialPort(closed, 9600 baud, 8 bits, 1 stopbits, no parity) Arguments and temporary variables: portId: '/dev/ttyUSB0' result: nil Receiver's instance variables: port: nil baudRate: 9600 stopBitsType: 1 parityType: 0 dataBits: 8 outputFlowControlType: 0 inputFlowControlType: 0 xOnByte: 19 xOffByte: 24 If I'm doing: SerialPort(#'/dev/ttyS0', 9600 baud, 8 bits, 1 stopbits, no parity) So the port is properly opened. Don't ask me why I'm not understanding it. Regards Friedrich