Brother PT-P700

  • model: PT-P700
  • serial number: E73121-C7Z848186

  • tape: Brother TZe-tape, 3.5 mm to 24 mm wide (tape widths: 3.5, 6, 9, 12, 18, 24 mm)

  • power adapter: Brother model AD-E001 EU, output 12 V DC 2A, center negative
  • tape raster heights
  • tape printable area
  • 3.5 mm 24 dots (3.40 mm)
  • 6 mm 32 dots (4.50 mm)
  • 9 mm 50 dots (7.50 mm)
  • 12 mm 70 dots (9.90 mm)
  • 18 mm 112 dots (15.8 mm)
  • 24 mm 128 dots (18.1 mm)
  • feed amount (left and right margins): minimum margin 14 dots (2 mm), maximum margin 900 dots (127 mm)
  • minimum length: 31 dots (4.4 mm)
  • maximum length: 7086 dots (1000 mm)

Commands

NULL       00         invalidate
ESC @      1b 40      initialize
ESC i S    1b 69 53   status information request
ESC i a    1b 69 61   switch dynamic command mode
ESC i z    1b 69 7a   print information command
ESC i M    1b 69 4d   various mode settings
ESC i K    1b 69 4b   advanced mode settings
ESC i d    1b 69 64   specify margin amount (feed amount)
M 4d                  select compression mode
g  67                 raster graphics transfer
Z 5a                  zero raster graphics
FF 0c                 print command
Control-Z  1a         print command with feeding

endpoints

ep 1 - in bulk   - max packet size 64 bytes - receive status from printer
ep 2  - out bulk - max packet size 64 bytes - sends printer commands and data from computer to printer

under: Debian,

back to label printers page.

Links

Openprinting.org: ptouch, Linux: ptouch (CUPS + ruby), B-Label, Github: ptouch-print, ptouch-770 and probonopd/ptouch-770, ptouch-php, ptouch-driver, png2ptouch (CUPS + Python), smd_ptouch (CUPS + Perl), python-ptouch-pc (Python for PT-PC RS-232),

crates.io ptouch, github brother-ptouch-label-printer-on-linux, ryankurte/rust-ptouch,

History

2024-11-12: there is a rust ptouch driver on crates.io. For now it supports PT-E550W/P750W/P710BT devices.

2021-07-14: I re-created this page on my self-hosted web server.

2019-09-04: test the newly compiled ptouch-print from

tingo@kg-core2$ pwd
/home/tingo/work/Brother/clarkewd/ptouch-print

help first

tingo@kg-core2$ ./ptouch-print --help
usage: ./ptouch-print [options] <print-command(s)>
options:
    --font <file>        use font <file> or <name>
    --writepng <file>    instead of printing, write output to png file
                This currently works only when using
                EXACTLY ONE --text statement
print-commands:
    --image <file>        print the given image which must be a 2 color
                (black/white) png
    --text <text>        Print 1-4 lines of text.
                If the text contains spaces, use quotation marks
                around it.
    --cutmark        Print a mark where the tape should be cut
    --fontsize        Manually set fontsize

version

tingo@kg-core2$ ./ptouch-print --version
ptouch-print version -ne 7fe3944.dirty by Dominic Radermacher

then try it

tingo@kg-core2$ ./ptouch-print
PT-P700 found on USB bus 0, device 4
error while detaching kernel driver: LIBUSB_ERROR_OTHER

ok, I have seen that message about detaching kernel driver before.

if the printer is powered off

tingo@kg-core2$ ./ptouch-print
No P-Touch printer found on USB (remember to put switch to position E)

so that's interesting.

2019-09-04: I just checked out clarkewd/ptouch-print from Github. Here:

tingo@kg-core2$ pwd
/home/tingo/work/Brother/clarkewd/ptouch-print

now, let me see if I can build it. Needs autoconf, automake,

tingo@kg-core2$ ./autogen.sh
Copying file ABOUT-NLS
Copying file config.rpath
Creating directory m4
Copying file m4/codeset.m4
Copying file m4/extern-inline.m4
Copying file m4/fcntl-o.m4
Copying file m4/gettext.m4
Copying file m4/glibc2.m4
Copying file m4/glibc21.m4
Copying file m4/iconv.m4
Copying file m4/intdiv0.m4
Copying file m4/intl.m4
Copying file m4/intldir.m4
Copying file m4/intlmacosx.m4
Copying file m4/intmax.m4
Copying file m4/inttypes-pri.m4
Copying file m4/inttypes_h.m4
Copying file m4/lcmessage.m4
Copying file m4/lib-ld.m4
Copying file m4/lib-link.m4
Copying file m4/lib-prefix.m4
Copying file m4/lock.m4
Copying file m4/longlong.m4
Copying file m4/nls.m4
Copying file m4/po.m4
Copying file m4/printf-posix.m4
Copying file m4/progtest.m4
Copying file m4/size_max.m4
Copying file m4/stdint_h.m4
Copying file m4/threadlib.m4
Copying file m4/uintmax_t.m4
Copying file m4/visibility.m4
Copying file m4/wchar_t.m4
Copying file m4/wint_t.m4
Copying file m4/xsize.m4
Copying file po/Makefile.in.in
Copying file po/Makevars.template
Copying file po/Rules-quot
Copying file po/boldquot.sed
Copying file po/en@boldquot.header
Copying file po/en@quot.header
Copying file po/insert-header.sin
Copying file po/quot.sed
Copying file po/remove-potcdate.sin
configure.ac:28: installing './compile'
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'
configure.ac:29: installing './install-sh'
configure.ac:30: installing './missing'
Makefile.am: installing './INSTALL'
Makefile.am: error: required file './README' not found
Makefile.am: installing './depcomp'
autoreconf-2.69: automake failed with exit status: 1

