Bug 2075 - System.IO.Ports SerialPort.DataReceived event doesn't work
Summary: System.IO.Ports SerialPort.DataReceived event doesn't work
Status: NEEDINFO
Alias: None
Product: Class Libraries
Classification: Mono
Component: System (show other bugs)
Version: 2.10.x
Hardware: PC All
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2011-11-17 00:09 UTC by Sash0k
Modified: 2015-04-12 03:10 UTC (History)
6 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
problem code part (1.92 KB, text/plain)
2011-11-17 00:09 UTC, Sash0k
Details
sample project (59.66 KB, application/x-bzip)
2012-03-13 06:11 UTC, Sash0k
Details

Description Sash0k 2011-11-17 00:09:33 UTC
Created attachment 900 [details]
problem code part

Hi, community.
I try to port project from .NET to mono, and have a problem:

SerialPort.DataReceived event doesn't handle SerialDataReceivedEventHandler procedure at all. I try mono 2.10.5 Linux, 2.10.6 Windows with same result. But on .NET 4.0 Windows my code works.
Comment 1 Miguel de Icaza [MSFT] 2012-03-12 23:06:07 UTC
Please provide a complete test case.
Comment 2 Sash0k 2012-03-13 06:11:40 UTC
Created attachment 1507 [details]
sample project

sample project, port from .net
uses on Windows to log all received commands from RS-232.
hope, it helps.
Comment 3 Hakan Lindestaf 2015-01-09 03:38:33 UTC
Verified to not work in 3.10 either. It seems that the events aren't even wired up if I read the code right.
Comment 4 kailash 2015-04-12 03:10:29 UTC
As told by sashok the serialport.datarecevied handler does not work in linux ..
"xamarin team " and update to make it work ..

using a thread would temperorality solve the issue but not a full proof ..

please give the updates or patches if anybody knows more on this ..

Note You need to log in before you can comment on or make changes to this bug.