Experimenting with digital lanyards – introducing the Badger2040



Experimenting with digital lanyards

As somebody who attends occasions frequently, I’ve spent a good bit of time over time taking a look at attention-grabbing methods to interact with attendees. One of many issues I used to be seeking to remedy was how do I share helpful data with attendees with out having to interrupt the conversations (one thing that sometimes occurs as I try to discover these hyperlinks on my cell phone).

I’m at all times taking a look at attention-grabbing new gadgets which may assist, and lately I used to be drawn to an announcement from Pimoroni a few gadget known as the Badger2040, a low value e-Ink show that was mixed with a Raspberry Pi Pico controller.

In the event you work and even dabble within the Raspberry Pi/ Maker house, you’ll know who that is, if not then head over to their web site and put together to be impressed and excited in equal measure

The gadget has quite a few buttons that you should utilize to make it extra dynamic – for instance, you may swap data you need to show or allow some primary interactivity doubtlessly. Cool stuff I believe, with plenty of potential.

I really purchased one among these a couple of weeks in the past, and put collectively over a few hours, a quite simple pattern software that’s excellent for my use case. I shared it on social media in the present day, and this tweet generated a good bit of curiosity. I had a couple of questions so thought I might shortly put collectively this put up to share what it’s and the way to get it up and working in case anybody else desires to attempt them out.

Introducing the Badger2040

As this put up, Getting Started with Badger 2040 on the Pimoroni web site says, the Badger2040 is a:

“a low value, RP2040-powered eInk/ePaper/EPD programmable badge”

To get began with this, you’re going to want the next:

  • a Badger2040 equipment – this comes with a battery pack, velcro, a lanyard and a USB-C/USB connection cable
  • Thonny – an open supply Python IDE that permits you to join and add/obtain code and property to the Badger2040. This works on Mac, Home windows and Linux.
  • entry to the GitHub repository that contains useful example code

Putting in Thonny

I had by no means heard of Thonny earlier than, however it’s a quite simple code editor that’s optimised for this sort of use case. Whenever you add information, it asks you whether or not you need to work on that file domestically, or instantly on the distant (i.e. Badger2040) gadget. Thonny is the best way to successfully deploy your code to the gadget.

It was easy sufficient to put in on my Mac, and simply put in utilizing the defaults. To prepare for improvement, you could first configure the runtime. To do that, from the TOOLS > OPTIONS, choose the INTERRUPTER tab and from the pull down, choose MICROPYTHON (RASPBERRY PI PICO).

Beneath this, you need to see PORTS – you may go away that alone because it ought to robotically configure. See the subsequent step as to how this is perhaps useful when troubleshooting points.

Connecting to the Badger2040

I’m utilizing a Macbook working Huge Sur, and in a rush to rise up and working (and naturally, ignoring the documentation) I linked the battery pack to the Badger2040, linked the USBC cable to my Mac after which booted up Thonny.

I encountered an error nevertheless.

System is busy or doesn't reply.
Enter fullscreen mode

Exit fullscreen mode

I checked to see if I had configured every part accurately by checking the TOOLS > OPTIONS and viewing the PORTS part beneath the INTERRUPTER tab. It’s best to see a worth that claims one thing like “BOARD IN FS MODE (/dev/cu.usbmodem14201)”. This appeared so I used to be unsure why I couldn’t join.

I shortly discovered my drawback. I had linked the battery pack, and I had switched it ON. This meant that the Badger2040 was really working and so I couldn’t connect with it (because it was busy). As soon as I turned the battery pack OFF, after which retried, I may efficiently connect with the Badger2040, and I may see each my native information in addition to the information on the Badger2040. I hope that saves people a while!

Updating the Firmware
I can’t cowl it on this put up, as it’s lined very effectively within the Pimoroni put up linked above. You’ll be able to add firmware to the Badger2040 by merely placing the gadget in boot rom mode (this makes the gadget seem as a drive in Finder) after which copying the uf2 file into the folder. As soon as copied, the replace occurs robotically. You in all probability is not going to want to do that in case you are simply getting every part up and working, however in the event you do, take a look at the put up above.

Working with photographs

It’s attainable to show low decision photographs in your badger2040, and I really actually just like the lowfi, retro really feel of them. So I can hear you all asking me, how?

Pimoroni present plenty of helpful instruments, and a picture conversion is one such great tool. You could find it here, and the best way that I created my picture file (it’s within the GitHub repo which I share on the finish of this put up) I did the next:

  • clone the repository, so I may use the convert.py script
  • resize a picture I wished to make use of in order that it was precisely 104 pixels in width and 128 pixels in top
  • run the convert.py script utilizing the command:
    *

    python3 convert.py --binary photographs/ricsue.png

  • this creates an output file in the identical folder, known as ricsue.bin, which is the binary picture format that the badger can use

There are extra examples of how one can work with photographs within the Pimoroni weblog put up, so verify them out.

My customised badger2040

The Badger2040 comes a ton a pattern purposes, two of which I realised I wished to mesh – the qrcode and the badge scripts. One permits you to configure QR codes to be displayed, with some textual content, utilizing a textual content file to configure the URL and generate the QR code. The opposite permits you to show a static picture with some textual content. I wished to make use of each, after which use the buttons on the gadget to toggle which one, relying on the place I used to be or what I used to be doing at a given time on the occasion.

I’m not going to cowl the code, as it’s closely primarily based on the pattern code. You could find the code I used for my badge over at this GitHub repo. It isn’t the perfect code on this planet, however I hacked it collectively utilizing the pattern purposes so I might advocate going via these to see what you should utilize.

I hope that you simply discover this attention-grabbing, and can put up again my findings of utilizing this gadget at occasions over the approaching weeks as I’ve fairly a couple of developing.



Add a Comment

Your email address will not be published. Required fields are marked *