Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index International Gentoo Users Forum italiano (Italian)
  • Search

I/O su seriale?

Questa è la sezione italiana del forum gentoo destinata a fornire supporto all'omonima distribuzione.

Moderator: ago

Post Reply
  • Print view
Advanced search
12 posts • Page 1 of 1
Author
Message
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

I/O su seriale?

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 5:30 pm

Come faccio a trasmettere dati sulla porta seriale RS232?

Ho attaccato un cavo null modem a 3 fili (testato) alla COM1 e alla COM2 del mio pc.

# stty -F /dev/ttyS0
speed 57600 baud; line = 0;
-brkint -imaxbel

# stty -F /dev/ttyS1
speed 57600 baud; line = 0;
-brkint -imaxbel

poi apro un secondo terminale e digito

# cat /dev/ttyS1


dal primo terminale, lancio

# cat > /dev/ttyS0
hello world
linea 2


questo è quel che vedo sul secondo terminale:

# cat /dev/ttyS1
h
l



come risolvo? l'obbiettivo finale è di riuscire a

1)mandare direttamente dei pacchetti .tar da un PC all'altro
2)stabilire una connessione TCP-IP

mi serve per uno scassatissimo portatile Pentium 100 che non dispone di altri dispositivi di I/O.

Grazie in anticipo
Last edited by CRV§ADER//KY on Thu Oct 07, 2004 9:05 pm, edited 1 time in total.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
xxchris
n00b
n00b
Posts: 23
Joined: Thu Oct 07, 2004 6:35 am

  • Quote

Post by xxchris » Thu Oct 07, 2004 7:49 pm

ti consiglio di dare un occhio a questo vecchio thread:
http://forums.gentoo.org/viewtopic.php? ... torder=asc&
ciao
while true...Gentoo
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 8:35 pm

xxchris wrote:ti consiglio di dare un occhio a questo vecchio thread:
http://forums.gentoo.org/viewtopic.php? ... torder=asc&
ciao
L'ho letto con molto interesse.... ma ne so quanto prima :(
Il problema è che a me NON funziona il test più semplice di tutti, ossia "echo hello > /dev/ttyS0"

# stty -F /dev/ttyS0 -a
speed 57600 baud; rows 0; columns 0; line = 0;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>;
eol2 = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W;
lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 hupcl -cstopb cread clocal -crtscts
-ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff
-iuclc -ixany -imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt
echoctl echoke
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
xxchris
n00b
n00b
Posts: 23
Joined: Thu Oct 07, 2004 6:35 am

  • Quote

Post by xxchris » Thu Oct 07, 2004 8:39 pm

inizia ad abbassare la velocita... (ad es 9600)
ciao
while true...Gentoo
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 8:42 pm

xxchris wrote:inizia ad abbassare la velocita... (ad es 9600)
ciao
Ci ho già provato. E cmq il cavo che sto usando è ampiamente testato a 57600.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
xxchris
n00b
n00b
Posts: 23
Joined: Thu Oct 07, 2004 6:35 am

  • Quote

Post by xxchris » Thu Oct 07, 2004 9:00 pm

domanda semplice...
forse hai digitato male nel primo post...

TERMINALE1

echo "CIAO" > /dev/ttyS0

TERMINALE2

cat /dev/ttyS1

o non ho capito io... :)
while true...Gentoo
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 9:04 pm

xxchris wrote:domanda semplice...
forse hai digitato male nel primo post...

TERMINALE1

echo "CIAO" > /dev/ttyS0

TERMINALE2

cat /dev/ttyS1

o non ho capito io... :)
no, è giusto. sto provando con la COM1 e la COM2 dello stesso PC, con un cavo esterno che le collega.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 9:07 pm

quel che è peggio è che non arriva sempre e soltanto la prima lettera: talvolta arriva la prima lettera; talvolta la prima lettera ripetuta 2-200 volte, talvolta nono arriva un bel niente.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
xxchris
n00b
n00b
Posts: 23
Joined: Thu Oct 07, 2004 6:35 am

  • Quote

Post by xxchris » Thu Oct 07, 2004 10:28 pm

mmm
ho riprovato poco fa e a me funzionava tutto.
Ho controllato con stty ed erano settate a 9600.

non hai un altro pc in giro con cui provare?
(si lo so...richiesta assurda :S)
while true...Gentoo
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Oct 07, 2004 10:35 pm

xxchris wrote:mmm
ho riprovato poco fa e a me funzionava tutto.
mi posti l'output di

stty -F /dev/ttyS0 -a

per favore? thx
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
xxchris
n00b
n00b
Posts: 23
Joined: Thu Oct 07, 2004 6:35 am

  • Quote

Post by xxchris » Thu Oct 07, 2004 10:47 pm

eccolo

Code: Select all

lyra root # stty -F /dev/ttyS0 -a
speed 9600 baud; rows 0; columns 0; line = 0;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; start = ^Q;
stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 hupcl -cstopb cread clocal -crtscts
-ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc -ixany
-imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt echoctl echoke

ciao
while true...Gentoo
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Mon Oct 11, 2004 4:33 pm

xxchris wrote:eccolo
ciao
aaargh! ma è identico al mio!

*va a sbattere la testa contro il muro non sapendo più che pesci pigliare*
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
Post Reply
  • Print view

12 posts • Page 1 of 1

Return to “Forum italiano (Italian)”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic