Skip to content
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

LED is not blinking #69

Open
technical-publishing opened this issue Apr 20, 2022 · 3 comments
Open

LED is not blinking #69

technical-publishing opened this issue Apr 20, 2022 · 3 comments

Comments

@technical-publishing
Copy link

Hello there and thank you so much for your great library and work. I want to start playing around with the ULP copro and as a first step, I want to get the blinky example getting to run. I am working with micropython 1.18 on Heltec Wifi Kit32. On this board, the onboard LED is on GPIO25, so I have changed the definition to:

#define RTCIO_GPIO25_CHANNEL 6

If I start the program it will run without an error and I still can see the print output changing from 1 to 0 and vice versa, but the LED doesn´t light. Could you give me a hint, of what I am doing wrong?

Thanks in advance and best regards,
Werner

@wnienhaus
Copy link
Collaborator

I had a quick look and I have the feeling the PIN might not be in output mode.

This line sets the output mode: https://github.com/micropython/micropython-esp32-ulp/blob/master/examples/blink.py#L63

Did you change the RTC_IO_TOUCH_PAD2_REG and RTC_IO_TOUCH_PAD2_MUX_SEL_M appropriately? As per this mapping table, those constants need to be changed to RTC_IO_PAD_DAC1_REG and RTC_IO_PDAC1_MUX_SEL_M respectively (see comments at the end of each line of the table for the "normal" GPIO pin number for reference).

Give it a try. If that doesn't do it - I happen to have a "Heltek Wireless Stick", which also has its onboard LED on GPIO 25 / RTC 6, so I could test it on my board at some point.

@technical-publishing
Copy link
Author

That`s exactly the point! Thanks a lot for your great support. I have changed the two definitions and now it works. Thanks again!

@wnienhaus
Copy link
Collaborator

Thanks for letting me know. I will try update the example file to better explain this for future users.

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

No branches or pull requests

2 participants