Skip to content

Instantly share code, notes, and snippets.

@alexanderhiam
Created July 18, 2014 14:01
Show Gist options
  • Save alexanderhiam/5055d27d7508e6d80440 to your computer and use it in GitHub Desktop.
Save alexanderhiam/5055d27d7508e6d80440 to your computer and use it in GitHub Desktop.
pruspeak shared variable example
SCRIPT
SET period_ms, 100 // set inital value
SET ain_val, AIN[0]
WAIT period_ms
GOTO 1
ENDSCRIPT
// When it's running you can change the sampling period with:
SET period_ms, x
// and get the value with:
GET ain_val
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment