Open RooieDirk opened 2 years ago
Dirk..
eta date: the ais is only using month and year. So no need for setting the year eta time: Same the seconds are not used.
Yes, I know only MMdd and hhmm.00 are sent. The use of wxWidgets date and time controls I suppose was a convenient solution. However simple conditioned list boxes would be feasible here? Not less since the date and time controls are not behaving quite the same on our different system.
Every time the tap/page is opened/reopened there should be a new read request call being send, to make sure up to date data is viewed.
An interesting idea to let the connected AIS update all controls while initiating. If no AIS is replying we could use the last saved values as now and maybe indicate the absence of an AIS in some way already then and not only at the attempt to "Send to AIS".
I could look into that.
Very good you're testing on a Trueheading, I've a SAAB R3.
Dirk Instead of the unnecessarily comprehensive date/time controls would something like this make more sens? Håkan
Much better in my opinion. Don't forget to add some logic that makes it impossible to use invalid values. Hours always in the 0-23 range etc. The reply sentence is also human readable now.
Dirk.. New code in master branch. changes:
I do think this update is better than before. Hopefully it fulfills your good ideas. Any thoughts before release?
Thanks Håkan
After any edit:
BTW:... There are binaries at Cloudsmith if you want to test. If so and you've access to the Trueheading please if possible check if that one report "Persons on board". My SAAB R3 didn't.
@RooieDirk Version 1.6.2 available at Cloudsmith if you want to download and import a tarball for test? No big function changes since last message. Mostly pluginmanager tweaks to get more system tarballs to work. So my plan is to release to master catalog in a day or so.
Goodmorning Hakan, Something is going bad, although I guess it is in the plugin managing system. My system is a linux variant. OpenCPN pluginsettings see picture. Using the regular plugin import I get this file: ais-vd-1.5.0+239.68423ca_ubuntu-gtk3-20.04-x86_64.tar.gz, but the ...20.04-x86_64 flavour is not available in your CloudSmith download map. And trying anotherone gives an "incompatible plugin detected error" I'm running the latest 'master' from github, and I do know there have been some changes in the plugin manager since 5.6.0
Dirk.. Yes that system is obviously missing in the actual build PM process. We'll see if Alec could help.. @leamas The Circleci result of the build results yields this Cloudsmith This time I'm using these upload script as of Shipdriver. What would be added to build for the system as of Dirk's shot above? Any hints appreciated. Thanks/Håkan
Hm...On cloudsmith I find this tarball. It has the 'ubuntu-gtk3-x86_64:20.04' ABI.
Looking at your screenshot it seems that the host also is using 'ubuntu-gtk3-x86_64:20.04' ABI.
@RooieDirk : Could you please start opencpn on the command line using 'opencpn --loglevel debug', try to import the tarball and then just exit. And then post the opencpn.log file as an attachment?
Github requires you to compress the logfile before you attach it; use something like gzip ~/.opencpn/opencpn.log
to create ~/.opencpn/opencpn.log.gz which can be attached
Alex, opencpn.tar.gz
You are aware that the tarrball in your link is an old version? Anyhow, if I download tat file, and import it works fine. See log.
No, I'm not aware of that it's an old version. Still, we now know how to test things. Could you do the same with the new tarball which fails: start using --loglevel debug, try to import it and post the compressed log?
While on it, also post the link to the tarball you are trying to import.
Alec.. Yes, the old plugin version as of your "this tarball" included that system but I couldn't find out which script created that one. So I'm not sure what to include to build it again.
The root is the .circleci/config.yml file. In the very end you find the different builds, basically just a list. 20.04 a. k. a Focal is triggered by these two lines.
- build-focal:
<<: *std-filters
The actual build is done by this snippet in the same file:
build-focal:
docker:
- image: cimg/base:stable-20.04
environment:
- OCPN_TARGET: focal
- CMAKE_BUILD_PARALLEL_LEVEL: 2
<<: *debian-steps
Is this what you are looking for?
Yes exactly that build-focal snippet is included. So "focal" is Ubuntu? But still no "-ubuntu-gtk3-20.04-x86_64.tar.gz" by Circleci?
So "focal" is Ubuntu?
No, Focal is 20.04 or more exact Ubuntu-20.04
But still no "-ubuntu-gtk3-20.04-x86_64.tar.gz" by Circleci?
Could you please link to the build logs.
The links as of above: The Circleci result of the build results yields this Cloudsmith This time I'm using these upload script as of Shipdriver. I'm though not sure what logs you're asking for? But, again, what I did was to use the same scripts and config.yml as Shipdriver. Obviously I then deleted some other script to make ubuntu-gtk3-20.04-x86_64.tar.gz?
Wait... there is a build log above, sorry. And it includes an upload of ubuntu-gtk3-20.04-x86_64. However, i doesn't seem to be visible on cloudsmith.
The hairy details: The complete version on cloudsmith is 1.2.0+146.e5881bd, but the current git HEAD is at 909ca5073d. And the cloudsmtih version is indeed way too old.
EDIT: This measn that the actual version on cloudsmith should be 1.2.0+148.909ca5073d or so. 148 is the build number, could be anything. But the last part should be the git commit hash
I have no clue...
So, now we are two wo a clue??
Indeed. Let me think & eat
I should have known. Something is broken with the opencpn/ais-vd_pi cloudsmith repo.
Forked https://github.com/Hakansv/ais-vd_pi.git, set it up to upload to my repo at https://cloudsmith.io/~alec-leamas/repos/opencpn-plugins-unstable/packages/ using my CLOUDSMITH_API_KEY and CLOUDSMITH_UNSTABLE_REPO which points to my repo. The build goes fine, everything uploaded and available (for some reason without git metadata in the version).
Ergo: something is wrong with the cloudsmith opencpn/ais-vd_pi repo, either the repo or the cloudsmith organization. You have to talk to Rick about it, I don't use that organization myself.
EDIT: @RooieDirk: You can try the tarball at https://dl.cloudsmith.io/public/alec-leamas/opencpn-plugins-unstable/raw/names/ais-vd-1.6-ubuntu-gtk3-20.04-tarball/versions/1.6.3/ais-vd-1.6.3_ubuntu-gtk3-20.04-x86_64.tar.gz for now.
@rgleason: ^
Thanks. Then we're on a path at least. What I can see is the "ubuntu-gtk3-20.04-x86_64.tar.gz" was built for the previous plugin version, 1.5, 6 days ago. Could there have been some kind of limitation for how many uploads are allowed recently? If Rick may check it would be great.
Could there have been some kind of limitation for how many uploads are allowed recently?
Not as far as I know, repos are cleaned using a FIFO algorithm: When there are "too many" packages, older ones are thrown away. But the latest should always pass.
You might want to merge my PR. Currently there is no git metadata in the version which makes it identical to the previous one in some cases. That should not really matter, but who knows? Try a new build after merging and see what happens.
You might want to merge my PR
That was a "massive" change according to the example Shipdriver. Thanks! I'll make a try but what about the password and key you changed. Are these yours or did you just hid mine?
I just read this.
ais-vd-1.5.0+239.68423ca_ubuntu-gtk3-20.04-x86_64.tar.gz, but the ...20.04-x86_64 flavour is not available
ubuntu-gtk3-x86_64:20.04'
Now I see version 1.6.3 being created. I would check the build logs for errors. Maybe the file is not getting pushed? but Hakan's builds all seem to be completing https://github.com/Hakansv/ais-vd_pi
I have a hard time identifying exactly which one is missing from the Cloudsmith naming.... no gtk3-x86_64 named.. Which one is the problem?
BTW Ubuntu 14.04 or whatever is being canned by Circleci. May not affect you but I have about 15 plugin to update.
PS the CS search feature is very good and may help.
Support for ubuntu 14.04 /Trusty is dropped since long, this is no problem. The updated plugin does not make any Trusty build.
While a somewhat big change, the only thing I did was to run 'update-templates 3.0.3-beta1'. (While beta, it will be identical to upcoming 3.0.3 as far as I know).
The one you are looking for is Focal-20.04. This is , well, not that transparent ;)
´@hakansv: Sorry, the one you are looking for is ais-vd-1.6-ubuntu-gtk3-20.04-tarball. Should not take things out of the top of my head.
I am finding that with a search in the alpha branch. There are 4 versions sub1, sub2, sub3, sub4
https://cloudsmith.io/~opencpn/repos/ais-vd-alpha/packages/?q=ais-vd-1.6-ubuntu-gtk3-20.04-tarball
@leamas Many thanks for your support. After merging your changes and a push all seems to be present at Cloudsmith also the one missed before. @rgleason Thanks for your checks and the search example. So all was about the files where "hidden" or strange sorted then? @RooieDirk Here's the last file for your system from "my" Git to Cloudsmith Alpha
The alpha repos retention policy is listed in the dev manual. It is more frequent. The prod repos has been expanded to keep more files as we found that we needed to do that.
https://opencpn-manuals.github.io/main/AlternativeWorkflow/InstallConfigure/Cloudsmith.html
*Plugin-alpha, Limit by days = 28, Limit by count=100, Limit by size = 0 Plugin-beta, Limit by days = 0, Limit by count=100, Limit by size = 0 Plugin-prod, Limit by days = 0, Limit by count=526, Limit by size = 0 Using a "0" means "disabled"
Hakan, the files were going to the "alpha" repository because you had not made a tagged push which sends them to the "prod" repos.
If you look in the alpha repos you will see them.
Thanks. I know I'm on Alpha. I found it a good place to check the build process and also to download tarballs for my checks on different system. (Instead of build on each system.) Now when I know the restrictions things are easier to overcome. Thanks all for your help! Dirk.. now we can go back to where we started. Check the plugin's function :) Håkan
OK did another try. Loading the tarball goes fine now. As far as I see only a little layout problem. In my screen there is only the '-' btn inside the entrybox visible. I guess there should be also a '+' btn, and indeed if I go to the extreme right and click there the value goes up. see screenshot. And maybe a little logic for the amount of days in a month. Only 30 days allowed in months 4,6,9,11 and month 2 max 29. Alex if you are still here if I change the catalog to Alpha, O does crash.
BTW the language file is in Crowdin if you like?
@RooieDirk Try this update if the spin control looks better on your system. It's a "hack" with a specific control size instead of "default". Not nice but a test. I also set max day according to your suggests.
Here's a download link to the tarball for import: Version 1.6.6_ubuntu-gtk3-20.04-x86_64
Dirk.. The "hack" was not good on RPi but to you see the arrows?
Your going fast;-). But my pictures look different. I tried both 1.6.6 and 1.6.7. The both look like :
@RooieDirk.. @bdbcat I asked Dave about this strange spin control of yours and we may continue here for a solution and common knowledge? "What machine is Dirk running on? I have never seen a spin control like this, with "+/-" So can you elaborate where this Ubuntu 20 is running. Thanks Håkan
I think this is the problem/cause. https://forums.wxwidgets.org/viewtopic.php?f=23&t=47821
OK I have read but not sure I understand what to do. On my RPi4 Rasbpian(Debian) Buster 32 GTK 2 (if the same?) the arrows are there as intended. @bdbcat Is there something we can do for the plugin to come over it? Would it be a problem an all Ubuntu 20.04?
Likely it could be solved by a GTK version check. Something like:
#if GTK_CHECK_VERSION(3, 0, 0)
spinctrl->SetWidth((int)spinctr->width()*1.2);
#endif //GTK_CHECK_VERSION(3, 0, 0)
I didn't noticed it before either, but now I do know in OpenCPN on my box the spinctrl looks also different.
Looks to me that the +/- spinbutton is all that is available for GTK3. Dirk's idea looks good. For reference, please check (on the target system) the appearance of wxDatePickerCtrl in the Route Properties dialog. That is, make a route, pull up its properties, and look at the the "Departure Date" control.. This core code uses exactly the same class and method as the ais-vd plugin. How does it look there?
That is pretty strange. In RoutePropDialog code:
m_dpDepartureDate =
new wxDatePickerCtrl(m_pnlBasic, wxID_ANY, wxDefaultDateTime,
wxDefaultPosition, wxDefaultSize, wxDP_DEFAULT);
In ais-vd_pi:
DatePicker = new wxDatePickerCtrl(m_AIS_VoyDataWin, ID_DATECTRL, wxDateTime(),
wxDefaultPosition, wxDefaultSize, wxDP_DEFAULT);
Is there some way the wxGTK2 and GTK3 are both being used? That is, GTK2 for the core, and GTK3 for the plugin?
Dave.. Since we are not interested in year and more the date/time-picker control are replaced by SpinControls. That's the present test. The last code is here with a try to control the size to avoid default size but it didn't helped: link to source But I can of course try Dirk's patch.
Hakan, I think you would look for something like this:
m_pCtrlMonth = new wxSpinCtrl(m_AIS_VoyDataWin, wxID_ANY, wxEmptyString,
wxDefaultPosition, wxSize(90, 40),
wxSP_ARROW_KEYS, 1, 12, EtaInitMonth);
#if GTK_CHECK_VERSION(3,0,0)
m_pCtrlMonth->SetMinClientSize( wxSize(m_pCtrlMonth->GetSize().GetY()*5, -1));
#endif
......
This would set the minimum width at least 5x the height of the control. My guess is that this should leave enough space for a "- +" btn's. And it should work on different screen pixel distances. But Dave might have better ideas
Basically we may first check a simple wxdefaultsize ans see if that survives instead of my try to shrink the controls.
Dirk.. I regret. Here's version 1.6.8 with this change: All Spincntrl size are (80, -1) and //Adjust spincontrols to fit Ubuntu GTK2
#ifdef GTK_CHECK_VERSION(3,0,0)
m_pCtrlMonth->SetMinClientSize(wxSize(m_pCtrlMonth->GetSize().GetY() * 5, -1));
m_pCtrlDay->SetMinClientSize(wxSize(m_pCtrlMonth->GetSize().GetY() * 5, -1));
m_pCtrlHour->SetMinClientSize(wxSize(m_pCtrlMonth->GetSize().GetY() * 5, -1));
m_pCtrlMinute->SetMinClientSize(wxSize(m_pCtrlMonth->GetSize().GetY() * 5, -1));
#endif
Hi Hakan, I was able to do a small test this afternoon in the local AIS workshop. The most important findings: eta date: the ais is only using month and year. So no need for setting the year eta time: Same the seconds are not used. Every time the tap/page is opened/reopened there should be a new read request call being send, to make sure up to date data is viewed. (If you change something now on the AIS itself, the data in the plugin is not updated.
Test was done on an "Trueheading" dual inland/solas AIS. WKR Dirk