Offline Trouble

Arduino Mega based PLCduino.
wit wifi only.

Unit shows offline periodically since 2 days ago. Reset and still not online. Serial monitor shows connected. Re-uploaded basic sketch example from @kreggly and still offline. When I got home yesterday, the serial monitor was showing ping with 512ms then invalid hw or cs, can’t remember which but could not duplicate that portion. Another mega and an uno had the same problem last week but after several resets the problem went away. Now if I disconnect he USB cable it goes offline as well.

Ideas?

William

When you’re back around the device could you share the Serial Monitor output you’re seeing here?

How are these devices ultimately powered? I wonder if it could be some sort of a power issue, since you mentioned disconnecting from USB and having it go offline – perhaps the USB port was providing enough additional power needed to keep things stable and whatever other power source is not sufficient for the device?

Hi William,

I use a 12V 3A power supply. Did you remove the jumper on J7?

Cheers,

Craig

J7? I’m no. Was that covered in the pamphlet? I’m using a hacked laptop power supply at 19.8v.

@rsiegel this is that PLCduino @kreggly has been graciously helping me with. This unit uses an external supply 12-24v.

@wmontg5988,

Yeah, I don’t know what the effects will be if you don’t. Also, hitting the reset button with that jumper attached will short out your baseband supply, thus all the warnings!!! :stuck_out_tongue:

Cheers,

Craig

Yeah, just got :house_with_garden: and realized I had forgotten what the jumper was for :flushed: But, I had removed it after powering down after the flash.

On another note, did you ever get to the smoker project? I’m thinking about a 3D printer for my project boxes but don’t know junk printers from good ones.

William

Smoker project is in the Projects with Cayenne. You will need to tweak the
PID parameters per your smoker.

I have a cheap TronXY that is very hackable.

Cheers,

Craig

@rsiegel. Here’s the screen shot of the serial monitor. As soon as I close the monitor my PLCduino goes offline and any relays energized drop out.

<img src="//cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex019/uploads/mydevices/original/2X/5/5d24053268c0190c829c219cf7385e60259a990b.JPG" width="374" height="500">

Hi @wmontg5988, thanks for the screenshots.

This is a bit of a guess, perhaps @kreggly can let us know if there is a specific reason for the baud rate that he chose for his PLCduino project – but I found this thread where lowering the baud rate to 9600 helped to resolve the ‘Invalid HW cmd’ errors. Cayenne’s Arduino code builds on an open source version of their code so it could be applicable here.

I know baud rate is set at 9600 as I can only see on serial monitor if set for 9600 baud. The ESP-2 is set to 115200. Last night I removed the board and set a new device token and it seems at this point it’s working ok.

Like the article says, default is 115200 for the ESP-02. If there are issues, then build a helper app like I did for programming, just don’t put it into program mode. Then you can change the default baud rate and save.

Then change your Cayenne code to communicate at a different baud to the ESP.

I haven’t seen any issues though myself.

Cheers,

Craig

1 Like

Sounds like that’ll work. The PLCduino has stayed online for couple days now. Now I’ve lost the uno and he other mega. This is a problem that has cropped up just lately and others seem to be having the same troubles.

1 Like