Home › Forums › AR Sandbox Forum › USB Button Solution
Tagged: brother printer offline
- This topic has 97 replies, 24 voices, and was last updated 6 months, 1 week ago by
ajy00.
-
AuthorPosts
-
November 5, 2018 at 10:42 am #117976
Joshua.waymire
ParticipantI have attached the Vruiverbose readout. Not exactly sure what is on the readout but maybe on of you can see what I am doing wrong. I have linked the file for you to review.
VruiVerbose readout through terminal.
https://drive.google.com/file/d/1U__TQyQzuN1-wCg4JB4s-A_BeX_FUuHX/view?usp=sharingI dont see a script executor in my utility submenu.
https://drive.google.com/file/d/1U__TQyQzuN1-wCg4JB4s-A_BeX_FUuHX/view?usp=sharing-
This reply was modified 2 years, 2 months ago by
Joshua.waymire.
-
This reply was modified 2 years, 2 months ago by
Joshua.waymire.
November 5, 2018 at 2:29 pm #117980ajy00
ParticipantJoshua
Well it looks like the system is running though as expected. The only thing puzzling me is the vruiverbose output is referencing two windows defined in config, whilst the SARndbox.cfg file you have ( and there seem to be a few copies in your Google Drive files) references a single window. I guess the question is are you sure that the SARndbox.cfg file is the one from your
/home/warren/.config/Vrui-4.5/Applications/SARndbox.cfg
location?On the Script Executor .. not sure if you meant to attach an image … What happens when you pres an unassigned key? what menu are you offered?
ANovember 5, 2018 at 6:17 pm #117982Joshua.waymire
ParticipantI apologize but I needed to revise this post:
I have attached the Vruiverbose readout. Not exactly sure what is on the readout but maybe on of you can see what I am doing wrong. I have linked the file for you to review.
VruiVerbose readout through terminal.
I dont see a script executor in my utility submenu.
https://drive.google.com/file/d/18znpph82kLwwPd5sbMEukzFmqLddUIwa/view?usp=sharingNovember 13, 2018 at 5:03 pm #118011Joshua.waymire
ParticipantOk guys and girls,
I have went over and over my code and still cannot find why my USB encoder is not working. Is there any kind soul that will review my code and see where Im going wrong? Thank you so much in advance. The kids are getting anxious and there may be a mutany if I dont get it running right soon. 😉
Thanks,
JoshNovember 13, 2018 at 7:46 pm #118012tuchwando
ParticipantHi Josh, since you don’t have the “Script Executor” option in a menu when pushing the button, you probably have an older VRUI installed.
Assuming you have Linux and the display driver correctly installed, start fresh from Step 3 here: http://idav.ucdavis.edu/~okreylos/ResDev/SARndbox/SoftwareInstallation.html
This will install Vrui 4.5, which has the script executor built in (old versions of Vrui didn’t have this yet).
Patrick
edit – i see you do have 4.5
One small thing – your button numbers should probably start at Button0
A second thing – the file ~/src/SARndbox-2.5/etc/SARndbox.cfg should not be the same as ~/.config/Vrui-4.5/Applications/SARndbox.cfg ; it is a place you can put options like this:# Configuration file for SARndbox application # Copyright (c) 2016 Oliver Kreylos section SARndbox section Camera # Configuration parameters for Kinect v1 compressDepthFrames true smoothDepthFrames false endsection waterTableSize (400,300) waterSpeed 1.0 waterMaxSteps 30 rainStrength 0.25 evaporationRate 0.0 elevationRange (-40,25) rainElevationRange (25,100) endsection
November 13, 2018 at 9:10 pm #118015tuchwando
ParticipantAlso, a few more troubleshooting things to try:
1) Script Executor. The computer freezing when trying to run a script in my experience has been due to the path of the script not being correct – it tries to run a script that isn’t there, and the machine locks up.
– Test the script executor manually: With the program running, navigate a terminal to the ~/src/SARndbox-2.5/ folder (press F11 to exit fullscreen if needed) and type./ToggleWeather.sh
– This will run the script manually. Similarly you could try running a specific script in your ~/src/SARndbox-2.5/scripts/ folder
– It’s a little strange that you don’t get the script executor as an option in the menu.2) USB encoder. One way to test whether the USB encoder is working is to see if you can assign a function (eg. global water etc) while the program is running, by simply pressing the buttons. First you need to comment out the button assignments in ~/.config/Vrui-4.5/Applications/SARndbox.cfg like so:
section Vrui section Desktop #Disable the Screen Saver inhibitScreenSaver true inputDeviceAdapterNames += (HIDAdapter) section HIDAdapter inputDeviceAdapterType HID inputDeviceNames (USBEncoder) section USBEncoder name USBEncoder deviceVendorProductId 0079:0006 trackingDeviceName Mouse endsection endsection section MouseAdapter mouseIdleTimeout 5.0 endsection section Window windowFullscreen true endsection section Tools toolClassNames += (ScriptExecutorTool) # section DefaultTools # section WaterTool # toolClass GlobalWaterTool # bindings ((USBEncoder, Button0, Button1)) # endsection # section ChangeWeather # toolClass ScriptExecutorTool # bindings ((USBEncoder, Button2)) # executablePathName ~/src/SARndbox-2.5/ToggleWeather.sh # arguments () # endsection # endsection endsection endsection endsection
If when you press a button you get a menu, the USBEncoder is working.
-
This reply was modified 2 years, 2 months ago by
tuchwando.
November 14, 2018 at 2:29 am #118029ajy00
ParticipantAgree the steps from tuchwando … though might I suggest that because ScroptExecutor isn’t there, it really would be a plan to re-install Vrui – if not bite the bullet and start afresh with a new clean version of the build
December 5, 2018 at 4:37 pm #118093Joshua.waymire
ParticipantBig thanks to all of you that have helped to get the sandbox at my school up and operational. Has been a great learning tool so far and cant wait to expand on it later. I am having one small issue. I cannot get the savedinputgraph to load on the start sandbox shell script. I have linked the files below:
https://drive.google.com/drive/folders/1r0p-VtMULvHpUEISjO41cRVzYmp9WLID?usp=sharingDecember 5, 2018 at 6:07 pm #118094ajy00
ParticipantJoshua
Can you load the input graph manually? (from right click menu:
Vrui System/Devices/Load InputGraph
). If that works then I’d guess it must be a directory path issue.AJY
January 17, 2019 at 4:07 pm #118274Joshua.waymire
ParticipantI finally got it all working. Thank you to all those who helped out and took the time to review my code and big shout out to @ajy00 and @ ChrisVeale for all the help.
Future possibilities:
Screenshot feature.
Displaying a topographic map alongside their live view of the sandbox.January 17, 2019 at 5:31 pm #118275ajy00
Participant🙂 Well done sir…
hope the kids appreciate your efforts!January 17, 2019 at 10:40 pm #118277Oliver Kreylos
KeymasterWhat do you mean by “screenshot feature?”
January 18, 2019 at 3:13 am #118278ajy00
ParticipantOliver, I suspect Joshua picked up on part of the scripts shared with him a while back.
Using SCROT as a minimalist screen capture tool (thanks @mkaszuba), we implemented an additional button – using ScriptExecutorTool – to allow a screen capture of the landscape in the box.
We use this with the students, challenging them to recreate a landscape in the ARSandbox from looking at a paper topography map or an image on separate screen, then capture the image of their version to see how they compare. Basic understanding of contours etc, and a great team challenge!
For older students it is also linked to locating and using map references.There are some outline topic notes here River Wey Trust resources (references UK Ordnance Survey mapping).
Screen Capture script we use to capture an image with timed info is
#capture-screen.sh #!bin/bash cd ~/[directory for screen captures] scrot 'SARndbox %Y-%m-%d %H-%M-%s.png' -u cd ~/src/SARndbox-2.5
January 29, 2019 at 6:14 am #118347dawsonll
ParticipantMy USB controller has died. It is not recognized by LSUB (nor are there lights on the controller anymore). I only had it working one day… 🙁 Are there trouble shooting measures I should take before trying to return it? I’m a novice, but learning so much as I set up my sandbox. Thanks!
January 29, 2019 at 6:20 am #118348dawsonll
ParticipantMore Info:
I used this encoder: https://www.amazon.com/gp/product/B00UUROWWK/ref=ppx_yo_dt_b_asin_title_o02__o00_s00?ie=UTF8&psc=1With these buttons:
-
This reply was modified 2 years, 2 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.