pleasedontcode

LED Control rev_01

Apr 29th, 2024
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /********* Pleasedontcode.com **********
  2.  
  3.     Pleasedontcode thanks you for automatic code generation! Enjoy your code!
  4.  
  5.     - Terms and Conditions:
  6.     You have a non-exclusive, revocable, worldwide, royalty-free license
  7.     for personal and commercial use. Attribution is optional; modifications
  8.     are allowed, but you're responsible for code maintenance. We're not
  9.     liable for any loss or damage. For full terms,
  10.     please visit pleasedontcode.com/termsandconditions.
  11.  
  12.     - Project: LED Control
  13.     - Source Code NOT compiled for: Arduino Uno
  14.     - Source Code created on: 2024-04-29 12:40:06
  15.  
  16. ********* Pleasedontcode.com **********/
  17.  
  18. /****** SYSTEM REQUIREMENTS *****/
  19. /****** SYSTEM REQUIREMENT 1 *****/
  20.     /* turn on LED automatically */
  21. /****** END SYSTEM REQUIREMENTS *****/
  22.  
  23. /****** DEFINITION OF LIBRARIES *****/
  24.  
  25. #include <Arduino.h>
  26.  
  27. /****** FUNCTION PROTOTYPES *****/
  28. void setup(void);
  29. void loop(void);
  30. void updateOutputs(void);
  31.  
  32. /***** DEFINITION OF DIGITAL OUTPUT PINS *****/
  33. const uint8_t gggggg_LED_PIN_D2 = 2;
  34.  
  35. /***** DEFINITION OF OUTPUT RAW VARIABLES *****/
  36. /***** used to store raw data *****/
  37. bool gggggg_LED_PIN_D2_rawData = 1; // Initial value set to turn on LED automatically
  38.  
  39. /***** DEFINITION OF OUTPUT PHYSICAL VARIABLES *****/
  40. /***** used to store data after characteristic curve transformation *****/
  41. float gggggg_LED_PIN_D2_phyData = 0.0;
  42.  
  43. void setup(void)
  44. {
  45.     // put your setup code here, to run once:
  46.     pinMode(gggggg_LED_PIN_D2, OUTPUT);
  47.  
  48.     // Initial state to turn on LED automatically
  49.     digitalWrite(gggggg_LED_PIN_D2, gggggg_LED_PIN_D2_rawData);
  50. }
  51.  
  52. void loop(void)
  53. {
  54.     // put your main code here, to run repeatedly:
  55.     updateOutputs(); // Refresh output data
  56. }
  57.  
  58. void updateOutputs()
  59. {
  60.     digitalWrite(gggggg_LED_PIN_D2, gggggg_LED_PIN_D2_rawData);
  61. }
  62.  
Add Comment
Please, Sign In to add comment