Pic16f877->RS232->VB6

Started by onmyownja January 11, 2005


WANT TO KNOW IF YOU AR USING RS232 FOR INPUTING AND OUPUTING DATA
VIA THE MSCOMM PORTS USING VISUAL BASIC , THE INPUT FROM THE SESOR
THROUGH THE MICROCONTROLLER TO THE RS232 WHAT FORM DOES VISUAL
INTERPRET AS?

MEANING DOES VB SEE ZEROS AND ONES OR CHARACTERS / ASCII.

I DONT HAV ETHE EQUIPMENT YET BUT I AM PLANNING AROUNG THESE
COMPONENT, AS I WOULD LIKE TO BE ABLE TO MANIPLIATE THE DATA COMMING
FROM THE MICROCRONTROLLER SO THAT IT STATES WITHIN A RANGE OR LETS
OUT AND ALARM IF IT GOES OUT OF RANGE AMONG OTHER THINGS.

ANYONE WHO CAN ASIST ME TO ANSWER MY QUESTION PLEASE REPLY.




The MSComm control in VB will see the data as ASCII characters, just
like if you were using HyperTerminal.

Mike --- In , "onmyownja" <onmyownja@y...> wrote:
>
>
> WANT TO KNOW IF YOU AR USING RS232 FOR INPUTING AND OUPUTING DATA
> VIA THE MSCOMM PORTS USING VISUAL BASIC , THE INPUT FROM THE SESOR
> THROUGH THE MICROCONTROLLER TO THE RS232 WHAT FORM DOES VISUAL
> INTERPRET AS?
>
> MEANING DOES VB SEE ZEROS AND ONES OR CHARACTERS / ASCII.
>
> I DONT HAV ETHE EQUIPMENT YET BUT I AM PLANNING AROUNG THESE
> COMPONENT, AS I WOULD LIKE TO BE ABLE TO MANIPLIATE THE DATA
COMMING
> FROM THE MICROCRONTROLLER SO THAT IT STATES WITHIN A RANGE OR LETS
> OUT AND ALARM IF IT GOES OUT OF RANGE AMONG OTHER THINGS.
>
> ANYONE WHO CAN ASIST ME TO ANSWER MY QUESTION PLEASE REPLY.




MSComm control allows either text (ANSI) or binary. Here's a snip
from the help file for the MSComm control 'InputMode' property.

****************************
The InputMode property determines how data will be retrieved through
the Input property. The data will either be retrieved as string or as
binary data in a byte array.

Use comInputModeText for data that uses the ANSI character set. Use
comInputModeBinary for all other data such as data that has embedded
control characters, Nulls, etc.
****************************

Eric
--- In , "onmyownja" <onmyownja@y...> wrote:
>
>
> WANT TO KNOW IF YOU AR USING RS232 FOR INPUTING AND OUPUTING DATA
> VIA THE MSCOMM PORTS USING VISUAL BASIC , THE INPUT FROM THE SESOR
> THROUGH THE MICROCONTROLLER TO THE RS232 WHAT FORM DOES VISUAL
> INTERPRET AS?
>
> MEANING DOES VB SEE ZEROS AND ONES OR CHARACTERS / ASCII.
>
> I DONT HAV ETHE EQUIPMENT YET BUT I AM PLANNING AROUNG THESE
> COMPONENT, AS I WOULD LIKE TO BE ABLE TO MANIPLIATE THE DATA
COMMING
> FROM THE MICROCRONTROLLER SO THAT IT STATES WITHIN A RANGE OR LETS
> OUT AND ALARM IF IT GOES OUT OF RANGE AMONG OTHER THINGS.
>
> ANYONE WHO CAN ASIST ME TO ANSWER MY QUESTION PLEASE REPLY.