Als pdf oder txt herunterladen
Als pdf oder txt herunterladen
Sie sind auf Seite 1von 57

Raspberry Pi Pico Schnelleinstieg mitp

Professional German Edition Thomas


Brühlmann
Visit to download the full and correct content document:
https://ebookstep.com/product/raspberry-pi-pico-schnelleinstieg-mitp-professional-ger
man-edition-thomas-bruhlmann/
More products digital (pdf, epub, mobi) instant
download maybe you interests ...

■■■■■■■■■ ■■■ Raspberry Pi ■■■■■■■■■■■■ ■■■■■■■■■


Edition ■■■■ ■■■■

https://ebookstep.com/download/ebook-44570984/

Raspberry Pi Przewodnik u■ytkownika 3rd Edition Eben


Upton Gareth Halfacree Konrad Matuk

https://ebookstep.com/product/raspberry-pi-przewodnik-
uzytkownika-3rd-edition-eben-upton-gareth-halfacree-konrad-matuk/

Internet das Coisas com ESP8266 Arduino e Raspberry Pi


1st Edition Sérgio De Oliveira

https://ebookstep.com/product/internet-das-coisas-com-
esp8266-arduino-e-raspberry-pi-1st-edition-sergio-de-oliveira/

Baukosten sicher ermitteln Mit Praxisbeispiel


Mehrfamilienhaus Schnelleinstieg für Architekten und
Bauingenieure essentials German Edition Scholz

https://ebookstep.com/product/baukosten-sicher-ermitteln-mit-
praxisbeispiel-mehrfamilienhaus-schnelleinstieg-fur-architekten-
und-bauingenieure-essentials-german-edition-scholz/
■■■■■■■■■ ■■■ Raspberry Pi ■■■■■■■■■■■■ ■■■■■■■■■
■■■■■■■■■■ ■■■■■■■■■■■■■ ■■■■ ■■■■ ■■■■■■■ ■
■■■■■■■■■■■ ■■■■■■■ ■■■■■■■■

https://ebookstep.com/download/ebook-46098264/

Pi und die Primzahlen: Eine Entdeckungsreise in die


Mathematik (German Edition) Edmund Weitz

https://ebookstep.com/product/pi-und-die-primzahlen-eine-
entdeckungsreise-in-die-mathematik-german-edition-edmund-weitz/

Raspberry Pi dein Einstieg Der vielseitige Linux


Computer für Smarthome Entertainment Experimente 4th
Edition Matt Richardson & Shawn Wallace & Wolfram Donat

https://ebookstep.com/product/raspberry-pi-dein-einstieg-der-
vielseitige-linux-computer-fur-smarthome-entertainment-
experimente-4th-edition-matt-richardson-shawn-wallace-wolfram-
donat/

Sisis schöne Leichen Kaiserin Elisabeth ermittelt


German Edition Thomas Brezina

https://ebookstep.com/product/sisis-schone-leichen-kaiserin-
elisabeth-ermittelt-german-edition-thomas-brezina/

Basiswissen Usability und User Experience Aus und


Weiterbildung zum UXQB Certified Professional for
Usability and User Experience 2nd Edition Thomas Geis

https://ebookstep.com/product/basiswissen-usability-und-user-
experience-aus-und-weiterbildung-zum-uxqb-certified-professional-
for-usability-and-user-experience-2nd-edition-thomas-geis/
Thomas Brühlmann

Raspberry Pi Pico
Schnelleinstieg
Impressum

Bibliografische Information der Deutschen Nationalbibliothek


Die Deutsche Nationalbibliothek verzeichnet diese Publikation in der Deutschen
Nationalbibliografie; detaillierte bibliografische Daten sind im Internet über
<http://dnb.d-nb.de> abrufbar.
ISBN 978-3-7475-0379-9
1. Auflage 2021
www.mitp.de

E-Mail: [email protected]
Telefon: +49 7953 / 7189 - 079
Telefax: +49 7953 / 7189 - 082
© 2021 mitp Verlags GmbH & Co. KG
Dieses Werk, einschließlich aller seiner Teile, ist urheberrechtlich geschützt. Jede
Verwertung außerhalb der engen Grenzen des Urheberrechtsgesetzes ist ohne
Zustimmung des Verlages unzulässig und strafbar. Dies gilt insbesondere für
Vervielfältigungen, Übersetzungen, Mikroverfilmungen und die Einspeicherung und
Verarbeitung in elektronischen Systemen.
Die Wiedergabe von Gebrauchsnamen, Handelsnamen, Warenbezeichnungen usw.
in diesem Werk berechtigt auch ohne besondere Kennzeichnung nicht zu der
Annahme, dass solche Namen im Sinne der Warenzeichen- und Markenschutz-
Gesetzgebung als frei zu betrachten wären und daher von jedermann benutzt
werden dürften.
Lektorat: Sabine Schulz
Sprachkorrektorat: Petra Heubach-Erdmann
Covergestaltung: Janina Bahlmann, Christian Kalkert
Coverbild: Thomas Brühlmann
Electronic Publishing: Petra Kleinwegen
Dieses Ebook verwendet das ePub-Format und ist optimiert für die Nutzung mit
dem iBooks-reader auf dem iPad von Apple. Bei der Verwendung anderer Reader
kann es zu Darstellungs­problemen kommen.
Hinweis des Verlages zum Urheberrecht und Digitalen Rechtemanagement (DRM)
Der Verlag räumt Ihnen mit dem Kauf des ebooks das Recht ein, die Inhalte im
Rahmen des gel­tenden Urheberrechts zu nutzen. Dieses Werk, einschließlich aller
seiner Teile, ist urheberrechtlich geschützt. Jede Verwertung außerhalb der engen
Grenzen des Urheherrechtsgesetzes ist ohne Zustimmung des Verlages unzulässig
und strafbar. Dies gilt insbesondere für Vervielfälti­gungen, Übersetzungen,
Mikroverfilmungen und Einspeicherung und Verarbeitung in elektroni­schen
Systemen.
Der Verlag schützt seine ebooks vor Missbrauch des Urheberrechts durch ein
digitales Rechtemanagement. Bei Kauf im Webshop des Verlages werden die
ebooks mit einem nicht sichtba­ren digitalen Wasserzeichen individuell pro Nutzer
signiert.
Bei Kauf in anderen ebook-Webshops erfolgt die Signatur durch die Shopbetreiber.
Angaben zu diesem DRM finden Sie auf den Seiten der jeweiligen Anbieter.
Inhalt

Impressum

Kapitel 1
Das Board
1.1 Die Leiterplatte
1.2 Anschlüsse
1.3 Spannungsversorgung

