update to receive smses, just add:
[GSM1]
device = /dev/vmodem0
send_delay = 25
the send_delay, makes every write delayed about 25 ms - because there is no real handshake in pty mode.
to reproduce, stop asterisk, reload dahdi to bring card into sane mode
socat PTY,link=/dev/vmodem0,raw,echo=0,wait-slave,perm-early=666,user=smsd,crnl EXEC:"/usr/local/bin/g4term 2",pty,crnl &
socat PTY,link=/dev/vmodem1,raw,echo=0,wait-slave,perm-early=666,user=smsd,crnl EXEC:"/usr/local/bin/g4term 4",pty,crnl &
socat PTY,link=/dev/vmodem2,raw,echo=0,wait-slave,perm-early=666,user=smsd,crnl EXEC:"/usr/local/bin/g4term 6",pty,crnl &
socat PTY,link=/dev/vmodem3,raw,echo=0,wait-slave,perm-early=666,user=smsd,crnl EXEC:"/usr/local/bin/g4term 8",pty,crnl &
So reading sms from sim card works:
2012-05-15 10:24:42,7, GSM1: -> AT+CPMS?
2012-05-15 10:24:42,7, GSM1: Command is sent, waiting for the answer
2012-05-15 10:24:42,7, GSM1: <- AT+CPMS? +CPMS: "SM",3,25,"SM",3,25,"SM",3,25 OK
2012-05-15 10:24:42,6, GSM1: Checking memory size
2012-05-15 10:24:43,7, GSM1: -> AT+CPMS?
2012-05-15 10:24:43,7, GSM1: Command is sent, waiting for the answer
2012-05-15 10:24:43,7, GSM1: <- AT+CPMS? +CPMS: "SM",3,25,"SM",3,25,"SM",3,25 OK
2012-05-15 10:24:43,6, GSM1: Used memory is 3 of 25
2012-05-15 10:24:43,6, GSM1: Trying to get stored message 1
2012-05-15 10:24:43,7, GSM1: -> AT+CMGR=1
2012-05-15 10:24:43,7, GSM1: Command is sent, waiting for the answer
2012-05-15 10:24:44,7, GSM1: <- AT+CMGR=1 +CMGR: 1,,29 07918497908913F0040B918405145775F70000215041516071800BD4F29C0ED283E0ECFA1C OK
2012-05-15 10:24:44,5, GSM1: SMS received, From: 48504XXXXXX
2012-05-15 10:24:44,6, GSM1: Wrote an incoming message file: /var/spool/sms/incoming/GSM1.ZdB7wa