How to change the default 'debug/programming' com port?

Hi all,

Using an FXT002, I have an application that uses the USB and COM2 (via add on card) ports, during normal operation.
I use COM1 for development, i.e. “debugging” using debug traces.

I now want to change the debug port to COM2. This would allow me to require ‘extra’ com2 hardware only for development.

I would expect (but can’t seem to find) commands to set COM2 to debug mode, and perhaps assign some I/O as control lines for COM2, if required by DS.

Has anybody tried this before?
tia

DS presents a complete list of available COM ports: you can choose any one at any time; you can change your selection at will.

You switch a port into debug mode by pressing the ‘Switch to Development Mode’ button;
You switch a port out of debug mode by pressing the ‘Switch to Production Mode’ button.

That’s all there is to it!

Hi awneil,

Perhaps this will make it more clear…

Read UART 1 and 2 for above. I’m talking about the serial ports on the FXT002, not my PC.

So, I’m trying to get the FXT002 to use its uart2 for debugging. Yes, the standard FXT002 does not have a RS232 driver IC, but I do.

Any ideas?
tia

It’s DS that “commands” the port to go into “Development” mode - so you just need to connect whatever port you choose to DS, and press the ‘Development Mode’ button for that port.

Simples.

Or. to put it slightly differently:

  • If you connect DS to UART1, and press the ‘Development Mode’ button, UART1 will go into Development mode;

  • If you connect DS to UART2, and press the ‘Development Mode’ button, UART2 will go into Development mode;

  • If you connect DS to UART3 (USB), and press the ‘Development Mode’ button, UART3 (USB) will go into Development mode.

Only one UART can be in Development mode at a time, but you can have all 3 connected to DS simultaneously - with the other 2 in “Production” mode.

You can switch the UART that’s in Development mode back to Production mode, and then put one of the others into Development mode at will.

Thanks awneil, that was useful.

I’ll give it a go.

Hello,
I have development kit for SL6087, there are two UARTs. I use UART1 in development mode. I need to use UART2 in development mode, but I’m unable to switch to it, because UART2 is “turned off”. I get timeout error when trying to switch do DM. I checked cable, switch near port is in ON position…
Can’t switch to DM even when application is not running (wopen=0).
Do you have idea what could be wrong?
Thanks.

What version of firmware do you use?
On old firmware it may be impossible to do.

Also, I found debugging via USB is not as reliable as via COM port. Mainly if modem resets, PC is not always happy to re-connect USB port.

Rudolf

So turn it “ON”, then :exclamation:

I don’t think there are any firmware limitations on accessing the debug traces :question:

I’m using firmware version: R7.46.0.201108091301

It’s not turned off, it’s “turned off”. :wink: It acts like turned off.
I measured port (shorcircuit RX and TX → loopback) and found out, that connection from PC to SL6087 is ok. (Tried it with socket-up removed)
It looks like UART2 on SL6087 is somehow disabled. Therefore Developer studio is unable to operate with port (timeout errors).
Even “Open port” button generates timeout error.

I “solved” my issue. If someone will have similar issue, this could help:
Port UART2 was disabled. By default all ports are enabled, but for some reason I had UART2 disabled. You can check state of ports by command

AT+WMFM?

It will return something like this:

+WMFM: 0,2,1,1
+WMFM: 0,2,2,0
+WMFM: 0,2,3,1
+WMFM: 1,2,4,0
+WMFM: 1,2,4,1

Third column is port ID (UART1=1, UART2=2, USB=3). Fourth column is state (enabled=1, disabled=0). In order to enable port send

AT+WMFM=0,1,2

More about this command can be found in At command guide.