Code: Select all
#NCCS = 32
#TCSANOW = 0
Structure termios Align #PB_Structure_AlignC
c_iflag.l
c_oflag.l
c_cflag.l
c_lflag.l
c_line.a
c_cc.a[#NCCS]
c_ispeed.l
c_ospeed.l
EndStructure
ProcedureDLL xx()
PortID = 0 ;SerialPortID(Port)
If tcgetattr_(PortID, @options) = 0 ; читает параметры порта.
If cfsetispeed_(@options, Sp) = 0 ; установка скорости порта.
If cfsetospeed_(@options, Sp) = 0 ; установка скорости порта.
If tcsetattr_(PortID, #TCSANOW, @options) = 0
Result=#True
EndIf
EndIf
EndIf
EndIf
EndProcedure
The problem only occurs when creating so-library. Use Linux Mint 16 x64.
This command does not work.
Code: Select all
Import "-fPIC" : EndImport


