-
-
08 Oct 2021 12:42:17 UTC
- Distribution: AnyEvent-MQTT
- Source (raw)
- Browse (raw)
- Changes
- Homepage
- How to Contribute
- Repository
- Issues (5)
- Testers (271 / 18 / 0)
- Kwalitee
Bus factor: 1- 91.88% Coverage
- License: perl_5
- Activity
24 month- Tools
- Download (36.81KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
NAME
anyevent-mqtt-pub - Perl script for publishing to an MQTT topic
VERSION
version 1.212810
SYNOPSIS
# messages one per line on stdin echo message | anyevent-mqtt-pub [options] topic # message as command line arguments anyevent-mqtt-pub [options] topic this is a message
DESCRIPTION
This script publishes each line from stdin as an MQTT message on the given topic.
OPTIONS
- -help
-
Print a brief help message.
- -man
-
Print the manual page.
- -host A.B.C.D
-
The host running the MQTT service. The default is
127.0.0.1
. - -port NNNNN
-
The port of the running MQTT service. The default is 1883.
- -client-id STRING
-
The client id to use in the connect message. The default is 'NetMQTTpm' followed by the process id of the process. This should be up to 23 characters and only use the characters A-Z, a-z, and 0-9 for maximum compatibility.
- -qos N
-
The QoS level for the published message. The default is 0 (
MQTT_QOS_AT_MOST_ONCE
). - -verbose
-
Include more verbose output. Without this option the script only outputs errors
- -keepalive NNN
-
The keep alive timer value. Defaults to 120 seconds. For simplicity, it is also currently used as the connection timeout.
- -retain
-
Set the retain flag on the message. Default is not set.
SEE ALSO
AnyEvent::MQTT(3)
DISCLAIMER
This is not official IBM code. I work for IBM but I'm writing this in my spare time (with permission) for fun.
AUTHOR
Mark Hindess <soft-cpan@temporalanomaly.com>
COPYRIGHT AND LICENSE
This software is copyright (c) 2014 by Mark Hindess.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
Module Install Instructions
To install AnyEvent::MQTT, copy and paste the appropriate command in to your terminal.
cpanm AnyEvent::MQTT
perl -MCPAN -e shell install AnyEvent::MQTT
For more information on module installation, please visit the detailed CPAN module installation guide.