Can you help me to communicate between a 8051 based micro controller and a PC via RS232 ?
I built this µC system some years ago; the PC interface is written in Qbasic.
Everything was all right untill I switched to Win XP.
I'm looking for either a Qbasic version supported by XP or an RS232 diver useable for instance in visual basic.
Thanks a lot in advance

Welcome to the world of Microsift incompatility. They almost NEVER make new systems hardwarily compatible with old ones, requiring new driver interfaces in programs which directly adress hardware.

Often recompiling the source code on the new machine fixes the problem.

One other little fly in the monitor cleaning fluid: Often under XP, the first serial port defaults to the USB. it might be just a case of your port now having a different port number. You may also have to install your microcontroller as a new hardware device, a new modem, or something similar. Or you can buy a USB to PC serial adaptor.

This is not very helpfull :cheesy:

Member Avatar for Kevin_160

Hi Herve,

Since it worked until you switched to XP, it is probably related to the functions you're using. Until windows 98, the dos.h included funtions like outportb() to send commands directly to the adresses you wanted (0x3F8 for com1). Since XP you have to treat the RS232 like a file with a HANDLE. I've found a nice article on this subject: www.robbayer.com/files/serial-win.pdf
I hope this can help you.

Cheers,

Kev

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.