Giter VIP home page Giter VIP logo

esp8266_isr_servo's Issues

use both servo and analogWrite on esp8266

thanks you for this library.

Describe the bug

ISR_Servo.setPosition() is not available after calling analogWrite()

Steps to Reproduce

when i calling analogWrite(12,128) servo is not available.

void setup()
{
  Serial.begin(115200);
  while (!Serial);

  delay(200);

  Serial.println(ESP8266_ISR_SERVO_VERSION);
  servoIndex1 = ISR_Servo.setupServo(14, MIN_MICROS, MAX_MICROS);
  ISR_Servo.setPosition(servoIndex1, 0);
  
  //servo is not available after this code  
  analogWrite(12,128);
}
void loop()
{
  int position;
  delay(2000);
  if ( ( servoIndex1 != -1) )
  {
    for (position = 0; position <= 180; position++)
    {
      ISR_Servo.setPosition(servoIndex1, position);
      delay(5  /*15*/);
    }
    delay(2000);
    for (position = 180; position >= 0; position--)
    {
      ISR_Servo.setPosition(servoIndex1, position);
      delay(5  /*15*/);
    } 
  }
}

D7 and D8 not defined in ESP8266_ISR_MultiServos.ino

Describe the bug

D7 and D8 not defined in ESP8266_ISR_MultiServos.ino

Steps to Reproduce

Attempt to Verify the .ino file in Arduion IDE

Expected behavior

No errors

Actual behavior


C:\Users\media\AppData\Local\Temp\.arduinoIDE-unsaved2022611-10312-15pdb1.j1r1l\sketch_jul11b\sketch_jul11b.ino: In function 'void setup()':
C:\Users\media\AppData\Local\Temp\.arduinoIDE-unsaved2022611-10312-15pdb1.j1r1l\sketch_jul11b\sketch_jul11b.ino:98:38: error: 'D8' was not declared in this scope; did you mean 's8'?
   98 |   servoIndex1 = ISR_Servo.setupServo(D8, MIN_MICROS, MAX_MICROS);
      |                                      ^~
      |                                      s8
C:\Users\media\AppData\Local\Temp\.arduinoIDE-unsaved2022611-10312-15pdb1.j1r1l\sketch_jul11b\sketch_jul11b.ino:99:38: error: 'D7' was not declared in this scope
   99 |   servoIndex2 = ISR_Servo.setupServo(D7, MIN_MICROS, MAX_MICROS);
      |                                      ^~

exit status 1

Compilation error: 'D8' was not declared in this scope; did you mean 's8'?

Debug and AT-command log (if applicable)

A clear and concise description of what you expected to happen.

Screenshots

If applicable, add screenshots to help explain your problem.

Information

After adding the following, the code verifies OK:

int D8;
int D7;

  • Arduino IDE version (e.g. 1.8.13) or Platform.io version
  • ESP8266,ESP32 or STM32 Core Version (e.g. ESP8266 core v2.7.4, ESP32 v1.0.5 or STM32 v1.9.0)
  • Contextual information (e.g. what you were trying to achieve)
  • Simplest possible steps to reproduce
  • Anything that might be relevant in your opinion, such as:
    • Operating system (Windows, Ubuntu, etc.) and the output of uname -a
    • Network configuration

Example


### Additional context

Add any other context about the problem here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.