Skip to content

devilhyt/sensor-adapter-stm8-public

Repository files navigation

Analog / Digital Sensor Adapter for LEGO EV3 (STM8 Version)

An adapter that allows LEGO EV3 to communicate with analog/digital sensors.

How it works

As is well known, common analog/digital sensors cannot communicate directly with the LEGO EV3. Therefore, we use a microcontroller (MCU) to convert sensor information into LEGO UART format and then transmit the information to the EV3 host via the LEGO UART Protocol.

Wiring

Connect the power supply to the sensor and connect the signal pins of the sensor to pin D3 of the adapter.

Solutions

Button Magnetic Switch Tilt Sensor
Rotation Sensor Temperature Sensor Light Sensor

⚠️ Supported sensors include, but are not limited to, the sensors mentioned above.

Functional descriptions

EV3 Port View

In the EV3 port view, the following three modes are available:

Analog Digital Up time (Debug)

EV3-G Block

Using the specialized block, you can retrieve the value of the sensor connected to the adapter. There are two modes available for the block:

Analog Read Digital Read

Disclaimer

LEGO® is a trademark of the LEGO Group of companies which does not sponsor, authorize or endorse this software. The LEGO Group and contributors to this repo are not liable for any loss, injury or damage arising from the use or misuse of the provided code or hardware.

Contributors

  • HsiangYi Tsai, devilhyt on Github (Author)
  • Anthony Hsu, a10036gt on Github (PCB Design / Technical Assistance)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages