[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Réf. : RE: Send data on serial port!



I do not know how do you check it, but if you want to see on terminal output
(printf, etc) you may need to include the following:

setvbuf(stdout, NULL, _IONBF, 0);

since the terminal in line buffered mode by default.

Sza2.

Problems with Windows - Reboot.
Problems with Linux       - Be root.


> -----Original Message-----
> From:	dchambrelan@xxxxxxx.com]
> Sent:	2003. január 9. 15:43
> To:	Goran Hillebrink; dev-etrax@xxxxxxx.com
> Subject:	Réf. : RE: Send data on serial port!
> 
> 
> I have do the same with no problems on a devboard LX
> some ideas:
> 
>  - you can see the hwtestserial.c source file given with the DEV KIT
> 
>  - you must open the device with open (not fopen)
> 
> -  If you send the character to a printer ,you need probably to send \n to
> see it
> 
> - do you use a line analyser to control the character ??
> 
> 
> / didier
> 
> 
> 
>  
> 
>                     "Goran Hillebrink"
> 
>                     <Goran.Hillebrink@tra        Pour :  "Johan Adolfsson"
> <johan.adolfsson@xxxxxxx.com>, "dev-etrax"           
>                     nsmode.se>                   <dev-etrax@xxxxxxx.com>
> 
>                     Envoyé par :                 cc :
> 
>                     owner-dev-etrax@xxxxxxx.        Objet :      RE: Send
> data on serial port!                                  
>                     com
> 
>  
> 
>  
> 
>                     09/01/03 15:26
> 
>  
> 
>  
> 
> 
> 
> 
> I've done that but I still need to send '\n' to have the character sent
> from the send buffer. Any other idea?
> 
> -----Original Message-----
> From: Johan Adolfsson [mailto:johan.adolfsson@xxxxxxx.com]
> Sent: 09 January 2003 14:05
> To: G?an Hillebrink; dev-etrax
> Subject: Re: Send data on serial port!
> 
> 
> Make sure you set the terminal settings to "raw" on both the
> sender and the receiver, e.g. by using the cfmakeraw() function.
> See 'man cfmakeraw'
> 
> /Johan
> 
> 
> ----- Original Message -----
> From: "Goran Hillebrink" <Goran.Hillebrink@xxxxxxx.se>
> To: "dev-etrax" <dev-etrax@xxxxxxx.com>
> Sent: Thursday, January 09, 2003 12:34
> Subject: Send data on serial port!
> 
> 
> > Hi,
> >
> > I need to send data character by character over a serial
> port(/dev/ttyS0)
> on a LX board. To achieve as high speed
> as possible I want to send as little overhead as possible. When I send
> data
> now I always need to add a line feed to
> have the data sent immediately. Is it possible to send just a byte without
> a line feed?
> >
> > /Goran
> >
> 
> 
> 
> 
> 
> 


**********************************************************************************************
The information contained in this message or any of its attachments may be confidential and is intended for the exclusive use of the addressee(s). Any disclosure, reproduction, distribution or other dissemination or use of this communication is strictly prohibited without the express permission of the sender. The views expressed in this email are those of the individual and not necessarily those of Sony or Sony affiliated companies. Sony email is for business use only. 

This email and any response may be monitored by Sony United Kingdom Limited.
(05)
**********************************************************************************************