No announcement yet.

GEN4-ULCD-70D-SB Arduino Due (no shield) External Power Wiring

This topic is closed.
  • Filter
  • Time
  • Show
Clear All
new posts

  • GEN4-ULCD-70D-SB Arduino Due (no shield) External Power Wiring


    I currently am working with a GEN4-ULCD-70D-SB display and an Arduino Due with no adapter. I'm having an interesting problem with regard to powerup and wiring I was hoping you could help with.

    I'm trying to power the display with an external 5v power supply, and power the Due with either a USB (for testing) or a 12V power supply. I'm running into issues where the display powers up but does not update on initial power up, but if I reset the arduino (using the reset button) the display works as intended and updates.

    Scenario 1: Initiatial power up of the display and arduino at the same time. The result is the display powers up, but nothing is updated on the screen
    Scenario 2: Once I hit the reset button on the arduino, the display resets and everything works as intended
    Scenario 3: If I power up the display first, then the arduino, the display powers up but nothing is updated on the screen.
    Scenario 4: If I power up the display using the external power supply, then try to use USB (computer) for the arduino, the arduino will not power up until I remove power from the display.

    Here is my rudimentary drawing. I'm not sure with an external power supply if I need something else so that it doesn't interfere with the Arduino. I'm at a bit of a loss. Thanks for your help!

    Click image for larger version

Name:	Arduino Due.jpg
Views:	134
Size:	27.7 KB
ID:	73320
    Here is the current code exactly as written - clearly there's a bunch of gnarly testing stuff but you should get the gist.

    * Write String Test - Demo application
    * This demo simply illustrates the various ways you can now send data to a String
    * object in ViSi-Genie, from an Arduino.
    * Demo uses Hardware Serial0 to communicate with the 4D Systems display module.
    * Simply create a Workshop4 Genie application for your 4D Systems display module,
    * and place a single 'Strings' object on the display, and download it to your module.
    * It will have the ID Strings0. This is then populated with data in the demo code below.
    * PLEASE NOTE: If you are using a non-AVR Arduino, such as a Due, or other variants
    * such as a Chipkit or Teensy, then you will need to comment out the Flash String
    * line below - Line 60, as it will prevent the demo from compiling.
    #include <genieArduino.h>
    #include <DueTimer.h>
    Genie screen1;
    Genie screen2;
    #define RESETLINE1 4 // Change this if you are not using an Arduino Adaptor Shield Version 2 (see code below)
    #define RESETLINE2 5 // Change this if you are not using an Arduino Adaptor Shield Version 2 (see code below)
    #define RESETLINE3 6 // Change this if you are not using an Arduino Adaptor Shield Version 2 (see code below)
    int digits = 0;
    int sampleRPM = 0;
    int sampleSPEED = 0;
    int counterFAST = 0;
    int counterSLOW = 0;
    int counterSUPERSLOW = 0;
    bool updateSpeedometer = false;
    bool updateTachometer = false;
    bool updateFuel = false;
    bool updateGauges = false;
    bool updateGear = false;
    bool debugging = true;
    void writeUIObject(int OBJ, int objectNumber, int value){
    screen1.WriteObject(OBJ, objectNumber, value);
    // Must delay after writing to a screen - when calling too many times
    // over serial the display will become locked up
    void updateUI_FAST(){
    if (debugging == true) {
    Serial.println("FAST UI");
    digits = digits + 1;
    sampleRPM = sampleRPM + 50;
    sampleSPEED = sampleSPEED + 3;
    updateSpeedometer = true;
    updateTachometer = true;
    updateGear = true;
    void updateUI_SLOW(){
    counterSLOW = counterSLOW + 1;
    updateGauges = true;
    void updateUI_SUPERSLOW(){
    counterSUPERSLOW = counterSUPERSLOW + 1;
    updateFuel = true;
    // Setup function
    void setup()
    // Use a Serial Begin and serial port of your choice in your code and use the genie.Begin function to send
    // it to the Genie library (see this example below)
    // max of 200K Baud is good for most Arduinos. Galileo should use 115200 or below.
    // Some Arduino variants use Serial1 for the TX/RX pins, as Serial0 is for USB.
    if (debugging == true) {
    Serial.begin(115200); // Disable Serial0 when not on USB
    // Maximum baude for displays should be 115200
    Serial1.begin(115200); // Serial1 @ 115200 Baud
    Serial2.begin(115200); // Serial2 @ 115200 Baud
    Serial3.begin(115200); // Serial3 @ 115200 Baud
    screen1.Begin(Serial1); // Use Serial0 for talking to the Genie Library, and to the 4D Systems display
    //screen2.Begin(Serial2); // Use Serial0 for talking to the Genie Library, and to the 4D Systems display
    //pinMode(9, OUTPUT);
    //digitalWrite(9, 0);
    // Reset the Display (change D4 to D2 if you have original 4D Arduino Adaptor)
    // If NOT using a 4D Arduino Adaptor, digitalWrites must be reversed as Display Reset is Active Low, and
    // the 4D Arduino Adaptors invert this signal so must be Active High.
    pinMode(RESETLINE1, OUTPUT); // Set D4 on Arduino to Output (4D Arduino Adaptor V2 - Display Reset)
    digitalWrite(RESETLINE1, 0); // Reset the Display via D4
    //digitalWrite(RESETLINE2, 0); // Reset the Display via D4
    digitalWrite(RESETLINE1, 1); // unReset the Display via D4
    //digitalWrite(RESETLINE2, 1); // unReset the Display via D4
    delay (5000); //let the display start up after the reset (This is important)
    Timer3.attachInterrupt(updateUI_FAST).setFrequency(20).start(); // 20 times per second
    Timer4.attachInterrupt(updateUI_SLOW).setFrequency(2).start(); // 2 times per second
    Timer5.attachInterrupt(updateUI_SUPERSLOW).setFrequency(1).start(); // 1 times per second
    // Main loop
    void loop()
    if (updateSpeedometer == true) {
    writeUIObject(GENIE_OBJ_ILED_DIGITS, 1, sampleSPEED%2000);
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 1, ceil((sampleSPEED%2000)/170.0));
    updateSpeedometer = false;
    if (updateTachometer == true) {
    writeUIObject(GENIE_OBJ_ILED_DIGITS, 0, sampleRPM%9000);
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 2, ceil((sampleRPM%9000)/800.0));
    updateTachometer = false;
    if (updateGear == true) {
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 0, (digits/10)%7);
    updateGear = false;
    if (updateFuel== true) {
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 3, counterSUPERSLOW%19);
    updateFuel = false;
    if (updateGauges == true) {
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 4, counterSLOW%19);
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 5, counterSLOW%19);
    screen1.WriteObject(GENIE_OBJ_USERIMAGES, 6, counterSLOW%19);
    writeUIObject(GENIE_OBJ_ILED_DIGITS, 2, counterSLOW);
    updateGauges = false;

  • #2
    EDIT: I'm using Visi-Genie
    Attached Files


    • #3
      UPDATE: I tested an Arduino MEGA using the same code and everything works as expected. I wonder if the Genie library isn't 100% compatible with the Due and causing some issues.


      • #4

        We weren't aware of any issues with the Due.

        The genieArduino library has been recently updated. If your not using the latest could you please try it and let us know if their is a difference.

        If you have already tried this and the result is the same you could try the Genie Beta library

        Best regards



        • #5
          I did a bunch more testing and it seems that the Due (or maybe my specific Due) is having issues. I'm switching to a Mega which seems to be working as expected. We can close this discussion, thanks!