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

Unify comment types #96

Closed
stylesuxx opened this issue May 24, 2023 · 2 comments
Closed

Unify comment types #96

stylesuxx opened this issue May 24, 2023 · 2 comments
Milestone

Comments

@stylesuxx
Copy link
Contributor

In an attempt to unify the code, I suggest the following types of comments and their structure

Types of comments:

  • Inline comment - starts at char 35 if possible, prefixed with a single ;
    clr ACAB                       ; Comment comes here and relates to this line only
  • Banner comments in header of a file and to describe a section in great detail should have the following format:
;**** **** **** **** **** **** **** **** **** **** **** **** ****
;
; HEADLINE
;
; DESCRIPTION 1
; DESCRIPTION 2
;
;**** **** **** **** **** **** **** **** **** **** **** **** ****
  • Headlines should help to quickly scan the code and group it into logical sections - only one line:
;**** **** **** **** **** **** **** **** **** **** **** **** ****
; HEADLINE
;**** **** **** **** **** **** **** **** **** **** **** **** ****
  • Label descriptors should be one or multiple lines of comments to describe the label in more detail
; A short description to provide more context to the label
label:
    ....
  • Line descriptors should explain what the following line(s) do, it should be aligned with the next line
play_beep_melody_loop:
    ; Read current location at Eep_Pgm_Beep_Melody to Temp4...
    clr  A
@damosvil
Copy link
Contributor

damosvil commented Jun 2, 2023

Agreed

@stylesuxx
Copy link
Contributor Author

Added to Wiki as reference: https://github.com/bird-sanctuary/bluejay/wiki/Development

@stylesuxx stylesuxx added this to the v0.20.0 milestone Jun 15, 2023
stylesuxx added a commit that referenced this issue Jul 14, 2023
* Codebase splitted in modules
* Updated makefile for splitting
* 'Cherry picked' 0.19.2 bugfix.
* Update editorconfig
* Removed dangling ENDIF
* Open bootloader file with banner
* Add autoformatter and linting tool
* Initial pass with the formatter
* Disable comment formatting by default (except inline comments)
* Make sure all files end with an empty line
* Unified comments in layout files according to #96
* Unified comments in accordance to #96
* Unified pinouts in main and layout files #13
* Do not remove spaces in inline comments
* Last pass with the formatter
* This commit reduces the scheduler timebase from 16ms to 128ms to interfere the minimum with commutation
* Refactored duplicate assignments #99 (#101)
* Refactored duplicate assignments
* Refactored CSEG definitions into separate file
* Refactored MCU types and checks
* Fixed check time bug and replaced schedule time literals by macros
* Replaced Stop_Adc and Start_Adc macro calls by Reastart_Adc macro call
* Updated names to more descriptive.
Added parameter to select timebase depending on the needs. Scheduler cycle set to 1024ms by default.
* Add 'enums' for PWM frequency and resolution #103 (#104)
* Bugfix/bring back bidirectional 3d mode (#105)
* Fixed temperature limiting affecting to 3D mode.
* Fixed Pwm_Limit_By_Rpm to match comments concept
* Implemented EDT safety arm feature
* Disable temp protection by default #95 (#100)
* Add ENUM for DSHOT commands (#117)
* Refactored MCU specific offsets to separate module (#116)
* Use a single macro for values. (#120)
* Renamed functions to improve readability
* Update melody size and tag count to be a single macro
* Implemented lock and unlock flash macros (#121)
* Refactored 16 bit division by two into seperate macro #112 (#119)
* Initial draft for supporter section (#89)
* Bump version number and mark as DEV version #122 (#124)
* Add TuneRC and T-Motor to the supporter section #85
* Add functionality to support two char layouts. Add OA layout. #113 (#114)
* Removed relative jumps (#126)
* Added/improved a couple of comments to better explain what is going on. (#107)
* Improved documentation, unified formatting, added explanations where necessary.
* Disable dithering by default (#130)
* Allow version string to be passed to Makefile via buildscript (for naming resulting files) (#128)
* RC7 tag (#132)
* Apply version also if building all files
* Fixed RC version
* Further reducing motor speed before changing direction in 3D bidirectional mode (#138)
* RC10
* Add happymodel and weebleed to the 'Supporters' section #139 (#140)
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