moodlite - Coming soon

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Coolstuff55

Pages: 1
moodlite Software / Re: Rhythm function and PCB update
« on: January 03, 2020, 11:56:34 PM »
Nope, can't even get the Moodlite software to work at all...

moodlite Software / Re: Help to connect
« on: November 22, 2019, 08:34:54 AM »
Update but not solved...
I changed the CPU freq to 160Mhz which solved many of the issues. It now has the initial SSID "Moodlite" and I can now connect to it and enter my details. It takes me to the <ip address>/set_wifi but doesnt load the page. I don't know if this is normal or not, but in the serial monitor it shows they have been set. The debug also shows Wifi status: 3, Wifi network started succesfully, however it doesn't connect to my wifi and I can't find it at all. Anything I can try?

moodlite Software / Re: Trouble uploading SPIFFS
« on: November 22, 2019, 08:28:47 AM »
Yep, I found the same thing. Is it working for you now? I'm stuck trying to get it connect to my own wifi...

moodlite Software / Re: Trouble uploading SPIFFS
« on: November 22, 2019, 06:46:21 AM »
I'm wondering if part of your problem may be the fact that your 'Tools' menu looks different, probably because you have a different board selected or at least a different version. Mine has nothing to do with python and mine uploads fine, and my board settings are identical to the instruction image. Try to follow the instructions again and all the board settings identical to the image in your first post.

moodlite Software / Help to connect
« on: November 16, 2019, 03:33:40 AM »
Hi guys,
I've been trying for many weeks with no success. I have moved to V2 as many people have had more success. The first time it is run, I only see "ESP30xxxx" in my wifi list, but can connect to it with the password "Moodlite". The page then displays for me to input my Wifi details which I do. But it wont connect to my Wifi, and debug shows
Code: [Select]
Wifi status: 6
--- initWiFi - End ---
I have tried many static IP addresses and DHCP but no luck. Any help would be much appreciated.
Also, I have some experience in C programming and networking, so its not all totally new to me.

moodlite Software / Re: Rhythm function and PCB update
« on: October 10, 2019, 03:42:44 AM »
Sweet as. My components arrived this week for the PCB, so I should get it built up in the next week and then I can have a play too.
I also discovered mDNS which would be cool to add to the code too. It would mean instead of typing an IP address, you could just type "moodlite.local" and it will come up. Looks quite simple too. More info here ->


moodlite Software / Re: Rhythm function and PCB update
« on: October 05, 2019, 09:09:28 AM »
Sweet, just attached as an image for now. Let me know if you need anything more.
On the right side of the schematic is the reset switch, PIR sensor and LED output (what exactly does the rst switch do in the software?).
On the left side is the microphone and amplifier circuit. The opamp used is the common LM386 audio amplifier. R5 is a pot that is used to adjust the volume if necessary. It should be adjusted once at setup and then left. C3 sets the gain of the amplifier. The 10uF that I've put in there sets it to its max of 46dB, or x200. This should be fine for our application. If necessary, this can be adjusted to x50 or x20 with different values.
Hopefully the components all arrive this week, so I can put it together and test some code.
I think that's all... If there are any details I've missed or any questions feel free to ask.

moodlite Software / Re: Rhythm function and PCB update
« on: October 04, 2019, 11:12:53 AM »
Cheers! I have no idea if it will work either, its just a simple mic and amplifier circuit. I'll post the schematic tomorrow, whats the best format for you? I designed in Altuim. I would really appreciate it if you could help with the code side, I think it would make an awesome feature.


moodlite Software / Re: Rhythm function and PCB update
« on: October 03, 2019, 10:31:34 PM »
Forgot to add PCB images... attached.

moodlite Software / Rhythm function and PCB update
« on: October 03, 2019, 11:27:54 AM »
Hi all,
I have received my PCBs back and are ready to assemble. I have attached some photos below.
I have also added a microphone circuit with a small amplifier connected to the analog pin of the ESP8266,
with the hope of adding a rhythm function later.
I have found a piece of code online called soundbracelet that looks great for this task.
A demo of the code can be seen here :

I have tried adding the code to a moodlite function, but my arduino coding is relatively limited.
Heres what I've got so far. Any help would be much appreciated. MIC_PIN etc is defined on the main page

