Can't change scfg for serial communication | Thales IoT Developer Community
December 2, 2014 - 11:07am, 3895 views
I changed AT^SCFG="Gpio/****/SPI" to std, because I need SPI line to communicate to sensor trough I2C. Now I have problem, because I also need serial communication, but I am having problems with it. Sometimes my java midlet won't open COM0. I check in the old threads (https://iot-developer.thalesgroup.com/threads/rs-232-connected-asc1) and if I understand corectly I need to set scfg to this:
My scfg is: http://pastebin.com/yT4UGrfG
But every time I try to chang my scfg to that values I get error:
Also a sub question. What settings should I use so that I can open COM0 port in Java even if the device isn't yet connected? It wokred in the past if I added to parameters blocking=on or off, but that doesn't work anymore and device has to be connected that it works.
The same lines may be dedicated to different interfaces. And you can change this with scfg command.
You can find the details in the AT commands Specification document.
But here you are using ASC0. And as I can see in the SCFG output the settings for ASC0 look fine.
SPI lines are shared with ASC1 so it shouldn't matter here.
Have you checked the SPOW command output? Is your answer "^SPOW: 1,0,0" ?
If you want to changethe "Serial/Interface/Allocation" option you should write at^scfg="Serial/Interface/Allocation","1"
at^spow returns "^SPOW: 1,0,0".
The only thing that I changed in SCFG was AT^SCFG="Gpio/****/SPI" to std and sometime after that problem apeared that I can't open COM0 before that other device isn't sending CTS and DSR. Before that I managed to open COM0 with seeting the blocking parameter, even if the device wasn't pluged. Without that I can't have my midlet runing because COM0 opens at the start of the program so that customer can enter commands when it ***** and so if module restarts midlet won't run.
I managed to fix it. It wasn't problem in SCFG but also I had to set autocts to on. Thank you for your help.