Some logging functions for MicroPython in combination with syslog-server
Project description
Eydam-Prototyping: ep_logger
Deutsche Version hier / German version here
Library, to send log messages from an IoT-Device running MicroPython to a syslog-server. How to setup a syslog-server in combination with Telegraf and Grafana is described here: here
The messages will be send in ietf-syslog-protocol-23-format.
Example:
# Syslog-Server (192.168.178.100) is listening on 514 (UDP)
import ep_logging
logger = ep_logging.logger("192.168.178.100", port=514)
logger.notice("Test")
This Code would produce the following message:
<85>1 2021-01-20T20:33:17.0Z esp32 logger - - Test
-- - ---------------------- ----- ------ - - ----
| | | | | | | +--- message
| | | | | | +------- MSGID (=None)
| | | | | +--------- PROCID (=None)
| | | | +------------- appname
| | | +-------------------- hostname
| | +----------------------------------- timestamp
| +----------------------------------------------- version (always 1)
+------------------------------------------------- facility + servity
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for micropython_eydam-prototyping_logging-0.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | cc45a5e33183f008fc1b0603f211027b2b63c6eab14c4484b7555b828a3892a1 |
|
MD5 | 708b200fa7a73ebaed22328cf8af5501 |
|
BLAKE2b-256 | e09ec9c3abc80a09cd0d59074eb761da2c6f2a442d58e037817e6a4fbac987fc |
Close
Hashes for micropython_eydam_prototyping_logging-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8438b3f0f6a3ec6620500bc5607d022873416a4b72a773ba09851f93e3237452 |
|
MD5 | 8a01788ec6f1a592aa15a173edef7dc0 |
|
BLAKE2b-256 | 841122af8d0bfdc547a9e7e2689f0479258497b9f8327c1352506cf1879a0c2d |