Jump to content

Is Filemaker capable of handling milliseconds?


 Share

This topic is 6537 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have a upcoming project in where I would need to show an image for maybe a few milleseconds and then the user would click a stop button. I was wondering if milleseconds were in FileMaker's capability? If not, is there any plugin for this, maybe someone can point me in the right direction?

Thanks.

Justin Grewe

Link to comment
Share on other sites

I'm not sure how accurate you want it, but you might try something akin to the old fasioned (pre- "every computer has a clock" method):

Set gTimer = 0

loop

set gTimer = gTimer + 1

exit loop if gTimer > 5

pause/reume script [00:00:00]

end loop

Experiment with different numbers to get the duration you want. button clicks should be processed at the Pause/resume script step so you can halt the script and run another.

Jeff

ps - I know this answers a 3-month-old question -- but I always get annoyed at dead-end message-board and newsgroup searches that turn up questions and no potential answers.

Link to comment
Share on other sites

I don't think this is solution. I am needing a reaction time button to where this method would work I think but there needs to be more. Also, for milleseconds, when it is setting the field, I have set the gtimer + .001, that doesn't improve the situation, does it? I mean it still takes the same time to set the field + .001 then it does to set it + 1.00 right? How can I do this if this is possible, and also, is there a way of dealing with repeating fields to where, the user clicks on the button, then clicks it again when they see an object, thus the difference is put into the next repeating field and that field keeps a log of the users performence. I probably need the object to start the script then the user clicks the button when they see the object, thus stopping the script.

Thanks for any help on this subject as I know it is a difficult one.

Justin Grewe

Link to comment
Share on other sites

Ian,

I know that REALBasic would be a more practicable solution for this sort of job, but I need to know if it is possible with FileMaker. I have a plugin that enables milliseconds with FileMaker but now I just need to integrate the object lauching the script. I think it is possible.

Thanks.

Justin Grewe

Link to comment
Share on other sites

Justin, to illustrate what Bob is talking about set up the script below using globals.

Set Field [ timecntst, Seconds(Status(CurrentTime)) ]

Set Field [ cntr, "" ]

Loop

Set Field [ cntr, cntr + 1 ]

Exit Loop If [ Seconds(Status(CurrentTime)) ? timecntst + 1 ]

End Loop

Set Field [ timecntstp, Seconds(Status(CurrentTime)) ]

Now you would think that the number returned in cntr would be pretty consistant, that is if you think your computers whole world stops to run this script....in fact there are many interupts that take precident over the filemaker script. So you cannot predict how long it will take your commands to get to the plugin to start and stop your timer or access the system clock.

Rod

Link to comment
Share on other sites

Yes, it's not just Filemaker; it's an operation system issue. With preemptive multitasking as in OSX and Windows, this is pretty much impossible to do. You could probably do it in OS8/9 or old versions of Windows/DOS. To do this with any kind of real accuracy on a modern computer, you need to be running a real time operating system such as QNX.

Link to comment
Share on other sites

>I have a upcoming project in where I would need to show an image for maybe a few milleseconds and then the user would click a stop button.

Quite unusual for a database application, isn't it?

Also, if the image is displayed for less than 20 milliseconds probably it won't appear in its whole size on the screen due to screen refresh issues.

Also I can't figure out how a user could see an image and click a button in few milliseconds.

Anyway, with lower level languages (probably with realbasic too), you can take advantage of system routines that let you perform operations at given time with great precision (less than milliseconds). In os 8/9 there was the TimeManager, I don't know in osX.

Going back to filemaker, the smalles time it deals with is 1 second, with Pause/Resume script step.

The loop workaround doesn't give neither precise or constant duration.

Good luck

Link to comment
Share on other sites

Paolo,

The database application would not be that unusual. Berea College has a system already, although at the moment I do not know the details of it, that tests a users vision. My supervisor asked me to explore if this was possible in FileMaker. I have found a milliseconds plugin for FileMaker, oAzium Date & Time and it works fine. Just as BobWeaver said, I would have problems with certain operating systems.

The issue is not displaying an image for a certain time, but to display an image, calculate the exact time that it was launched, then the user clicks the button, and the diffrence that they clicked the button will be calculated within milleseconds.

So with the system routines that you were talking about for os 8/9, would this work for a windows system?

Justin Grewe

Link to comment
Share on other sites

>display an image, calculate the exact time that it was launched, then the user clicks the button,

>and the diffrence that they clicked the button will be calculated within milleseconds.

ok, now I understand.

I haven't tried anything like that on FM, however I don't think you can do that in filemaker (and have precise results).

The time needed to perform script steps is not trascurable. Also when the user click a button the script is performed only on mouse-Up, not on mouse-Down. I suppose you want to measure time from image display to mouse-down.

You need an external application to do the image display+time measurement task. The app would then export data into a file that is then imported in filemaker.

In system 8/9 this shouldn't involve many problems (I can say that because I wrote in the past C application in system 8).

It is possible in osx or win too but I don't know how complex it could be. The problem is ensuring that background operations doesn't inferfere with the measurement.

Link to comment
Share on other sites

This topic is 6537 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.