grblHAL core  20241107
plugins_init.h
Go to the documentation of this file.
1 /*
2  plugins_init.h - An embedded CNC Controller with rs274/ngc (g-code) support
3 
4  Calls the init function of enabled plugins, may be included at the end of the drivers driver_init() implementation.
5 
6  These are NOT referenced in the core grbl code
7 
8  Part of grblHAL
9 
10  Copyright (c) 2021-2023 Terje Io
11 
12  Grbl is free software: you can redistribute it and/or modify
13  it under the terms of the GNU General Public License as published by
14  the Free Software Foundation, either version 3 of the License, or
15  (at your option) any later version.
16 
17  Grbl is distributed in the hope that it will be useful,
18  but WITHOUT ANY WARRANTY; without even the implied warranty of
19  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  GNU General Public License for more details.
21 
22  You should have received a copy of the GNU General Public License
23  along with Grbl. If not, see <http://www.gnu.org/licenses/>.
24 */
25 
26 #if TRINAMIC_ENABLE
27  extern bool trinamic_init (void);
28  trinamic_init();
29 #endif
30 
31 #if PLASMA_ENABLE
32  extern void plasma_init (void);
33  plasma_init();
34 #endif
35 
36 #if MODBUS_ENABLE && (MODBUS_ENABLE & 0x01)
37  extern void modbus_rtu_init (void);
38  modbus_rtu_init();
39 #endif
40 
41 #if CANBUS_ENABLE
42  extern void canbus_init (void);
43  canbus_init();
44 #endif
45 
46 #if SPINDLE_ENABLE & (1<<SPINDLE_PWM0_CLONE)
47  extern void cloned_spindle_init (void);
48  cloned_spindle_init();
49 #endif
50 
51 #if SPINDLE_ENABLE & (1<<SPINDLE_STEPPER)
52  extern void stepper_spindle_init (void);
53  stepper_spindle_init();
54 #endif
55 
56 #if SPINDLE_ENABLE & ((1<<SPINDLE_ONOFF1)|(1<<SPINDLE_ONOFF1_DIR))
57  extern void onoff_spindle_init (void);
58  onoff_spindle_init();
59 #endif
60 
61 #if SPINDLE_ENABLE & (1<<SPINDLE_PWM2)
62  extern void pwm_spindle_init (void);
63  pwm_spindle_init();
64 #endif
65 
66 #if VFD_ENABLE
67  extern void vfd_init (void);
68  vfd_init();
69 #endif
70 
71 #if BLUETOOTH_ENABLE > 1
72  extern void bluetooth_init (void);
73  bluetooth_init();
74 #endif
75 
76 #if ESP_AT_ENABLE
77  extern void esp_at_init (void);
78  esp_at_init();
79 #endif
80 
81 #if KEYPAD_ENABLE
82  extern bool keypad_init (void);
83  keypad_init();
84 #endif
85 
86 #if MACROS_ENABLE
87  extern bool macros_init (void);
88  macros_init();
89 #endif
90 
91 #if LASER_COOLANT_ENABLE
92  extern void laser_coolant_init (void);
93  laser_coolant_init();
94 #endif
95 
96 #if FANS_ENABLE
97  extern void fans_init (void);
98  fans_init();
99 #endif
100 
101 #if OPENPNP_ENABLE
102  extern void openpnp_init (void);
103  openpnp_init();
104 #endif
105 
106 #if LB_CLUSTERS_ENABLE
107  extern void lb_clusters_init (void);
108  lb_clusters_init();
109 #endif
110 
111 #if PROBE_PROTECT_ENABLE
112  extern void probe_protect_init (void);
113  probe_protect_init();
114 #endif
115 
116 #if WEBUI_ENABLE
117  extern void webui_init (void);
118  webui_init();
119 #endif
120 
121 #if EMBROIDERY_ENABLE
122  extern void embroidery_init (void);
123  embroidery_init();
124 #endif
125 
126 #if RGB_LED_ENABLE
127  extern void rgb_led_init (void);
128  rgb_led_init();
129 #endif
130 
131  extern void my_plugin_init (void);
132  my_plugin_init();
133 
134 #if N_SPINDLE > 1
135  extern void spindle_select_init(void);
136  spindle_select_init();
137  #if SPINDLE_OFFSET == 1
138  extern void spindle_offset_init (void);
139  spindle_offset_init();
140  #endif
141 #endif
142 
143 // Third party plugin definitions.
144 // The code for these has to be downloaded from the source and placed in the same folder as driver.c
145 // Note: Third party plugins may have more than one implementation, there is no "owner" of plugins listed here.
146 // It is also guaranteed that there will be no implementation in the grblHAL repository of these.
147 
148 #if PWM_SERVO_ENABLE
149  extern void pwm_servo_init (void);
150  pwm_servo_init();
151 #endif
152 
153 #if BLTOUCH_ENABLE
154  extern void bltouch_init (void);
155  bltouch_init();
156 #endif
157 
158 #if ATC_ENABLE
159  extern void atc_init (void);
160  atc_init();
161 #endif
162 
163 #if PROBE_RELAY_ENABLE
164  extern void probe_relay_init (void);
165  probe_relay_init();
166 #endif
167 
168 #if DISPLAY_ENABLE
169  void display_init (void);
170  display_init();
171 #endif
172 
173 #if STATUS_LIGHT_ENABLE
174  extern void status_light_init (void);
175  status_light_init();
176 #endif
177 
178 #if PANEL_ENABLE
179  extern void panel_init (void);
180  panel_init();
181 #endif
182 
183 #if EVENTOUT_ENABLE
184  extern void event_out_init (void);
185  event_out_init();
186 #endif
187 
188 // End third party plugin definitions.
189 
190 #if ODOMETER_ENABLE
191  extern void odometer_init (void);
192  odometer_init(); // NOTE: this *must* be last plugin to be initialized as it claims storage at the end of NVS.
193 #endif
194 
195 /*EOF*/
void canbus_init(void)
Definition: canbus.c:199
void my_plugin_init(void)