Hi
When i was testing a serial communication level sensor, using a CR800's COM1 port, i didnt have any answer from the sensor. i tryed to change it to COM2 with the same result. then i tryed to use the serial RS232 COM port and it worked fine. but in the field i cant use the RS232 or the CS I/O port because they are already taken. I tryed to reload the OS to the most recent there was in your page (OS Std 22) and it stayed the same. when i use an external hiperterminal to see what is being written in the COM port it seems to be the correct message. Does anyone has an ideia why this happens and how can i fix it?
i use this test program:
SequentialMode
Public PTemp, batt_volt
Public StrgPressao As String * 30
Public StatusStrg As String * 100
Public Pressao
'Main Program
BeginProg
Scan (10,Sec,10,0)
PanelTemp (PTemp,250)
Battery (batt_volt)
'measurement instruction
SerialOpen (ComRS232,9600,0,5,1000)
SerialFlush (ComRS232)
SerialOut (ComRS232,"pres?" + CHR(13),"",0,0)
SerialIn (StrgPressao,ComRS232,200,"",30)
SerialClose (ComRS232)
'using the COM1 or COM2 as comminication ports, it doesnt 'take any values
If StrgPressao="" Then
StatusStrg="msg fail"
Pressao=0
Else
StatusStrg="msg OK"
Pressao = StrgPressao
EndIf
NextScan
EndProg
Thanks a lot
The serial ports provided through control ports are limited to TTL voltage levels (0-5 V). This is likely to be the reason why the sensors fail to work over these ports. With SDC devices, like the SC105 and MD485, multiple devices can be attached to the CS I/O port provided that each of them is assigned a different SDC address in their settings.
is there any command that i should use to get a GPRS modem comunicating with a logger through the COM Ports?
You were correct jtrauntvein, the sensor i use doesnt use TTL voltage values. but in the field i already have one modem linked to the RS232 port, so now, im trying to get the modem to link with the CR800 through COM2, leaving the RS232 port to the sensor, but im not having sucess until now.
im my program i just open COM2 before doing the scan routine
thanks
JPRodrigues
* Last updated by: TaCaPica on 11/2/2011 @ 9:58 AM *
@TaCaPica
i have the same problem, but john from campbell helped me out.
since the com ports doesn't act like a real RS-232 port, you have to put 5V on the serial connection.
so,
5V - Red
Tx - Black
Rx - Orange
G - Green
and just make sure you do a serialopen command, and don't use autobaud on the modbusmaster command.
Mark