Display

The display driver is now in master and enabled for BBBMINI by default. If you want to use a display with your BBBMINI just buy a SSD1306 128 x 64 OLED display (about 6$). The display should have four pins GND, VCC, SDA, SCL.

Connect the display to the BBBMINI:

  • Display GND to P15 GND
  • Display VCC to P15 3.3V
  • Display SCL to P15 SCL
  • Display SDA to P15 SDA

3691269840?profile=originalHave fun with your display and BBBMINI.

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • Mirko,

    I find this so useful on my BBBmini that I would like to use it with my Pixhawk based MR.

    You note that the display driver is "enabled for BBBmini by default" does that mean we can enable it for other platforms somehow? Just because it is in master doesn't mean it is in a stable build yet, correct? How do we know when features added to master migrate down to stable release builds, commented in the release notes?

    In the same idea the second IMU branch of yours will not have the display code correct, it is just for you testing the multi-IMU's?

    Will the multi-IMU be moved to master soon?

    Thanks

    MFK

    • Hi Mike,

      if you run Ardupilot on your pixhawk it should be usable, too. You may add "Display_SSD1306_I2C Display;" here https://github.com/diydrones/ardupilot/blob/master/libraries/AP_Not... (I do not have a Pixhawk, I can not try it).

      You have to check out the stable branch on github if it is in or not. I hope to get most bbbmini changes into ArduCopter 3.4, then I can recommend to fly bbbmini with stable. Now I recommend to fly with master. Big changes are listed in the release notes.

      The dual IMU branch is my master_dual branch. Display is in and enabled.

      Dual IMU can not be in master now, because then single IMU will not run when dual IMU is enabled. There must be add some auto detection (signle / dual IMU) in the code, then it could be merged into master.

      Regards

      Mirko

       

    • Mirko, I gave this a try and was unable to get it to work. Your link indicates to edit the AP_Notify.cpp line 45 and add "Display_SSD1306_I2C Display. I complied it and loaded onto a Pixhawk and it did not display.

      I then looked at the code and it looks like maybe it belongs after line 56? Like this:

      #if CONFIG_HAL_BOARD == HAL_BOARD_PX4
          Display_SSD1306_I2C Display;
          AP_BoardLED boardled;
          ToshibaLED_PX4 toshibaled;
          ToneAlarm_PX4 tonealarm;

      I compiled that and got no display.

      Is there a parameter that must be set to get it to function?

      Thanks

      PS I just noticed that maybe it needs to be lower case d is Display?

    • I am getting closer modified AP_Notify.cpp  as:

      #if CONFIG_HAL_BOARD == HAL_BOARD_PX4

          Display_SSD1306_I2C display;
          AP_BoardLED boardled;
          ToshibaLED_PX4 toshibaled;
          ToneAlarm_PX4 tonealarm;
      #if OREOLED_ENABLED
          OreoLED_PX4 oreoled;
          NotifyDevice *AP_Notify::_devices[] = {&display &boardled, &toshibaled, &tonealarm, &oreoled};
      #else
          NotifyDevice *AP_Notify::_devices[] = {&display &boardled, &toshibaled, &tonealarm};
      #endif

      I get output on the display but the data is rolling, the picture doesn't show it but the screen is constatlt rolling like an old tv with the vertical sync off:

      3702808135?profile=original

    • Hi Mike,

      #if CONFIG_HAL_BOARD == HAL_BOARD_PX4

          Display_SSD1306_I2C display;
          AP_BoardLED boardled;
          ToshibaLED_PX4 toshibaled;
          ToneAlarm_PX4 tonealarm;
      #if OREOLED_ENABLED
          OreoLED_PX4 oreoled;
          NotifyDevice *AP_Notify::_devices[] = {&display &boardled, &toshibaled, &tonealarm, &oreoled};
      #else
          NotifyDevice *AP_Notify::_devices[] = {&display &boardled, &toshibaled, &tonealarm};
      #endif

      Make sure you do not miss the comma it has to be ...&display, &boardled...

    • I checked and I have the commas. Remember I have the display working on the BBBmini so there is something different with the Pixhawk. I checked the display running on 5v and 3.3v and it does the same thing. When used with the BBBmini the logic does not load any of the other LED drivers. But the way I added it to the PX4 Hal section it leaves the other devices active. I wonder if the i2c address is in conflict with another device driver? I'll try removing them and recompile.

      I can put the scope on it but would the i2c hardware driver be so different between the BBBmini and the Pixhawk?

    • Hi Mike,

      in my cause I'm using display and i2c compass and are ok, what kind of leds are you talking about ?

    • In the AP_notify.cpp library controls for various notification devices like LED's and Alarms.
      **************************************************************************
      #if CONFIG_HAL_BOARD == HAL_BOARD_PX4
          AP_BoardLED boardled;
          ToshibaLED_PX4 toshibaled;
          ToneAlarm_PX4 tonealarm;
      #if OREOLED_ENABLED
          OreoLED_PX4 oreoled;
          NotifyDevice *AP_Notify::_devices[] = {&boardled, &toshibaled, &tonealarm, &oreoled};
      #else
          NotifyDevice *AP_Notify::_devices[] = {&boardled, &toshibaled, &tonealarm};
      #endif

      ************************************************************************************

      I added Display_SSD1306_I2C display; to the PX4 Hal but I did not remove the others.

      When Mirko added Display_SSD1306_I2C display; for the BBBmini is only added that one device


          #elif CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_LINUX_BBBMINI
              Display_SSD1306_I2C display;
              NotifyDevice *AP_Notify::_devices[] = {&display};
             

    • Good catch. Hopefully it was just a typo when i wrote the post. I'll check. I do get it do drive the display, which did not happen before I modified those lines, but as in the picture it rolls. I'll check and see if there is a voltage level problem.

      Thanks very much.

    • Hi, 

      to properly work i2c on my BBB Mini - to use an external compass and i2c display I had to use 2 resistors of 1k as pull-up, and is working 

This reply was deleted.