RS232

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

RS232

Post by brunoflow »

Hello
I would like to help in an RS232 communication
I use Windows 7. hyperterminal use a separate program.

I can not send and receive the same information.

thank you

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

2. Simple Echo 16F877A-picgenios.fcf
(6.5 KiB) Downloaded 329 times

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: RS232

Post by medelec35 »

Hi brunoflow,

If you right click on your RS232 on your control panel and select Ext properties.
Try changing from Bytes to Characters in the Simulation part.

Martin
Martin

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

Hello
The problem is the time to emulate the hardware when I send a post by my hyperterminal value it returns another ex: 890 and sent me back 80 or 980.

It's all right configurate the time the crystal?

and I doubt this is because this type of error?

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: RS232

Post by medelec35 »

Ah I see.
What I suggested is correct for simulation, But for the hardware side, go back to Ext properties. and change Char receive type from Int to byte.
Then you should receive correct characters

Probably what I would do is when type a message, I would fill LCD from left to right, then when get to the far right of LCD, start scrolling text .

Martin
Martin

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

Hello Martin
I changed how he had explained to me and left the way it was, just that when I use my USART terminal continues giving error

I send and receive 80 to 809
command again when I get 809 980 and is thus like to know what's happening and the error in my program that is configured crsital this right?

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

medelec35 wrote:Ah I see.
What I suggested is correct for simulation, But for the hardware side, go back to Ext properties. and change Char receive type from Int to byte.
Then you should receive correct characters

Probably what I would do is when type a message, I would fill LCD from left to right, then when get to the far right of LCD, start scrolling text .

Martin

Hello Martin
has some hyperterminal for windows 7?

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

Hello Martin

Maybe you can help me, I'm doing a cominicação via RS232 only when I record on my hardware it does wrong transmission wonder what would be the problem?
Attachments
11.png
(91.14 KiB) Downloaded 3095 times

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: RS232

Post by medelec35 »

brunoflow wrote: has some hyperterminal for windows 7?
Hi brunoflow,
Two such programs was mentioned here:
http://www.matrixmultimedia.com/mmforum ... 563#p30563

I tried your flowchart with hyperterminal. After changing it as I suggested, when I pressed letter K on pc, then LCD also showed K.

What about just sending ASCII and have support for ASCII selected?

Martin
brunoflow wrote:Hello Martin

Maybe you can help me, I'm doing a cominicação via RS232 only when I record on my hardware it does wrong transmission wonder what would be the problem?
What software are you using for comms?
Martin

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

thank you

using SerialPort not work what is the problem?

It set up the crystal, where I am making a mistake.
Attachments
12.png
(28.87 KiB) Downloaded 3092 times

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

Hello

When sending the number 90 does not return anything if I keep pressing several times in this way is like a help to know if the Flowcode works with serial communication or it only works in the simulation?

brunoflow
Posts: 24
Joined: Mon Dec 19, 2011 4:24 pm
Been thanked: 1 time

Re: RS232

Post by brunoflow »

Hello,

I managed to solve my problem. I am sending the code if someone has solved the same doubts I had.
Attachments
2. Simple Echo 16F877A.fcf
(6.5 KiB) Downloaded 296 times

Post Reply