hmm, try this

tingo@kg-core2$ echo "dummy" > README

then re-try

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

better. Next step

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb-1.0... no
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb-1.0/libusb.h usability... no
checking libusb-1.0/libusb.h presence... no
checking for libusb-1.0/libusb.h... no
configure: error: libusb headers missing - maybe you need to install package libusb-dev or libusb-devel?

ok, need to tell configure where to find libusb under FreeBSD. For now, I just changed the line in configure.ac from

#AC_CHECK_HEADERS([libusb-1.0/libusb.h], [], [AC_MSG_ERROR([libusb headers missing - maybe you need to install package libusb-dev or libusb-devel?])])

to

AC_CHECK_HEADERS([libusb.h], [], [AC_MSG_ERROR([libusb headers missing - maybe you need to install package libusb-dev or libusb-devel?])])

then re-run autogen.sh

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

and configure

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb-1.0... no
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb.h usability... yes
checking libusb.h presence... yes
checking for libusb.h... yes
checking for ssize_t... yes
checking for uint8_t... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for memset... yes
checking for setlocale... yes
checking for strpbrk... yes
checking for strtol... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

ok, it runs at least. Now try make

tingo@kg-core2$ make
make  all-recursive
Making all in po
test ! -f ./ptouch.pot ||  test -z "de.gmo en.gmo" || make de.gmo en.gmo
rm -f de.gmo && /usr/local/bin/msgfmt -c --statistics --verbose -o de.gmo de.po
de.po: 26 translated messages, 10 untranslated messages.
rm -f en.gmo && /usr/local/bin/msgfmt -c --statistics --verbose -o en.gmo en.po
en.po: 36 translated messages.
touch stamp-po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
In file included from src/ptouch-print.c:29:
./include/ptouch.h:21:10: fatal error: 'libusb-1.0/libusb.h' file not found
#include <libusb-1.0/libusb.h>
         ^~~~~~~~~~~~~~~~~~~~~
1 error generated.
*** Error code 1

Stop.
make[2]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make[1]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print

as expected. Change the line in ptouch.h from

tingo@kg-core2$ grep libusb.h include/ptouch.h
#include <libusb-1.0/libusb.h>

to

tingo@kg-core2$ grep libusb.h include/ptouch.h
#include <libusb.h>

what happens now?

tingo@kg-core2$ make
make  all-recursive
Making all in po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c && mv -f $depbase.Tpo $depbase.Po
cc -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2  -lusb-1.0 -lgd  -o ptouch-print src/ptouch-print.o  src/libptouch.o 
/usr/bin/ld: cannot find -lusb-1.0
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
make[2]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make[1]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print

ok, need to fix that too. Change the line in configre.ac from

#AC_CHECK_LIB([usb-1.0], [libusb_init])

to

AC_CHECK_LIB([usb], [libusb_init])

re-run autogen.sh

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

then configure

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb.h usability... yes
checking libusb.h presence... yes
checking for libusb.h... yes
checking for ssize_t... yes
checking for uint8_t... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for memset... yes
checking for setlocale... yes
checking for strpbrk... yes
checking for strtol... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

ok, make is next

tingo@kg-core2$ make
make  all-recursive
Making all in po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c && mv -f $depbase.Tpo $depbase.Po
cc -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2  -lusb-1.0 -lgd  -o ptouch-print src/ptouch-print.o  src/libptouch.o  -lusb
/usr/bin/ld: cannot find -lusb-1.0
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
make[2]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make[1]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print

hmmm... oh, I forgot to fix everything in Makefile.am

change

tingo@kg-core2$ grep LDFLAGS Makefile.am
ptouch_print_LDFLAGS=-lusb-1.0 -lgd

to

tingo@kg-core2$ grep LDFLAGS Makefile.am
ptouch_print_LDFLAGS=-lusb -lgd

re-try, first autogen.sh

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

then configure

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb.h usability... yes
checking libusb.h presence... yes
checking for libusb.h... yes
checking for ssize_t... yes
checking for uint8_t... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for memset... yes
checking for setlocale... yes
checking for strpbrk... yes
checking for strtol... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

now, try make again

tingo@kg-core2$ make
make  all-recursive
Making all in po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c && mv -f $depbase.Tpo $depbase.Po
cc -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2  -lusb -lgd  -o ptouch-print src/ptouch-print.o  src/libptouch.o  -lusb
/usr/bin/ld: cannot find -lgd
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
make[2]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make[1]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print

ok, ld needs -L. Try this

tingo@kg-core2$ grep LDFLAGS Makefile.am
ptouch_print_LDFLAGS=-L/usr/local/lib -lusb -lgd

and do the whole thing again, starting with autogen.sh

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

configure

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb.h usability... yes
checking libusb.h presence... yes
checking for libusb.h... yes
checking for ssize_t... yes
checking for uint8_t... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for memset... yes
checking for setlocale... yes
checking for strpbrk... yes
checking for strtol... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

then make

tingo@kg-core2$ make
make  all-recursive
Making all in po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c && mv -f $depbase.Tpo $depbase.Po
cc -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2  -L/usr/local/lib -lusb -lgd  -o ptouch-print src/ptouch-print.o  src/libptouch.o  -lusb
src/ptouch-print.o: In function `unsupported_printer':
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:70: undefined reference to `libintl_gettext'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:71: undefined reference to `libintl_gettext'
src/ptouch-print.o: In function `print_img':
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:91: undefined reference to `libintl_gettext'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:92: undefined reference to `libintl_gettext'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:(.text+0x176): undefined reference to `libintl_gettext'
src/ptouch-print.o:/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:152: more undefined references to `libintl_gettext' follow
src/ptouch-print.o: In function `main':
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:405: undefined reference to `libintl_bindtextdomain'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:406: undefined reference to `libintl_textdomain'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:415: undefined reference to `libintl_gettext'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:(.text+0xf24): undefined reference to `libintl_gettext'
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:489: undefined reference to `libintl_gettext'
src/ptouch-print.o: In function `write_png':
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:152: undefined reference to `libintl_gettext'
src/ptouch-print.o: In function `main':
/zs/tingo/work/Brother/clarkewd/ptouch-print/src/ptouch-print.c:445: undefined reference to `libintl_gettext'
src/libptouch.o:/zs/tingo/work/Brother/clarkewd/ptouch-print/src/libptouch.c:(.text+0x124): more undefined references to `libintl_gettext' follow
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
make[2]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make[1]: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print
*** Error code 1

Stop.
make: stopped in /zs/tingo/work/Brother/clarkewd/ptouch-print

ok, libintl_gettext is needed too. So try this

tingo@kg-core2$ grep LDFLAGS Makefile.am
ptouch_print_LDFLAGS=-L/usr/local/lib -lusb -lgd -lintl

re-run all, autogen.sh first

tingo@kg-core2$ ./autogen.sh
Copying file config.rpath
configure.ac:31: installing './config.guess'
configure.ac:31: installing './config.sub'

then configure

tingo@kg-core2$ ./configure --prefix=/usr/local
checking for gcc... no
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking whether cc understands -c and -o together... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether make supports the include directive... yes (GNU style)
checking whether make supports nested variables... yes
checking dependency style of cc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking whether NLS is requested... yes
checking for msgfmt... /usr/local/bin/msgfmt
checking for gmsgfmt... /usr/local/bin/msgfmt
checking for xgettext... /usr/local/bin/xgettext
checking for msgmerge... /usr/local/bin/msgmerge
checking build system type... amd64-unknown-freebsd11.3
checking host system type... amd64-unknown-freebsd11.3
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to run the C preprocessor... cc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for GNU gettext in libc... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... /usr/local/lib/libiconv.so -Wl,-rpath -Wl,/usr/local/lib
checking for GNU gettext in libintl... yes
checking whether to use NLS... yes
checking where the gettext function comes from... external libintl
checking how to link with libintl... /usr/local/lib/libintl.so -Wl,-rpath -Wl,/usr/local/lib
checking for gdImageStringFT in -lgd... no
checking for libusb_init in -lusb... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking gd.h usability... yes
checking gd.h presence... yes
checking for gd.h... yes
checking libusb.h usability... yes
checking libusb.h presence... yes
checking for libusb.h... yes
checking for ssize_t... yes
checking for uint8_t... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for memset... yes
checking for setlocale... yes
checking for strpbrk... yes
checking for strtol... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

then make

tingo@kg-core2$ make
make  all-recursive
Making all in po
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c && mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; cc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -I/usr/local/include -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c && mv -f $depbase.Tpo $depbase.Po
cc -g -std=c11 -Wall -Wextra -Wunused -O3 -I./include -fPIC -g -O2  -L/usr/local/lib -lusb -lgd -lintl  -o ptouch-print src/ptouch-print.o  src/libptouch.o  -lusb

interesting.

2019-08-20: getting back to my old development:

tingo@kg-core2$ pwd
/home/tingo/work/Brother/PT-P700
testing the scripts without a PT-P700 connected
tingo@kg-core2$ python2.7 br-status
No Brother P-Touch printer found

and

tingo@kg-core2$ python2.7 py-find-p700
Traceback (most recent call last):
  File "py-find-p700", line 12, in <module>
    raise ValueError('Our device is not connected')
ValueError: Our device is not connected

connect up the PT-P700, which shows up as this in /var/log/messages

Aug 20 23:18:37 kg-core2 kernel: ugen0.4: <Brother PT-P700> at usbus0
Aug 20 23:18:37 kg-core2 kernel: ulpt0 on uhub1
Aug 20 23:18:37 kg-core2 kernel: ulpt0: <Brother PT-P700, class 0/0, rev 2.00/1.00, addr 3> on usbus0
Aug 20 23:18:37 kg-core2 kernel: ulpt0: using bi-directional mode

try the scripts again

tingo@kg-core2$ python2.7 br-status
Found a Brother PT-P700 at bus <usb.legacy.Bus object at 0x801aefc90>  device <usb.legacy.Device object at 0x801aefd10>
No Brother P-Touch printer found

hmm, better fix that

tingo@kg-core2$ python2.7 br-status
Found a Brother PT-P700 at bus <usb.legacy.Bus object at 0x801aefc90>  device <usb.legacy.Device object at 0x801aefd10>

aah, a bit better. Probably should rewrite for Python3 (python3.6).

tingo@kg-core2$ python2.7 py-find-p700
Brother PT-P700 found
 Config: 1
    interface: 0,altsetting: 0
        ep: 2    (hex: 0x2)
        ep: 129    (hex: 0x81)
Traceback (most recent call last):
  File "py-find-p700", line 25, in <module>
    dev.detach_kernel_driver(0)
  File "/usr/local/lib/python2.7/site-packages/usb/core.py", line 1077, in detach_kernel_driver
    interface)
  File "/usr/local/lib/python2.7/site-packages/usb/backend/libusb1.py", line 902, in detach_kernel_driver
    _check(self.lib.libusb_detach_kernel_driver(dev_handle.handle, intf))
  File "/usr/local/lib/python2.7/site-packages/usb/backend/libusb1.py", line 595, in _check
    raise USBError(_strerror(ret), ret, _libusb_errno[ret])
usb.core.USBError: [Errno None] Other error

ok, it kind of works... or not. Try to comment out the kernel driver and conf setting lines, and let the rest run:

