News

moodlite - Coming soon


scan start bootloop?

Sam_Perry77 · 169

Sam_Perry77

  • Newbie
  • *
    • Posts: 4
    • Likes: +0/-0
    • View Profile
on: January 23, 2019, 01:02:22 AM
So I'm starting my moodlite project and have run into a slight issue. I connected the Nodemcu to my computer, was able to flash the sketch and spiffs. However I get an error stating that "java.io.IOException: jssc.SerialPortException: Port name - COM5; Method name - setEventsMask(); Exception type - Can't set mask." in the Arduino IDE. Then, in serial monitor there is simply a repeating message of "scan started" > "scan done" > "xx networks found" and this repeats over and over. My laptop doesn't see a moodlite wifi network to connect to either. I'm not very good with coding, but can muddle through. Any idea what I need to do? I made no changes to the sketch except for setting static ip to false (for now).



CdRsKuLL

  • The Fat Dude
  • Administrator
  • Full Member
  • *****
    • Posts: 109
    • Likes: +14/-0
  • Lighting the way...
    • View Profile
Reply #1 on: January 23, 2019, 11:24:29 AM
You may need to wipe the eeprom and try again.

Have a look here..
https://github.com/spigotx/Moodlite/wiki#faq


Thanks,


Steve

Moodlite is a completely free open source project.
If however you would like to say thanks and help contribute to this site, or just buy me a beer then please donate below. :-)



Sam_Perry77

  • Newbie
  • *
    • Posts: 4
    • Likes: +0/-0
    • View Profile
Reply #2 on: January 23, 2019, 02:01:57 PM
So I did that and I have the same thing happening to me.  I ordered a two pack of the ESP8266 boards and the same thing happens on both of them. It must be something in the software no? I have tried flashing with only static ip being false, I have tried defining the wifi information, I have had no luch and have flashed in many ways and end up at the same point. All serial monitor explains to me is that
"scan start
scan done
17 networks found"
then it repeats this infinitely... Has anyone made a really detailed step by step for the programming of this board so I can see what steps I have messed up on?



CdRsKuLL

  • The Fat Dude
  • Administrator
  • Full Member
  • *****
    • Posts: 109
    • Likes: +14/-0
  • Lighting the way...
    • View Profile
Reply #3 on: January 23, 2019, 03:22:45 PM
okay.. try this..

First lets start a fresh by wiping both the eeprom and spiffs


In the void setup()  uncomment as below..


   // --- Uncomment to reset ---
   // Erase EEPROM
   eraseEEPROM();
   // Erase SPIFFS
   eraseSPIFFS();


Flash to the board.. Then comment out a gain ready for the next flash.


So.. You have three choices now.
1. Either set a static IP and input your Wifi name and password
2. Load as is and search for the moodlite wifi when it boots up.
3. OR.. you can set the wifi name and password and get a IP address.


So, first the 1st option (I use) I have done the below;


#define STATIC_IP true        // flag to use static IP           [True = Static IP, False = DHCP]

// Static IP
   IPAddress ipaWifiIP(192, 168, 1, 40);
   IPAddress ipaWifiSubnet(255, 255, 255, 0);
   IPAddress ipaWifiGateway(192, 168, 1, 1);
   // If you don't wish to use DNS leave "ipaWifiDns" variable as it is, otherwise set yours DNS or Google DNS (8.8.8. 8)
   // You won't be able to use NTP server
   IPAddress ipaWifiDns(192, 168, 1, 1);
   // Configure:
   String sHostName = "Moodlite";
   String sWifiSsd = "MYWiFIName";
   String sWifiPassword = "WifiPassword";


For the 2nd option..
#define STATIC_IP false// flag to use static IP           [True = Static IP, False = DHCP] 


For the 3rd option you can ..

#define STATIC_IP false// flag to use static IP           [True = Static IP, False = DHCP] 

   // WiFi AP (DHCP)
   IPAddress ipaWifiApIP(192, 168, 100, 250);
   IPAddress ipaWifiApGateway(192, 168, 100, 1);
   IPAddress ipaWifiApSubnet(255, 255, 255, 0);
   // Leave unconfigured:
   String sHostName = "Moodlite";
   String sWifiSsd = "SetWifiName";
   String sWifiPassword = "WifiPass";
   // AP Password
   // ! Must be at least 8 chars long
   const char* WIFI_AP_PASSWORD = "Moodlite";


Then.. in void initWiFi () { comment out..

    //WiFi.mode(WIFI_AP_STA);
    //WiFi.softAP(sHostName.c_str(), WIFI_AP_PASSWORD);
    //WiFi.softAPConfig(ipaWifiApIP, ipaWifiApGateway, ipaWifiApSubnet);   
 
and add underneath
    WiFi.begin(sWifiSsd.c_str(), sWifiPassword.c_str());

That should do it :-)  Oh, and you will then need to reload the data folder SPIFFS
« Last Edit: January 23, 2019, 03:26:40 PM by CdRsKuLL »

Moodlite is a completely free open source project.
If however you would like to say thanks and help contribute to this site, or just buy me a beer then please donate below. :-)



 


SMF spam blocked by CleanTalk