Kapitel 2
Die Software
2.1 Thonny-Entwicklungsumgebung (IDE)
2.1.1 Installation von Thonny
2.1.2 Konfiguration von Thonny
2.2 MicroPython
2.2.1 MicroPython für Raspberry Pi Pico
2.2.2 Installation von MicroPython
2.2.3 MicroPython in Thonny IDE

Kapitel 3
Erste Schritte
3.1 Erstes Programm
3.2 Projekt »Blink LED«
3.3 Programmaufbau
3.4 Steckbrett und Elektronik
3.4.1 Steckbrett
3.4.2 Bauteile der Elektronik

Kapitel 4
Digitale Ein- und Ausgänge
4.1 Ein- und Ausgänge am Pico
4.2 Eingang einlesen
4.2.1 Pullup oder Pulldown
4.3 Praxisbeispiel: Taster einlesen und Status ausgeben
4.4 LED ansteuern
4.5 PWM
4.5.1 Praxisbeispiel: LED mit PWM
4.6 Servo
4.6.1 Praxisbeispiel: Servo mit Potentiometer
4.7 Transistor, Relais
4.7.1 Transistor
4.7.2 Relais
4.8 Motor
4.8.1 Einfache Motor-Stufe (ein Motor)
4.8.2 Motor-Treiber für zwei Motoren
4.8.3 Praxisbeispiel: Motor-Ansteuerung (1 Motor)
4.8.4 Praxisbeispiel: Motor-Ansteuerung (2 Motoren)
4.8.5 Praxisbeispiel: Mini-Roboter

Kapitel 5
Analoge Welt
5.1 Spannung einlesen
5.1.1 Praxisbeispiel: Messung mit dem internen
Temperatursensor
5.2 Praxisbeispiel: Poti mit LED-Ampel
5.3 Praxisbeispiel: Lichtmesser mit LDR
5.4 Praxisbeispiel: Temperaturmessung mit NTC

Kapitel 6
Anzeigen
6.1 RGB-LED
6.2 LC-Display (LCD)
6.3 OLED-Display
6.4 Projekt: Wetterstation mit Umweltsensor DHT22

Kapitel 7
Schnittstellen
7.1 UART
7.1.1 Praxisbeispiel: Datenaustausch mit Arduino
7.2 I2C
7.2.1 I2C-Bus auf dem Pico
7.2.2 Definition I2C mit MicroPython
7.2.3 I2C-Scanner
7.3 Praxisbeispiel: Lichtmesser mit BH1750

Kapitel 8
Programm-Erweiterungen
8.1 Bibliotheken
8.2 Programmable Input and Output (PIO)
8.2.1 Praxisbeispiel: Blink mit State Machine
8.2.2 Praxisbeispiel: Blinker als Alarmmelder
Kapitel 9
Pinout und Boards
9.1 Pico-Pinout und Beschreibung
9.2 Technische Daten
9.3 RP2040-Boards
9.3.1 Sparkfun
9.3.2 Arduino
9.3.3 Adafruit
9.3.4 PIMORONI
9.4 Hardware-Erweiterungen
9.4.1 Reset-Schalter
9.4.2 Pico-Pinout-Board für Steckbrett

Kapitel 10
Stücklisten
Einführung

Im Januar 2021 hat eine News-Meldung die Maker- und Bastlerszene


