session timer issue
MEDState Notation Repository › Forums › Coding Help Archive › session timer issue
- This topic has 5 replies, 1 voice, and was last updated 8 years, 9 months ago by
Med_Support.
-
AuthorPosts
-
January 16, 2015 at 12:34 pm #12820
Med_Support
Moderatorandersem
Hi there,
I am using the attached program for progressive ratio. All works great (there is a 20 second time out, the session runs for five hours or an hour without a reward being received) HOWEVER, the session run time is not in seconds or minutes but rather some arbitrary number. Do you know how I can fix this?
Also, is there a way to code and display the time since the last pellet was received?
Thanks!January 16, 2015 at 2:14 pm #12821Med_Support
ModeratorJon Beyor
andersem,
The program currently runs in decimal minutes, EXAMPLE: 1.50 = 1 minute 30 seconds.
You can change it to just seconds by going to line 127 in bold below (S.S.1, S3,) and remove the /60 so that it reads SHOW 1, Session,S;
S3, \ Time Session Length
0.01″: SET S = S + 0.01;
SHOW 1,Session,S/60;Here is some code to set a reward timer (add another State Set) you could bin Y if you wanted to as well.
\*************************************************** \ LAST REWARD TIMER \*************************************************** S.S.5, S1, #ZA(^RewardDevice): ---> S2 S2, #ZA(^RewardDevice): Set Y = 0 --->S2 0.1": SET Y = Y + 0.1; SHOW 6,Last Reward,Y ---> S2
Regards,
JonJanuary 19, 2015 at 12:44 pm #12824Med_Support
ModeratorThe time now is in seconds. I deleted the S/300 in S.S.1, S3 and I think that is what you meant. The last reward timer is not showing up in the display. I changed ^rewarddevice to ^pellet and that still did not work. I also tried changing it to 7 since 6 is softCRcode in S.S.1, S2. Any other ideas for why it may not be working? Thanks!
January 19, 2015 at 2:55 pm #12826Med_Support
ModeratorJim Frei
Hi Andersem,
Jon had to leave early today so he asked me to check in. He gave me some code but I’m not sure if it’s the same as the one you’re working from. The last reward timer shows up fine in the version I have. You need to make sure you have enough rows showing in your display. Look near the top of Med-PC and you’ll see “Summary Show Rows”, make sure you have this set to at least 2 if your reward timer is in block 7.
If you’re still having trouble please post the code you’re working from and I’ll take a look.
jJanuary 20, 2015 at 1:36 pm #12828Med_Support
Moderatorandersem
That’s all it needed, thanks!
Now for a non coding question:
Is there a specific protocol to tell how much weight it takes for the lever to consider a press? Do I set a weight on it or drop a weight from a certain height?January 20, 2015 at 2:55 pm #12831Med_Support
ModeratorJim Frei
Depends on which lever you have. Some like the ultra-sensitive levers are set at the factory and are not adjustable. Others have a little spring and nut that can be used to adjust the tension on the spring which adjusts the force needed to press the lever. With this type of user adjustable lever you could probably set (don’t drop) a small weight of the value you desire and it would be close enough. Ie: you need 2g of force, place a 2g weight on the lever and see if an input is recorded.
-
AuthorPosts
- You must be logged in to reply to this topic.