tingo@kg-core2$ python2.7 py-find-p700
Brother PT-P700 found
 Config: 1
    interface: 0,altsetting: 0
        ep: 2    (hex: 0x2)
        ep: 129    (hex: 0x81)
Status from the printer
media width:  24 mm
media type: laminated tape
tape color:  white
text color:  black

much better.

2019-08-19: on PyPi also Labelprinterkit, a Python3 library for creating and printing labels, it supports PT-700.

2019-08-19: the old ptouch-print is gone, clarkewd/ptouch-print seems to be a continuation. There is a EtherGraf/ptouch-print which is tested on PT-2430PC.

2017-07-06: the package from yaha.no arrived into my mailbox.

2017-07-03: I needed tape of different widths and so on to test that I get correct status, so I ordered a few tapes from yaha.no: TZE-N201 (100.-) 3.5mm black on white, YT-TZE221 (79.-) 9mm black on white, YT-TZE631 (79.-) 12mm black on yellow, YT-TZE241 (89.-) 18mm black on white, all are 8 m long. Shipping was 39.- which brought that total to 386.-

2017-06-21: ptouch-print - yes, it is not supported

[tingo@kg-elitebook ptouch-print]$ ./ptouch-print --text "linje 1" "linje 2"
PT-P700 found on USB bus 3, device 8
choosing font size=48
your printer unfortunately is not supported by this tool
the rasterdata a transferred in some other (unknown) format

ok.

2017-06-21: ptouch-print - well, it helps if the printer is turned on. Verify that printer exists:

[tingo@kg-elitebook ptouch-print]$ lsusb -d 04f9:
Bus 003 Device 007: ID 04f9:2061 Brother Industries, Ltd

do we get anything from ptouch-print?

[tingo@kg-elitebook ptouch-print]$ ./ptouch-print
PT-P700 found on USB bus 3, device 7

nice. More info?

[tingo@kg-elitebook ptouch-print]$ ./ptouch-print --info
PT-P700 found on USB bus 3, device 7
maximum printing width for this tape is 128px

cool.

2017-06-20: ptouch-print - simplified build process - clone with git 'autoreconf -i' 'sh configure' 'make' and test

[tingo@kg-elitebook ptouch-print]$ ./ptouch-print
No P-Touch printer found on USB (remember to put switch to position E)
[tingo@kg-elitebook ptouch-print]$ ./ptouch-print --info
No P-Touch printer found on USB (remember to put switch to position E)

ok, it doesn't work yet.

2017-06-20: test ptouch-print get source

[tingo@kg-elitebook Brother]$ git clone https://github.com/dradermacher/ptouch-print.git
Cloning into 'ptouch-print'...
remote: Counting objects: 92, done.
remote: Total 92 (delta 0), reused 1 (delta 0), pack-reused 91
Unpacking objects: 100% (92/92), done.
Checking connectivity... done.

build

[tingo@kg-elitebook Brother]$ cd ptouch-print/
[tingo@kg-elitebook ptouch-print]$ sh configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
configure: error: cannot find install-sh, install.sh, or shtool in "." "./.." "./../.."

try autoreconf

[tingo@kg-elitebook ptouch-print]$ autoreconf
aclocal: warning: couldn't open directory 'm4': No such file or directory
configure.ac:31: warning: macro 'AM_GNU_GETTEXT' not found in library
configure.ac:32: warning: macro 'AM_GNU_GETTEXT_VERSION' not found in library
autoreconf: configure.ac: AM_GNU_GETTEXT_VERSION is used, but not AM_GNU_GETTEXT
configure.ac:31: error: possibly undefined macro: AM_GNU_GETTEXT
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
configure.ac:32: error: possibly undefined macro: AM_GNU_GETTEXT_VERSION
autoreconf: /usr/bin/autoconf failed with exit status: 1

hmm... I installed shtool, try it

