Have redone over 5 times and always getting " 'rx_buffer' was not declared in this scope " .
Now i tried printer Factory marlin from their site and same " 'rx_buffer' was not declared in this scope " .
Dont know what to do im so lost.
Factory printer had MKS Base V1.4 that broke Now i upgraded to MKS Gen L V1.0 . changed the Config.h file
// The following define selects which electronics board you have.
// Please choose the name from boards.h that matches your setup
#ifndef MOTHERBOARD
#define MOTHERBOARD BOARD_MKS_GEN_L
#endif
and
#define SERIAL_PORT 4
ERROR that im getting
Arduino: 1.8.5 (Windows 10), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"
sketch\MarlinSerial.cpp: In function 'ring_buffer_pos_t atomic_read_rx_head()':
MarlinSerial.cpp:114: error: 'rx_buffer' was not declared in this scope
return rx_buffer.head;
^
sketch\MarlinSerial.cpp: In function 'void atomic_set_rx_tail(ring_buffer_pos_t)':
MarlinSerial.cpp:142: error: 'rx_buffer' was not declared in this scope
rx_buffer.tail = value;
^
sketch\MarlinSerial.cpp: In function 'ring_buffer_pos_t atomic_read_rx_tail()':
MarlinSerial.cpp:155: error: 'rx_buffer' was not declared in this scope
return rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In function 'void store_rxd_char()':
MarlinSerial.cpp:166: error: 'rx_buffer' was not declared in this scope
ring_buffer_pos_t h = rx_buffer.head;
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:67: error: 'UDR4' was not declared in this scope
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:67:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:185:17: note: in expansion of macro 'M_UDRx'
uint8_t c = M_UDRx;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::begin(long int)':
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:391:7: note: in expansion of macro 'M_UCSRxA'
M_UCSRxA = _BV(M_U2Xx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:72: error: 'U2X4' was not declared in this scope
#define M_U2Xx SERIAL_REGNAME(U2X,SERIAL_PORT,)
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:72:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_U2Xx SERIAL_REGNAME(U2X,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:391:22: note: in expansion of macro 'M_U2Xx'
M_UCSRxA = _BV(M_U2Xx);
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:395:7: note: in expansion of macro 'M_UCSRxA'
M_UCSRxA = 0;
^
MarlinSerial.h:68: error: 'UBRR4H' was not declared in this scope
#define M_UBRRxH SERIAL_REGNAME(UBRR,SERIAL_PORT,H)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:68:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UBRRxH SERIAL_REGNAME(UBRR,SERIAL_PORT,H)
^
sketch\MarlinSerial.cpp:400:5: note: in expansion of macro 'M_UBRRxH'
M_UBRRxH = baud_setting >> 8;
^
MarlinSerial.h:69: error: 'UBRR4L' was not declared in this scope
#define M_UBRRxL SERIAL_REGNAME(UBRR,SERIAL_PORT,L)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:69:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UBRRxL SERIAL_REGNAME(UBRR,SERIAL_PORT,L)
^
sketch\MarlinSerial.cpp:401:5: note: in expansion of macro 'M_UBRRxL'
M_UBRRxL = baud_setting;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:57: error: 'UCSR4B' was not declared in this scope
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\macros.h:71:19: note: in definition of macro 'SBI'
#define SBI(n,b) (n |= _BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:57:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\MarlinSerial.cpp:403:9: note: in expansion of macro 'M_UCSRxB'
SBI(M_UCSRxB, M_RXENx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:58: error: 'RXEN4' was not declared in this scope
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:403:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_RXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:58:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:403:19: note: in expansion of macro 'M_RXENx'
SBI(M_UCSRxB, M_RXENx);
^
MarlinSerial.h:59: error: 'TXEN4' was not declared in this scope
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:404:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_TXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:59:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:404:19: note: in expansion of macro 'M_TXENx'
SBI(M_UCSRxB, M_TXENx);
^
MarlinSerial.h:61: error: 'RXCIE4' was not declared in this scope
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:405:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_RXCIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:61:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:405:19: note: in expansion of macro 'M_RXCIEx'
SBI(M_UCSRxB, M_RXCIEx);
^
MarlinSerial.cpp:409: error: '_written' was not declared in this scope
_written = false;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::end()':
MarlinSerial.h:57: error: 'UCSR4B' was not declared in this scope
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\macros.h:72:19: note: in definition of macro 'CBI'
#define CBI(n,b) (n &= ~_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:57:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\MarlinSerial.cpp:413:9: note: in expansion of macro 'M_UCSRxB'
CBI(M_UCSRxB, M_RXENx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:58: error: 'RXEN4' was not declared in this scope
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:413:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_RXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:58:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:413:19: note: in expansion of macro 'M_RXENx'
CBI(M_UCSRxB, M_RXENx);
^
MarlinSerial.h:59: error: 'TXEN4' was not declared in this scope
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:414:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_TXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:59:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:414:19: note: in expansion of macro 'M_TXENx'
CBI(M_UCSRxB, M_TXENx);
^
MarlinSerial.h:61: error: 'RXCIE4' was not declared in this scope
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:415:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_RXCIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:61:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:415:19: note: in expansion of macro 'M_RXCIEx'
CBI(M_UCSRxB, M_RXCIEx);
^
MarlinSerial.h:66: error: 'UDRIE4' was not declared in this scope
#define M_UDRIEx SERIAL_REGNAME(UDRIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:416:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_UDRIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:66:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRIEx SERIAL_REGNAME(UDRIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:416:19: note: in expansion of macro 'M_UDRIEx'
CBI(M_UCSRxB, M_UDRIEx);
^
sketch\MarlinSerial.cpp: In static member function 'static int MarlinSerial::peek()':
MarlinSerial.cpp:420: error: 'rx_buffer' was not declared in this scope
const ring_buffer_pos_t h = atomic_read_rx_head(), t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static int MarlinSerial::read()':
MarlinSerial.cpp:428: error: 'rx_buffer' was not declared in this scope
ring_buffer_pos_t t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static ring_buffer_pos_t MarlinSerial::available()':
MarlinSerial.cpp:466: error: 'rx_buffer' was not declared in this scope
const ring_buffer_pos_t h = atomic_read_rx_head(), t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::write(uint8_t)':
MarlinSerial.cpp:576: error: '_written' was not declared in this scope
_written = true;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\macros.h:70:23: note: in definition of macro 'TEST'
#define TEST(n,b) !!((n)&_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:577:20: note: in expansion of macro 'M_UCSRxA'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:62: error: 'UDRE4' was not declared in this scope
#define M_UDREx SERIAL_REGNAME(UDRE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:577:15: note: in expansion of macro 'TEST'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:62:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDREx SERIAL_REGNAME(UDRE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:577:30: note: in expansion of macro 'M_UDREx'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:67: error: 'UDR4' was not declared in this scope
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:67:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:578:7: note: in expansion of macro 'M_UDRx'
M_UDRx = c;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::flushTX()':
MarlinSerial.cpp:584: error: '_written' was not declared in this scope
if (!_written) return;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\macros.h:70:23: note: in definition of macro 'TEST'
#define TEST(n,b) !!((n)&_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:587:20: note: in expansion of macro 'M_UCSRxA'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:60: error: 'TXC4' was not declared in this scope
#define M_TXCx SERIAL_REGNAME(TXC,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:587:15: note: in expansion of macro 'TEST'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:60:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXCx SERIAL_REGNAME(TXC,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:587:30: note: in expansion of macro 'M_TXCx'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
exit status 1
'rx_buffer' was not declared in this scope
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Now i tried printer Factory marlin from their site and same " 'rx_buffer' was not declared in this scope " .
Dont know what to do im so lost.
Factory printer had MKS Base V1.4 that broke Now i upgraded to MKS Gen L V1.0 . changed the Config.h file
// The following define selects which electronics board you have.
// Please choose the name from boards.h that matches your setup
#ifndef MOTHERBOARD
#define MOTHERBOARD BOARD_MKS_GEN_L
#endif
and
#define SERIAL_PORT 4
ERROR that im getting
Arduino: 1.8.5 (Windows 10), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"
sketch\MarlinSerial.cpp: In function 'ring_buffer_pos_t atomic_read_rx_head()':
MarlinSerial.cpp:114: error: 'rx_buffer' was not declared in this scope
return rx_buffer.head;
^
sketch\MarlinSerial.cpp: In function 'void atomic_set_rx_tail(ring_buffer_pos_t)':
MarlinSerial.cpp:142: error: 'rx_buffer' was not declared in this scope
rx_buffer.tail = value;
^
sketch\MarlinSerial.cpp: In function 'ring_buffer_pos_t atomic_read_rx_tail()':
MarlinSerial.cpp:155: error: 'rx_buffer' was not declared in this scope
return rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In function 'void store_rxd_char()':
MarlinSerial.cpp:166: error: 'rx_buffer' was not declared in this scope
ring_buffer_pos_t h = rx_buffer.head;
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:67: error: 'UDR4' was not declared in this scope
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:67:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:185:17: note: in expansion of macro 'M_UDRx'
uint8_t c = M_UDRx;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::begin(long int)':
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:391:7: note: in expansion of macro 'M_UCSRxA'
M_UCSRxA = _BV(M_U2Xx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:72: error: 'U2X4' was not declared in this scope
#define M_U2Xx SERIAL_REGNAME(U2X,SERIAL_PORT,)
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:72:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_U2Xx SERIAL_REGNAME(U2X,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:391:22: note: in expansion of macro 'M_U2Xx'
M_UCSRxA = _BV(M_U2Xx);
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:395:7: note: in expansion of macro 'M_UCSRxA'
M_UCSRxA = 0;
^
MarlinSerial.h:68: error: 'UBRR4H' was not declared in this scope
#define M_UBRRxH SERIAL_REGNAME(UBRR,SERIAL_PORT,H)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:68:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UBRRxH SERIAL_REGNAME(UBRR,SERIAL_PORT,H)
^
sketch\MarlinSerial.cpp:400:5: note: in expansion of macro 'M_UBRRxH'
M_UBRRxH = baud_setting >> 8;
^
MarlinSerial.h:69: error: 'UBRR4L' was not declared in this scope
#define M_UBRRxL SERIAL_REGNAME(UBRR,SERIAL_PORT,L)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:69:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UBRRxL SERIAL_REGNAME(UBRR,SERIAL_PORT,L)
^
sketch\MarlinSerial.cpp:401:5: note: in expansion of macro 'M_UBRRxL'
M_UBRRxL = baud_setting;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:57: error: 'UCSR4B' was not declared in this scope
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\macros.h:71:19: note: in definition of macro 'SBI'
#define SBI(n,b) (n |= _BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:57:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\MarlinSerial.cpp:403:9: note: in expansion of macro 'M_UCSRxB'
SBI(M_UCSRxB, M_RXENx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:58: error: 'RXEN4' was not declared in this scope
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:403:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_RXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:58:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:403:19: note: in expansion of macro 'M_RXENx'
SBI(M_UCSRxB, M_RXENx);
^
MarlinSerial.h:59: error: 'TXEN4' was not declared in this scope
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:404:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_TXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:59:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:404:19: note: in expansion of macro 'M_TXENx'
SBI(M_UCSRxB, M_TXENx);
^
MarlinSerial.h:61: error: 'RXCIE4' was not declared in this scope
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:405:5: note: in expansion of macro 'SBI'
SBI(M_UCSRxB, M_RXCIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:61:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:405:19: note: in expansion of macro 'M_RXCIEx'
SBI(M_UCSRxB, M_RXCIEx);
^
MarlinSerial.cpp:409: error: '_written' was not declared in this scope
_written = false;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::end()':
MarlinSerial.h:57: error: 'UCSR4B' was not declared in this scope
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\macros.h:72:19: note: in definition of macro 'CBI'
#define CBI(n,b) (n &= ~_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:57:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxB SERIAL_REGNAME(UCSR,SERIAL_PORT,B)
^
sketch\MarlinSerial.cpp:413:9: note: in expansion of macro 'M_UCSRxB'
CBI(M_UCSRxB, M_RXENx);
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:58: error: 'RXEN4' was not declared in this scope
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:413:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_RXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:58:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXENx SERIAL_REGNAME(RXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:413:19: note: in expansion of macro 'M_RXENx'
CBI(M_UCSRxB, M_RXENx);
^
MarlinSerial.h:59: error: 'TXEN4' was not declared in this scope
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:414:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_TXENx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:59:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXENx SERIAL_REGNAME(TXEN,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:414:19: note: in expansion of macro 'M_TXENx'
CBI(M_UCSRxB, M_TXENx);
^
MarlinSerial.h:61: error: 'RXCIE4' was not declared in this scope
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:415:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_RXCIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:61:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_RXCIEx SERIAL_REGNAME(RXCIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:415:19: note: in expansion of macro 'M_RXCIEx'
CBI(M_UCSRxB, M_RXCIEx);
^
MarlinSerial.h:66: error: 'UDRIE4' was not declared in this scope
#define M_UDRIEx SERIAL_REGNAME(UDRIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:416:5: note: in expansion of macro 'CBI'
CBI(M_UCSRxB, M_UDRIEx);
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:66:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRIEx SERIAL_REGNAME(UDRIE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:416:19: note: in expansion of macro 'M_UDRIEx'
CBI(M_UCSRxB, M_UDRIEx);
^
sketch\MarlinSerial.cpp: In static member function 'static int MarlinSerial::peek()':
MarlinSerial.cpp:420: error: 'rx_buffer' was not declared in this scope
const ring_buffer_pos_t h = atomic_read_rx_head(), t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static int MarlinSerial::read()':
MarlinSerial.cpp:428: error: 'rx_buffer' was not declared in this scope
ring_buffer_pos_t t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static ring_buffer_pos_t MarlinSerial::available()':
MarlinSerial.cpp:466: error: 'rx_buffer' was not declared in this scope
const ring_buffer_pos_t h = atomic_read_rx_head(), t = rx_buffer.tail;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::write(uint8_t)':
MarlinSerial.cpp:576: error: '_written' was not declared in this scope
_written = true;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\macros.h:70:23: note: in definition of macro 'TEST'
#define TEST(n,b) !!((n)&_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:577:20: note: in expansion of macro 'M_UCSRxA'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:62: error: 'UDRE4' was not declared in this scope
#define M_UDREx SERIAL_REGNAME(UDRE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:577:15: note: in expansion of macro 'TEST'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:62:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDREx SERIAL_REGNAME(UDRE,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:577:30: note: in expansion of macro 'M_UDREx'
while (!TEST(M_UCSRxA, M_UDREx)) sw_barrier();
^
In file included from sketch\serial.h:29:0,
from sketch\MarlinConfig.h:46,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:67: error: 'UDR4' was not declared in this scope
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.h:52:63: note: in definition of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME_INTERNAL(registerbase,number,suffix) registerbase##number##suffix
^
sketch\MarlinSerial.h:67:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UDRx SERIAL_REGNAME(UDR,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:578:7: note: in expansion of macro 'M_UDRx'
M_UDRx = c;
^
sketch\MarlinSerial.cpp: In static member function 'static void MarlinSerial::flushTX()':
MarlinSerial.cpp:584: error: '_written' was not declared in this scope
if (!_written) return;
^
In file included from sketch\MarlinConfig.h:27:0,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:56: error: 'UCSR4A' was not declared in this scope
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\macros.h:70:23: note: in definition of macro 'TEST'
#define TEST(n,b) !!((n)&_BV(b))
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:56:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_UCSRxA SERIAL_REGNAME(UCSR,SERIAL_PORT,A) // defines M_UCSRxA to be UCSRnA where n is the serial port number
^
sketch\MarlinSerial.cpp:587:20: note: in expansion of macro 'M_UCSRxA'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
In file included from c:\program files (x86)\arduino\hardware\tools\avr\avr\include\avr\io.h:99:0,
from sketch\fastio.h:34,
from sketch\HAL.h:33,
from sketch\MarlinConfig.h:39,
from sketch\MarlinSerial.cpp:36:
MarlinSerial.h:60: error: 'TXC4' was not declared in this scope
#define M_TXCx SERIAL_REGNAME(TXC,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:587:15: note: in expansion of macro 'TEST'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
sketch\MarlinSerial.h:48:52: note: in expansion of macro 'SERIAL_REGNAME_INTERNAL'
#define SERIAL_REGNAME(registerbase,number,suffix) SERIAL_REGNAME_INTERNAL(registerbase,number,suffix)
^
sketch\MarlinSerial.h:60:28: note: in expansion of macro 'SERIAL_REGNAME'
#define M_TXCx SERIAL_REGNAME(TXC,SERIAL_PORT,)
^
sketch\MarlinSerial.cpp:587:30: note: in expansion of macro 'M_TXCx'
while (!TEST(M_UCSRxA, M_TXCx)) sw_barrier();
^
exit status 1
'rx_buffer' was not declared in this scope
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.