Skip to content

Commit

Permalink
Remove legacy print backward compatiblitly (qmk#11805)
Browse files Browse the repository at this point in the history
* Remove legacy print backward compatiblitly

* Remove legacy print backward compatiblitly - core

* revert comment changes
  • Loading branch information
zvecr authored Feb 6, 2021
1 parent 7daa349 commit e98a904
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 23 deletions.
2 changes: 1 addition & 1 deletion quantum/matrix_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ void matrix_print(void) {
print_matrix_header();

for (uint8_t row = 0; row < MATRIX_ROWS; row++) {
phex(row);
print_hex8(row);
print(": ");
print_matrix_row(row);
print("\n");
Expand Down
12 changes: 6 additions & 6 deletions tmk_core/common/command.c
Original file line number Diff line number Diff line change
Expand Up @@ -550,22 +550,22 @@ static void mousekey_param_print(void) {
# if !defined(NO_PRINT) && !defined(USER_PRINT)
print("\n\t- Values -\n");
print("1: delay(*10ms): ");
pdec(mk_delay);
print_dec(mk_delay);
print("\n");
print("2: interval(ms): ");
pdec(mk_interval);
print_dec(mk_interval);
print("\n");
print("3: max_speed: ");
pdec(mk_max_speed);
print_dec(mk_max_speed);
print("\n");
print("4: time_to_max: ");
pdec(mk_time_to_max);
print_dec(mk_time_to_max);
print("\n");
print("5: wheel_max_speed: ");
pdec(mk_wheel_max_speed);
print_dec(mk_wheel_max_speed);
print("\n");
print("6: wheel_time_to_max: ");
pdec(mk_wheel_time_to_max);
print_dec(mk_wheel_time_to_max);
print("\n");
# endif /* !NO_PRINT */
}
Expand Down
2 changes: 1 addition & 1 deletion tmk_core/common/mousekey.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ void mousekey_clear(void) {
static void mousekey_debug(void) {
if (!debug_mouse) return;
print("mousekey [btn|x y v h](rep/acl): [");
phex(mouse_report.buttons);
print_hex8(mouse_report.buttons);
print("|");
print_decs(mouse_report.x);
print(" ");
Expand Down
10 changes: 0 additions & 10 deletions tmk_core/common/print.h
Original file line number Diff line number Diff line change
Expand Up @@ -258,13 +258,3 @@ extern "C"
# define print_val_bin_reverse32(v)

#endif /* NO_PRINT */

/* Backward compatiblitly for old name */
#define pdec(data) print_dec(data)
#define pdec16(data) print_dec(data)
#define phex(data) print_hex8(data)
#define phex16(data) print_hex16(data)
#define pbin(data) print_bin8(data)
#define pbin16(data) print_bin16(data)
#define pbin_reverse(data) print_bin_reverse8(data)
#define pbin_reverse16(data) print_bin_reverse16(data)
8 changes: 4 additions & 4 deletions tmk_core/protocol/m0110.c
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,11 @@ void m0110_init(void) {
uint8_t data;
m0110_send(M0110_MODEL);
data = m0110_recv();
print("m0110_init model: "); phex(data); print("\n");
print("m0110_init model: "); print_hex8(data); print("\n");
m0110_send(M0110_TEST);
data = m0110_recv();
print("m0110_init test: "); phex(data); print("\n");
print("m0110_init test: "); print_hex8(data); print("\n");
*/
}

Expand All @@ -122,7 +122,7 @@ uint8_t m0110_send(uint8_t data) {
return 1;
ERROR:
print("m0110_send err: ");
phex(m0110_error);
print_hex8(m0110_error);
print("\n");
_delay_ms(500);
idle();
Expand All @@ -146,7 +146,7 @@ uint8_t m0110_recv(void) {
return data;
ERROR:
print("m0110_recv err: ");
phex(m0110_error);
print_hex8(m0110_error);
print("\n");
_delay_ms(500);
idle();
Expand Down
2 changes: 1 addition & 1 deletion tmk_core/protocol/ps2_mouse.c
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ static inline void ps2_mouse_clear_report(report_mouse_t *mouse_report) {
static inline void ps2_mouse_print_report(report_mouse_t *mouse_report) {
if (!debug_mouse) return;
print("ps2_mouse: [");
phex(mouse_report->buttons);
print_hex8(mouse_report->buttons);
print("|");
print_hex8((uint8_t)mouse_report->x);
print(" ");
Expand Down

0 comments on commit e98a904

Please sign in to comment.