Page 2 of 2 FirstFirst 12
Results 11 to 17 of 17

Thread: SparkFun EL Wire Sequencer Shield on Wemos D1

  1. #11
    Join Date
    Dec 2013
    Location
    Elkridge, MD
    Posts
    786
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    Quote Originally Posted by Barnabybear View Post
    See how that goes. I'm looking for a schematic for the El Scudo then I see if there is a better plan.
    schematic is here.

  2. #12
    Join Date
    Dec 2013
    Location
    Elkridge, MD
    Posts
    786
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    ok, well ...that didn't work...

    When I made the wiring changes and the shield plugged in, I couldn't communicate with the board to program. I unplugged shield, programmed the board then plugged it back in. Upon powerup, the outputs were on and the wifi was dead.
    Pics of the wiring change.
    2018-09-15 09.46.38.jpg2018-09-15 09.47.04.jpg
    Also, these changes needed to be in the setup, it wouldn't compile

    Code:
    void setup() {
      pinMode(1, FUNCTION_3);  //***** EDIT by Banabybear *****
      pinMode(3, FUNCTION_3);  //***** EDIT by Banabybear *****

  3. #13
    Join Date
    Dec 2013
    Location
    Elkridge, MD
    Posts
    786
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    i did a little research today.

    This page Here describes using pin 0,2 or 15. These pins determine how the ESP boots. In reading this I'm not sure how to proceed. Could i connect a 3k resistor from pin 0 to Vcc which I assume is 3.3v pin? and do the same for using pin 2? I also thought about trying to use A0 as an output? I hate to lose 2 channels of this controller, ready need to use all 8.

    Thanks,J

  4. #14
    Join Date
    Dec 2012
    Location
    Hudson MA
    Posts
    2,880
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    gpio 0 needs to be high at boot or else the chip goes into a special mode. a pullup takes care of that. you need to include the pullup current in your output calculation. i would use a 4k ohm resistor


    2018 - Moving and going to visit my Daughter in New Zealand. Most likely I will be dark or nearly dark, Some static stuff that is simple to put up.

  5. Thanks JCook thanked for this post
  6. #15
    Join Date
    Dec 2011
    Location
    UK S80 postcode
    Posts
    1,304
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    Hi, sorry I've not replied sooner it been a busy weekend. I’ve never had a problem driving opto devices from the GPIO’s on the Wemos. Did you get chance to see if it was GPIO 1, 3 or both that are causing the boot issue?

    As you and Martin suggested it may well be that pullup resistors are needed if using GPIO’s 0, 1, 2, or 3. I can confirm that there are at least 8 usable output channels (A0 isn’t one) it’s just as some have different functions they need to be treated differently.

    Check to see if it’s GPIO 1, 3 or both that is causing the issue.

    Try using a pull up on the output that is causing the issue. I’d try and make this a high value, start with 10K and work down to 1K.
    Be careful when doing this power off the boards and double check your work for shorts. If you damage the Tx or Rx pins you can’t program the ESP.

  7. #16
    Join Date
    Dec 2013
    Location
    Elkridge, MD
    Posts
    786
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    So here what I've found out.

    I bought the following resistors in 1/8watt. 1k, 2.2k, 3.3k, 4.7k, 10k

    I've ended up with both versions of the Wemos Board R1 & R2.

    For testing the resistors I started at 10k and worked my way down to 1k.

    on the Wemos D1 R1 0 & 2 were the issue.
    on pin 0 or D8 a 4.7k resistor worked.
    on pin 2 or D9 a 1k resistor worked.

    Wemos D1 R2
    pin 2 or D4 was the only pin that caused an issue.
    on Pin 2 1k worked.

    It will be easier to use the R2 version as it has points to solder this resistors in place.

    I'm going to solder the resistors in place then test again. I'll post pictures when I'm done.

    Thoughts??
    Last edited by JCook; 09-17-2018 at 10:46 PM.

  8. #17
    Join Date
    Dec 2013
    Location
    Elkridge, MD
    Posts
    786
    Post Thanks / Like

    Default Re: SparkFun EL Wire Sequencer Shield on Wemos D1

    I soldered the 1k Ohm resistor onto the board, I actually did 4 of them, they all work.

    Here is a picture of the board with the resistor. I put shrink tubing over the resistor so that its leads don't touch anything else.

    Now to focus on wiring up the costumes and finish my sequences. Thanks for all of the help.
    I'll post pictures once I get everything up and running.
    Wemos_D1_R2 with Resistor.jpg

    Here is the code I'm currently running.
    Code:
    // Wemos D1 E1.31 - 8 channel sketch for Sparkfun EL Escudo Dos shield
    //Spark Fun link https://www.sparkfun.com/products/10878
    
    #include <ESP8266WiFi.h>
    #include <E131.h> // Copyright (c) 2015 Shelby Merrick http://www.forkineye.com
    
    // ***** USER SETUP STUFF *****
    const char ssid[] = "MY WIRELESS";  // replace with your SSID.
    const char passphrase[] = "MY PASSWORD"; // replace with your PASSWORD.
    const int universe = 1; // this sets the universe number you are using.
    IPAddress ip (192,168,1,221);  // xx,xx,xx,xx CHANGE TO YOUR DESIRED IP ADDRESS
    IPAddress netmask (255,255,255,0);  //255,255,255,0 is common
    IPAddress gateway (192,168,1,1);  // xx,xx,xx,xx normally your router / access piont IP address
    IPAddress dns (192,168,1,1); //  // xx,xx,xx,xx normally your router / access point IP address
    
    // this sets the pin numbers to use as outputs.
    //for Wemos D1 R1 pins are 16,5,4,14,12,13,0,2
    //for Wemos D1 R2 pins are 16,5,4,0,2,14,12,13
    const int output_1 = 16; //the pin to use as output 1 (D0)
    const int output_2 = 5;  //the pin to use as output 2 (D1)
    const int output_3 = 4;  //the pin to use as output 3 (D2)
    const int output_4 = 0;  //the pin to use as output 4 (D3)
    const int output_5 = 2;  //the pin to use as output 5 (D4)
    const int output_6 = 14; //the pin to use as output 6 (D5)
    const int output_7 = 12; //the pin to use as output 7 (D6)
    const int output_8 = 13; //the pin to use as output 8 (D7)
    
    
    E131 e131;
    
    void setup() {
      Serial.begin(115200);
      // set the pins chosen above as outputs.
      pinMode(output_1, OUTPUT);
      pinMode(output_2, OUTPUT);
      pinMode(output_3, OUTPUT);
      pinMode(output_4, OUTPUT);
      pinMode(output_5, OUTPUT);
      pinMode(output_6, OUTPUT);
      pinMode(output_7, OUTPUT);
      pinMode(output_8, OUTPUT);
    
      // set the pins chosen above to low / off.
      digitalWrite(output_1, LOW);
      digitalWrite(output_2, LOW);
      digitalWrite(output_3, LOW);
      digitalWrite(output_4, LOW);
      digitalWrite(output_5, LOW);
      digitalWrite(output_6, LOW);
      digitalWrite(output_7, LOW);
      digitalWrite(output_8, LOW);
      
      /* Choose one to begin listening for E1.31 data */
     // e131.begin(ssid, passphrase);               /* via Unicast on the default port */
      e131.begin(ssid, passphrase, ip, netmask, gateway, dns);               /* via Unicast on the default port */
      // e131.beginMulticast(ssid, passphrase, ip, netmask, gateway, dns); /* via Multicast for Universe 1 */
    }
    
    void loop() {
      /* Parse a packet */
      uint16_t num_channels = e131.parsePacket();
    
      /* Process channel data if we have it */
      if (num_channels) {
        Serial.println("we have data");
    
        digitalWrite(output_1, (e131.data[0] > 127) ? HIGH : LOW);
        digitalWrite(output_2, (e131.data[1] > 127) ? HIGH : LOW);
        digitalWrite(output_3, (e131.data[2] > 127) ? HIGH : LOW);
        digitalWrite(output_4, (e131.data[3] > 127) ? HIGH : LOW);
        digitalWrite(output_5, (e131.data[4] > 127) ? HIGH : LOW);
        digitalWrite(output_6, (e131.data[5] > 127) ? HIGH : LOW);
        digitalWrite(output_7, (e131.data[6] > 127) ? HIGH : LOW);
        digitalWrite(output_8, (e131.data[7] > 127) ? HIGH : LOW);
        }//end we have data
    
    } // end void loop

Page 2 of 2 FirstFirst 12

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •