Trying to control Nomad3 by Arduino UNO

I’m pretty new about Nomad3 and I’m sorry if there is a similar post already.

I’m trying to control Nomad3 from Arduino UNO.

I connected Arduino UNO and Nomad3 via USB typeB cable and tested to send command from Arduino UNO.

However, I have trouble with sending any command to Nomad 3 at this moment.

Looks like Nomad 3 does not respond and the connection is not able to be established properly or Nomad3 does not wake up.

I don’t get any error at the Arduino serial begin() stage.

Does anyone try to connect Arduino UNO to Nomad 3 and does succeed to send G-code?

This is my arduino sketch

void setup()
{
	Serial.begin(115200);
	while (!Serial) {}
	delay(100);
	Serial.print(“\r\n\r\n”);
	Serial.flush();

	delay(100);
	Serial.print(“$H\n”);
	Serial.flush();
}

void loop()
{
}

Thanks

It should work — did you compare the source of gctrl?

Serial.Begin won’t give you much of an error as it is more related to the port on the UNO as opposed to what it connected to. It won’t show an error if the connection speed is wrong.

Have you confirmed if 115200 is the correct speed?
Is there any particular “wake up” that the Nomad is looking for?

Perhaps another issue may be the USB mode on the UNO. I am guessing here, but natively it is running in “Client” mode as it talks to the PC which is in “Host” mode… In order to control something from the USB port it needs to be in “Host” mode. I am not sure the UNO is capable of that.

I seem to remember this, anyone correct me if I am wrong:
In Host mode the device controls the conversation and will either send data or ask if the client has anything to say. Client mode devices will only talk when asked by a device in Host mode.

So if the UNO is in client mode it’s not going to work… (Thats just theory in my mind as I have never tried this :slight_smile: )

I do have a spare controller so I might try this with an ESP32 device I made that has a native FDDI USB chip onboard.

3 Likes

115200 should be the correct value (as far as I know the Shapeoko and Nomad share the same GRBL version, which config file was shared here, and it has the default 115200 value)

1 Like

For reference, I connected my Mac to Nomad3 and used IONinja (serial port monitor) in order to send/receive data. I confirmed 115200 is the proper speed. Using this method, I can send commands to Nomad3 properly.

I also sent “^X” to initialize Normad 3 from UNO instead \r\n\r\n but the result is the same.

The problem is not sending code itself, it is how to establish the connection and wake up Nomad 3 I guess (I might be wrong :slight_smile:

In reference to what I posted above about Host mode I found this:
https://www.arduino.cc/en/Reference/USBHost

Seems this is only related to the “Due” board. Also states this is experimental.

1 Like

Thank you for the important info, Nick!
Looks like I should try to use Arduino USB host shield. I give it a try.

No worries Toshi. If that works it would be ideal as you can use Serial1 to view what is going on, and Serial2 to control the Nomad.

Before you buy one though that a look at the libraries to make sure it supports Host mode. Maybe the Due library can be ported.

OR, you could bypass the USB hurdles altogether, and connect your Uno’s RX/TX IOs (pins 0 and 1) to the RX/TX of the ATMega on the Nomad controller.

Example on a Shapeoko back when @neilferreri implemented a wireless serial comm:

2 Likes

Good point, it’s just straight UART to UART communication…

But just be mindful of cable length and routing as there is no error correction at this level.

1 Like

This topic was automatically closed after 30 days. New replies are no longer allowed.