Open UserHIJ opened 1 year ago
Hi, I think you can use my code with your board. Can you capture the error?
On Sat, 27 May 2566 BE at 20:52 UserHIJ @.***> wrote:
Getting an error on this statement .. its saying SERIAL is already defined or the like . Let me ask .. can I use this code with: an Adafruit CAM bus and an RMD-x10? It’s not a shield like yours the adafruit has an integrated cam-bus connector . Is there something that needs to change in the configuration by chance>?
— Reply to this email directly, view it on GitHub https://github.com/ThuanLeUte/RMD_X8_PRO_CAN_BUS_CONTROLER/issues/4, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN4DHMPPXVAHAHLPPNWDWELXIIBLBANCNFSM6AAAAAAYRGJ3ME . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Hey for sure thanks. I'm a little new to this, have not coded in a while , but I wonder if Arduino core has a SERIAL defined already .. and I wonder if we can use that instead.
/Users/xyz/Documents/Arduino/main/main.ino:23: warning: "SERIAL" redefined 23 | #define SERIAL Serial |
---|
In file included from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/Interrupts.h:8, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/ArduinoAPI.h:29, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/ArduinoAPI.h:2, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/Arduino.h:28, from /private/var/folders/0j/227lrybj63j5q_p56qb5_28r0000gn/T/arduino/sketches/2FA1A756C1517B2E966E3FBA7234EBBE/sketch/main.ino.cpp:1: /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/Common.h:41: note: this is the location of the previous definition 41 | #define SERIAL 0x0 |
---|
/Users/xyz/Documents/Arduino/main/main.ino: In function 'void
m_can_receive()':
/Users/xyz/Documents/Arduino/main/main.ino:258:44: error: no matching
function for call to 'MCP_CAN::readMsgBuf(uint8_t, uint8_t [8])'
258 | CAN.readMsgBuf(&can_rx_len, can_rx_data);
| ^
In file included from /Users/xyz/Documents/Arduino/main/main.ino:16:
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:119:11: note:
candidate: 'byte MCP_CAN::readMsgBuf(long unsigned int, byte, byte,
byte)'
119 | INT8U readMsgBuf(INT32U id, INT8U ext, INT8U len, INT8U
buf); // Read message from receive buffer
| ^~~~~~
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:119:11: note:
candidate expects 4 arguments, 2 provided
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:120:11: note:
candidate: 'byte MCP_CAN::readMsgBuf(long unsigned int, byte, byte)'
120 | INT8U readMsgBuf(INT32U id, INT8U len, INT8U *buf);
// Read message from receive buffer
| ^~~~~~
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:120:11: note:
candidate expects 3 arguments, 2 provided
/Users/xyz/Documents/Arduino/main/main.ino: In function 'void
x8_can_init()':
/Users/xyz/Documents/Arduino/main/main.ino:430:39: error: no matching
function for call to 'MCP_CAN::begin(int)'
430 | if (CAN_OK != CAN.begin(CAN_1000KBPS))
| ^
In file included from /Users/xyz/Documents/Arduino/main/main.ino:16:
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:110:11: note:
candidate: 'byte MCP_CAN::begin(byte, byte, byte)'
110 | INT8U begin(INT8U idmodeset, INT8U speedset, INT8U clockset);
// Initialize controller parameters
| ^~~~~
/Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:110:11: note:
candidate expects 3 arguments, 1 provided
exit status 1
@.***
On Sat, May 27, 2023 at 9:58 AM Thuan Le @.***> wrote:
Hi, I think you can use my code with your board. Can you capture the error?
On Sat, 27 May 2566 BE at 20:52 UserHIJ @.***> wrote:
Getting an error on this statement .. its saying SERIAL is already defined or the like . Let me ask .. can I use this code with: an Adafruit CAM bus and an RMD-x10? It’s not a shield like yours the adafruit has an integrated cam-bus connector . Is there something that needs to change in the configuration by chance>?
— Reply to this email directly, view it on GitHub https://github.com/ThuanLeUte/RMD_X8_PRO_CAN_BUS_CONTROLER/issues/4, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AN4DHMPPXVAHAHLPPNWDWELXIIBLBANCNFSM6AAAAAAYRGJ3ME
. You are receiving this because you are subscribed to this thread.Message ID: @.***>
— Reply to this email directly, view it on GitHub https://github.com/ThuanLeUte/RMD_X8_PRO_CAN_BUS_CONTROLER/issues/4#issuecomment-1565432029, or unsubscribe https://github.com/notifications/unsubscribe-auth/AISWVY7HS4XBZQ4E23XTKLDXIICA3ANCNFSM6AAAAAAYRGJ3ME . You are receiving this because you authored the thread.Message ID: @.***>
Another note .. I've been playing around and may have hit a new brick wall , I posted this on discord .. curious your thoughts.
Hey gang .. little stuck . .got a myactuator and the doc is really messed up. there's a lot of versions and some of the doc is locked down by the manufacturer, making me rely on old doc . If I'm using the Can-L connection on my actuator there's a white and black wire. my assumption is that black goes to ground and white goes to can-l. But I can't find that written down anywhere. The issue I have is .. the actuator is powered on, physically connected and I'm getting and error. I'm using the Feather 2040 with Can connectors... and I'm trying MCP_CAN CAN0(CS_PIN); and while this is true: if (CAN0.begin(MCP_ANY, CAN_1000KBPS, MCP_16MHZ) == CAN_OK) Serial.println("MCP2515 Initialized Successfully!");This is the part that fails : byte sndStat = CAN0.sendMsgBuf(odrive_id, 0, 6, data) , and test of if (sndStat == CAN_OK) always fails. I can't tell if I have a hardware or software problem... and curious this groups thoughts . @.***
On Sat, May 27, 2023 at 10:38 AM Dave @.***> wrote:
Hey for sure thanks. I'm a little new to this, have not coded in a while , but I wonder if Arduino core has a SERIAL defined already .. and I wonder if we can use that instead.
/Users/xyz/Documents/Arduino/main/main.ino:23: warning: "SERIAL" redefined 23 #define SERIAL Serial
In file included from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/Interrupts.h:8, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/ArduinoAPI.h:29, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/ArduinoAPI.h:2, from /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/Arduino.h:28, from /private/var/folders/0j/227lrybj63j5q_p56qb5_28r0000gn/T/arduino/sketches/2FA1A756C1517B2E966E3FBA7234EBBE/sketch/main.ino.cpp:1: /Users/xyz/Library/Arduino15/packages/rp2040/hardware/rp2040/3.2.1/cores/rp2040/api/../../../ArduinoCore-API/api/Common.h:41: note: this is the location of the previous definition 41 #define SERIAL 0x0 /Users/xyz/Documents/Arduino/main/main.ino: In function 'void m_can_receive()': /Users/xyz/Documents/Arduino/main/main.ino:258:44: error: no matching function for call to 'MCP_CAN::readMsgBuf(uint8_t, uint8_t [8])' 258 | CAN.readMsgBuf(&can_rx_len, can_rx_data); | ^ In file included from /Users/xyz/Documents/Arduino/main/main.ino:16: /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:119:11: note: candidate: 'byte MCP_CAN::readMsgBuf(long unsigned int, byte, byte, byte)' 119 | INT8U readMsgBuf(INT32U id, INT8U ext, INT8U len, INT8U buf); // Read message from receive buffer | ^
~~~~~ /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:119:11: note: candidate expects 4 arguments, 2 provided /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:120:11: note: candidate: 'byte MCP_CAN::readMsgBuf(long unsigned int, byte, byte)' 120 | INT8U readMsgBuf(INT32U id, INT8U len, INT8U *buf); // Read message from receive buffer | ^~~~~~ /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:120:11: note: candidate expects 3 arguments, 2 provided /Users/xyz/Documents/Arduino/main/main.ino: In function 'void x8_can_init()': /Users/xyz/Documents/Arduino/main/main.ino:430:39: error: no matching function for call to 'MCP_CAN::begin(int)' 430 | if (CAN_OK != CAN.begin(CAN_1000KBPS)) | ^ In file included from /Users/xyz/Documents/Arduino/main/main.ino:16: /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:110:11: note: candidate: 'byte MCP_CAN::begin(byte, byte, byte)' 110 | INT8U begin(INT8U idmodeset, INT8U speedset, INT8U clockset); // Initialize controller parameters | ^~~~~ /Users/xyz/Documents/Arduino/libraries/mcp_can/mcp_can.h:110:11: note: candidate expects 3 arguments, 1 providedexit status 1
Compilation error: no matching function for call to 'MCP_CAN::readMsgBuf(uint8_t*, uint8_t [8])'
@.***
On Sat, May 27, 2023 at 9:58 AM Thuan Le @.***> wrote:
Hi, I think you can use my code with your board. Can you capture the error?
On Sat, 27 May 2566 BE at 20:52 UserHIJ @.***> wrote:
Getting an error on this statement .. its saying SERIAL is already defined or the like . Let me ask .. can I use this code with: an Adafruit CAM bus and an RMD-x10? It’s not a shield like yours the adafruit has an integrated cam-bus connector . Is there something that needs to change in the configuration by chance>?
— Reply to this email directly, view it on GitHub https://github.com/ThuanLeUte/RMD_X8_PRO_CAN_BUS_CONTROLER/issues/4, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AN4DHMPPXVAHAHLPPNWDWELXIIBLBANCNFSM6AAAAAAYRGJ3ME
. You are receiving this because you are subscribed to this thread.Message ID: @.***>
— Reply to this email directly, view it on GitHub https://github.com/ThuanLeUte/RMD_X8_PRO_CAN_BUS_CONTROLER/issues/4#issuecomment-1565432029, or unsubscribe https://github.com/notifications/unsubscribe-auth/AISWVY7HS4XBZQ4E23XTKLDXIICA3ANCNFSM6AAAAAAYRGJ3ME . You are receiving this because you authored the thread.Message ID: @.***>
Getting an error on this statement .. its saying SERIAL is already defined or the like . Let me ask .. can I use this code with: an Adafruit CAM bus and an RMD-x10? It’s not a shield like yours the adafruit has an integrated cam-bus connector . Is there something that needs to change in the configuration by chance>?