MOUSE command problem (FW 2.1.14730)
|
08-07-2023, 03:02 PM
Post: #1
|
|||
|
|||
MOUSE command problem (FW 2.1.14730)
I tried to read the touch screen status in a loop. It's important that it's not a blocking function (like WAIT) because other tasks are executed in the meantime. I used the MOUSE() command, but it behaves oddly.
First, I'll provide an example of a program that works, but doesn't quite meet my expectations: Code:
Above, the coordinate retrieval is done by calling MOUSE() twice, which is not very neat, and with very fast movements, it can lead to returning the x coordinate from one point and the y from another, combining them into a single mismatched point on the screen that might not have been touched at all. A better solution would be to retrieve the MOUSE() result into a variable once and then operate on its components: Code:
Unfortunately, such a solution doesn't work. Despite the infinite loop, the program stops after several iterations of the loop and it doesn't even report an error. Moreover, MOUSE2 can only be run from the 'Program Catalog', but from the command line in 'Home', it returns "Error: Invalid input". Is this a bug? Regards Piotr Kowalewski |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
MOUSE command problem (FW 2.1.14730) - komame - 08-07-2023 03:02 PM
RE: MOUSE command problem (FW 2.1.14730) - gehakte_bits - 08-07-2023, 06:06 PM
RE: MOUSE command problem (FW 2.1.14730) - komame - 08-07-2023, 07:05 PM
RE: MOUSE command problem (FW 2.1.14730) - matalog - 08-08-2023, 07:58 PM
RE: MOUSE command problem (FW 2.1.14730) - matalog - 08-08-2023, 08:07 PM
|
User(s) browsing this thread: 1 Guest(s)