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

[BUG] EMERGENCY_PARSER broken on LPC after #17953 (Fix host_action_notify calls passing SRAM pointers) #17955

Closed
thisiskeithb opened this issue May 11, 2020 · 5 comments

Comments

@thisiskeithb
Copy link
Member

thisiskeithb commented May 11, 2020

Bug Description

After PR #17953 "Fix host_action_notify calls passing SRAM pointers", I can no longer compile with EMERGENCY_PARSER enabled on LPC1768:

In file included from Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/HAL.h:45,
                 from Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/HAL.h:26,
                 from Marlin/src/HAL/LPC1768/../../feature/../inc/MarlinConfig.h:30,
                 from Marlin/src/HAL/LPC1768/../../feature/host_actions.h:24,
                 from Marlin/src/HAL/LPC1768/../../feature/e_parser.h:31,
                 from Marlin/src/HAL/LPC1768/usb_serial.cpp:28:
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h:59:5: error: 'EmergencyParser' does not name a type
   59 |     EmergencyParser::State emergency_state;
      |     ^~~~~~~~~~~~~~~
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h: In constructor 'MarlinSerial::MarlinSerial(LPC_UART_TypeDef*)':
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h:47:9: error: class 'MarlinSerial' does not have any field named 'emergency_state'
   47 |       , emergency_state(EmergencyParser::State::EP_RESET)
      |         ^~~~~~~~~~~~~~~
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h:47:25: error: 'EmergencyParser' has not been declared
   47 |       , emergency_state(EmergencyParser::State::EP_RESET)
      |                         ^~~~~~~~~~~~~~~
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h: In member function 'virtual bool MarlinSerial::recv_callback(char)':
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h:55:7: error: 'emergency_parser' was not declared in this scope
   55 |       emergency_parser.update(emergency_state, c);
      |       ^~~~~~~~~~~~~~~~
Marlin/src/HAL/LPC1768/../../feature/../inc/../HAL/./LPC1768/MarlinSerial.h:55:31: error: 'emergency_state' was not declared in this scope
   55 |       emergency_parser.update(emergency_state, c);
      |                               ^~~~~~~~~~~~~~~
*** [.pio/build/LPC1768/src/src/HAL/LPC1768/usb_serial.cpp.o] Error 1

Dropping the commit (00e7599), I can compile successfully.

My Configurations

SKR 1.4-based config with the issue and SKR 1.3-based config with the issue

Steps to Reproduce

  1. Use an SKR 1.4 or SKR 1.3 (LPC1768 and probably other LPC-based boards), enableEMERGENCY_PARSER
  2. Compile & observe errors

Expected behavior: Successful compile.

Actual behavior: Compilation fails

@thisiskeithb thisiskeithb changed the title [BUG] Can't compile after PR #17953 (Fix host_action_notify calls passing SRAM pointers) [BUG] EMERGENCY_PARSER broken on LPC after #17953 (Fix host_action_notify calls passing SRAM pointers) May 11, 2020
@thisiskeithb
Copy link
Member Author

thisiskeithb commented May 12, 2020

Fixed in #17961.

@Evg33
Copy link
Contributor

Evg33 commented May 12, 2020

skr 1.4T LPC1769
enabled #define EMERGENCY_PARSER
sources after 2f3077f

Compiling .pio\build\LPC1769\src\src\HAL\shared\backtrace\backtrace.cpp.o
In file included from d:\cod\marlin\marlin\src\hal\lpc1768\hal.h:45,
                 from d:\cod\marlin\marlin\src\hal\hal.h:26,
                 from d:\cod\marlin\marlin\src\inc\marlinconfig.h:30,
                 from d:\cod\marlin\marlin\src\feature\host_actions.h:24,
                 from d:\cod\marlin\marlin\src\feature\e_parser.h:31,
                 from Marlin\src\HAL\LPC1768\usb_serial.cpp:28:
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h:59:5: error: 'EmergencyParser' does not name a type
   59 |     EmergencyParser::State emergency_state;
      |     ^~~~~~~~~~~~~~~
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h: In constructor 'MarlinSerial::MarlinSerial(LPC_UART_TypeDef*)':
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h:47:9: error: class 'MarlinSerial' does not have any field named 'emergency_state'
   47 |       , emergency_state(EmergencyParser::State::EP_RESET)
      |         ^~~~~~~~~~~~~~~
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h:47:25: error: 'EmergencyParser' has not been declared
   47 |       , emergency_state(EmergencyParser::State::EP_RESET)
      |                         ^~~~~~~~~~~~~~~
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h: In member function 'virtual bool MarlinSerial::recv_callback(char)':
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h:55:7: error: 'emergency_parser' was not declared in this scope
   55 |       emergency_parser.update(emergency_state, c);
      |       ^~~~~~~~~~~~~~~~
d:\cod\marlin\marlin\src\hal\lpc1768\MarlinSerial.h:55:31: error: 'emergency_state' was not declared in this scope
   55 |       emergency_parser.update(emergency_state, c);
      |                               ^~~~~~~~~~~~~~~
*** [.pio\build\LPC1769\src\src\HAL\LPC1768\usb_serial.cpp.o] Error 1
============================================= [FAILED] Took 12.38 seconds =============================================

@thisiskeithb
Copy link
Member Author

thisiskeithb commented May 12, 2020

@Evg33 You have to wait for either #17961 to be merged, pull in the changes from the PR to your branch, or temporarily disable EMERGENCY_PARSER.

@thisiskeithb
Copy link
Member Author

I'll reopen this issue for now so its clear that EMERGENCY_PARSER is still broken until that PR is merged.

@thisiskeithb thisiskeithb reopened this May 12, 2020
thinkyhead added a commit that referenced this issue May 12, 2020
vgadreau pushed a commit to vgadreau/Marlin that referenced this issue May 29, 2020
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators Jul 11, 2020
jmp0x0000 pushed a commit to jmp0x0000/Marlin that referenced this issue Aug 7, 2020
njibhu pushed a commit to njibhu/Marlin that referenced this issue Aug 24, 2020
HairingX pushed a commit to HairingX/Marlin that referenced this issue Jun 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants