U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » U++ Library : Other (not classified elsewhere) » About RS232
About RS232 [message #3788] Mon, 26 June 2006 18:21 Go to next message
alvintseng is currently offline  alvintseng
Messages: 1
Registered: June 2006
Junior Member
May I use U++ to write the rs232 client program?
Re: About RS232 [message #3789 is a reply to message #3788] Mon, 26 June 2006 20:05 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 14290
Registered: November 2005
Ultimate Member
alvintseng wrote on Mon, 26 June 2006 12:21

May I use U++ to write the rs232 client program?


While there is no specific support, it is still regular C++, so everything you can do in C/Win32 API (or C/Posix/Linux API), you can do in U++ too...

Mirek
Re: About RS232 [message #3966 is a reply to message #3788] Tue, 11 July 2006 19:44 Go to previous messageGo to next message
qwerty is currently offline  qwerty
Messages: 130
Registered: May 2006
Experienced Member
try libwxctb v0.8. it's great. I am using it in upp extensively.
here: http://www.iftools.com/ctb.en.html
I can send you a package, but it's really simple.

[Updated on: Tue, 11 July 2006 19:45]

Report message to a moderator

Re: About RS232 [message #5228 is a reply to message #3966] Mon, 11 September 2006 01:25 Go to previous messageGo to next message
qwerty is currently offline  qwerty
Messages: 130
Registered: May 2006
Experienced Member
I've glued up together a working version(linux, win32) of 'plugin' of wxctb. if anyone interesed...
icon9.gif  Re: About RS232 [message #9267 is a reply to message #3788] Tue, 24 April 2007 19:34 Go to previous messageGo to next message
supertorresmo is currently offline  supertorresmo
Messages: 4
Registered: April 2007
Location: Brazil
Junior Member
I'm trying to implement an RS232 GUI program, but I had no success yet.

Does anyone have an working example?
Re: About RS232 [message #9287 is a reply to message #9267] Wed, 25 April 2007 20:39 Go to previous messageGo to next message
ebojd is currently offline  ebojd
Messages: 225
Registered: January 2007
Location: USA
Experienced Member
A cople of projects you might look at are Minicom <http://alioth.debian.org/projects/minicom> and Kermit <http://www.columbia.edu/kermit/>. You might run into licensing issues if you use their code, but it will give you something to compare against...

EBo --
Re: About RS232 [message #9309 is a reply to message #3788] Thu, 26 April 2007 13:40 Go to previous messageGo to next message
supertorresmo is currently offline  supertorresmo
Messages: 4
Registered: April 2007
Location: Brazil
Junior Member
I've finally got it working.

Here is what I did for anyone who might be interested:


MyClass::MyClass()
{
	CtrlLayout(*this, "Window title");
	Zoomable().Sizeable();
	connect <<= THISBACK(OnConnect);
	disconnect <<= THISBACK(OnDisconnect);
	send <<= THISBACK(OnSend);
	conectado = 0;
	SetTimeCallback(-1, callback(this, &MyClass::Timer));
}


GUI_APP_MAIN
{
	MyClass().Run();
}


void MyClass::OnConnect(){
	
	dev = new wxSerialPort();

	if(dev->Open(wxCOM1) < 0) {
		  PromptOK("Cannot open COM Port");
		  delete dev;
		  return;
	   }
	   // set the baudrate
	   conectado = 1;
	   ((wxSerialPort*)dev)->SetBaudRate(wxBAUD_57600);	
}

void MyClass::OnDisconnect(){
	
	conectado = 0;
	dev->Close();
        delete dev;
}

void MyClass::OnSend(){

	dev->Writev("Hellow",6,0);
}

void MyClass::Timer() {
	char ch;    
        int n = 0;
	
	if (conectado) {
    	n = dev->Read(&ch,1);
    	if (n>0)
    	editbox1.Insert(ch);
	}
	
}



This is a simple program that puts any incoming characters in a edit box and sens a "Hellow" string when the send button is pressed...
Re: About RS232 [message #13411 is a reply to message #9309] Fri, 04 January 2008 17:37 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Is this still the present state of serial port communication under UPP?

Are there any examples?

I have to say that I would rather do imperfect serial port programming and stay within the confines of UPP than start incorporating 3rd party code.

I am trying to read NMEA sentences from a (bluetooth)GPS connected to (virtual) serial port (3). I don't care about data loss as the GPS streams sentences continually. So long as I catch at least one whole sentence each time I look at the GPS port, I'm good. With this in mind, can anyone tell me why the following does not work?

MyClass::MyClass()
{
	CtrlLayout(*this, "Window title");
	Zoomable().Sizeable();

	SetTimeCallback(1000, callback(this, &MyClass::Timer));
	
}

void MyClass::Timer() 
{
	char cBuf[300];
	
	void* ptr = (void*)0x2f8;
	
	memcpy(cBuf,ptr,200);

	m_s.SetText(cBuf);
}

GUI_APP_MAIN
{
	MyClass().Run();
}


It throws an exception whenever I try to directly access the address 0x2f8

Any ideas or insults welcome Smile

EDIT: ah ok so I've found that direct access of these addresses is outlawed under newer versions of windows - great!

I am finding freely available serial port classes but they are either pre 1995 or written to run under MSVC and use handles etc. If I find one that can be converted I will post it here.

If anyone knows how to get around the windows access exception, I would be very happy to hear it.



Nick

[Updated on: Fri, 04 January 2008 18:24]

Report message to a moderator

Re: About RS232 [message #13414 is a reply to message #13411] Fri, 04 January 2008 23:48 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Nick, your code will of course throw an exception.
Mistakes you`ve made:
1) You try to read 0x2f8 address instead of port 2f8, which is usually connected with one of RS232 ports.
2) You try to read from port in Windows, where direct working with hardware ports is prohibited (if you`re not kernel-mode device driver).
3) Virtual COM-ports like bluetooth ones are not physical RS-232 ports. So there is no way to read them with any physical port, like 2f8.

Instead, you should do following:
1) Open port with CreateFile
2) Do reading/writing with ReadFile/WriteFile
3) Close the port with CloseHandle.

Things you must consider:
1) Your application must be multithreaded. One thread works with COM-port, while other thread respond to users`s GUI input.
2) You should make some kind of options or config, where to change COM-port number and it`s settings (speed, timeouts, etc) without recompiling the program

I strongly recommend you reading these topics:
(basic)
MSDN: CreateFile, ReadFile, WriteFile (COM-ports)
MSDN: Threads
U++: Config
(intermediate)
MSDN: Threads synchronization
(advanced)
MSDN: Overlapped i/o

Recently I`ve written U++ class, which makes all the hard work with COM-port. You should only write appropriate callbacks. For now, it works only for Windows, since I`m just starting learning Linux. If it`s needed in current state of development - I`ll upload it here.
Re: About RS232 [message #13434 is a reply to message #13414] Sun, 06 January 2008 03:26 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Thanks! I'll checkout your suggestions.

I actually managed to find a freely available serial port class that works under windows but I suspect it wont work under linux.

I would be very interested in a U++ class that works under both linux and windows but I am happy to wait until you have it finished - that would be fantastic.

I managed to write a small app that reads location from a bluetooth GPS and if anyone wants it I'll happily post it here. However, I think what you propose sounds way better. I hope that it gets incorporated into the next release of U++.

Thanks for replying,

Nick
Re: About RS232 [message #18595 is a reply to message #13414] Fri, 10 October 2008 21:33 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Mindtraveller wrote on Fri, 04 January 2008 23:48


Recently I`ve written U++ class, which makes all the hard work with COM-port. You should only write appropriate callbacks. For now, it works only for Windows, since I`m just starting learning Linux. If it`s needed in current state of development - I`ll upload it here.


Hello,

please let me ask you if your class is already included in the current 2008.1 or it is still under development.
Even in this state, if available, it could be very useful. I have got a temperature sensor connected to COM 1 and I would like to read it within U++.

Bolshoie spasiba!
Luigi
Re: About RS232 [message #18597 is a reply to message #18595] Fri, 10 October 2008 22:49 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

For now class is working good and only for Windows. It already was refactoried and tested in released application. The main drawback is lack of *nix support - this was the cause of not-publishing it into U++ (also I didn`t discuss it`s adding at all). If you need Windows-only version I`ll prepare it and post in this thread tomorrow.

[Updated on: Fri, 10 October 2008 22:51]

Report message to a moderator

Re: About RS232 [message #18605 is a reply to message #18597] Sat, 11 October 2008 11:17 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Mindtraveller wrote on Fri, 10 October 2008 22:49

If you need Windows-only version I`ll prepare it and post in this thread tomorrow.


Windows is quite enough at the moment.
Thanks,
Luigi
Re: About RS232 [message #18610 is a reply to message #18605] Sat, 11 October 2008 22:36 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Here are these files: ConveyorThread.h & RS232Thread.h
You should use RS232Thread class.

Kran.h & main.cpp are files from sample project which uses RS232Thread class.

Currently I`m writing manual for RS232Thread. It will be ready within some days. Hope it will answer your questions.
  • Attachment: ConveyorThread.h
    (Size: 3.10KB, Downloaded 1022 times)
  • Attachment: RS232Thread.h
    (Size: 6.72KB, Downloaded 1561 times)
  • Attachment: main.cpp
    (Size: 7.87KB, Downloaded 1162 times)
  • Attachment: Kran.h
    (Size: 1.16KB, Downloaded 1065 times)
Re: About RS232 [message #18611 is a reply to message #18610] Sat, 11 October 2008 23:07 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Mindtraveller wrote on Sat, 11 October 2008 22:36

Here are these files: ConveyorThread.h & RS232Thread.h
You should use RS232Thread class.

Kran.h & main.cpp are files from sample project which uses RS232Thread class.

Currently I`m writing manual for RS232Thread. It will be ready within some days. Hope it will answer your questions.


Hi Pavel,

Is it possible to have even the Kran.lay file in order to have a working example? The file with extension .iml I suppose is not important.

Thanks a lot,
Luigi
Re: About RS232 [message #18616 is a reply to message #18611] Sun, 12 October 2008 09:40 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Here is an archive with my project. Hope this helps.
  • Attachment: 4.ZIP
    (Size: 34.43KB, Downloaded 1174 times)
Re: About RS232 [message #18628 is a reply to message #18616] Sun, 12 October 2008 22:35 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Half of manual is written. If you wait for a couple of days, you won`t have to dig into my code with comments in Russian. Smile
Re: About RS232 [message #18630 is a reply to message #18628] Sun, 12 October 2008 23:03 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Mindtraveller wrote on Sun, 12 October 2008 22:35

Half of manual is written. If you wait for a couple of days, you won`t have to dig into my code with comments in Russian. Smile


Soglassian!

I'll wait as many days you need Smile
Your package compiles and run, but I have not understood how to get the data from the device connected to the serial port.
At the moment I've a working console example for linux and it uses the class "termios". It seems that the most important part is done by the line

/* get a line of data from the sensor */
p = serial_read(buffer, 128);

and then performs some parsing of the string buffer. So I need to know how to open the connection, retrieve the string, close the connection.

Luigi

[Updated on: Sun, 12 October 2008 23:05]

Report message to a moderator

icon3.gif  Re: About RS232 [message #18637 is a reply to message #18630] Mon, 13 October 2008 20:08 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Here is an archive with my manual. It is almost finished - last advanced topic is to be written. In it`s current condition Manual will likely answer the most of your questions.
I`d apreciate any comments and suggestions.

Extract this archive into your package (project) directory and you will find documentation in TheIDE help within your package node.

[Updated on: Mon, 13 October 2008 20:09]

Report message to a moderator

Re: About RS232 [message #18639 is a reply to message #18637] Mon, 13 October 2008 23:00 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Mindtraveller wrote on Mon, 13 October 2008 20:08

Here is an archive with my manual. It is almost finished - last advanced topic is to be written. In it`s current condition Manual will likely answer the most of your questions.
I`d apreciate any comments and suggestions.

Extract this archive into your package (project) directory and you will find documentation in TheIDE help within your package node.


Hi,

thanks for the doc. Unfortunately the very important tutorial3 seems damaged. I can't read it after the phrase:

1. I just want to send some bytes to remote device.
ERROR: Invalid face number: ) void main()]&][s

Perhaps some character is not well parsed by my theide 2008.1 (perhaps have you used another version to prepare the docs?)

Luigi
Re: About RS232 [message #18640 is a reply to message #18639] Mon, 13 October 2008 23:25 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Of course. Since 2008.1 there where big number of improvements (thanx to Mirek) and QTF as well as TheIDE Help system is upgraded. I recommend to use Projects > SVN synchronize ability to obtain latest sources and recompile TheIDE.
I use latest SVN sources and manual was developed under latest version.

[Updated on: Mon, 13 October 2008 23:26]

Report message to a moderator

Re: About RS232 [message #18773 is a reply to message #18640] Mon, 20 October 2008 19:27 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1221
Registered: March 2006
Location: Italy
Senior Contributor
Hello,

I'm trying to simplify your application (using only methods from tutorial_1-4) to read the temperature of a sensor connected to a micro controller. Here is a picture of this stuff http://quozl.netrek.org/ts/

I have tried the program tsl-1.2.tar.gz in C given by the author (same link above) that run under windows in consolle mode and works OK.
His short code uses the termios lib available under linux.
I would like to replicate it with your library and add a GUI that should even draw a graph during the reading (other three sensors are coming and this increase the fun Smile ).

At the moment I was not able to wake up the micro controller. Please let me ask you if DTR in set ON automatically or I must add "dtr=on" in the comString.

Thanks,
Luigi
Re: About RS232 [message #23657 is a reply to message #3788] Wed, 11 November 2009 08:44 Go to previous messageGo to next message
gxl117 is currently offline  gxl117
Messages: 71
Registered: March 2009
Location: China
Member
I'm try to compile your example Kran,but compiler show a error:
main.cpp
f:\MyApps\siral\Kran\../COMMON\RS232Thread.h(103) : error C2664: 'ConveyorThread<T>::Request' : cannot conver
	t parameter 1 from 'Upp::Gate' to 'Upp::Callback1<P1>'
        with
        [
            T=RS232RequestElement
        ]
        and
        [
            P1=const RS232RequestElement &
        ]
        No constructor could take the source type, or constructor overload resolution was ambiguous
        F:\MyApps\siral\Kran\main.cpp(164) : see reference to function template instantiation 'void RS232Thre
	ad::RequestIOSlave<Kran::Triad>(const RS232RequestElement &)' being compiled


How to fix that?
Re: About RS232 [message #23666 is a reply to message #23657] Wed, 11 November 2009 21:05 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Sorry, it was a long time since Kran was developed. It looks like ConveyorThread is of much newer version than RS232Thread you use. I'm afraid for now I have no time to support it, as completely new version of RS232 library is under heavy development (it is crossplatform and based on 3rd part lib).
Re: About RS232 [message #23682 is a reply to message #23666] Fri, 13 November 2009 04:40 Go to previous messageGo to next message
gxl117 is currently offline  gxl117
Messages: 71
Registered: March 2009
Location: China
Member
Look it like a VC7.1's RTTI problem.
Re: About RS232 [message #24408 is a reply to message #23682] Fri, 15 January 2010 00:10 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Hi,

I'm wondering if there was ever any progress made on getting a Linux version to work. I have a serial port class for windows which I didn't post as it seems like it got overtaken by other posts.

Seems like there should be plenty of open-source code out there but I'm not finding it.If I find a way before this gets answered then I'll post what I find.

Nick
Re: About RS232 [message #24633 is a reply to message #24408] Tue, 26 January 2010 04:39 Go to previous messageGo to next message
nlneilson is currently offline  nlneilson
Messages: 644
Registered: January 2010
Location: U.S. California. Mojave &...
Contributor
I would also like something in U++ to work with serial ports.

The example for sockets is very good and I will be using that.
If something similar for serial ports could be done that would be great.

I have worked with serial ports for GPS data using:

Python with PySerial

Java with rxtx

Windows with:
#using <System.dll>
using namespace System;
using namespace System::IO::Ports;
using namespace System::Threading;
using namespace System::IO;
using namespace std;

I have tried and have the code for wxTerminal but digging through the code and trying to get something to work with U++ is something I have not tried.

Something to work with serial ports for Win and Linux in U++ would be a real plus.

[Updated on: Tue, 26 January 2010 04:46]

Report message to a moderator

Re: About RS232 [message #24672 is a reply to message #24633] Tue, 26 January 2010 22:54 Go to previous messageGo to next message
Didier is currently offline  Didier
Messages: 740
Registered: November 2008
Location: France
Contributor
I have a basic serial port package for linux only (sorry) but it works well.
I'll post it as soon as possible

Re: About RS232 [message #24673 is a reply to message #24672] Tue, 26 January 2010 23:21 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Hi Didier,

That would be great as then its just a case of preprocessor directives to choose between my windows serial code and the linux serial code.

Cheers,

Nick
Re: About RS232 [message #24928 is a reply to message #24673] Fri, 05 February 2010 00:19 Go to previous messageGo to next message
Didier is currently offline  Didier
Messages: 740
Registered: November 2008
Location: France
Contributor
Hi nixnixnix,

sorry for delay, but I'm missing time.

Here is my very basic serial port package for linux.

There is only open(port, speed)/close and read/read_timed/write.

But with that you can treat 90% of the cases.
Re: About RS232 [message #25030 is a reply to message #24928] Mon, 08 February 2010 21:45 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Thanks Didier,

Will give it a shot. Am just reading NMEA sentences from GPS so it should be more than I need Smile

Cheers,

Nick
Re: About RS232 [message #25650 is a reply to message #24928] Sat, 06 March 2010 02:31 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Hi Didier,

Works fine although one needs to know of course that the serial ports are named

/dev/ttyS1
/dev/ttyS2

etc.

Also, its more useful to return whether the port is open or not. I will post my modification of your serial port class once I've had time to clean them up but if anyone else wants serial port code, post here and I will pull my finger out.

Nick
Re: About RS232 [message #25652 is a reply to message #25650] Sat, 06 March 2010 11:38 Go to previous messageGo to next message
nlneilson is currently offline  nlneilson
Messages: 644
Registered: January 2010
Location: U.S. California. Mojave &...
Contributor
It would be good to get this implemented in upp.
Maybe
If win ports = COM7, COM8, ...

If unix ports = /dev/ttyS7, /dev/ttyS8, ...

As posted on 26, January I have used serial ports extensively on Win. Getting something that is cross platform would be great.

Getting rid of the requirement for:
using namespace System::IO::Ports;
and using something that works on Win and Linux.

All the parsing, etc. is no problem.
Re: About RS232 [message #25661 is a reply to message #25652] Sat, 06 March 2010 18:42 Go to previous messageGo to next message
Reini is currently offline  Reini
Messages: 28
Registered: April 2009
Location: Berlin
Promising Member
Hello NL,

Since I red a lot of it in the past that U++ Users request RS232 support I just thaught of trying the challenge.

Several years ago I programmed the RS232 with Visual Basic and had the common problem that most VB Users can code 95% of the features in 10% of the time or so Very Happy

Back then the whole PC was at 100% CPU load, stuck completely and I had data loss packages if I went above 56k Laughing

It was a nightmare and in the end I couldn't solve it with VB since it does not allow threading and stuff.

Anyway because I spent back then a lot of time with RS232 and designed an RS232 Monitoring Program for filtering characters my Idea would be to publish an updated version in C++ for this.
So I could try to get all my knowledge from then into an RS232 Lib for Upp could be a challenge.

Do you have already some code ?
If you are interested I could provide also the old VB Version.

Greetings
Re: About RS232 [message #25665 is a reply to message #25661] Sun, 07 March 2010 00:33 Go to previous messageGo to next message
nixnixnix is currently offline  nixnixnix
Messages: 415
Registered: February 2007
Location: Kelowna, British Columbia
Senior Member
Ok here is what I've got. Its clumsy but it works for both Windows and Linux. I have attempted to modify Didier's code to provide a more unified interface but it could be done a lot better.

Basically it does what I need just now and like I say it works on both platforms. My main addition is to provide a common Open function as well as an IsOpen function.

Nick
  • Attachment: Serial.cpp
    (Size: 7.74KB, Downloaded 1385 times)
  • Attachment: Serial.h
    (Size: 2.61KB, Downloaded 1133 times)
Re: About RS232 [message #25671 is a reply to message #25665] Sun, 07 March 2010 12:58 Go to previous messageGo to next message
nlneilson is currently offline  nlneilson
Messages: 644
Registered: January 2010
Location: U.S. California. Mojave &...
Contributor
Reini: The code I use just follows after the connection.

For the connection on Win it's System::IO::Ports
With Java it's rxtx
With Python it's PySerial

With your experience and what Nick has maybe something can
be put together that Mirek and others can check and possibly have that included in Upp.

I will look closer at Nick's code, I couldn't find termios.h, is that included in C++ ?

Neil

[Updated on: Sun, 07 March 2010 13:14]

Report message to a moderator

Re: About RS232 [message #25673 is a reply to message #25671] Sun, 07 March 2010 13:38 Go to previous messageGo to next message
Didier is currently offline  Didier
Messages: 740
Registered: November 2008
Location: France
Contributor
Hi Nick and others,

I'm happy to see that that you managed to use my linux serial port package and even added the windows support.

It would be a good idea to continue the effort and make a complete management of the serial port, add support for:
- handshake
- parity
- ....

Also, I think it would be a good idea to have SerialConfig struct that would enable easy management of predefined configs.

We could use the port number instead of /dev/tts0 or COM1 to make it fully portable.


I can manage the linux version enhancements, can you manage the windows version ?

What do you think Nick.

Re: About RS232 [message #25679 is a reply to message #25673] Sun, 07 March 2010 17:25 Go to previous messageGo to next message
Mindtraveller is currently offline  Mindtraveller
Messages: 917
Registered: August 2007
Location: Russia, Moscow rgn.
Experienced Contributor

Why don't use wxSerial from wxWidgets?
icon14.gif  Re: About RS232 [message #25681 is a reply to message #25679] Sun, 07 March 2010 19:50 Go to previous messageGo to next message
Didier is currently offline  Didier
Messages: 740
Registered: November 2008
Location: France
Contributor

Why don't use wxSerial from wxWidgets?


If there are no links to wxWidgets inside the code that can get very simple to do.
But even if there are some links to wxWidgets, we will probably find some corner cases linked with porting issues that we would also have to resolve.

So taking a look will probably get very instructive.

I'll try to find the time to look at it.

Thank's for the tip
Re: About RS232 [message #25683 is a reply to message #25681] Sun, 07 March 2010 20:56 Go to previous messageGo to previous message
Didier is currently offline  Didier
Messages: 740
Registered: November 2008
Location: France
Contributor
I've just looked at wxSerial.
OK it's a serial port Smile

But I'm not sure the wxWindows license is compatible with the BSD of UPP ?

Anyway a serial port is simple enough to do it without copying it.

Previous Topic: templated callback
Next Topic: Memory Mapped Files
Goto Forum:
  


Current Time: Tue Apr 28 17:48:08 GMT+2 2026

Total time taken to generate the page: 0.01352 seconds