Click here to Skip to main content
15,867,594 members
Home / Discussions / C#
   

C#

 
QuestionOne 8-Bit Byte Across The Serial Port Pin
C-P-User-324-Oct-12 12:58
C-P-User-324-Oct-12 12:58 
AnswerRe: One 8-Bit Byte Across The Serial Port Pin
Dave Kreskowiak24-Oct-12 13:35
mveDave Kreskowiak24-Oct-12 13:35 
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
C-P-User-325-Oct-12 11:51
C-P-User-325-Oct-12 11:51 
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
Dave Kreskowiak26-Oct-12 2:26
mveDave Kreskowiak26-Oct-12 2:26 
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
C-P-User-326-Oct-12 6:23
C-P-User-326-Oct-12 6:23 
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
Dave Kreskowiak26-Oct-12 8:47
mveDave Kreskowiak26-Oct-12 8:47 
AnswerRe: One 8-Bit Byte Across The Serial Port Pin
Gerry Schmitz24-Oct-12 15:19
mveGerry Schmitz24-Oct-12 15:19 
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
C-P-User-330-Oct-12 8:32
C-P-User-330-Oct-12 8:32 
Thank you Dave, and Gerry, again.

Now I feel really stupid.

Windows was lying to me.

The reason the byte wasn't going across the port was because somebody (not sure who) was lying to somebody (again, not sure).

This line returned the port in question...

C#
string[] The_List_Of_ComPorts = SerialPort.GetPortNames();


The result was a big lie. The given port wasn't there in the first place, despite the fact that Windows did report it, did return it to the function call, and the port name showed up in The_List_Of_ComPorts.

This one was beyond my ability to recognize immediately.

For future reference, and perhaps to help the next victim like me, the fix that worked this time with Win'7 was...

-- Close down C#
-- Windows, Start button
-- Control Panel
-- Device Manager
-- Ports (COM & LPT)
-- Delete any com port that isn't physically wired
-- -- (This probably means COM3, COM4, COM5,,, COM99, etc.)
-- Exit everything
-- Restart computer
-- Reconnect the USB-Induced serial ports
-- Let them do their driver stuff
-- Invoke your C# IDE again
-- Watch this line execute...

C#
The_Chosen_Serial_Port.Write(new byte[] { 0xFF }, 0, 1);



Then you will be happy for the rest of your life and there will be world peace and prosperity for all humans everwhere.

Dave, Gerry, again, I thank you. I am embarrassed and even more annoyed by such an oblique problem.
GeneralRe: One 8-Bit Byte Across The Serial Port Pin
Gerry Schmitz30-Oct-12 11:01
mveGerry Schmitz30-Oct-12 11:01 
QuestionC# exe app Pin
Michael Kurdík24-Oct-12 10:10
Michael Kurdík24-Oct-12 10:10 
AnswerRe: C# exe app Pin
Pete O'Hanlon24-Oct-12 10:49
subeditorPete O'Hanlon24-Oct-12 10:49 
AnswerRe: C# exe app Pin
Abhinav S24-Oct-12 19:58
Abhinav S24-Oct-12 19:58 
QuestionWinforms or WPF Pin
Orjan Westin24-Oct-12 0:09
professionalOrjan Westin24-Oct-12 0:09 
AnswerRe: Winforms or WPF Pin
BobJanova24-Oct-12 0:52
BobJanova24-Oct-12 0:52 
AnswerRe: Winforms or WPF Pin
Pete O'Hanlon24-Oct-12 1:11
subeditorPete O'Hanlon24-Oct-12 1:11 
GeneralRe: Winforms or WPF Pin
Orjan Westin25-Oct-12 3:25
professionalOrjan Westin25-Oct-12 3:25 
AnswerRe: Winforms or WPF Pin
Eddy Vluggen24-Oct-12 1:18
professionalEddy Vluggen24-Oct-12 1:18 
AnswerRe: Winforms or WPF Pin
V.24-Oct-12 2:42
professionalV.24-Oct-12 2:42 
AnswerRe: Winforms or WPF Pin
Keith Barrow24-Oct-12 6:49
professionalKeith Barrow24-Oct-12 6:49 
AnswerRe: Winforms or WPF Pin
Gerry Schmitz24-Oct-12 15:37
mveGerry Schmitz24-Oct-12 15:37 
AnswerRe: Winforms or WPF Pin
Bernhard Hiller26-Oct-12 0:34
Bernhard Hiller26-Oct-12 0:34 
Questioncreate a node with color in c# Pin
mahendiran bala23-Oct-12 23:43
mahendiran bala23-Oct-12 23:43 
AnswerRe: create a node with color in c# Pin
Pete O'Hanlon23-Oct-12 23:49
subeditorPete O'Hanlon23-Oct-12 23:49 
QuestionVSTO 2010 Word Addin, passing arguments problem Pin
Shah Ali Haider23-Oct-12 22:52
Shah Ali Haider23-Oct-12 22:52 
AnswerRe: VSTO 2010 Word Addin, passing arguments problem Pin
Richard Deeming24-Oct-12 2:15
mveRichard Deeming24-Oct-12 2:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.