B4J Question Serial PurgePort

mrossen

Active Member
Licensed User
Longtime User
Hi,

What is the correct use of Serial PurgePort

I do:
B4X:
Serial1.PurgePort(1)

But the doc says ex. PURGE_RXCLEAR

And there should also be a way to combine the 4 methods

Mogens
 

agraham

Expert
Licensed User
Longtime User
But the doc says ex. PURGE_RXCLEAR
That is just an integer constant. By the way 1 is PURGE_TXABORT. PURGE_RXCLEAR is actually 8.

And there should also be a way to combine the 4 methods
Read the comment in the xml.

PurgeFlags should be one of the PURGE constants
or any combination (with Bit.Or).
Actually you could just add them, it's a bit simpler.
 
Upvote 0

mrossen

Active Member
Licensed User
Longtime User
Hi,

Thanks for the reply, but where have you found the value for ex. PURGE_RXCLEAR?

I have looked in the xml, but cannot see it

Mogens
 
Upvote 0

Similar Threads

Replies
1
Views
1K
Replies
3
Views
2K
Replies
3
Views
3K
Replies
1
Views
2K
Top