Hi all, I am also interested in serial ports for a student project. What I understood so far: - A patch as been in integrated in 1.3 http://code.google.com/p/pharo/issues/detail?id=1057 @Bill, what are the differences with your code? - the standard VM (Squeak-4.2.5beta1U for me as a Mac user) should be OK primitives in the SerialPlugin are: 00001230 T _primitiveSerialPortFindNamesPlusKeys 00001410 T _primitiveSerialPortUnixCfgetispeed 00001618 T _primitiveSerialPortUnixCfgetospeed 00001820 T _primitiveSerialPortUnixCfmakeraw 000019f8 T _primitiveSerialPortUnixCfsetispeed 00001c74 T _primitiveSerialPortUnixCfsetospeed 00001ef0 T _primitiveSerialPortUnixClose 00002038 T _primitiveSerialPortUnixErrno 00002108 T _primitiveSerialPortUnixOpen 000022e8 T _primitiveSerialPortUnixRead 000025ec T _primitiveSerialPortUnixSizeOftermios 000026b0 T _primitiveSerialPortUnixTcdrain 000027f8 T _primitiveSerialPortUnixTcflow 0000296c T _primitiveSerialPortUnixTcflush 00002ae0 T _primitiveSerialPortUnixTcgetattr 00002d34 T _primitiveSerialPortUnixTcsendbreak 00002ea8 T _primitiveSerialPortUnixTcsetattr 00003128 T _primitiveSerialPortUnixWrite 0000342c T _primitiveSerialPortUnixioctl Students will tests that soon. Cheers, #Luc 2011/3/2 Friedrich Dominicus <frido@q-software-solutions.de>
"Schwab,Wilhelm K" <bschwab@anest.ufl.edu> writes:
Friedrich,
I recall having success with the vm as-is and just patching the image. One thing the vm certainly should do is tell us the translations it makes. I think it is always a good idea to know which port was actually opened, or failed to open :) Double that for external libraries, but that's another story.
Sorry I wonder the primitive is placed in libSerialPlugin.a this are the function I found in the Content/Linux subdirectory
e 08102f10 t primitiveSerialPortOpen 08102df0 t primitiveSerialPortRead 08102cc0 t primitiveSerialPortWrite 08105980 t primitiveSocketBindToPort 081055c0 t primitiveSocketConnectToPort 08104b40 t primitiveSocketListenOnPort 08104a00 t primitiveSocketListenOnPortBacklog 08104830 t primitiveSocketListenOnPortBacklogInterface 08104670 t primitiveSocketLocalPort 08103e60 t primitiveSocketRemotePort 08102630 t secCanConnectToPort 081025d0 t secCanListenOnPort 081034a0 T serialPortClose 081030d0 T serialPortInit 080d9a90 T serialPortMidiClockRate 08103210 T serialPortOpen 08103190 T serialPortReadInto 081030b0 T serialPortShutdown 08103120 T serialPortWriteFrom
The code in Pharo is: <primitive: 'primitiveSerialPortOpenByName' module:'SerialPlugin'> So hasn't there a function with that name?
Regards Friedrich
-- Q-Software Solutions GmbH; Sitz: Bruchsal; Registergericht: Mannheim Registriernummer: HRB232138; Geschaeftsfuehrer: Friedrich Dominicus