-
-
Notifications
You must be signed in to change notification settings - Fork 533
MSG Style Guide
bdring edited this page Dec 9, 2020
·
4 revisions
Grbl has a standard for non queried feedback. It uses the use a [MSG: xxxx] format. Senders can do what they want with these messages, but must be able to deal with or ignore any that are in this format. The primary reader of these messages is human eyes. It is not a protocol.
Grbl_ESP32 uses a lot of MSGs to show the setup and at key events. It may not be of use to senders but, it is crucial for effective support.
While anything in the [MSG:xxxxx] format should be fine, to make messages as clear and consistent as possible use this style guide.
Use the grbl_msg_sendf(...) function.
- MsgLvl::Info This is used for virtually everything now.
- Start with axis letter or item number if applicable. Do not include the word axis if it is obvious from the letter.
- Descriptions shall have first word capitalized only
- Each parameter should be capitalized followed by a colon. No space after the colon
- Use the GPIO formatting function for consistency
The messages below are formatted correctly
[MSG:Grbl_ESP32 Ver 1.3a Date 20201207]
[MSG:Compiled with ESP32 SDK:v3.2.3-14-gd3e562907]
[MSG:Using machine:6 Pack Controller StepStick XYZ]
[MSG:Axis count:3]
[MSG:I2S steps Mode:Stream]
[MSG:Init motors]
[MSG:Using stepStick mode]
[MSG:X Motor:Standard stepper Step:I2SO(2) Dir:I2SO(1) Disable:I2SO(0) Limits(0.000,300.000)]
[MSG:Y Motor:Standard stepper Step:I2SO(5) Dir:I2SO(4) Disable:I2SO(7) Limits(-300.000,0.000)]
[MSG:Z Motor:Standard stepper Step:I2SO(10) Dir:I2SO(9) Disable:I2SO(8) Limits(-300.000,0.000)]
[MSG:0 Macro pin:GPIO(2)]
[MSG:1 Macro pin:GPIO(25)]
[MSG:2 Macro pin:GPIO(39)]
[MSG:3 Macro pin:GPIO(36)]
[MSG:0 User digital output:I2SO(24)]
[MSG:1 User digital output:I2SO(25)]
[MSG:2 User digital output:I2SO(26)]
[MSG:3 User digital output:I2SO(27)]
[MSG:Laser Pin:GPIO(15), Enbl:GPIO(12), Freq:5000Hz, Res:13bits Laser mode:On]
[MSG:Client started]
[MSG:Connecting Barts-WLAN]
[MSG:Connecting.]
[MSG:Connecting..]
[MSG:Connecting...]
[MSG:Connecting....]
[MSG:Connecting.]
[MSG:Connecting..]
[MSG:Connecting...]
[MSG:Connecting....]
[MSG:Connected:192.168.1.28]
[MSG:Start mDNS hostname:http://grblesp.local/]
[MSG:SSDP Started]
[MSG:HTTP Started]
[MSG:TELNET Started Port:23]
[MSG:X Limit switch:GPIO(33)]
[MSG:Y Limit switch:GPIO(32)]
[MSG:Z Limit switch:GPIO(35)]
- Home
- Hardware
- ESP32 Dev Kit Versions
- Compiling with Arduino IDE
- Compiling with PlatformIO
- Using the Serial Port
- Grbl_ESP32 Settings
- Controlling Grbl_ESP32
- Setting Up the I/O pins
- Spindle Types
- Basic Kinematics
- Custom Machine Functions
- Home/Limit Switches
- Machine Work Space
- Stepper Motor Drivers
- Trinamic Drivers
- Axis Squaring and Ganging
- Settings
- SD Card
- Bluetooth
- Wifi
- WebUI
- Using Telnet
- Servo Axis
- Push notifications
- Switches
- Stepper Drivers
- Spindle options
- Other Ouputs
Testing public edit