WorldViz User Forum  

Go Back   WorldViz User Forum > Plug-in development

 
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 01-15-2010, 10:53 AM
ursi ursi is offline
Member
 
Join Date: Dec 2009
Posts: 11
External Trigger via LabJack

Hi,
I wanna trigger a Vizard-function via an external trigger (via LabJack). How do I do that?

I wrote the following code using 'vizact.waitsignal':

##############################
import viz
viz.go()

import u12
d = u12.U12()
##############################
Trigg = d.eAnalogIn(0)

#Create the signal object
sig = vizact.signal(Trigg > 0)

#Create an action to wait on the signal
waitsig = vizact.waitsignal(sig)

def ExtTrigg(waitsig)
### add SOUND
song = viz.add('Beethoven.wma')
song.loop(viz.OFF)

#viz.callback(viz.Event,ExtTrigg) ##?
viz.callback(viz.ACTION_BEGIN_EVENT,ExtTrigg) ##?
##############################

Thanks!
Reply With Quote
 

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Implement LabJack ursi Vizard 4 01-07-2010 03:14 PM
Updating viewpoint via external computer Rachel Vizard 1 02-04-2008 06:23 PM
labjack plugin Jerry Vizard 1 03-14-2007 04:36 PM
collision events trigger Eunice Vizard 1 01-03-2006 10:39 AM
A hotspot id of -1 will never trigger. jrodman Vizard 1 01-27-2004 03:22 PM


All times are GMT -7. The time now is 11:13 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC