Skip to main content

EV3 simulator for the ev3dev2 library

Project description

ev3dev2simulator: simulator for the EV3 (ev3dev2 API)

The behaviour of the EV3 robot is simulated in the simulator. This is convenient to quickly test programs when you momentarily don’t have access to an EV3.

ev3dev2simulator

You can use the 'ev3dev2' python library to program the EV3. The simulator installs a fake 'ev3dev2' library on the PC. When using this library on the PC, every call to this API is forwarded to the simulator which uses it to simulate the behaviour of the EV3 robot.

For an example see: https://github.com/ev3dev-python-tools/thonny-ev3dev/wiki/Simulator-example
The running program can be seen in the following video: http://www.cs.ru.nl/lab/ev3dev2simulator.html .

The thonny-ev3dev plugin makes it easier to program the EV3 programmable LEGO brick using the Thonny Python IDE for beginners. The thonny-ev3dev plugin for the Thonny IDE comes with the ev3dev2simulator.

For more info about the thonny-ev3dev plugin see: https://github.com/ev3dev-python-tools/thonny-ev3dev/wiki
For more info about Thonny: http://thonny.org

Getting started

Prerequisites needed only for Linux

For Macos and Windows you don't need any prerequisites, but for linux you do.

The pyttsx3 python speech library uses system libraries in its implementation. For Macos/Windows the used system 'speak' libraries are always available, but for linux you must sure these are installed with:

 sudo apt update && sudo apt install espeak ffmpeg libespeak1

For linux there are is no binary distribution available for simpleaudio. The Python 3 and ALSA development packages are required for pip to build the extension. For Debian variants (including Raspbian), this will usually get the job done:

 sudo apt-get install -y python3-dev libasound2-dev

Installation

Install with pip:

  pip install ev3dev2simulator

For Windows and Macos all binary dependencies are provided by wheels on pypi, however for Linux the binary extenssion for simpleaudio is compiled when installing.

Then you can just run the simulator by running the executable:

  ev3dev2simulator

The simulator works on all python versions 3.8 till python 3.12.

Using the simulator

The user guide of the simulator can be found on the wiki.

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

ev3dev2simulator-2.0.8.tar.gz (309.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

ev3dev2simulator-2.0.8-py3-none-any.whl (356.4 kB view details)

Uploaded Python 3

ev3dev2simulator-2.0.8-2-py3-none-any.whl (356.3 kB view details)

Uploaded Python 3

File details

Details for the file ev3dev2simulator-2.0.8.tar.gz.

File metadata

  • Download URL: ev3dev2simulator-2.0.8.tar.gz
  • Upload date:
  • Size: 309.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.3

File hashes

Hashes for ev3dev2simulator-2.0.8.tar.gz
Algorithm Hash digest
SHA256 7fb7fc593827c6b488c5bf0f4db4f8b71db25e42ef1cc51ec2a22566f3bb087d
MD5 67f8f0cd5b4c85b0310114a4522143f9
BLAKE2b-256 c7ee98426385f87256309c2abd93469bf8290a536bb946c3fe5f73c40b8fa287

See more details on using hashes here.

File details

Details for the file ev3dev2simulator-2.0.8-py3-none-any.whl.

File metadata

File hashes

Hashes for ev3dev2simulator-2.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 09932171e318ab37cb03b84d274dcee33708c79ccbaf89f65519064eecc1b4a2
MD5 455c8d92237ec8ff6cc9185f11104eef
BLAKE2b-256 fbc50c15262244c68b81dbbf7413e193b2e73d95a702083953248699190d0e5d

See more details on using hashes here.

File details

Details for the file ev3dev2simulator-2.0.8-2-py3-none-any.whl.

File metadata

File hashes

Hashes for ev3dev2simulator-2.0.8-2-py3-none-any.whl
Algorithm Hash digest
SHA256 430f6194cd854d9eddbcd7e4c0a6e7a1f199355cc40bee603858ac17028abaa6
MD5 69073ae0d41e9fb70e2de6381ee20bd0
BLAKE2b-256 c8a2f82c03ba23f90cf781210e4292bf8ad47eb0401a14aee4e7bce1047c3d85

See more details on using hashes here.

Supported by

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