Skip to main content

Module and sample code for obtaining data with OMRON 2JCIE-BU01 Environment Sensor by Python. The codes work with Python 3.6 and above. This module supports USB serial communication and BLE. This module depends on pySerial(serial communication) and Bleak(BLE).

Example:

# Obtain sensing data via serial communication
from omron_2jcie_bu01 import Omron2JCIE_BU01
sensor = Omron2JCIE_BU01.serial("/dev/ttyUSB0") # Linux
sensor = Omron2JCIE_BU01.serial("COM5")         # Windows
devinfo = sensor.info()
data = sensor.latest_data_long()

# Obtain sensing data via BLE communication
# Read latest data with connection
from omron_2jcie_bu01 import Omron2JCIE_BU01
sensor = Omron2JCIE_BU01.ble("AA:BB:CC:DD:EE:FF")
data1 = sensor.latest_sensing_data()
data2 = sensor.latest_calculation_data()

# Read latest data by scan
def on_scan(data):
    print("SCAN", data)

# Advertising mode: 0x01 (Passive)
sensor.scan(on_scan, scantime=3)

# Advertising mode: 0x03 (Active)
sensor.scan(on_scan, scantime=3, active=True)

# Notify sensing data
def on_notify(sender, tpl):
    print(f"{sender} {tpl}")

sensor.start_notify(0x5012, on_notify)
sensor.start_notify(0x5013, on_notify)
sensor.sleep(5)
sensor.stop_notify(0x5012)
sensor.stop_notify(0x5013)

Metadata

Release files for omron-2jcie-bu01-interact 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for omron-2jcie-bu01-interact 0.1.1
File Size Uploaded Provenance
omron-2jcie-bu01-interact-0.1.1.tar.gz 13.2 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for omron-2jcie-bu01-interact 0.1.1
File Interpreter ABI Platform
omron_2jcie_bu01_interact-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 38.7 kB

Release files / omron-2jcie-bu01-interact-0.1.1.tar.gz

Download URL omron-2jcie-bu01-interact-0.1.1.tar.gz
Size 13.2 kB
Tags Source
SHA-256 checksum
How to use checksums
384612e6ab09d2c92c79705d6c2282c8c95fb44f7cc68e0b5197525a27769c06
BLAKE2b-256 checksum
How to use checksums
9de2f879e8bcc019d03b16a0df9131f37aea7499f502302a4af13a9e48f17357
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Release files / omron_2jcie_bu01_interact-0.1.1-py3-none-any.whl

Download URL omron_2jcie_bu01_interact-0.1.1-py3-none-any.whl
Size 25.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
83da20975c324aeba045b5e635f4680c27126ca9fa0958ec9afa44d7de985f67
BLAKE2b-256 checksum
How to use checksums
60abc9ef0696c6e1209203c3c396af5a15d6892a84d9f43485229897d5409bac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Security for omron-2jcie-bu01-interact 0.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page