überrascht. Die Raspberry Pi Foundation, also die Organisation, die
den bisher bekannten Minicomputer Raspberry Pi entwickelt hat,
präsentierte ein neues Mitglied in ihrer Produkte-Reihe. Willkommen
Raspberry Pi Pico!
Die Vorstellung des neuen Raspberry Pi Pico, in diesem Buch in der
Kurzform »Pico«, wurde unbemerkt im Hintergrund vorbereitet und
nur wenige Hardware-Hersteller aus dem Maker-Umfeld waren
informiert. Zu diesen Anbietern gehören Adafruit, Sparkfun, Arduino
und Pimoroni. Diese Hardware-Firmen präsentieren mit der
Vorstellung des Pico gleichzeitig eigene kompatible Boards und
Lösungen. Diese Lösungen sind zum aktuellen Zeitpunkt (März 2021)
noch in Entwicklung. Die bisher präsentierten Informationen zu den
neuen Boards werden viele Maker, Bastler und Microcontroller-Board-
Anwender erfreuen.
Dank der zeitlich geplanten Vorstellung des Pico ist das neue
Microcontroller-Board bereits bei einzelnen Händlern und Online-
Shops verfügbar. Abonnenten und Käufer der Ausgabe 39 der
englischen Bastlerzeitschrift HackSpace (http://hsmag.cc) erhielten
zusätzlich zur Zeitschrift ein Pico-Board. Leider war diese Aktion breit
gefächert nur auf der englischen Insel verfügbar. Glückliche Besitzer
haben sich vielleicht auch an einem Zeitschriftenshop auf einem
Flughafen eine Ausgabe mit Board sichern können.
Da Sie dieses Buch gekauft haben, gehören Sie vermutlich auch zur
Maker-Community und interessieren sich für das neue Board der
Raspberry Pi Foundation und möchten gerne interaktive
Anwendungen mit Schalter, Anzeigen, Motoren usw. realisieren.
Möglicherweise haben Sie bereits erste Erfahrungen mit
Microcontrollern wie Arduino gemacht.
Der neue Raspberry Pi Pico ist im Gegensatz zu seinen Geschwistern
aus der Raspberry-Serie kein Minicomputer mit Betriebssystem,
sondern ein kleines, kompaktes Microcontroller-Board, auf dem
Programme in MicroPython oder C/C++ ausgeführt werden können.
Mit der Vorstellung des Pico sind die News aber noch nicht fertig
erzählt. Neben dem neuen Microcontroller-Board gibt es auch einen
neuen Microcon­troller. Auf dem Pico wird ein eigener, von der
Raspberry Pi Foundation entwickelter Chip eingesetzt – der
Microcontroller hat die Bezeichnung RP2040.
Diese spannenden Neuigkeiten bringen wieder Schwung in die
Maker-Szene. Ein neues Microcontroller-Board, das einen solch
markanten Eindruck in der Szene und in den sozialen Medien
hinterlässt, erscheint nicht täglich. Obwohl erst kurze Zeit seit der
Präsentation des Pico vergangen ist, findet man auf den bekannten
sozialen Plattformen wie Twitter, YouTube und Hackaday schon eine
ganze Menge an nützlichen Informationen, Beispielen und Tutorials.
Täglich kommen neue Projekte dazu und erweitern so die
Möglichkeiten des kleinen Boards.
Dieser kompakte Guide soll Sie beim Einstieg ins Thema Raspberry
Pi Pico und MicroPython unterstützen. Idealerweise haben Sie schon
mit anderen Microcontroller-Boards gearbeitet und schon
Grundkenntnisse in Python oder einer anderen Programmiersprache.
Das Buch ist so aufgebaut, dass Sie die Kapitel nacheinander
durcharbeiten können.
In Kapitel 1 wird der Raspberry Pi Pico vorgestellt, die Anschlüsse
erklärt und die technischen Daten und Funktionen vorgestellt.
In Kapitel 2 wird die Firmware der Programmiersprache MicroPython,
eine kompakte und abgespeckte Version von Python, installiert.
Anschließend wird die Entwicklungsumgebung Thonny installiert und
konfiguriert. Nach dem Verbindungsaufbau zwischen der
Entwicklungsumgebung und dem Pico steht die nötige Infrastruktur
bereit.
Das erste Programm, im Hardware-Umfeld ein Blink-Programm, wird
in Kapitel 3 erstellt und auf den Pico geladen. Anschließend werden
die Struktur der Programme und der Programmaufbau erklärt.
Gleichzeitig werden die nötige Elektronik und Hardware, die für die
nachfolgenden Beispiele verwendet werden, erläutert.
Das Kapitel 4 beschreibt den Einsatz der digitalen Ein- und Ausgänge
des Pico. In praktischen Beispielen werden die Zustände von Tastern
eingelesen und Leuchtdioden, Servos und Relais angesteuert.
Die analoge Welt mit den integrierten Analog/Digital-Wandlern wird
in Kapitel 5 vorgestellt. Analoge Sensoren wie Fotowiderstand und
Temperatursensor werden in Betrieb genommen.
In Kapitel 6 werden Anzeige-Elemente eingesetzt. Zuerst wird eine
Leuchtdiode als optisches Element über eine Dimm-Funktion
angesteuert. Anschließend erklären Praxisbeispiele den Einsatz von
LC- und OLED-Displays. Zum Schluss wird eine kleine Wetterstation
realisiert.
Kapitel 7 beschreibt den Einsatz der seriellen Schnittstelle (UART)
und des I2C-Bus. In einem Praxisprojekt wird ein Lichtmesser
realisiert.
In Kapitel 8 werden Programmerweiterungen wie die State-Machine
und Module und Bibliotheken beschrieben.
Kapitel 9 beinhaltet technische Themen wie die Beschreibung des
Pinouts und der einzelnen Anschluss-Pins sowie technische Daten
zum Pico und dem M ­ icrocontroller RP2040.
Alle Stücklisten zu den einzelnen Projekten werden in Kapitel 10
bereitgestellt.

Weitere Informationen
Weitere Informationen zum Buch und zu den Projekten mit dem
Raspberry
Pi Pico sind auf meiner Website erhältlich:
https://555circuitslab.com
Die Beispielprogramme aus dem Buch können über meinen Github-
Account bezogen werden:
https://github.com/arduinopraxis
Auf meiner Website findet man auch weitere Informationen zu
meinen Microcontroller-Projekten wie auch Details zu meinen
Büchern über die Themen Arduino und Sensoren.
Auf der Website des Verlages sind Informationen zu diesem Buch
unter folgender Adresse verfügbar:
https://mitp.de/0377

Kontakt zum Autor


Anregungen, Rückmeldungen und Fragen können Sie über Twitter
oder per E-Mail an mich senden.
E-Mail: [email protected]
Twitter: https://twitter.com/arduinopraxis

Danksagung
Ein großer Dank geht an meine Familie, meine Frau Aga und meine
Jungs Tim und Nik. Auch bei diesem Buchprojekt haben sie mir
wieder den nötigen Freiraum gegeben.
Herzlichen Dank an meine Lektorin Sabine Schulz für den
unkomplizierten und schnellen Ablauf bei der Entstehung dieses
Buchprojekts.
Im Mai 2021
Thomas Brühlmann
Kapitel 1
Das Board

In diesem Kapitel werden die Hardware des Raspberry Pi Pico, die


Anschlüsse und die Spannungsversorgung beschrieben.

1.1 Die Leiterplatte


Der Raspberry Pi Pico ist das bisher kleinste Board der Raspberry-Pi-
Familie und hat eine Größe von 50 x 20 mm. Der Pico wird als kleine
Leiterplatte mit seitlichen Anschlüssen geliefert. In Abbildung 1.1 ist
der Raspberry Pi Pico zu sehen.

Abb. 1.1: Raspberry Pi Pico

Die wichtigsten Komponenten des Raspberry Pi Pico sind in


Abbildung 1.2 farbig dargestellt.
Abb. 1.2: Raspberry Pi Pico – Komponenten des Boards

Microcontroller
Die Zentraleinheit, also das Gehirn des Pico, ist der Microcontroller
vom
Typ RP2040. Dieser Microcontroller wurde von der Raspberry Pi
Foundation eigens für dieses neue Board entwickelt. Die technischen
Daten zum Board und dem Microcontroller sind in Kapitel 9
beschrieben.
Im Gegensatz zu den bisherigen Raspberry-Pi-Boards kann auf dem
Pico kein Betriebssystem betrieben werden. Auf den Microcontroller
wird eine Firm­ware geladen, die anschließend einzelne Programme
ausführt. In diesem Buch wird der Einsatz von MicroPython
beschrieben.

Ein- und Ausgänge


Über die goldenen Anschlusspads oder Lötflächen auf den
Längsseiten können die externen Bauteile angeschlossen werden.
Dabei kann ein einzelner Anschlussdraht oder eine Stiftleiste
angelötet werden.
In der Praxis lohnt sich das Anlöten einer 20-poligen Stiftleiste.
Dabei werden die Anschluss-Pins von der Unterseite des Pico
aufgesteckt und an der Oberseite der Leiterplatte angelötet. In
Abbildung 1.3 sind die Stiftleisten angelötet. Anschließend wurde der
Pico auf ein Steckbrett aufgesteckt.
Das Anlöten von Stiftleisten für den Einsatz auf einem Steckbrett
kennen Sie vielleicht schon von anderen Microcontroller-Boards wie
dem Arduino Nano.
Die Anschlussbelegung des Pico ist im nachfolgenden Abschnitt
beschrieben.

Abb. 1.3: Raspberry Pi Pico mit Stiftleisten auf Steckbrett


USB-Anschluss
Mit dem Anschließen eines USB-Kabels an den USB-Anschluss
(Micro-USB-Typ B) wird der Raspberry Pi Pico mit Spannung
versorgt. Gleichzeitig erfolgt über diese USB-Verbindung der
Datenaustausch vom Pico zum angeschlossenen Rechner. Dazu
gehört auch das Hochladen von neuen Programmen auf den Pico.

Onboard-LED
Die Onboard-LED ist intern am Ausgangspin GP25 des RP2040
angeschlossen und kann für Statusanzeigen verwendet werden.

Boot-Selektor
Der Boot-Selektor ist ein Drucktaster zur Selektion des Startmodus.
Der Boot-Selektor wird später noch verwendet und beschrieben.

Debug-Schnittstelle
Die drei Anschluss-Pads mit der Bezeichnung Debug sind für die
fortgeschrittene Fehlersuche, das sogenannte Debugging,
herausgeführt. Die Schnittstelle wird als ARM-Serial-Wire-Debug-
(SWD-)Schnittstelle bezeichnet. Die Verwendung dieser Schnittstelle
ist in diesem Buch nicht beschrieben.

1.2 Anschlüsse
Die Anschluss-Pins des Pico sind an allen vier Seiten der Leiterplatte
angeordnet. An den Längsseiten findet man alle Ein- und Ausgänge,
um externen Komponenten wie Schalter, Taster, Leuchtdioden,
Sensoren oder Anzeigen anzuschließen.
In Abbildung 1.4 ist die Anschlussbelegung (Pinout) mit den
verschiedenen Funktionen der einzelnen Pins dargestellt. Die
Funktionen werden zusätzlich mit einzelnen Farben gezeigt. Die Ein-
und Ausgänge für übliche GPIO-­Funktionen, also allgemeine Ein-
und Ausgänge, sind hellgrün. Die vier analogen Eingänge sowie die
interne Referenzspannung sind dunkelgrün markiert.

Abb. 1.4: Pico – Anschlussbelegung (Quelle: Website Raspberry Pi Foundation)

Durch die vielen Anschluss-Pins und die verschiedenen Funktionen


muss beim Anstecken einer Drahtverbindung immer genau geprüft
werden, ob man den richtigen Pin verwendet. Leider ist die
Pinbelegung nur auf der Rückseite des Raspberry Pi Pico aufgedruckt
( Abbildung 1.5).
Abb. 1.5: Anschlussbelegung auf Rückseite

Wie bereits im vorherigen Abschnitt erwähnt, empfiehlt es sich, zwei


20-polige Stiftleisten an den seitlichen Anschlusspads anzulöten.
Ich habe mir für die sichtbare Anzeige der Anschlussbelegung eine
kleine Leiterplatte entwickelt. Diese kann von unten an die Stiftleiste
angeschlossen werden (Abbildung 1.6).
Abb. 1.6: Leiterplatte mit Anschlussbelegung

Stückliste (Anschluss-Pins)
1 Raspberry Pi Pico
2 Stiftleisten 1 x 20 Pin
Lötzinn
Lötkolben (30 bis 50 Watt)
Im ersten Schritt wird das Board von oben auf die Stiftleisten
gesteckt.
Als Hilfe für die Positionierung der Stiftleisten kann auch eine
unbestückte Lochrasterplatine verwendet werden( Abbildung 1.7).
Anschließend lötet man je einen Pin der beiden Stiftleisten von oben
an. Um die Stiftleiste gerade zu zentrieren, muss man allenfalls den
Pin nochmals erhitzen und mit der Hand die Position korrigieren.
Bevor man nun alle Pins der Stiftleiste anlötet, kann man das Board
auf ein Steckbrett platzieren und so prüfen, ob die Stiftleisten
geradestehen.
Beim Anlöten der Stiftleiste dürfen die Lötpads nicht zu lange erhitzt
werden, da andernfalls aufgelötete Bauteile auf der Leiterplatte des
Pico durch die Hitze verschoben werden.

Abb. 1.7: Stiftleisten anlöten

In vielen Tutorials und Anleitungen wird beschrieben,


dass man die Stiftleisten am Pico anlöten soll, wenn
diese im Steckbrett eingesteckt sind. Ich empfehle
diese Variante nicht, da beim Löten Hitze entsteht, die
den Kunststoff des Steckbretts angreifen kann. Falls
man ein Steckbrett zur Verfügung hat, das nur für
Lötarbeiten verwendet wird, kann diese Lösung
trotzdem verwendet werden.

Für den praktischen Einsatz und für die Entwicklung von


Anwendungen kann der Pico auch auf eine stabile Grundplatine
gesteckt werden.
Zum aktuellen Zeitpunkt (März 2021) stehen aber erst wenige
solcher Lösungen zur Verfügung. Als Beispiel kann das Grove Shield
für Pi Pico von Seeedstudio erwähnt werden (Abbildung 1.8):
https://www.seeedstudio.com/Grove-Shield-for-Pi-
Pico-v1-0-p-4846.html

Abb. 1.8: Grove Shield für Pi Pico (Bild Seeedstudio)

Für meine Anwendungen habe ich ein kleines Protoboard mit


Stiftleisten für den Pico sowie vielen freien Lötpads erstellt
(Abbildung 1.9).
Abb. 1.9: Protoboard für Pico

Die Leiterplatte ist in meinem Shop verfügbar:


https://www.tindie.com/products/23201/

1.3 Spannungsversorgung
Auf dem Raspberry Pi Pico ist eine Spannungsversorgungsschaltung
aufgebaut, die die internen 3,3 V generiert. Die Eingangsspannung
für diese Versorgung kann dabei im Bereich von 1,8 V bis 5,5 V
liegen.
Durch diesen großen Spannungsbereich kann der Raspberry Pi Pico
zukünftig auch mit einem einzelnen Lipo-Akku oder über mehrere
AA-Batterien versorgt werden.
Falls der Pico über eine externe Spannungsquelle versorgt wird,
muss die Versorgungsspannung über den Anschluss VSYS zugeführt
werden.
Für fortgeschrittene Anwender sind dazu im Datenblatt des
Raspberry Pi Pico etliche Anwendungs-Beispiele beschrieben.
Kapitel 2
Die Software

In diesem Kapitel wird die Entwicklungsumgebung Thonny IDE


installiert und die Firmware MicroPython auf den Raspberry Pi Pico
geladen. Anschließend kann das erste MicroPython-Programm auf
den Pico geladen werden.
MicroPython ist nur eine Option, wenn es um die Programmierung
von ­Microcontroller-Boards geht. Weitere mögliche
Programmiersprachen sind C/C++ oder CircuitPython.
In diesem Buch wird MicroPython, das von der Raspberry Pi
Foundation als Python-Variante gewählt wurde, installiert und mit
vielen Beispielen beschrieben.

2.1 Thonny-Entwicklungsumgebung
(IDE)
Die Software Thonny ist eine einfache und beliebte
Entwicklungsumgebung, in Englisch IDE (Integrated Development
Environment) genannt, für die Programmierung von Python und
MicroPython.
Die Software kann kostenlos von der Thonny-Website geladen
werden.

2.1.1 Installation von Thonny


Gehen Sie auf die Website thonny.org und laden Sie sich die Thonny-
Version für Ihr Betriebssystem herunter. Zum aktuellen Zeitpunkt ist
dies die Version 3.3.3.
Falls Sie planen, die Pico-Entwicklung auf einem Raspberry Pi mit
Raspberry Pi OS auszuführen, müssen Sie nichts unternehmen.
Thonny ist nämlich bereits auf dem System installiert.
Andernfalls installieren Sie nach dem Download Thonny auf Ihrem
System, indem Sie den Anweisungen des Installers folgen.
Nachdem die Software installiert ist, kann die Thonny IDE gestartet
werden. Die Entwicklungsumgebung öffnet sich mit einem leeren
Codefenster. Unterhalb der Menüpunkte ist der Bereich der Code-
Eingabe (grün markiert) angeordnet. Unterhalb des Code-Bereichs
liegt die Shell (rot markiert). Über die Shell können Code-
Anweisungen direkt ausgeführt werden und gleichzeitig werden in
der Shell Status-Meldungen und Informationen ausgegeben
(Abbildung 2.1). In der Standard-Einstellung nach der Installation
wird die Python-Version angegeben.
Abb. 2.1: Thonny-Entwicklungsumgebung

2.1.2 Konfiguration von Thonny


Nach der erfolgreichen Installation von Thonny öffnet sich die
Anwendung mit einem leeren Code-Blatt. Als Standard-Interpreter ist
Python 3.7 eingestellt, was man über die Shell unterhalb des
Codefensters erkennen kann.
Mit der Eingabe einer Testzeile in der Shell kann Python getestet
werden.
Geben Sie
print("Hello Python")

ein und es wird eine Python-Ausgabe des Textes ausgeführt


(Abbildung 2.2).

Abb. 2.2: Thonny IDE – Test Python

Nun muss noch der MicroPython-Interpreter für Pico eingestellt


werden.
Gehen Sie im Hauptmenü auf Run|Select interpreter und wählen Sie
den Interpreter für den Pico aus (Abbildung 2.3).
Abb. 2.3: Thonny IDE – Interpreter MicroPython für Pico

Unter der Auswahl Port kann der Port eines angeschlossenen


Raspberry Pi Pico ausgewählt werden.
Nach Bestätigen mit OK ist die Installation von Thonny
abgeschlossen.

2.2 MicroPython
Python ist eine Programmiersprache für Desktop- und
Serveranwendungen und wurde in den 90er-Jahren entwickelt und
nach der bekannten Comedy-Truppe »Monty Python« benannt.
Python ist momentan sehr beliebt und kann als aufstrebende
Programmiersprache bezeichnet werden.
MicroPython ist eine Python-kompatible Programmiersprache und
wurde speziell für den Einsatz mit Microcontrollern entwickelt und
optimiert. Die offizielle Implementation von MicroPython basiert auf
dem Python-3.4-Befehlssatz.
Wenn Sie also bereits mit Python programmiert haben, wird Ihnen
bei MicroPython ziemlich viel bekannt vorkommen und der Umgang
damit wird Ihnen leichtfallen. Die Beispiele sind aber so aufgebaut,
dass Sie auch als Einsteiger die Programme verstehen.
Für den Einsatz auf Microcontrollern, in unserem Fall dem Raspberry
Pi Pico, muss eine Firmware auf das Microcontroller-Board geladen
werden.
MicroPython-Programme können in der Entwicklungsumgebung oder
direkt auf dem Board gespeichert ausgeführt werden.

2.2.1 MicroPython für Raspberry Pi Pico


MicroPython für den Pico steht auf der Website des Raspberry Pi
Pico zum Download bereit:
https://www.raspberrypi.org/documentation/pico/ge
tting-started/
Folgen Sie dem Link Getting started with MicroPython (Abbildung 2.4).

Abb. 2.4: MicroPython für Pico


In Abbildung 2.5 sehen Sie den Download der Firmware in Form
einer UF2-Datei.

Abb. 2.5: MicroPython – Download UF2-Datei

Die aktuelle Version der heruntergeladenen Datei steht dann im


Download-Ordner Ihres Betriebssystems zur Verfügung (Abbildung
2.6).
Another random document with
no related content on Scribd:
“Three months ago I was looking through a trunk which contained
some things belonging to my brother, and I found an old
memorandum book.
“I opened it, and I was surprised to find written in it a short account of
Blanchard’s confession.
“I was interested.
“At the end of the confession I found a note.”
“What was it?”
“I will get the book and read it to you.”
“Do so.”
Lena got up, walked over to a bureau, opened a drawer, took out a
small, leather-bound book, returned to her seat, opened the book
and commenced to read:
“‘This night I stopped at the Red Dragon Inn. I gave the confession of
Blanchard to the proprietor to lock up in his safe. I have seen
Simeon Rich three times. I have told him that unless he pays me ten
thousand dollars I will take Blanchard’s confession to the district
attorney. I did not let him know where I had put the documents. No
one knows about the contents of the papers except myself. Doctor
Thompson did not ask to read the confession when he signed his
name as a witness.
“‘Rich has promised to raise the money in a few days.’”
“Is that all?” Carter asked, when Lena stopped reading.
“It is.”
“Let me have that book.”
“Here it is.”
The detective glanced at some of the pages, and then placed the
book in his pocket.
“What did you do after reading that memorandum?” he asked.
“I knew Simeon Rich,” Lena replied. “I met him some years ago. As
soon as I read that memorandum I made up my mind that Rich
would have to pay me well to keep silent.
“The thought came to me that perhaps he might have had a hand in
my brother’s death.
“I knew that Rich was quite sweet on Isabella Porter, the daughter of
the woman for whom my brother had worked.”
“She is dead now—I mean Mrs. Porter.”
“Did you see Rich?”
“Yes; I hunted him up.”
“Where was he living?”
“In the Studio Building, with Darwin, to whom he introduced me.”
“How did you find that out?”
“I called on Miss Porter, whom I knew was living at the Gerlach.”
“What did you say to Rich?”
“I told him that I knew about the confession, and I knew where it
was.”
“Was he frightened?”
“Yes. He held a conference with Darwin, and he then told me that
they would let me know how much they would pay me.
“I demanded ten thousand dollars.
“We have had several conversations about the matter, and a few
days ago I called on Darwin, and he gave me five thousand dollars
on account.
“I then gave him a copy of the memorandum in regard to the papers
having been left with the proprietor of the Red Dragon Inn.”
“Have you seen him since then?”
“Once.”
“Did he pay you any more money?”
“No, but he promised to do so.”
From what Lena said, Carter knew now how it was that Rich had
learned of the existence of the Blanchard confession.
The case was becoming clearer to the detective.
But, still, for all that, he had not secured any positive evidence to
prove that Rich had anything to do with the murder.
“Lena,” he said, “you say that you believe your brother was
murdered?”
“I do,” the woman replied.
“Do you think Rich had anything to do with it?”
“I am not sure.”
“Will you be guided by me?”
“I will.”
“I want you to put on your things and accompany me.”
“Are you going to place me under arrest?”
“No.”
“Then, what?”
“I am going to take you to my house. I want you to remain there until
I have finished the case upon which I am at work.”
“What is that?”
“The mystery of the Red Dragon Inn.”
“And you suspect Rich?”
“I do.”
“I have been reading about that case.”
“You have?”
“Yes, and it has seemed strange to me that the detectives have not
been able to find a clew.”
“Will you accompany me?”
“Yes.”
“I may need your assistance.”
“I will help you, Mr. Carter, gladly.”
“Let us start.”
Lena put on her hat and coat, packed a few articles in a valise, and
then she and the detective left the tenement.
Day was dawning when Carter reached his home. He conducted
Lena to Mrs. Peters, his housekeeper, who gave her a room, in
which she promised to remain.
Nick gave her a few instructions, and then he retired to his own
room, where he threw himself down upon a couch and went to sleep.
It was late in the morning when Carter awoke. He had an interview
with Lena, and then, after partaking of a light breakfast, he went
downtown. Chickering Carter and Patsy Garvan, his two chief
assistants, were engaged upon another case—in which, by the way,
Nick was fated to play a prominent part—so he did not see them that
morning.
Nick stepped into the Cosmopolitan Hotel, and saw Mr. Wright, who
informed him that his room had been entered during the night by
some one.
“I think I know who it was,” the detective remarked, and then he
departed, feeling sure that the person who had entered the room
was Brockey Gann.
It tickled him to think that the rascal had been disappointed.
Carter called at police headquarters, and there he learned that other
detectives had not made a discovery. He informed the chief
inspector that he was following a promising clew, and that he might
be able to render a report in a few days.
After leaving headquarters, he went uptown to the Knickerbocker
Cottage. There he questioned the waiters, and at last he found the
man who had served Rich and Darwin on New Year’s Eve.
“Did you hear any of their conversation?” the detective asked the
waiter.
“Only a little,” the man answered. “They talked about some man who
had just arrived in the city.”
“Was any name mentioned?”
“Yes.”
“Can you recall it?”
“I think it was Lawrence.”
“What did they say about him?”
“I don’t know.”
“What time did they leave here?”
“About half past ten o’clock.”
“Did you hear them mention where they were going?”
“A messenger boy brought Rich a note. He read it, and then I heard
him remark that they had better hurry down to McKeever’s saloon.”
“Was that all?”
“Yes.”
“Did you notice the number of the messenger?”
“It was seven-twenty-one.”
“Do you know the boy?”
“He is attached to the office on Broadway and Thirtieth Street.”
The waiter was unable to give the detective any more information.
Carter hurried to the office of the district messenger company.
There he found the messenger boy.
“Do you remember delivering a note on New Year’s Eve to a man
who was dining at the Knickerbocker Cottage?” the detective asked
the messenger.
“Was he a tall man?” the boy queried.
“Yes.”
“He was with a short, stout man?”
“Yes.”
“I gave him the note.”
“From whom did you receive it?”
“A man.”
“Did you ever see him before?”
“No.”
“Can you describe him?”
“He was pock-marked.”
“Was he a tough?”
“Yes.”
“Would you be able to recognize him again?”
“Yes.”
Carter gave the boy a bill and told him not to mention their
conversation to a soul.
From the boy’s description he recognized Brockey Gann.
At McKeever’s saloon the detective was fortunate enough to find the
bartender who had been on duty on New Year’s Eve. He was
acquainted with the man, and as soon as he made himself known to
him he readily answered all his questions.
They retired into a back room together, and as soon as they were
seated Carter asked:
“Are you acquainted with a man named Simeon Rich?”
“I know who he is,” the bartender replied.
“Do you remember if he was in here on New Year’s Eve?”
“He was here with two men.”
“At what time?”
“It was about eleven o’clock.”
“Do you know the men who were with him?”
“One of the men was Brockey Gann—the other man I do not know,
although I have seen him several times.”
“How long did they remain here?”
“Only a few minutes. They held a whispered conversation and then
went out.”
“Did you hear anything they said?”
“Not a word.”
This information only established one fact, and that was that Rich,
Darwin, and Brockey were together on New Year’s Eve.
Carter left the saloon.
He stood on the corner some time trying to determine what he ought
to do next. He was almost positive that Brockey Gann was the
scoundrel who had tracked the murdered man.
But how was he going to prove that?
This was a conundrum.
After a time Carter crossed the street and entered the establishment
of a costumer.
CHAPTER XI.
ACTING A PART.

Carter secured a disguise from the costumer.


When he came out he looked like a typical tough.
Nick had some plan in his mind. He was sure that he was on the
right trail, and that, such being the case, it would not be long before
he would have forged every link in the chain of evidence.
While he was confident of success, still he did not know for a
certainty who had committed the dastardly crime at the Red Dragon
Inn, or what the real motive was.
He had suspicions, and he had collected strong circumstantial
evidence.
But he wanted something more than this, and he was prepared to
take any risk to obtain it. On his way downtown he stopped at a
telephone station and called up Patsy, whose whereabouts he knew.
“Meet me downtown at my den within two hours,” he said.
At last he reached Lem Samson’s saloon, and entered.
A bartender was on duty.
Samson was not in the place.
Only a few hangers-on were lolling about.
Carter staggered up to the bar, and, calling for a drink, he cast his
eyes about the room.
No one seemed to be paying any particular attention to him.
Nearly all of the men had records, and were known to the police.
The detective poured the liquor into a cuspidor when the bartender’s
back was turned. It was vile stuff, and he would not have drunk it
unless he had been forced to do so by dire expediency.
After placing the glass back on the bar he walked into the back room
and sat down. He picked up a copy of a sporting weekly and
pretended to be deeply interested in examining the text and pictures.
But while he seemed to be reading, his eyes were wandering about
the room, and every person who entered the barroom he scrutinized
closely.
He was waiting for some one.
Was that some one Brockey?
Half an hour passed.
Carter had not stirred out of his chair.
The side door opened.
A man entered.
The man was Brockey Gann.
The detective saw him.
Still he did not move.
No change took place in his countenance.
Not a muscle moved.
Brockey looked around the back room.
His eyes fell on Carter, whose eyes were bent on the paper.
Brockey started, bent forward, and a change took place in the
expression of his evil face. He uttered an ugly oath and stepped up
to Carter, exclaiming:
“Why, Mugsey Donovan, when did you get out?”
Carter looked up, smiled inanely—a weak, silly, maudlin grin!—and
replied:
“How are you, Brockey? Wot’s dot youse said? Sit down an’ have a
ball wid me?”
“I asked you when you got out?”
“Six weeks ago. Wot cher goin’ ter have? Name yer pisen?”
“I’ll take some of the rosy.”
“I’ve been on de tramp. I just dropped in here tinkin’ I’d run up agin’
youse.”
“Oh!”
The bartender brought the liquor, and the two men were silent.
It will be well to explain that Mugsey Donovan was an old pal of
Brockey’s, whom Carter had arrested and sent to prison for highway
robbery.
The rascal was still in Sing Sing.
It will be seen that the detective’s disguise must have been perfect to
have deceived Brockey as it did.
The scoundrel actually believed that he was talking to his old pal.
“How is it you got out so soon?” Brockey asked, after he had
swallowed his liquor.
“Dey reduced me sentence,” the detective rejoined.
“How was that?”
“I saved one o’ de keepers’ life.”
“Go way!”
“I ain’t jollyin’ you.”
“How did you do it?”
“An insane mug tried to escape from his cell. De keeper catched him
an’ den he made an attempt to kill de keeper. I seed it an’ knocked
ter mug out, see? Den de jailer petitioned de guvnor ter lea’ me out.”
“What are you going to do?”
“Dat’s what I wanted to see youse about.”
“I’m not into anything.”
“Youse are not?” asked Nick dubiously.
“What do you mean by looking at me in that way?”
“Brockey, dis isn’t a safe place ter talk.”
“What do you mean?”
“Lea’ go some place where we kin talk wid safety.”
“I don’t understand you.”
“Brockey, don’ youse try ter gi’ an’ old pal like me any sich a bluff as
dat!”
“Mugsey——”
“Brockey, I’m on to yer game.”
“You are on to my game?”
“Sure.”
“Come——”
“Le’s go some place where we kin talk wid safety.” Brockey looked
intently at the detective.
“I can’t see what’s in your nut,” he ejaculated.
“Do youse want to talk over private matters here?” Carter asked, and
Brockey drawled:
“No-o.”
“Den le’s go down ter some quiet joint.”
“I’ll be hanged!”
“Brockey, I knows wot game youse is working?”
“I am working no game. I’m on my uppers.”
“Don’t try ter gi’ me eny game like dat, now, ’cause I’m on to de hull
layout.”
“You——”
“Wait.”
“I——”
“Brockey Gann, I tort youse’s never’d go back on an old pal in dis
way.”
“I’m not going back on you, Mugsey.”
“Youse is when youse refuse to let me in on de game, so dat I kin git
some o’ de graft.”
“You talk in riddles.”
“I seed one t’ing.”
“What’s that?”
“I’ve got to speak more plain.”
“You will.”
“Den here goes—don’t youse blame me if eny one hears it an’ youse
git into a trap. Las’ winter youse was paid to——”
“Wait, Mugsey.”
Brockey bent forward.
A strange expression was in his eyes.
“I’m waitin’, Brockey,” Carter said, and he returned the rascal’s
searching gaze.
“Where were you last night?” Brockey asked.
Carter laughed.
“Youse is comin’ to yer milk now, Brockey,” he remarked.
“Were you in this place last night?”
“Wot’s de use o’ talking here? It ain’t safe, Brockey. Le’ me gi’ you a
tip. Nick Carter may turn up here eny moment, an’ youse an’ me
might not be able to git on to him, see?”
Brockey uttered an oath. His face turned pale. He glanced over his
shoulder and his eyes wandered about the room.
“Ain’t my advice sensible?” the detective asked.
“I guess it is,” Brockey replied.
“Den le’s git out o’ here.”
“All right. But I’ll be hanged if I can understand what——”
“I’ll explain everything, Brockey.”
“Where’ll we go?”
“Ter a quiet crib dat I knows about.”
“Is it far?”
“No.”
The two men arose from the table and hurried out of the saloon.
Carter was playing a dangerous game.
Would he be able to carry it through successfully to the end?
At any moment he was liable to make a slip and Brockey would then
be able to penetrate his disguise.
So far he had deceived the rascal.
As they left the saloon the detective breathed easier. He had
succeeded in getting Brockey away from his friends.
That was a great point gained.
They turned into Macdougal Street.
“Where are you goin’?” Brockey asked, after they had reached
Fourth Street.
“Not far,” Carter replied. “I’ve got a room around here in Fo’rt’ Street.”
“When did you hire it?”
“Ter-day.”
“Oh!”
“Here it is.”
The detective led the way into a private house.
Brockey’s suspicions were not aroused.
If he had been aware that he was being led into a trap like a lamb to
slaughter he would have then and there made a desperate fight.
Carter had rented a room in this house for years, and he had used it
frequently. He opened the door of the room with a key.
The house was as quiet as a graveyard.
“This is a quiet joint,” Brockey said, as he followed the detective into
the room and gazed around.
There was nothing about the place to indicate for what purpose it
had been used by the detective. It was nothing more, to all outward
appearances, than a plainly furnished bedroom.
“Take a seat, Brockey,” said Carter blandly, and at the same time he
turned the key in the lock, took it out, and put it into his pocket.
“I wish you had some liquor about here,” Brockey remarked, as he
sank down into a chair.
“I kin accommodate youse.”
“Can you?”
“Yes.”
Carter opened a bureau drawer, took out a bottle and glasses and
placed them on the table.
Brockey poured out a glassful of the liquor and drank it.
A few minutes after it was down a look of surprise spread over his
face.
“Gosh!” he exclaimed. “Where did you get that, Mugsey?”
“Ain’t it rich?” Carter asked, with a smile.
“It’s more than rich.”
“Where did you get it?”
“I swiped it off a drunk.”
“I thought you didn’t pay for it.”
“Le’ us talk bizness now.”
Brockey’s countenance changed. He leaned back in his chair, looked
at the detective, and made no reply.
Carter was silent for a time, and then said:
“Brockey, as I said down in Samson’s joint, I be on ter your game.”
“And I’d like to know how you got on to it,” Brockey growled.
“I’ll tell youse after a while.”
“Go ahead.”
“Youse is mixed up in de Red Dragon Inn murder!”
“My Gawd!”
Brockey bounded out of his chair as if he had received a shock of
electricity. His face was the color of ashes. He stood still and gasped
at Carter.
“Youse needn’t t’row a fit,” the detective ejaculated. “Dere ain’t no fly
cop around here to hear me an’ pinch youse.”
“I’m a fool,” Brockey exclaimed as he wiped the cold perspiration
from his brow and sat down in his chair again.
“Rest easy, me covey.”
“But, Mugsey, you puzzle me.”
“Do I?”
“Yes.”
Carter laughed.
“Fire ahead,” Brockey said.
“Two rich blokes hired you to put Carter out o’ de way.
“Un o’ dem’s named Darwin an’ de oder Rich——”
“I——”
“Wait.”
“I——”
“Es I said—dey hired youse, an’ las’ night youse broke into old
Wright’s room at de Cosmopolitan Hotel an’ youse got sold.”
“Mugsey——”
“Gi’ me a chance to git through.”
“I will.”
“Now, I knows all dese tings, an’ I know how much youse got—an’
want a slice o’ de dough, see?”
“And if I don’t agree to give up?”
“Den I’ll go to yer friend, Carter.”
“You wouldn’t do that?”
“Jess youse try ter t’row me down an’ youse’ll see wot I’ll do.”
“Mugsey——”
“Brockey, youse’ve got to come ter time.”
“I suppose I’ll have to.”
“Youse kin gamble on dat.”
“If I give up you’ll have to help me.”
“All right.”
“I’ll introduce you to Rich and Darwin.”
“Tell me de full lay.”
“Tell me how you got onto what you know.”
“I piped youse.”
“When?”
“Las’ nite.”
“Was that all?”
“Yes.”
“Humph!”
“Doan git so disgusted.”
“I’m not.”
“Tell me de hull lay.”
“I will.”
Brockey became silent.
Carter’s eyes sparkled as he watched his companion.
His heart was beating rapidly, but outwardly he appeared composed.
Patiently he waited for Brockey to commence to speak.
“Would the rascal speak the truth?” he asked himself.
Brockey was liable to tell a false story.
“I know more dan youse t’ink, Brockey,” Carter remarked. “So if
youse go ter givin’ me any fairy tales I’ll be down on youse wid all me
force.”
“I’m going to tell you all about the lay,” Brockey replied, as he
aroused himself out of his reverie.
“Den fire ahead.”
“Don’t get impatient.”
“I’m not.”
“Have you got anything to smoke?”
“Cert.”
“Then set it out.”
Carter placed some cigars on the table.
Brockey picked up one, lit it, and commenced to smoke.
With a sigh, he settled himself back in the chair.
Another silence followed, and it was nearly five minutes before he
commenced to talk.
CHAPTER XII.
CAUGHT IN A TRAP.

“I want to tell you one thing, Mugsey,” Brockey exclaimed suddenly,


sitting bolt upright in his chair. “I’m not as deep in this affair of the
Red Dragon Inn as you suspect.”
“Don’ gi’ me any o’ dat,” Carter rejoined, blowing a cloud of smoke
up in the air over his head.
“Upon my honor, what I tell you is the truth.”
Carter could not help smiling when Brockey spoke of his honor.
Such a scoundrel as that does not know what honor is!
The detective knew well that Brockey had no honor, that he would
lie, steal, and if he found himself in a tight place, he would not
hesitate to betray an accomplice, if by so doing he could save
himself.
Brockey noticed the smile, and he flared up instantly.
“What are you smiling at, Mugsey?” he demanded.
“Youse,” Carter replied, without moving a muscle, and he puffed
away at his cigar, unconcernedly.
“You are laughing at me?”
“Cert.”
“I——”
“Youse gi’ me a pain! Go on wid yer story.”
“I want to know——”
“Drop it.”
“What were you laughing at?”
“When youse talk o’ honor it’s ’nuff ter make a dorg laff.”
“Is——”
“Come, Brockey—we’s understand each udder—speel ahead, neider
of us has got any honor, fur dat matter.”
“All right.”
Brockey quieted down. He took several pulls at his cigar, and then
he continued:
“As I said, I’m not as deep in that Red Dragon Inn affair as you
think.”
“Let it go at dat.”
“I’ll tell you all about the affair, Mugsey.
“Then you and I can put our heads together and decide what to do.”
“We’ll gi’ dem a good song and dance—make no mistake o’ dat.”
“How shall I start?”
“At de beginnin’.”
“How else would I start?”
“Youse might start at de tail.”
“That will do.”
“Youse is wastin’ time.”
“Then keep quiet.”
“I’m mum.”
“Listen.”
Brockey cleared his throat.
“It was the day before New Year’s,” he said.
“I was down on my luck and I hadn’t a cent in my pocket.
“Not in a long time had I been in such a hole.
“I tried to touch a dozen o’ the gang, but every one seemed to be in
the same boat.
“No one could show me a cent.
“I was at Samson’s saloon.
“Along about four o’clock a bloke came in.
“It was Sim Rich.
“Darwin had given me a knockdown to him some time before.
“At a glance I saw that he was excited about something.
“He spied me, came up, caught hold of my arm, dragged me after
him out of the saloon, pushed me into a cab and ordered the cabby
to hurry up and not lose sight of another cab that was just turning
into Broadway.
“My breath was taken away.
“I didn’t know what to make of Rich’s actions.
“The cab started, and before I could utter a word, Rich said:
“‘Brockey, I need your assistance.’
“‘You can have it, if you pay for it,’ I replied.
“‘I’ll pay,’ Rich said.
“‘Then what is it you want me to do?’ I asked.
“‘I want you to track a man.’
“Well, Rich pulled out a roll of bills and staked me with a hundred. He
told me that in the cab which we were following was a man whom he
hated and whom he wanted to locate.
“As soon as I found out where the man was going to put up I was to
send him word.
“Rich got out of the cab.
“Before he did so he told me he was going to dine that night at the
Knickerbocker Cottage, and I could send him word there.”

Das könnte Ihnen auch gefallen