Skip to content

Some function not exposed on 3.0.0-alpha #8753

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
1 task done
frdoni opened this issue Oct 10, 2023 · 7 comments
Closed
1 task done

Some function not exposed on 3.0.0-alpha #8753

frdoni opened this issue Oct 10, 2023 · 7 comments
Assignees
Labels
Type: Question Only question

Comments

@frdoni
Copy link

frdoni commented Oct 10, 2023

Board

ESP32 DEVKIT V1

Device Description

Trying new 3.0.0-alpha version, my sketch don't compile because some internal function seems not be exposed anymore:

error: 'esp_random' was not declared in this scope; did you mean 'srandom'?

error: 'ledcAttachPin' was not declared in this scope; did you mean 'ledcAttach'?

error: 'ledcSetup' was not declared in this scope

Hardware Configuration

no special configuration

Version

latest development Release Candidate (RC-X)

IDE Name

Arduino IDE V2

Operating System

Win11 x64

Flash frequency

80Mhz

PSRAM enabled

yes

Upload speed

115200

Description

Can't compile on 3.0.0-alpha

Sketch

int i = esp_random() % 10;

ledcSetup(GPIO_NUM_18, 100, 8);

ledcAttachPin(GPIO_NUM_18, 0);

Debug Message

exit status 1

Compilation error: 'esp_random' was not declared in this scope; did you mean 'srandom'?

Other Steps to Reproduce

on 2.0.x version it's compile correctly

I have checked existing issues, online documentation and the Troubleshooting Guide

  • I confirm I have checked existing issues, online documentation and Troubleshooting guide.
@frdoni frdoni added the Status: Awaiting triage Issue is waiting for triage label Oct 10, 2023
@me-no-dev
Copy link
Member

Functions have changed. Maybe wait for the update guide to come out?

@P-R-O-C-H-Y P-R-O-C-H-Y self-assigned this Oct 11, 2023
@P-R-O-C-H-Y
Copy link
Member

@frdoni LEDC functions have changed, migration guide and documentation is almost ready.
For esp_random() function you need add an include #include "esp_random.h".

I am closing this as there won't be any action needed.

@P-R-O-C-H-Y P-R-O-C-H-Y added Type: Question Only question and removed Status: Awaiting triage Issue is waiting for triage labels Oct 11, 2023
@atchoo78
Copy link

@frdoni LEDC functions have changed, migration guide and documentation is almost ready.

Where can I find it? I'm getting ledc errors all over the place.

@me-no-dev
Copy link
Member

here is the PR with it being worked on: #8716

@P-R-O-C-H-Y
Copy link
Member

@frdoni another option to check LEDC API docs source file or reworked examples.

@frdoni
Copy link
Author

frdoni commented Oct 13, 2023 via email

@atchoo78
Copy link

Thanks, @P-R-O-C-H-Y. I figured it out by looking at the new AnalogOut LEDC examples 👍🏼

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Question Only question
Projects
None yet
Development

No branches or pull requests

4 participants