Skip to main content

Easily display messages on your two-line LCD screen.

Features

  • Network accessible: Posting a message on your screen is as easy as a simple curl command.

  • Automatic rotation: If you send multiple messages to the screen for display, Twoline will rotate through them for you automatically.

  • Automatic paging: Your screen can only show 32 characters at a time? Don’t worry; Twoline will page through your message for you.

  • Easy color and blinking configuration: Every message can have its own color.

  • Message expiration: Can’t be bothered to send a DELETE to remove your message when its no longer relevant? Just set your messages’s expires key and Twoline will automatically remove the message when it’s over.

URLS

/: Index

URL Index

  • GET: Display all endpoints and acceptable methods.

/message/: Messages

List or create a message to add to the message rotation.

  • GET: Get a list of all current messages.

  • POST: Add a new message to the list of messages to cycle through.

/message/<message_id>/: Message Details

Create, delete, or alter an existing message.

  • GET: Get an existing message object for a given ID.

  • PUT: Replace an existing message object for a given ID.

  • PATCH: Update an existing message object for a given ID.

  • DELETE: Delete an existing message object for a given ID.

/flash/: Flash Messages

Short-duration single-time announcements.

  • GET: Get the current flash message (if one exists).

  • PUT: Set the flash message to a given message object.

  • DELETE: Delete the current flash message (if one exists).

/brightness/: Brightness

Screen brightness.

  • PUT: Set brightness.

/contrast/: Contrast

Screen contrast.

  • PUT: Set contrast.

Message Object

{
    'message': 'Until this message disappears, Adam is not yet 30',
    'color': [255, 255, 255], # Optional; set the color
    'blink': [
        [255, 0, 0],
        [0, 0, 0]
    ], # Optional; cycle through these colors
    'expires': '2014-03-02 00:00', # Optional;  The parser -- dateutil --
                                   # is very liberal, but your mileage may
                                   # vary.  If no timezone is specified
                                   # defaults to the local system timezone.
                                   # Can also be an integer number of
                                   # seconds from the current time.
    'interval': 5, # Optional; Only for regular messages;
                   # Number of seconds to display this message before
                   # switching to the next
    'timeout': 300,  # Optional; Only for flash messages;
                     # Number of seconds until message disappears
    'backlight': True,  # Optional; Backlight on or off
}

Simple Curl Example

To post a message to your screen using curl just run a command like the below:

curl -i -X POST -H "Content-Type: application/json" -d '{"message": "Hello World"}' http://127.0.0.1:6224/message/

Pretty easy, huh?!

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

twoline-0.10.tar.gz (9.9 kB view details)

Uploaded Source

File details

Details for the file twoline-0.10.tar.gz.

File metadata

  • Download URL: twoline-0.10.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for twoline-0.10.tar.gz
Algorithm Hash digest
SHA256 6fffda7cf1fbb280234e450f511718de79d3b9a24ae9d216f2814a12567bf8a2
MD5 fd439aac1af94d1eaaac5fa9ced286ab
BLAKE2b-256 1ae30ebf614573580fdc0d10a137c4deed84fb51c555a506bc1717d8cc877f60

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.10 This release

1 file

0.9

1 file

0.8

1 file

0.7.21

1 file

0.7.20

1 file

0.7.19

1 file

0.7.18

1 file

0.7.17

1 file

0.7.16

1 file

0.7.15

1 file

0.7.14

1 file

0.7.13

1 file

0.7.12

1 file

0.7.11

1 file

0.7.9

1 file

0.7.8

1 file

0.7.7

1 file

0.7.6

1 file

0.7.5

1 file

0.7.4

1 file

0.7.3

1 file

0.7.2

1 file

0.7.1

1 file

0.7

1 file

0.6.3

1 file

0.6.2

1 file

0.6.1

1 file

0.6

1 file

0.5

1 file

0.0.1

1 file

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page