Hello,
I have to read/write in the UART to transfer bytes through the serial
port. I use Visual C++ 6 and Win2000.
When I used Win98, the problem was easy : the functions _inp and _outp
(or the file port95nt.dll) allow to read/write on the UART. But these
functions (or this DLL) do not work...
If anyone knows how to have the rights to access the UART with Win2000
or the functions to use in VC++, please help me !
Thanks with advance
Vincent 3 1917
"Dabeule" <da*****@yahoo. fr> wrote in message
news:5c******** *************** ***@posting.goo gle.com... Hello,
I have to read/write in the UART to transfer bytes through the serial port. I use Visual C++ 6 and Win2000. When I used Win98, the problem was easy : the functions _inp and _outp (or the file port95nt.dll) allow to read/write on the UART. But these functions (or this DLL) do not work... If anyone knows how to have the rights to access the UART with Win2000 or the functions to use in VC++, please help me !
I *think* you can use CreateFile and the associated functions to do this,
but I'm not sure...
The folks over in microsoft.publi c.dotnet.langua ges.vc would be able to help
you better. Thanks with advance
Vincent
Dabeule wrote: Hello,
I have to read/write in the UART to transfer bytes through the serial port. I use Visual C++ 6 and Win2000. When I used Win98, the problem was easy : the functions _inp and _outp (or the file port95nt.dll) allow to read/write on the UART. But these functions (or this DLL) do not work... If anyone knows how to have the rights to access the UART with Win2000 or the functions to use in VC++, please help me !
Thanks with advance
Vincent
UARTs are a platform specific feature and thus are off-topic
in this newsgroup, news:comp.lang. c++. Please read the
welcome.txt and FAQ below for more information on which
newsgroups to post to.
That said, I just assign pointers to the various UART
registers and access them by dereferencing the pointers:
volatile char * const UART_STATUS_REG =
(volatile char * const) 0x43000;
// to get the status:
unsigned char status = *UART_STATUS_RE G;
But then, I am not working on a Windows platform.
--
Thomas Matthews
C++ newsgroup welcome message: http://www.slack.net/~shiva/welcome.txt
C++ Faq: http://www.parashift.com/c++-faq-lite
C Faq: http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.l earn.c-c++ faq: http://www.raos.demon.uk/acllc-c++/faq.html
Other sites: http://www.josuttis.com -- C++ STL Library book This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Arnold |
last post by:
I want to use python to communicate with UART port in my PC, how can I
achieve this? any modules need to be installed?
Thanks
|
by: Peter Nolan |
last post by:
Hi All,
I have some software that currently loads database tables into sorted arrays
in memory to be binary searched by processes. (Long story as to why it does
this..)
Each process must either read the data from the in memory array or from the
database itself if the table is too large to be loaded into memory. (2GB is
usually the limit because the array is indexed by a 32 bit signed integer.
I have never had one of these tables go over...
|
by: amorphous999 |
last post by:
I will be creating a small web site using php/apache/SQL Server running
on a Win2000 server. It sounds as if there a number of alternatives
for accessing SQL Server: mssql* functions, ADOdb object, using a ADO
COM object, ODBC calls, etc. Has anybody out there evaluated the
alternatives for speed, error handling, quality of documentation, etc?
TIA
|
by: Petr Jakes |
last post by:
Hi,
I am trying to set-up communication to the coin change-giver from my
Linux box using the Python code. The change giver uses MDB (Multi Drop
Bus) serial protocol to communicate with the master. MDB protocol is
the 9bit serial protocol:
(TX, RX lines only) 9600bps, 9bits, No Parity, 1 Start, 1 Stop.
I would like to control the UART "parity bit" to try to simulate 9bit
communication.
|
by: Grei |
last post by:
how can i impersonate from win2000 to WinXP?
in MSDN says: (gives example how to implemet it but not with win2000, and it
doesn't say what to do on win2000!!!)
any ideas?
workarounds?
Thanx!
// This sample demonstrates the use of the WindowsIdentity class to
impersonate a user.
| |
by: Strahimir Antoljak |
last post by:
I completed a VB.NET application and it runs fine on WinXP.
I wanted to run it on Win2000 and it is not working. Is it not supposed to
work on Win2000 too? (I installed .NET framework distributable on the
Win2000 machine).
Any suggestion much appreciated.
Thanks,
--
Strah @ Langan
|
by: sundarr |
last post by:
Hi all,
I am doing some work on UART. the code to recieve data on my UART from Hyperterminal is as follows:
Recieve(Count, Destination)
{
//Monitor the port to recieve data and continously poll the data.
//A data byte recieved will set the LSB in LCR to 1.
//Thus the CPU has safely read the data
do
|
by: wizche |
last post by:
Hi,
I'm currently trying to develop a IR Remote (TV consumer) listener in C under Linux.
First of all I tried with an old notebook with an integrated IR peripheral (FIR)under Debian (kernel 2.6). All seems to work fine, I can also access directly with
#cat /dev/ttyS1
And my listener (written in C) work pretty fine.
Problems came up with a newer notebook with Ubuntu 8.10.
I set FIR in Bios like the older notebook. But trying to access...
|
by: wizche |
last post by:
Hi,
I'm currently trying to develop a IR Remote (TV consumer) listener in C under Linux.
First of all I tried with an old notebook with an integrated IR peripheral (FIR)under Debian (kernel 2.6). All seems to work fine, I can also access directly with
#cat /dev/ttyS1
And my listener (written in C) work pretty fine.
Problems came up with a newer notebook with Ubuntu 8.10.
I set FIR in Bios like the older notebook. But trying to access...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |