×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Problem with Pegasus Universal Power Box 2

  • Posts: 220
  • Thank you received: 27
Hi,

a few problems (and solutions) with Pegasus UPB driver

1. Couldn't figure out why I had 2 (almost similar) config files. (But one was name UBP instead of UPB.

The driver seems to return UBP instead of UPB on line 422
const char * PegasusUPB::getDefaultName()
{
return "Pegasus UBP";
}

Should be

const char * PegasusUPB::getDefaultName()
{
return "Pegasus UPB";
}


2 A more serious problem: Enable disable USB ports gave all kinds of strange problems and the view in control panel is not in sync with the real situation

Took me a wile looking at logs before I found what is wrong.

Pegasus doc shows commands ar U1 through U6 for enable/disable ports

Indi is sending U0 through U5

So following code on line 1115
snprintf(cmd, PEGASUS_LEN, "U%d:%d", port, enabled ? 1 : 0);

should be
snprintf(cmd, PEGASUS_LEN, "U%d:%d", port + 1, enabled ? 1 : 0);


Compiled the changes on my RPI4 and it looks as if that solved it.

Can someone make these 2 changes on github?

There are still a few other things not working 100% (power on boot, weather interface?) so I keep testing.

Regards,

Paul
The following user(s) said Thank You: Jose Corazon, Craig
3 years 11 months ago #52881

Please Log in or Create an account to join the conversation.

  • Posts: 1067
  • Thank you received: 140

Well to be honest I hope no one does change the files In github as I have the UPB V2 and all works perfectly fine, so the issues is with your system I’m afraid....and not the INdI driver...
3 years 10 months ago #52889

Please Log in or Create an account to join the conversation.


It's done, I just pushed these fixes to Git, thanks Paul! Let me know if you find any further bugs.
3 years 10 months ago #52891

Please Log in or Create an account to join the conversation.

  • Posts: 220
  • Thank you received: 27

Well hope I did not delete the debug logs. I can send them if you like.
Worked pretty well under Windows. Check disable and enable USB ports in Indi, and see what you get. (I tested against the latest Indi sources)

Which powerbox dou you have? This happens only with Ultimate PoweBox V2 (different from the UPB) and do you run the latest firmware? There was a recent firmware upgrade for the UPBV2.

Paul

Found the log file; this shows the error (trying to disable port 1, and 6)

DEBUG 195.429660 sec : RES <UPB2:12.5:0.2:2:22.3:49:11.1:1111:110101:0:0:0:0:0:0:0:0:0:0:0000000:0>
DEBUG 195.431164 sec : CMD <PC>
DEBUG 195.461754 sec : RES <0.20:0.20:2.54:3606404>
DEBUG 195.462495 sec : CMD <SA>
DEBUG 195.493546 sec : RES <65535:0:0:0>
DEBUG 196.089341 sec : CMD <U0:0>
DEBUG 196.101497 sec : RES <ERR>

DEBUG 196.101631 sec : CMD <U5:0>
DEBUG 196.117510 sec : RES <U5:0>
DEBUG 196.494538 sec : CMD <PA>
DEBUG 196.581471 sec : RES <UPB2:12.5:0.2:2:22.3:49:11.1:1111:110101:0:0:0:0:0:0:0:0:0:0:0000000:0>
DEBUG 196.583011 sec : CMD <PC>
DEBUG 196.613548 sec : RES <0.20:0.20:2.54:3607550>
DEBUG 196.614288 sec : CMD <SA>
DEBUG 196.645343 sec : RES <65535:0:0:0>
DEBUG 197.646949 sec : CMD <PA>
DEBUG 197.733321 sec : RES <UPB2:12.5:0.2:2:22.3:49:11.1:1111:110101:0:0:0:0:0:0:0:0:0:0:0000000:0>
DEBUG 197.734976 sec : CMD <PC>
DEBUG 197.765603 sec : RES <0.20:0.20:2.54:3608696>
DEBUG 197.766596 sec : CMD <SA>
DEBUG 197.797180 sec : RES <65535:0:0:0>
DEBUG 198.798804 sec : CMD <PA>
DEBUG 198.885781 sec : RES <UPB2:12.5:0.2:2:22.3:49:11.1:1111:110101:0:0:0:0:0:0:0:0:0:0:0000000:0>
DEBUG 198.887701 sec : CMD <PC>
Last edit: 3 years 10 months ago by PDB.
3 years 10 months ago #52914

Please Log in or Create an account to join the conversation.

  • Posts: 220
  • Thank you received: 27
It's done, I just pushed these fixes to Git, thanks Paul! Let me know if you find any further bugs.

Thank you very much Jasem. There is one other strange thing, but the Windows control program does exactly the same thing. (will report this to Pegasus first before thinking of considering this as a bug)

Global power state can be disabled / enabled; When triggering it also seams to put the dewheaters at full force. Disable all only disables the power ports and leaves the heaters on. But will check with Pegasus guys first.

Regards,

Paul
3 years 10 months ago #52922

Please Log in or Create an account to join the conversation.

  • Posts: 1067
  • Thank you received: 140

I never noticed any of those issues, as my Hub was always powered on at boot up so never saw the need, I have the latest V2 UPB with the latest 1.4 firmwear

But there are a few things missing from the INdI driver, such as no power info for the Alway on 12v port, or the variable power port, or no way to label the dew control outputs, Also no identification between the USB 2 and USB 3.0 ports in the driver....it’s a basic driver but it work. Bu I agree the windows driver is much more detailed... but I am not a coder so can’t help, I am just an end user.... :)
3 years 10 months ago #52927

Please Log in or Create an account to join the conversation.

  • Posts: 220
  • Thank you received: 27
Things are always on with my device too. I noticed it because I have a very annoying SX filterwheel that sometimes needs the usb cable unplugged/plugged. So I need those USB disable/enable (or walk to the scope ...) to get things working again. Also some ASI cameras (if switching between applications) sometimes get hung (also on Wiindows, started with new ASI libraries (and DLL's on W10) introduced by ZWO some time ago) get really stuck. Then switching off/on usb ports helps.

I have some time next week, so I can take a look at the driver and maybe introduce the missing things. I really would like the interface tho the weather tabin Ekos getting to work, but so far no success yet.

Paul
The following user(s) said Thank You: AstroNerd
Last edit: 3 years 10 months ago by PDB.
3 years 10 months ago #52928

Please Log in or Create an account to join the conversation.

  • Posts: 1067
  • Thank you received: 140
Does your autofocus work ok...?
As I get errors of failed to move to position, and also get them on manual if I try and make the moves to quick, as if it can’t quite keep up...if I leave a few seconds between moves it seems ok...and that’s on short 100 step moves, so it’s not as if the focuser is still moving to previous position.... any ideas...
3 years 10 months ago #53012

Please Log in or Create an account to join the conversation.

  • Posts: 527
  • Thank you received: 139
I'm seeing the failed to move to position errors too. Jasem is addressing it from another thread. However, his fix, and potentially the fixes added in this thread have caused the driver to crash now and not load any devices plugged into the USB ports of it. I'm reverting back to a previous install to get the old driver back.
Last edit: 3 years 10 months ago by Andrew Burwell.
3 years 10 months ago #53021

Please Log in or Create an account to join the conversation.

  • Posts: 527
  • Thank you received: 139
I'm not sure what changed with regards to the Pegasus UPB here. I see what you're talking about in the posts above, and what you changed. But the driver now no longer fully works for me.

I updated to the latest driver to help Jasem solve the focus error issue and now I can no longer connect any devices to the USB ports of this device, possibly due to the above changes or possibly some other issue related to this update.

When trying to activate the USB ports Pegasus UPBv2 now no longer does anything. I can deactivate, and try to reactivate, neither button works.

See my attached logs showing errors.

File Attachment:

File Name: log_12-10-46.txt.zip
File Size:10 KB
3 years 10 months ago #53034
Attachments:

Please Log in or Create an account to join the conversation.

So I just checked the log and indeed Pegasus returns ERR when you try to activate the hub or deactivate it... so that's coming from the unit itself. btw, is firmware 1.3 the latest Pegasus offers?

Have you tried the individual USB port enable/disable ? These were the ones that were corrected in the last patch.
3 years 10 months ago #53043

Please Log in or Create an account to join the conversation.

  • Posts: 527
  • Thank you received: 139
The latest firmware is 1.4. Mine is already updated to that firmware. I did not get a chance to try each USB one at a time as I reverted back to Stellarmate 1.5.2. But when I do try to disable the ports on the original driver, I see the problem he's posted about where the port number is off by one. When you disable and enable say port 3, enabling port 3 again actually makes port 2 disable. So that's a real issue. But something else in the driver change has made it so USB devices don't seem to work.

Also ZWO cameras no longer work with the newest INDI core drivers whether they are plugged in to the Pegasus UPB or directly into the Stellarmate.
3 years 10 months ago #53044

Please Log in or Create an account to join the conversation.

Time to create page: 0.614 seconds