[tingo@kg-elitebook ptouch-print]$ shtoolize -o shtool install
Use of assignment to $[ is deprecated at /usr/bin/shtoolize line 60.
Generating shtool...(install 4567/5495 bytes)

retry autoreconf

[tingo@kg-elitebook ptouch-print]$ autoreconf
aclocal: warning: couldn't open directory 'm4': No such file or directory
configure.ac:28: error: required file './compile' not found
configure.ac:28:   'automake --add-missing' can install 'compile'
configure.ac:31: error: required file './config.guess' not found
configure.ac:31:   'automake --add-missing' can install 'config.guess'
configure.ac:31: error: required file './config.rpath' not found
configure.ac:31: error: required file './config.sub' not found
configure.ac:31:   'automake --add-missing' can install 'config.sub'
configure.ac:29: error: required file './install-sh' not found
configure.ac:29:   'automake --add-missing' can install 'install-sh'
configure.ac:30: error: required file './missing' not found
configure.ac:30:   'automake --add-missing' can install 'missing'
Makefile.am: error: required file './INSTALL' not found
Makefile.am:   'automake --add-missing' can install 'INSTALL'
configure.ac:31: error: required file './ABOUT-NLS' not found
Makefile.am: error: required file './depcomp' not found
Makefile.am:   'automake --add-missing' can install 'depcomp'
autoreconf: automake failed with exit status: 1

hmm, try automake

[tingo@kg-elitebook ptouch-print]$ automake --add-missing
configure.ac:28: installing './compile'
configure.ac:31: installing './config.guess'
configure.ac:31: error: required file './config.rpath' not found
configure.ac:31: installing './config.sub'
configure.ac:29: installing './install-sh'
configure.ac:30: installing './missing'
Makefile.am: installing './INSTALL'
configure.ac:31: error: required file './ABOUT-NLS' not found
Makefile.am: installing './depcomp'

ok, getting a bit further.

[tingo@kg-elitebook ptouch-print]$ autoreconf -i
Copying file ABOUT-NLS
Copying file config.rpath
Creating directory m4
Copying file m4/codeset.m4
Copying file m4/extern-inline.m4
Copying file m4/fcntl-o.m4
Copying file m4/gettext.m4
Copying file m4/glibc2.m4
Copying file m4/glibc21.m4
Copying file m4/iconv.m4
Copying file m4/intdiv0.m4
Copying file m4/intl.m4
Copying file m4/intldir.m4
Copying file m4/intlmacosx.m4
Copying file m4/intmax.m4
Copying file m4/inttypes-pri.m4
Copying file m4/inttypes_h.m4
Copying file m4/lcmessage.m4
Copying file m4/lib-ld.m4
Copying file m4/lib-link.m4
Copying file m4/lib-prefix.m4
Copying file m4/lock.m4
Copying file m4/longlong.m4
Copying file m4/nls.m4
Copying file m4/po.m4
Copying file m4/printf-posix.m4
Copying file m4/progtest.m4
Copying file m4/size_max.m4
Copying file m4/stdint_h.m4
Copying file m4/threadlib.m4
Copying file m4/uintmax_t.m4
Copying file m4/visibility.m4
Copying file m4/wchar_t.m4
Copying file m4/wint_t.m4
Copying file m4/xsize.m4
Copying file po/Makefile.in.in
Copying file po/Makevars.template
Copying file po/Rules-quot
Copying file po/boldquot.sed
Copying file po/en@boldquot.header
Copying file po/en@quot.header
Copying file po/insert-header.sin
Copying file po/quot.sed
Copying file po/remove-potcdate.sin

nice. Now run sh configure again, which ends with

configure: creating ./config.status
config.status: creating Makefile
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile

cool. Run 'make'

[tingo@kg-elitebook ptouch-print]$ make
(CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/sh /zs/tingo/work/Brother/ptouch-print/missing autoheader)
rm -f stamp-h1
touch config.h.in
cd . && /bin/sh ./config.status config.h
config.status: creating config.h
config.status: config.h is unchanged
make  all-recursive
make[1]: Entering directory '/zs/tingo/work/Brother/ptouch-print'
Making all in po
make[2]: Entering directory '/zs/tingo/work/Brother/ptouch-print/po'
test ! -f ./ptouch.pot || \
  test -z "de.gmo en.gmo" || make de.gmo en.gmo
make[3]: Entering directory '/zs/tingo/work/Brother/ptouch-print/po'
rm -f de.gmo && /usr/bin/msgfmt -c --statistics --verbose -o de.gmo de.po
de.po: 26 translated messages, 10 untranslated messages.
rm -f en.gmo && /usr/bin/msgfmt -c --statistics --verbose -o en.gmo en.po
en.po: 36 translated messages.
make[3]: Leaving directory '/zs/tingo/work/Brother/ptouch-print/po'
touch stamp-po
make[2]: Leaving directory '/zs/tingo/work/Brother/ptouch-print/po'
make[2]: Entering directory '/zs/tingo/work/Brother/ptouch-print'
depbase=`echo src/ptouch-print.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
gcc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -g -std=c11 -Wall -O3 -I./include -g -O2 -MT src/ptouch-print.o -MD -MP -MF $depbase.Tpo -c -o src/ptouch-print.o src/ptouch-print.c &&\
mv -f $depbase.Tpo $depbase.Po
depbase=`echo src/libptouch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
gcc -DHAVE_CONFIG_H -I.  -DLOCALEDIR='"/usr/local/share/locale"'  -g -std=c11 -Wall -O3 -I./include -g -O2 -MT src/libptouch.o -MD -MP -MF $depbase.Tpo -c -o src/libptouch.o src/libptouch.c &&\
mv -f $depbase.Tpo $depbase.Po
gcc -g -std=c11 -Wall -O3 -I./include -g -O2 -lusb-1.0 -lgd  -o ptouch-print src/ptouch-print.o src/libptouch.o  -lusb-1.0 -lgd
make[2]: Leaving directory '/zs/tingo/work/Brother/ptouch-print'
make[1]: Leaving directory '/zs/tingo/work/Brother/ptouch-print'

that worked.

test ptouch-print

[tingo@kg-elitebook ptouch-print]$ ./ptouch-print --text "linje 1" "linje 2"
No P-Touch printer found on USB (remember to put switch to position E)

ok, it said it didn't support this printer.

2017-06-20: test ptouch-770: get source

[tingo@kg-elitebook Brother]$ git clone https://github.com/abelits/ptouch-770.git
Cloning into 'ptouch-770'...
remote: Counting objects: 10, done.
remote: Total 10 (delta 0), reused 0 (delta 0), pack-reused 10
Unpacking objects: 100% (10/10), done.
Checking connectivity... done.

build

[tingo@kg-elitebook Brother]$ cd ptouch-770/
[tingo@kg-elitebook ptouch-770]$ make
gcc -Wall -O2 -c -o ptouch-770-write.o ptouch-770-write.c
gcc -o ptouch-770-write ptouch-770-write.o  -ludev

test

[tingo@kg-elitebook ptouch-770]$ ./ptouch-770-write
Usage: ./ptouch-770-write <file.pbm>
[tingo@kg-elitebook ptouch-770]$ ./ptouch-770-write tux-128px-bw.pbm
Can't open printer: Permission denied

ok, a permissions problem, After adding my user to the 'lp' group it works:

[tingo@kg-elitebook ptouch-770]$ ./ptouch-770-write tux-128px-bw.pbm

nice.

2017-06-20: I connect it to my Fedora laptop at the office:

[tingo@kg-elitebook ~]$ cat /etc/fedora-release
Fedora release 25 (Twenty Five)
[tingo@kg-elitebook ~]$ uname -a
Linux kg-elitebook.kg4.no 4.11.5-200.fc25.x86_64 #1 SMP Wed Jun 14 17:17:29 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

lsusb says

[tingo@kg-elitebook ~]$ lsusb -d 04f9:
Bus 003 Device 006: ID 04f9:2061 Brother Industries, Ltd

from /var/log/messages

Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: new full-speed USB device number 6 using xhci_hcd
Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: New USB device found, idVendor=04f9, idProduct=2061
Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: Product: PT-P700
Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: Manufacturer: Brother
Jun 20 15:23:40 kg-elitebook kernel: usb 3-1.3: SerialNumber: 000C7Z848186
Jun 20 15:23:40 kg-elitebook mtp-probe: checking bus 3, device 6: "/sys/devices/pci0000:00/0000:00:14.0/usb3/3-1/3-1.3"
Jun 20 15:23:40 kg-elitebook mtp-probe: bus: 3, device: 6 was not an MTP device
Jun 20 15:23:40 kg-elitebook systemd: Starting CUPS Scheduler...
Jun 20 15:23:40 kg-elitebook systemd: Created slice system-configure\x2dprinter.slice.
Jun 20 15:23:40 kg-elitebook systemd: Started Configure Plugged-In Printer.

Jun 20 15:23:40 kg-elitebook kernel: usblp 3-1.3:1.0: usblp0: USB Bidirectional printer dev 6 if 0 alt 0 proto 2 vid 0x04F9 pid 0x2061
Jun 20 15:23:40 kg-elitebook kernel: usbcore: registered new interface driver usblp

Jun 20 15:23:40 kg-elitebook systemd: Started CUPS Scheduler.
Jun 20 15:23:40 kg-elitebook systemd: Reached target Printer.

Jun 20 15:23:45 kg-elitebook cupsd: REQUEST localhost - - "POST / HTTP/1.1" 401 244 CUPS-Get-Devices successful-ok
Jun 20 15:23:45 kg-elitebook cupsd: [cups-deviced] PID 10577 (gutenprint52+usb) stopped with status 1!
Jun 20 15:23:45 kg-elitebook kernel: usblp0: removed
Jun 20 15:23:45 kg-elitebook kernel: usblp 3-1.3:1.0: usblp0: USB Bidirectional printer dev 6 if 0 alt 0 proto 2 vid 0x04F9 pid 0x2061
Jun 20 15:23:45 kg-elitebook cupsd: REQUEST localhost - root "POST / HTTP/1.1" 200 1080 CUPS-Get-Devices -
Jun 20 15:23:49 kg-elitebook cupsd: REQUEST localhost - - "POST / HTTP/1.1" 200 4043981 CUPS-Get-PPDs -
Jun 20 15:23:50 kg-elitebook udev-configure-printer: No ID match for device usb://Brother/PT-P700?serial=000C7Z848186:
Jun 20 15:23:50 kg-elitebook udev-configure-printer: MFG:Brother;MDL:PT-P700;CMD:PT-CBP;
Jun 20 15:23:50 kg-elitebook udev-configure-printer: Using drv:///cupsfilters.drv/textonly.ppd (status: 3)

usb lp device

[tingo@kg-elitebook ~]$ ls -l /dev/usb/lp0
crw-rw----. 1 root lp 180, 0 Jun 20 15:23 /dev/usb/lp0

ok.

2017-06-08: try ptouch-770:

[tingo@localhost Brother]$ pwd
/home/tingo/work/Brother
[tingo@localhost Brother]$ git clone https://github.com/abelits/ptouch-770.git
Cloning into 'ptouch-770'...
remote: Counting objects: 10, done.
remote: Total 10 (delta 0), reused 0 (delta 0), pack-reused 10
Unpacking objects: 100% (10/10), done.
Checking connectivity... done.

try to build it

[tingo@localhost ptouch-770]$ make
gcc -Wall -O2 -c -o ptouch-770-write.o ptouch-770-write.c
ptouch-770-write.c:28:21: fatal error: libudev.h: No such file or directory
 #include <libudev.h>
                     ^
compilation terminated.
Makefile:16: recipe for target 'ptouch-770-write.o' failed
make: *** [ptouch-770-write.o] Error 1

aha. since this is Fedora, I had to install systemd-devel first. Try again

[tingo@localhost ptouch-770]$ make
gcc -Wall -O2 -c -o ptouch-770-write.o ptouch-770-write.c
gcc -o ptouch-770-write ptouch-770-write.o  -ludev

good. Does it work?

[tingo@localhost ptouch-770]$ ./ptouch-770-write
Usage: ./ptouch-770-write <file.pbm>
[tingo@localhost ptouch-770]$ ./ptouch-770-write  --help
Can't open bitmap file

ok, example bitmap files

[tingo@localhost ptouch-770]$ file *pbm
tux-128px-bw-ascii.pbm: Netpbm image data, size = 109 x 128, bitmap, ASCII text
tux-128px-bw.pbm:       Netpbm image data, size = 109 x 128, rawbits, bitmap

try one?

[tingo@localhost ptouch-770]$ ./ptouch-770-write tux-128px-bw-ascii.pbm
Can't open printer: Permission denied

sudo then?

[tingo@localhost ptouch-770]$ sudo ./ptouch-770-write tux-128px-bw-ascii.pbm

and it printed a nice black and white Tux. Cool.

2017-06-08: ptouch-print states that it doesn't work with the PT-P700 yet.

2017-06-08: second test - with the printer powered off, I connect it to my laptop, and the I turn on the printer. Still, both the power indicator and the PLite indicator lights up, and the printer shows up as usb storage. lsusb says:

[tingo@localhost ~]$ lsusb -d 04f9:
Bus 001 Device 007: ID 04f9:2064 Brother Industries, Ltd 
when I press the PLite button for a few seconds, the PLite indicator tuns off, and the usb storage vanishes. From /var/log/messages:
Jun  8 23:20:55 localhost systemd: Created slice system-configure\x2dprinter.slice.
Jun  8 23:20:55 localhost systemd: Started Configure Plugged-In Printer.

Jun  8 23:20:55 localhost kernel: usblp 1-2:1.0: usblp0: USB Bidirectional printer dev 8 if 0 alt 0 proto 2 vid 0x04F9 pid 0x2061
Jun  8 23:20:55 localhost kernel: usbcore: registered new interface driver usblp
Jun  8 23:20:55 localhost systemd: Starting CUPS Scheduler...
Jun  8 23:20:55 localhost dbus-daemon[835]: [system] Activating via systemd: service name='org.freedesktop.ColorManager' unit='colord.service' requested by ':1.222' (uid=0 pid=17452 comm="/usr/sbin/cupsd -l " label="system_u:system_r:cupsd_t:s0-s0:c0.c1023")
Jun  8 23:20:55 localhost systemd: Starting Manage, Install and Generate Color Profiles...
Jun  8 23:20:55 localhost dbus-daemon[835]: [system] Successfully activated service 'org.freedesktop.ColorManager'
Jun  8 23:20:55 localhost systemd: Started Manage, Install and Generate Color Profiles.

Jun  8 23:20:55 localhost colord: (colord:17454): Cd-WARNING **: failed to get session [pid 17452]: No such device or address
Jun  8 23:20:55 localhost systemd: Started CUPS Scheduler.

Jun  8 23:20:55 localhost systemd: Reached target Printer.
Jun  8 23:21:00 localhost cupsd: REQUEST localhost - - "POST / HTTP/1.1" 401 244 CUPS-Get-Devices successful-ok
Jun  8 23:21:00 localhost cupsd: [cups-deviced] PID 17464 (gutenprint52+usb) stopped with status 1!
Jun  8 23:21:00 localhost kernel: usblp0: removed
Jun  8 23:21:00 localhost kernel: usblp 1-2:1.0: usblp0: USB Bidirectional printer dev 8 if 0 alt 0 proto 2 vid 0x04F9 pid 0x2061
Jun  8 23:21:00 localhost cupsd: REQUEST localhost - root "POST / HTTP/1.1" 200 744 CUPS-Get-Devices -
Jun  8 23:21:06 localhost cupsd: REQUEST localhost - - "POST / HTTP/1.1" 200 4045157 CUPS-Get-PPDs -
Jun  8 23:21:07 localhost udev-configure-printer: No ID match for device usb://Brother/PT-P700?serial=000C7Z848186:
Jun  8 23:21:07 localhost udev-configure-printer: MFG:Brother;MDL:PT-P700;CMD:PT-CBP;
Jun  8 23:21:07 localhost udev-configure-printer: Using lsb/usr/cupsfilters/textonly.ppd (status: 3)

(I've edited out all the "audit" crap) anyway, it doesn't show up as a printer, perhaps because cups didn't manage to get a PPD for it.

2017-06-08: first power on - I connect the power adapter, the turn on the printer. The power indicator and the PLite indicator lights up. I use my Fedora laptop for testing, it runs Fedora 24 (F24):

[tingo@localhost ~]$ more /etc/fedora-release
Fedora release 24 (Twenty Four)
[tingo@localhost ~]$ uname -a
Linux localhost.localdomain 4.10.14-100.fc24.x86_64 #1 SMP Wed May 3 19:09:53 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

I plug in the printer to a usb port. It shows up as a usb storage device. From /var/log/messages:

Jun  8 23:03:38 localhost kernel: usb 1-2: new full-speed USB device number 6 using xhci_hcd
Jun  8 23:03:39 localhost kernel: usb 1-2: New USB device found, idVendor=04f9, idProduct=2064
Jun  8 23:03:39 localhost kernel: usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jun  8 23:03:39 localhost kernel: usb 1-2: Product: PT-P700
Jun  8 23:03:39 localhost kernel: usb 1-2: Manufacturer: Brother
Jun  8 23:03:39 localhost kernel: usb 1-2: SerialNumber: 000C7Z848186
Jun  8 23:03:39 localhost mtp-probe: checking bus 1, device 6: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
Jun  8 23:03:39 localhost mtp-probe: bus: 1, device: 6 was not an MTP device
Jun  8 23:03:39 localhost kernel: usb-storage 1-2:1.0: USB Mass Storage device detected
Jun  8 23:03:39 localhost kernel: scsi host3: usb-storage 1-2:1.0
Jun  8 23:03:39 localhost kernel: usbcore: registered new interface driver usb-storage
Jun  8 23:03:39 localhost kernel: usbcore: registered new interface driver uas
Jun  8 23:03:40 localhost kernel: scsi 3:0:0:0: Direct-Access     Brother  PT-P700          0.01 PQ: 0 ANSI: 2
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: Attached scsi generic sg1 type 0
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: [sdb] 8161 512-byte logical blocks: (4.18 MB/3.98 MiB)
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: [sdb] Write Protect is off
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: [sdb] No Caching mode page found
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: [sdb] Assuming drive cache: write through
Jun  8 23:03:40 localhost kernel: sdb: sdb1
Jun  8 23:03:40 localhost kernel: sdb: p1 size 8160 extends beyond EOD, enabling native capacity
Jun  8 23:03:40 localhost kernel: sdb: sdb1
Jun  8 23:03:40 localhost kernel: sdb: p1 size 8160 extends beyond EOD, truncated
Jun  8 23:03:40 localhost kernel: sd 3:0:0:0: [sdb] Attached SCSI removable disk

ok. I mount it (via double-click), it has a FAT filesystem:

[tingo@localhost ~]$ mount | grep PT-P700
/dev/sdb1 on /run/media/tingo/PT-P700 type vfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)

contents:

[tingo@localhost ~]$ ls -l /run/media/tingo/PT-P700
total 1076
-rw-r--r--. 1 tingo tingo     79 Apr  7  2008 AUTORUN.INF
-rw-r--r--. 1 tingo tingo    512 Nov 22  2007 PRTSTATE.STS
-rw-r--r--. 1 tingo tingo 268288 Jul  5  2016 PTBLANK.BIN
drwxr-xr-x. 2 tingo tingo   3584 Jul  5  2016 Ptlite10
-rwxr-xr-x. 1 tingo tingo 783360 Jul  4  2016 PTLITE10.EXE
-rw-r--r--. 1 tingo tingo  45056 Jul 17  2008 PTLITE.PRN
drwxr-xr-x. 3 tingo tingo    512 Jul  5  2016 'P-touch Editor Lite.app'
[tingo@localhost ~]$ ls -l /run/media/tingo/PT-P700/Ptlite10
total 1014
-r--r--r--. 1 tingo tingo 12632 May  1  2014 PRTINFO.INI
-rw-r--r--. 1 tingo tingo  7510 Apr 12  2016 ptemct.ini
-r--r--r--. 1 tingo tingo 11912 Jun  3  2013 PtlLang.ini
-rw-r--r--. 1 tingo tingo 31744 Jul  5  2016 PtlRes10_ARE.dll
-rw-r--r--. 1 tingo tingo 35328 Jul  4  2016 PtlRes10_BGR.dll
-rw-r--r--. 1 tingo tingo 23552 Jul  4  2016 PtlRes10_CHS.dll
-rw-r--r--. 1 tingo tingo 24064 Jul  4  2016 PtlRes10_CHT.dll
-rw-r--r--. 1 tingo tingo 33280 Jul  4  2016 PtlRes10_CRO.dll
-rw-r--r--. 1 tingo tingo 32768 Jul  4  2016 PtlRes10_CZE.dll
-rw-r--r--. 1 tingo tingo 33280 Jul  4  2016 PtlRes10_DAN.dll
-rw-r--r--. 1 tingo tingo 34816 Jul  4  2016 PtlRes10_DUT.dll
-rw-r--r--. 1 tingo tingo 33280 Jul  4  2016 PtlRes10_FIN.dll
-rw-r--r--. 1 tingo tingo 36352 Jul  4  2016 PtlRes10_FRA.dll
-rw-r--r--. 1 tingo tingo 35328 Jul  4  2016 PtlRes10_GER.dll
-rw-r--r--. 1 tingo tingo 29696 Jul  5  2016 PtlRes10_HEB.dll
-rw-r--r--. 1 tingo tingo 34304 Jul  4  2016 PtlRes10_HUN.dll
-rw-r--r--. 1 tingo tingo 35328 Jul  4  2016 PtlRes10_ITA.dll
-rw-r--r--. 1 tingo tingo 25600 Jul  4  2016 PtlRes10_JPN.dll
-rw-r--r--. 1 tingo tingo 26112 Jul  4  2016 PtlRes10_KOR.dll
-rw-r--r--. 1 tingo tingo 32768 Jul  4  2016 PtlRes10_NOR.dll
-rw-r--r--. 1 tingo tingo 33280 Jul  4  2016 PtlRes10_POL.dll
-rw-r--r--. 1 tingo tingo 35328 Jul  4  2016 PtlRes10_POR.dll
-rw-r--r--. 1 tingo tingo 34816 Jul  4  2016 PtlRes10_PTB.dll
-rw-r--r--. 1 tingo tingo 34304 Jul  4  2016 PtlRes10_ROM.dll
-rw-r--r--. 1 tingo tingo 33792 Jul  4  2016 PtlRes10_RUS.dll
-rw-r--r--. 1 tingo tingo 35328 Jul  4  2016 PtlRes10_SPA.dll
-rw-r--r--. 1 tingo tingo 33792 Jul  4  2016 PtlRes10_SVK.dll
-rw-r--r--. 1 tingo tingo 33280 Jul  4  2016 PtlRes10_SVN.dll
-rw-r--r--. 1 tingo tingo 32768 Jul  4  2016 PtlRes10_SWE.dll
-rw-r--r--. 1 tingo tingo 31744 Jul  4  2016 PtlRes10_THA.dll
-rw-r--r--. 1 tingo tingo 32768 Jul  4  2016 PtlRes10_TUR.dll
-rw-r--r--. 1 tingo tingo 32256 Jul  4  2016 PtlRes10_UK.dll
-rw-r--r--. 1 tingo tingo 32256 Jul  4  2016 PtlRes10_US.dll
-rw-r--r--. 1 tingo tingo 32256 Jul  4  2016 PtlRes10_VIT.dll

doesn't look like useful stuff. It has Mac stuff too, also not useful.

2017-06-08: contents: PT-P700 printer, power adapter (Brother model AD-E001 EU), usb cable (usb A - Mini-B), 1 x sample tape cassette (TZe-251 SAMPLE) laminated 24mm wide, drivers CD-ROM, documentation.

2017-06-08: It got a pick up message (SMS) from Posten, and got the package from PIB Extra Trondheimsveien on my way home from the office.

2017-06-07: Posten sent me a message: the package is on its way.

2017-06-06: Multicom sent me a message; my order is packed and ready for shipping.

2017-05-30: I ordered a Brother PT-P700 from Multicom (PTP700) for NOK 485.- plus NOK 79.- in shipping (a total of NOK 564.-).