Code: [Select]
void three_sin()  //just overwriting an exsisting function as a test
  #define DC_OFFSET  0                                         // DC offset in mic signal - if unusure, leave 0
                                                                // I calculated this value by serialprintln lots of mic values
  #define NOISE     30                                         // Noise/hum/interference in mic signal and increased value until it went quiet
  #define SAMPLES   60                                          // Length of buffer for dynamic level adjustment
  #define TOP (iNrOfLeds + 2)                                    // Allow dot to go slightly off scale
  #define PEAK_FALL 10                                          // Rate of peak falling dot
    peak      = 0,                                              // Used for falling dot
    dotCount  = 0,                                              // Frame counter for delaying dot-falling speed
    volCount  = 0;                                              // Frame counter for storing past volume data
    vol[SAMPLES],                                               // Collection of prior volume samples
    lvl       = 10,                                             // Current "dampened" audio level
    minLvlAvg = 0,                                              // For dynamic adjustment of graph low & high
    maxLvlAvg = 512;

  uint8_t  i;
  uint16_t minLvl, maxLvl;
  int      n, height;
  n = analogRead(MIC_PIN);                                    // Raw reading from mic
  n = abs(n - 512 - DC_OFFSET);                               // Center on zero

  n = (n <= NOISE) ? 0 : (n - NOISE);                         // Remove noise/hum
  lvl = ((lvl * 7) + n) >> 3;                                 // "Dampened" reading (else looks twitchy)
  // Calculate bar height based on dynamic min/max levels (fixed point):
  height = TOP * (lvl - minLvlAvg) / (long)(maxLvlAvg - minLvlAvg);
  if (height < 0L)       height = 0;                          // Clip output
  else if (height > TOP) height = TOP;
  if (height > peak)     peak   = height;                     // Keep 'peak' dot at top
  // Color pixels based on rainbow gradient
  for (int k=0; k<iNrOfLeds; k++) {
    if (k >= height)   crgbLeds[k].setRGB( 0, 0,0);
    else crgbLeds[k] = ColorFromPalette(crgbCurrentPalette, 255, 255);
  // Draw peak dot 
  if (peak > 0 && peak <= iNrOfLeds-1) crgbLeds[peak] = CHSV(map(peak,0,iNrOfLeds-1,30,150), 255, 255);

// Every few frames, make the peak pixel drop by 1:
    if (++dotCount >= PEAK_FALL) {                            // fall rate
      if(peak > 0) peak--;
      dotCount = 0;
  vol[volCount] = n;                                          // Save sample for dynamic leveling
  if (++volCount >= SAMPLES) volCount = 0;                    // Advance/rollover sample counter
  // Get volume range of prior frames
  minLvl = maxLvl = vol[0];
  for (i=1; i<SAMPLES; i++) {
    if (vol[i] < minLvl)      minLvl = vol[i];
    else if (vol[i] > maxLvl) maxLvl = vol[i];
  // minLvl and maxLvl indicate the volume range over prior frames, used
  // for vertically scaling the output graph (so it looks interesting
  // regardless of volume level).  If they're too close together though
  // (e.g. at very low volume levels) the graph becomes super coarse
  // and 'jumpy' keep some minimum distance between them (this
  // also lets the graph go to zero when no sound is playing):
  if((maxLvl - minLvl) < TOP) maxLvl = minLvl + TOP;
  minLvlAvg = (minLvlAvg * 63 + minLvl) >> 6;                 // Dampen min/max levels
  maxLvlAvg = (maxLvlAvg * 63 + maxLvl) >> 6;                 // (fake rolling average)


moodlite Design / Re: Nanoleaf like PCBs
« on: September 12, 2019, 01:32:38 PM »
I'm brand new to this forum, but have been looking into nanoleaf-like modular lights for some time. After many hours of research and trials, I found the ESP8266 board, perfect, followed by the WS8212B LEDs. Those two led me to here, which is exactly what I was after. Anyway, I am an electrical engineering student, and I have learnt schematic and PCB design, using the professional software Altuim. I'm not exactly sure what you are asking for, so some more specifics would be good, but I may be able to help. I am in the process of designing a PCB for my own project, however the power module case will be a different design as I want some different features and to reduce the size. My pcb will hopefully have include: A power input socket, a usb input socket (to change code without opening case), a switch, a motion sensor, and a microphone. I will let you know how I get on. Sorry for the long post! Cheers.

Pages: 1

SMF spam blocked by CleanTalk