sheen.bot Logo

1.10.1 Interfacing OLED Display and RGB Lights

In this section, we demonstrate how to use Mind+ visual blocks to control the OLED display and RGB lights on the sheenbot∞ board.

Before proceeding, ensure the sheenbot∞ extension is properly loaded into Mind+ as explained in Section 1.9.1. Follow these setup steps to start writing your first sheenbot programme:

  1. Change the mode from "Online" to "Offline" if it is not on offline mode by default.

  2. Start a new project by clicking the Project tab

  3. Click the Extensions tab.

  4. Select the board FireBeetle ESP32-E.

  5. Open the User-Ext tab and select the sheenbot∞ extension, as shown in Figure 1.10a.

  6. Click Back to return to the Woekspace area.

The Mind+ interface consists of three main sections: the Block Palette on the left (where you drag coding blocks from), the Coding Area in the middle (where you build your program visually), and the Code Tabs on the right (which show the auto-generated code and allow manual editing). These sections are illustrated in Figure 1.10.1b.

Once set up, you're ready to create a sample program that writes text to the OLED screen and changes the RGB light color based on logic blocks.

Now, once you are in the workspace (see Figure 1.10.1c for all the following isntructions):

  • Click on the User icon expansion on the far left inside the Block Palette.

  • Drag the following blocks into the forever loop inside your Coding Area:

    • lampNumber[]displayColor[] `
  • You can set the lampNumber for the specific RGB light you want to turn on.

  • You can also select the colour for each RGB light.

  • Paste the line 3 times and select a specific lamp number and colour for each RGB light as shown in Figure 1.10c.

  • Drag the screen display text block into your forever loop and customize it to print the text of your choice.

  • Connect to your sheenbot by clicking the Connect Device tab, as shown in step 3 of Figure 1.10.1c.

  • Upload your code using the Upload button indicated in step 4 of the same figure.

  • The Console Window will display messages showing the progress of the code upload and confirm when it has been successfully uploaded.

  • After a successful upload, your OLED display will show the custom text, and the RGB lights will turn on as programmed.


Figure 1.10.1a: Select the sheenbot∞ extension.

Figure 1.10.1b: Block Palette| Coding Area| Code View Tabs

Figure 1.10.1c: Drag, drop and upload your code"

Figure 1.10.1d: The Final ressult