This release is a pre-release and may not be stable for production use.
CounterFit Shims - Grove
Shims for the Seeed Grove sensors and actuators to use with the CounterFit virtual IoT device app.
See the Grove Py Docs for the API documentation.
Getting started
To use these shims, you will need to install CounterFit and have it running, with the appropriate hardware created.
-
Install this package from pip:
pip install counterfit-shims-grove
-
Import the Grove modules as normal, but using the
counterfit_shims_grovepackage instead of thegrovepackage, as well as importing theCounterFitConnectionfrom thecounterfit_shims_grove.counterfit_connectionmodule:from counterfit_connection import CounterFitConnection from counterfit_shims_grove.grove_light_sensor_v1_2 import GroveLightSensor from counterfit_shims_grove.grove_led import GroveLed
-
Configure the connection to the CounterFit app. Change the hostname and port to where you are running it:
CounterFitConnection.init('127.0.0.1', 5000)
-
Write your Grove code as usual, setting the pins to match the ones you set in the CounterFit app:
light_sensor = GroveLightSensor(2) sensor_value = light_sensor.light
Implemented shims
Not all the Grove sensor and actuators are currently implemented:
| Sensor/Actuator |
|---|
| grove_led |
| grove_light_sensor_v1_2 |
Metadata
Release files for counterfit-shims-grove 0.1.4.dev5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| counterfit_shims_grove-0.1.4.dev5-py3-none-any.whl | Python 3 | none | any | Details |
Release files / counterfit_shims_grove-0.1.4.dev5-py3-none-any.whl
| Download URL | counterfit_shims_grove-0.1.4.dev5-py3-none-any.whl |
|---|---|
| Size | 7.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c5b36e917d2a55b3e5ec17f7627b23fac001ef547d894aedd7835f0a2883c13f
|
|
BLAKE2b-256 checksum How to use checksums |
87371fe78516d2e5e9d17bbc6137d90706b710bd73a0bf65bddd858fb973b19f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.1
|