Hello
How should I set the correct transmission parameters for the serial port?
Exactly interested in serial transmission on the bus 485. In my program I want to send 14 characters at 1200 bps. UP is used PIC18F46K22 with quartz 3,2768MHz, the program is set to interrupt TMR0 - 100Hz I know (diagram explains the connections) that I have to wait ok.20ms at the end of sending data to odbirnika and exact change in broadcasting - receiving for the MAX485. So it follows that my UP can query about every 25ms. And here I was killed. I query my UP every 250ms, and get an answer. The problem is that after a time disappears transmission that is the question page views a questioner UP stops to respond.
jak prawidłowo ustalić paramatry transmisji RS
Witam
Jak powinno się ustawić prawidłowo parametry transmisji dla portu szeregowego?
Dokładnie interesuje mnie transmisja szeregowa na magistrali 485. W moim programie chcę wysyłać 14 znaków z prędkością 1200 bps. Używanym UP jest PIC18F46K22 z kwarcem 3,2768MHz, w programie jest ustawione przerwanie TMR0 - 100Hz Już wiem (schemat wyjaśnia sposób połaczenia) że muszę odczekać ok.20ms na zakończenie wysyłania danych do odbirnika, a dokładnie ze zmianą stanu nadawanie - odbieranie dla MAX485. Czyli wynika z tego że moj UP mogę odpytywać co około 25ms. I tu poległam. Odpytuję mój UP co 250ms, i dostaję odpowiedź. Problem w tym że po czasie zanika transmisja to znaczy zapytania z strony pytającego wychodzą a UP przestaje na nie odpowiadać.
how to properly set the transmission parameters RS
Moderator: Benj
-
- Posts: 39
- Joined: Tue Feb 12, 2013 9:07 am
- Has thanked: 4 times
- Been thanked: 5 times
- Contact:
how to properly set the transmission parameters RS
- Attachments
-
- glowny_up_18f46k22v14.fcf
- (575.76 KiB) Downloaded 364 times
-
- Schowek01.jpg (51.15 KiB) Viewed 8044 times
-
- Protel Schematic.pdf
- (49.13 KiB) Downloaded 350 times
-
- Posts: 39
- Joined: Tue Feb 12, 2013 9:07 am
- Has thanked: 4 times
- Been thanked: 5 times
- Contact:
Re: how to properly set the transmission parameters RS
Hello
I gave partly cope with this problem. (drawing)
In spite of this, please, and I'll be grateful for a broader representation of the method of calculation and correct setting of the RS232 port.
Witam
Częściowo dałam sobie rady z tym problemem. (rysunek)
Pomimo tego proszę i będę wdzięczna, za szersze przedstawienie sposobu obliczeń i poprawności ustawienia portu RS232.
I gave partly cope with this problem. (drawing)
In spite of this, please, and I'll be grateful for a broader representation of the method of calculation and correct setting of the RS232 port.
Witam
Częściowo dałam sobie rady z tym problemem. (rysunek)
Pomimo tego proszę i będę wdzięczna, za szersze przedstawienie sposobu obliczeń i poprawności ustawienia portu RS232.
- Attachments
-
- Schowek02.jpg
- (146.97 KiB) Downloaded 1584 times