g4klx / MMDVMHost

The host program for the MMDVM
GNU General Public License v2.0
378 stars 275 forks source link

Waiting for ACK... #193

Closed AlexEKoren closed 8 years ago

AlexEKoren commented 8 years ago

Hey g4klx, I tried reimplementing your script for updating Nextion displays over the serial cables as part of a larger project and I'm getting stuck on the "Waiting for ACK..."

I then downloaded your code directly, made sure it was directed towards the correct serial device and still, nada. It seems to just be getting an empty string when it reads in "reader()."

Any thoughts on how to fix this? Not sure how you reverse engineered this, but happy to try and help what the problem might be!

g4klx commented 8 years ago

Actually I didn't write it! Can you ask on the MMDVM Yahoo! group and hopefully the author will pop up.

n7tae commented 8 years ago

I could never get it to work either. It seems some (maybe a lot) of the serial devices aren't compatible with the programming software.

Move the correct Nextion display files* to a microSD card, put the card into the display and power up the display. It should see the files and transfer them over. Unplug the display after you see the Sucess message and take out the microSD. You should be all set.

*You only need one, but I can't remember whether it is the tft or the hmi file on the microSD card, but it won't hurt to have them both there.

On 11/02/2016 09:07 PM, Alex Koren wrote:

Hey g4klx, I tried reimplementing your script for updating Nextion displays over the serial cables as part of a larger project and I'm getting stuck on the "Waiting for ACK..."

I then downloaded your code directly, made sure it was directed towards the correct serial device and still, nada. It seems to just be getting an empty string when it reads in "reader()."

Any thoughts on how to fix this? Not sure how you reverse engineered this, but happy to try and help what the problem might be!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/g4klx/MMDVMHost/issues/193, or mute the thread https://github.com/notifications/unsubscribe-auth/AE6qmNCLE4PMJSQxLyZCiN_QQ9s-7jhaks5q6TPQgaJpZM4Kn6zv.

phl0 commented 8 years ago

You need the .tft file on the SD card. And the display seems to be picky about partition layout and file system. Should be < 8GB and FAT32 formatted.

g4klx commented 8 years ago

I think I may remove that program if it so problematic.

AlexEKoren commented 8 years ago

I know that I can use an SD card for this, but once I install this component in the box I'm building, I can't access it. I need to be able to do software updates from a Linux system over the serial cables. I can tell it's doing something, but it's just not receiving acknowledgements back!

phl0 commented 8 years ago

I will have a look and see if I can get that running again as I also would need it. Seems like the protocol for uploading to the display changed with recent versions of the display FW.

phl0 commented 8 years ago

I made a sniff from the serial communication between the Nextion Editor and the Nextion display. And I reworked the python script on that basis. It seems that the serial protocol has changed with some the recent FW upgrades of the display. The script works but somehow breaks sometimes during upload. You could give that a try. You can find it in my devel branch: https://github.com/phl0/MMDVMHost/tree/nextion.py

AlexEKoren commented 8 years ago

I just made a pull request to the repo. Made a working script that hasn't failed and I've tried it with several TFTs on 2.4" displays.

You can check it here: https://github.com/AlexEKoren/MMDVMHost

phl0 commented 8 years ago

@AlexEKoren: What do you think if the model number and port are to be read from the command line? That would prevent us from changing the python script and being bothered if we change files that are tracked by git.

https://github.com/g4klx/MMDVMHost/compare/master...phl0:nextion.py

Could you please give that a try on Mac OS? I tested it under Ubuntu Linux.

AlexEKoren commented 8 years ago

No problem. Will update on my branch and submit a pull request.