vcom_connected() == FALSE Ubuntu Linux 14.04 - Use USB for Serial Monitor

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

vcom_connected() == FALSE Ubuntu Linux 14.04 - Use USB for Serial Monitor

1,355件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by a_bet on Fri Mar 18 07:14:02 MST 2016
Hi everyone,
I'm new to lpcxpresso and to the arm world. I've bought a lpcxpresso 43s37 board, which is doing fine with all the lpcopen examples i've tried.
In order to do some ADC and dsplay the data I'd like to set up the serial monitor.
Sadly I don't have a usb-uart adaptor so I'm trying to use the vcom on J5 as said in the docs.
When I build and debug the usbd_rom_cdc_vcom example from the LPCOpen folder everything seems ok, and the debug console gives no error. But the simply anything happens: no Hello World printed on the Console.
Observing the Step Over execution I noticed that the 1st if statement in the superloop is always false.
The superloop is as follows

Quote:
while (1) {
/* Check if host has connected and opened the VCOM port */
if ((vcom_connected() != 0) && (prompt == 0)) {
vcom_write("Hello World!!\r\n", 15);
prompt = 1;
}
/* If VCOM port is opened echo whatever we receive back to host. */
if (prompt) {
rdCnt = vcom_bread(&g_rxBuff[0], 256);
if (rdCnt) {
vcom_write(&g_rxBuff[0], rdCnt);
}
}
/* Sleep until next IRQ happens */
__WFI();
}



So, it seems that the VCOM is actually NOT connected.
Since in the readme.txt is given no advice for linux users I'm quie stuck at this point.

Any hint woulb be higly appreciated,
thanks in advance
ラベル(1)
3 返答(返信)

1,143件の閲覧回数
monparahimanshu
Contributor I

you can remove the hello world statement.

what code does is, when you open the port and send first string it sends back to host and afterwords it enter into the command transmitting loop.

in Linux you can install screen and try to send any char it will send back.

i hope it works, let me know if you have any question.+

Regards,

himanshu

0 件の賞賛
返信

1,143件の閲覧回数
rishitborad
Contributor II

Any one faced this issue? Whats the cause?

Thanks

Rishit

0 件の賞賛
返信

1,143件の閲覧回数
lpcware
NXP Employee
NXP Employee
bump
0 件の賞賛
返信