You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've recently embarked on a journey to learn and experiment with VESC Express, starting with a DIY setup based on the ESP32-C3 Super Mini. As a beginner, I was hoping to find straightforward examples to kickstart my project, similar to the basic "blink" LED examples found in many development environments.
While I successfully implemented a simple LED blink program on GPIO 8, I'm aiming to delve into more complex scenarios. Specifically, I'm interested in controlling the LED (connected to GPIO 8 of the ESP32-C3) based on the brake signal's state, intending to turn on the LED whenever the brake is applied.
This functionality, I believe, would not only serve my learning curve but could also benefit others in the community, providing a practical example of integrating VESC's control signals with external hardware actions.
Below is the "blink" example I've managed to implement, which I'm sharing in the hopes it might assist someone else starting out:
;; Configure GPIO 8 as an output
(print"Start")
(gpio-configure 8'pin-mode-out)
(gpio-write 81)
;; Define a recursive function to blink the LED without using `loop`
(defunblink-led ()(progn
(gpio-write 81) ;; Turn LED on
(print"led on")
(sleep1) ;; Wait for 1000 milliseconds (1 second)
(gpio-write 80) ;; Turn LED off
(print"led off")
(sleep1) ;; Wait for 1000 milliseconds (1 second)
(blink-led))) ;; Recursively call blink-led to continue the loop;; Call the blink-led function to start blinking the LED
(blink-led)
The text was updated successfully, but these errors were encountered:
Hello VESC Express Team,
I've recently embarked on a journey to learn and experiment with VESC Express, starting with a DIY setup based on the ESP32-C3 Super Mini. As a beginner, I was hoping to find straightforward examples to kickstart my project, similar to the basic "blink" LED examples found in many development environments.
While I successfully implemented a simple LED blink program on GPIO 8, I'm aiming to delve into more complex scenarios. Specifically, I'm interested in controlling the LED (connected to GPIO 8 of the ESP32-C3) based on the brake signal's state, intending to turn on the LED whenever the brake is applied.
This functionality, I believe, would not only serve my learning curve but could also benefit others in the community, providing a practical example of integrating VESC's control signals with external hardware actions.
Below is the "blink" example I've managed to implement, which I'm sharing in the hopes it might assist someone else starting out:
The text was updated successfully, but these errors were encountered: