Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Troubleshooting
  3. Can't load from Codebender :-(

Can't load from Codebender :-(

Scheduled Pinned Locked Moved Troubleshooting
27 Posts 4 Posters 9.7k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Dean
    wrote on last edited by
    #16

    I'm still trying.... Now I am using Firefox and the errors have gone back up to a total of 62 errors. I just tried it again with Chrome, and it too is reporting the same number of errors.

    1 Reply Last reply
    0
    • D Offline
      D Offline
      Dean
      wrote on last edited by
      #17

      Time to give up for a while. Already lost a day trying to get this to work....

      1 Reply Last reply
      0
      • D Offline
        D Offline
        Dean
        wrote on last edited by
        #18

        It's annoying me that I can't get this to work lol

        As a test, I tried verifying the code using Codebender for the serial gateway, and I get the same result. 62 errors.

        When I hover the mouse over this : #include <stdarg.h> it says "file not detected"

        :-(

        1 Reply Last reply
        0
        • D Offline
          D Offline
          Dean
          wrote on last edited by
          #19

          I don't think there is any point continuing to try and sort this out using Codebender. My guess is that the libraries attached to the sketches don't match anymore or something like that, because I have tried both types of gateways, as well as a couple sensors, and I'm getting errors all the time.

          1 Reply Last reply
          0
          • D Offline
            D Offline
            Dean
            wrote on last edited by
            #20

            OK, I am trying again on my computer, and I get a lot further than using Codebender. Again, the message I am getting is this:

            In file included from /Users//Documents/Arduino/libraries/DigitalIO/DigitalIO.h:34,
            from EthernetGateway.ino:34:
            /Users/
            /Documents/Arduino/libraries/DigitalIO/SoftI2cMaster.h: In member function 'bool SoftI2cMaster::writeScl(bool)':
            /Users//Documents/Arduino/libraries/DigitalIO/SoftI2cMaster.h:143: warning: no return statement in function returning non-void
            /Users/
            /Documents/Arduino/libraries/DigitalIO/SoftI2cMaster.h: In member function 'bool SoftI2cMaster::writeSda(bool)':
            /Users/***/Documents/Arduino/libraries/DigitalIO/SoftI2cMaster.h:156: warning: no return statement in function returning non-void

            Can anyone point me in the right direction as to how to fix this?

            1 Reply Last reply
            0
            • hekH Offline
              hekH Offline
              hek
              Admin
              wrote on last edited by
              #21

              This only looks like warnings .. Which IDE version?

              D 1 Reply Last reply
              0
              • hekH hek

                This only looks like warnings .. Which IDE version?

                D Offline
                D Offline
                Dean
                wrote on last edited by
                #22

                @hek said:

                This only looks like warnings .. Which IDE version?

                1.0.6.

                BulldogLowellB 1 Reply Last reply
                0
                • D Dean

                  @hek said:

                  This only looks like warnings .. Which IDE version?

                  1.0.6.

                  BulldogLowellB Offline
                  BulldogLowellB Offline
                  BulldogLowell
                  Contest Winner
                  wrote on last edited by
                  #23

                  @Dean said:

                  /Users/*/Documents/Arduino/libraries/DigitalIO/SoftI2cMaster.h:156: warning: no return statement in function returning non-void

                  ...and they look to be warnings from the library, not your sketch, which would appear with a line number.

                  what does your sketch look like now?

                  1 Reply Last reply
                  0
                  • D Offline
                    D Offline
                    Dean
                    wrote on last edited by
                    #24
                    • Copyright (C) 2013 Henrik Ekblad henrik.ekblad@gmail.com
                    • Contribution by a-lurker
                    • This program is free software; you can redistribute it and/or
                    • modify it under the terms of the GNU General Public License
                    • version 2 as published by the Free Software Foundation.
                    • DESCRIPTION
                    • The EthernetGateway sends data received from sensors to the ethernet link.
                    • The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
                    • The GW code is designed for Arduino 328p / 16MHz. ATmega168 does not have enough memory to run this program.
                    • COMPILING WIZNET (W5100) ETHERNET MODULE
                    • Edit RF24_config.h in (libraries\MySensors\utility) to enable softspi (remove // before "#define SOFTSPI").

                    • VERA CONFIGURATION:
                    • Enter "ip-number:port" in the ip-field of the Arduino GW device. This will temporarily override any serial configuration for the Vera plugin.
                    • E.g. If you want to use the defualt values in this sketch enter: 192.168.178.66:5003
                    • LED purposes:
                      • RX (green) - blink fast on radio message recieved. In inclusion mode will blink fast only on presentation recieved
                      • TX (yellow) - blink fast on radio message transmitted. In inclusion mode will blink slowly
                      • ERR (red) - fast blink on error during transmission error or recieve crc error
                    • See http://www.mysensors.org/build/ethernet_gateway for wiring instructions.

                    */

                    #include <DigitalIO.h> // This include can be removed when using UIPEthernet module
                    #include <SPI.h>
                    #include <MySensor.h>
                    #include <MyGateway.h>
                    #include <stdarg.h>

                    // Use this if you have attached a Ethernet ENC28J60 shields
                    //#include <UIPEthernet.h>

                    // Use this fo WizNET W5100 module and Arduino Ethernet Shield
                    #include <Ethernet.h>

                    #define INCLUSION_MODE_TIME 1 // Number of minutes inclusion mode is enabled
                    #define INCLUSION_MODE_PIN 3 // Digital pin used for inclusion mode button

                    #define RADIO_CE_PIN 5 // radio chip enable
                    #define RADIO_SPI_SS_PIN 6 // radio SPI serial select
                    #define RADIO_ERROR_LED_PIN 7 // Error led pin
                    #define RADIO_RX_LED_PIN 8 // Receive led pin
                    #define RADIO_TX_LED_PIN 9 // the PCB, on board LED

                    #define IP_PORT 5003 // The port you want to open
                    IPAddress myIp (192, 168, 178, 66); // Configure your static ip-address here COMPILE ERROR HERE? Use Arduino IDE 1.5.7 or later!

                    // The MAC address can be anything you want but should be unique on your network.
                    // Newer boards have a MAC address printed on the underside of the PCB, which you can (optionally) use.
                    // Note that most of the Ardunio examples use "DEAD BEEF FEED" for the MAC address.
                    byte mac[] = { 0xDE, 0xED, 0xBE, 0xEF, 0xFE, 0xED }; // DEED BEEF FEED

                    // a R/W server on the port
                    EthernetServer server = EthernetServer(IP_PORT);

                    // No blink or button functionality. Use the vanilla constructor.
                    MyGateway gw(RADIO_CE_PIN, RADIO_SPI_SS_PIN, INCLUSION_MODE_TIME);

                    // Uncomment this constructor if you have leds and include button attached to your gateway
                    //MyGateway gw(RADIO_CE_PIN, RADIO_SPI_SS_PIN, INCLUSION_MODE_TIME, INCLUSION_MODE_PIN, RADIO_RX_LED_PIN, RADIO_TX_LED_PIN, RADIO_ERROR_LED_PIN);

                    char inputString[MAX_RECEIVE_LENGTH] = ""; // A string to hold incoming commands from serial/ethernet interface
                    int inputPos = 0;

                    void setup()
                    {
                    // Initialize gateway at maximum PA level, channel 70 and callback for write operations
                    gw.begin(RF24_PA_LEVEL_GW, RF24_CHANNEL, RF24_DATARATE, writeEthernet);

                    Ethernet.begin(mac, myIp);

                    // give the Ethernet interface a second to initialize
                    delay(1000);

                    // start listening for clients
                    server.begin();
                    }

                    // This will be called when data should be written to ethernet
                    void writeEthernet(char *writeBuffer) {
                    server.write(writeBuffer);
                    }

                    void loop()
                    {
                    // if an incoming client connects, there will be
                    // bytes available to read via the client object
                    EthernetClient client = server.available();

                    if (client) {
                    // if got 1 or more bytes
                    if (client.available()) {
                    // read the bytes incoming from the client
                    char inChar = client.read();

                         if (inputPos<MAX_RECEIVE_LENGTH-1) { 
                           // if newline then command is complete
                           if (inChar == '\n') {  
                              // a command was issued by the client
                              // we will now try to send it to the actuator
                              inputString[inputPos] = 0;
                    
                              // echo the string to the serial port
                              Serial.print(inputString);
                    
                              gw.parseAndSend(inputString);
                    
                              // clear the string:
                              inputPos = 0;
                           } else {  
                             // add it to the inputString:
                             inputString[inputPos] = inChar;
                             inputPos++;
                           }
                        } else {
                           // Incoming message too long. Throw away 
                           inputPos = 0;
                        }
                      }
                    

                    }
                    gw.processRadioMessage();
                    }

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      Dean
                      wrote on last edited by
                      #25

                      Sorry it looks like a mess. It is the same as the example on this site.

                      I will see if I can work out how to post it in a more readable way.

                      1 Reply Last reply
                      0
                      • D Offline
                        D Offline
                        Dean
                        wrote on last edited by
                        #26
                        This post is deleted!
                        1 Reply Last reply
                        0
                        • D Offline
                          D Offline
                          Dean
                          wrote on last edited by
                          #27

                          Look like the problem all along was the sketch that I copied from Codebender. In the end it appears that I wasn't the only problem with the issue, and this is where I found the fix : http://forum.mysensors.org/topic/737/uno-w5100-shield-not-pinging

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          15

                          Online

                          11.7k

                          Users

                          11.2k

                          Topics

                          113.1k

                          Posts


                          Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • MySensors
                          • OpenHardware.io
                          • Categories
                          • Recent
                          • Tags
                          • Popular