Click here to Skip to main content
16,004,974 members
Home / Discussions / C#
   

C#

 
GeneralRe: Decrypt but not Encrypt Pin
dino20946-Jul-07 9:04
dino20946-Jul-07 9:04 
GeneralRe: Decrypt but not Encrypt Pin
mav.northwind6-Jul-07 9:06
mav.northwind6-Jul-07 9:06 
QuestionBinding with an intermediate table Pin
Richard Blythe5-Jul-07 10:27
Richard Blythe5-Jul-07 10:27 
QuestionTele-operated robotic arm need help in programming Pin
koool_faysie5-Jul-07 9:14
koool_faysie5-Jul-07 9:14 
AnswerRe: Tele-operated robotic arm need help in programming Pin
Christian Graus5-Jul-07 9:24
protectorChristian Graus5-Jul-07 9:24 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie5-Jul-07 9:35
koool_faysie5-Jul-07 9:35 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Christian Graus5-Jul-07 10:24
protectorChristian Graus5-Jul-07 10:24 
AnswerRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn5-Jul-07 10:03
sitebuilderLuc Pattyn5-Jul-07 10:03 
Hi,

I once looked into AVR, but ended up using a small Microchip PIC instead
(with assembly code).
And did serial comm with that, long before .NET emerged.
I will revamp that project pretty soon, this time with .NET !

if you can control the target by sending commands over a serial line,
if you know the command language (syntax and semantics),
if the number of bytes per second is reasonable (less than say 500),
if your PC has a serial port that is compatible with your target's,
if your cable is set up correctly (null modem needed?),
then you could simply write the PC-side of the app using C# and
use the SerialPort class for communication.

The SerialPort class offers port initialization, plus elementary read and
write operations (both in binary in case you need bytes, or in text characters
if your commands are "printable"). If text, be careful about text encoding,
C# uses Unicode characters (which are 16-bit), your target probably uses
8-bit ANSI (or 7-bit ASCII), so you may need an explicit Encoding.ASCII

If your command language is built from printable text, I would advice you test
your hardware set-up first, using a terminal emulator such as HyperTerminal.

If not, you need to start programming right away and would be best to try a
simple and harmless output command first, something that would make your
AVR show some reaction without being time critical or dangerous.

Then you could try to receive something; hopefully your target sends
something when it starts up, so you would catch that and show it on a Form or
Console. Your first receive attempt might use a synchronous read; final code
would require you switch to asynchronous operation, i.e. you install
a handler that gets triggered by a DataReceived event (soemwhat similar to an
Interrupt Service Routine); be careful, the event runs on a separate thread, one
that cannot reliably operate on GUI Controls, you would need Control.Invoke()
for that.

Have fun !

Smile | :)


GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie5-Jul-07 10:41
koool_faysie5-Jul-07 10:41 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn5-Jul-07 10:57
sitebuilderLuc Pattyn5-Jul-07 10:57 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie5-Jul-07 11:06
koool_faysie5-Jul-07 11:06 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn5-Jul-07 11:29
sitebuilderLuc Pattyn5-Jul-07 11:29 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie7-Jul-07 5:53
koool_faysie7-Jul-07 5:53 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn7-Jul-07 6:05
sitebuilderLuc Pattyn7-Jul-07 6:05 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie7-Jul-07 6:09
koool_faysie7-Jul-07 6:09 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn7-Jul-07 6:21
sitebuilderLuc Pattyn7-Jul-07 6:21 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie7-Jul-07 6:34
koool_faysie7-Jul-07 6:34 
GeneralRe: Tele-operated robotic arm need help in programming Pin
Luc Pattyn7-Jul-07 6:57
sitebuilderLuc Pattyn7-Jul-07 6:57 
GeneralRe: Tele-operated robotic arm need help in programming Pin
koool_faysie7-Jul-07 7:12
koool_faysie7-Jul-07 7:12 
QuestionSetting things like TCP/IP Address and Gateway through code. Pin
jbradshaw5-Jul-07 8:13
jbradshaw5-Jul-07 8:13 
AnswerRe: Setting things like TCP/IP Address and Gateway through code. Pin
Bert delaVega5-Jul-07 10:40
Bert delaVega5-Jul-07 10:40 
GeneralRe: Setting things like TCP/IP Address and Gateway through code. Pin
jbradshaw6-Jul-07 4:30
jbradshaw6-Jul-07 4:30 
QuestionTitle of FolderBrowserDialog [modified] Pin
topksharma19825-Jul-07 7:49
topksharma19825-Jul-07 7:49 
AnswerRe: Title of FolderBrowserDialog Pin
led mike5-Jul-07 8:08
led mike5-Jul-07 8:08 
AnswerRe: Title of FolderBrowserDialog Pin
Luc Pattyn5-Jul-07 8:44
sitebuilderLuc Pattyn5-Jul-07 8:44 

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.