Data::Coloured - Visualize random ASCII data streams
use DDC; my $coloured = coloured($data); my $coloured = c($data); poloured($data); # print coloured pc($data); # same use Data::Coloured; # no auto export of pc and c
This module is made for visualizing in coloured and printable form random bytes of a data stream or any other source. It was specifically made for debugging TCP and UART connections, to also see the control characters.
This module does the following with the data for return or print:
- Control characters
The ASCII control characters are described on Wikipedia. Those get replaced with their name listed in "Abbreviation" on the Wikipedia page, surrounded by square brackets (exception is here HT which is shown as TAB). The ANSI colour is bright_red
- Printable characters
The prinatable characters (from space to ~) are just taken as is, and put in the colour bright_yellow.
- Binary characters / extended ASCII
All non printable characters, so those above 127, are converted into their hex value and surrounded by angle brackets.
Join #vonbienenstock on irc.freenode.net. Highlight Getty for fast reaction :).
http://github.com/Getty/p5-data-coloured Pull request and additional contributors are welcome
Torsten Raudssus <email@example.com>
This software is copyright (c) 2014 by Torsten Raudssus.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.