Skip to main content

Mouse joystick interface for communicating with mouse joystick controller.

Project description

This Python package creates a class named MouseJoystickInterface.

Authors:

Peter Polidoro <peterpolidoro@gmail.com>

License:

BSD

Example Usage:

dev = MouseJoystickInterface() # Might automatically find devices if available
# if devices not found automatically, specify ports directly
dev = MouseJoystickInterface(use_ports=['/dev/ttyACM0','/dev/ttyACM0']) # Linux specific ports
dev = MouseJoystickInterface(use_ports=['/dev/tty.usbmodem262471','/dev/tty.usbmodem262472']) # Mac OS X specific ports
dev = MouseJoystickInterface(use_ports=['COM3','COM4']) # Windows specific ports
# abort_assay prematurely stops a running assay and leaves the rig ready to start a new assay
dev.abort_assay()
# start_assay is the main method that starts the assay, collects assay data, and saves data files
dev.start_assay()

# optional mouse_joystick_controller methods
dev.mouse_joystick_controller.set_properties_to_defaults(['ALL'])
dev.mouse_joystick_controller.get_property_values(['ALL'])
dev.mouse_joystick_controller.reach_position1_means('getValue')
dev.mouse_joystick_controller.reach_position1_means('setValue',[100,160,200])
dev.mouse_joystick_controller.reach_position1_means('setArrayLength',2)
dev.mouse_joystick_controller.reach_position1_means('setValue',[100,200])
dev.mouse_joystick_controller.trial_count('setValue',3)
dev.mouse_joystick_controller.repeat_aborted_trial('setValue',False)
dev.mouse_joystick_controller.get_assay_status()
dev.mouse_joystick_controller.move_joystick_to_base_position()
dev.mouse_joystick_controller.move_joystick_to_reach_position()
count = 1
dev.mouse_joystick_controller.activate_lickport(count)
dev.mouse_joystick_controller.get_trial_timing_data()
dev.mouse_joystick_controller.abort_trial()

# optional encoder_interface methods
dev.encoder_interface.set_properties_to_defaults(['ALL'])
dev.encoder_interface.get_property_values(['ALL'])
dev.encoder_interface.sample_period('setValue',15)
dev.encoder_interface.get_positions()
dev.encoder_interface.get_sample_count()
dev.encoder_interface.get_samples()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mouse_joystick_interface-2.0.0.tar.gz (6.6 kB view details)

Uploaded Source

Built Distribution

mouse_joystick_interface-2.0.0-py2.py3-none-any.whl (6.1 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file mouse_joystick_interface-2.0.0.tar.gz.

File metadata

  • Download URL: mouse_joystick_interface-2.0.0.tar.gz
  • Upload date:
  • Size: 6.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.7.0 requests/2.25.0 setuptools/41.2.0 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for mouse_joystick_interface-2.0.0.tar.gz
Algorithm Hash digest
SHA256 d2d2e7d2fbee31c2ddaafc5d254d86f5ad2b8a2c48793b48d26a5e2456536ac6
MD5 2eab36d49309e34a95257860a2390dfb
BLAKE2b-256 3fabaa80f49e20cfd2f59562c669689e4e3a3191a87716397820fd2eb4f720d9

See more details on using hashes here.

Provenance

File details

Details for the file mouse_joystick_interface-2.0.0-py2.py3-none-any.whl.

File metadata

  • Download URL: mouse_joystick_interface-2.0.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.7.0 requests/2.25.0 setuptools/41.2.0 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for mouse_joystick_interface-2.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 cd9dbaa7545d6b96004b5bbdd76b53a027d745c078f237cc9cb4958cf33fdea4
MD5 5f77fbdebad4608c299fc24e701d2c80
BLAKE2b-256 02098f13b3c37e612961d349d77d732fd003b411f758f3c5cfc5a279aa6130ae

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page