Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Rs-232
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Polish OTW
View previous topic :: View next topic  
Author Message
szybi
Tux's lil' helper
Tux's lil' helper


Joined: 12 Jan 2007
Posts: 75

PostPosted: Mon Aug 18, 2008 3:06 pm    Post subject: Rs-232 Reply with quote

Port nawet działa, ale się zastanawiam, czy dobrze. Jest inaczej niż się spodziewałem, a jest tak:

Wetknąłem kabel i połączyłem ze sobą pin 2 i 3 zdaje się. W każdym razie TxD i RxD. Nadaję dane tak:
Code:

echo asdfba > /dev/ttyS0

a odbieram tak:
Code:

cat /dev/ttyS0

Wygląda, jak by się coś zapętliło. Na wyjścu pojawia się podany tekst, po nim wolna linia, znów tekst, kilka wolnych lini, znów tekst, coraz więcej wolnych lini i znów tekst. I tak dalej. Na prawdę nic ciekawego :)

Odkryłem też, że jak się zrobi
Code:

echo -n asdfba > /dev/ttyS0

to się tekst nie pokazuje. Ale się buforuje, bo po którymś razie jak się da ze znakiem nowej linii, to poleci wszystko, co było dotychczas.
No to tyle zwierzeń. Czy to normalne?

Pozdrawiam.
Back to top
View user's profile Send private message
Arfrever
Bodhisattva
Bodhisattva


Joined: 29 Apr 2006
Posts: 2462
Location: Polska / Lenkija

PostPosted: Mon Aug 18, 2008 5:00 pm    Post subject: Reply with quote

Moved from Polish to Polish OTW.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Polish OTW All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum