diseqc: Cannot disable Limits

xforze

Member
Original poster
Mar 22, 2021
10
1
München
Hi All!

Im trying to move my Positioner (STAB HH 120) to 70°
The Electronic Limit is at 65° and the mechanical Limit is at 70°

Moving the Positioner to 65° works fine but when I try a greater angle, the Positioner dont start moving.
Im using these Commands (5 times disable Limits and 5 Times move to Position 70° ):

{ { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
{ { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
{ { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
{ { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
{ { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },

An Angel of 65° is working fine:
{ { { 0xe0, 0x31, 0x6e, 0xe4, 0x10, 0x00 }, 5 }, 0 },


Any suggestions why it is not working ?

Cheers, Thomas
 
Hi!

Thanks for your quick answer, Could you please explain me how I can do this ?
Unfortunately, Im new in this Topic.

Do you mean that I should save a Sat Position behind the Limits with 0x6a ({{0xe0, 0x31, 0x6a, n1, 0x00, 0x00}, 4}) ?

Cheers!
 
Are you using a STB to control the HH120 or another device to control the motor?

USALS is a calculated position based on the install location's Longitude and Latitude settings. DiSEqC 1.2 is a manual instruction to Move (continuous or step) East / West / Save / return to a previous user saved position.

Complete documentation of the DiSEqC protocol: https://www.eutelsat.com/files/PDF/DiSEqC-documentation.zip
 
Im using a Dvbsky S960 V2 USB Box to control my Devices. Its plugget to an odroid XU-3 Hardware.
I will have a look at the Documentation you sent me.

Many Thanks!
 
What satellite software are you using on the computer?

In your satellite software package, there should be a motor control menu where the motor control mode or type is selected. Motor control is either by USALS (often called DiSEqC 1.3 to avoid licensing) or DiSEqC 1.2. If you open the DiSEqC 1.2 motor control menu it will provide options to drive or step the motor East or West, Assign a motor position number, save the motor position number to the Stab HH120, and recall the motor position number.

Typically, software packages do not require manual formatted commands to control switch or motor movement.
 
Hi!

Im not using special software, Im running Linux and have the v4l drivers installed.
My Card is accessible under /dev/dvb/adapter0/frontend0

Im using the C-Code below to control the card:
When I uncomment the "Move to 65" Block, it works fine, the Positioner is moving to 65°

The "Move to 70°" Block is not working but it should as I disable the Limits with the first Block (Disable Limits)
I tried other Commands like "storing Sat Position", "Goto Sat Position" and these Commands are working fine but no Idea why the disable Limits Command (0xe0, 0x31, 0x63,) is not working.


Code:
struct diseqc_cmd {
        struct dvb_diseqc_master_cmd cmd;
        uint32_t wait;
};

struct diseqc_cmd switch_cmds[] = {
// Disable Limits
        { { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },
        { { { 0xe0, 0x31, 0x63, 0x00, 0x00, 0x00 }, 3 }, 0 },

// Move to 65° (working)
//        { { { 0xe0, 0x31, 0x6e, 0xe4, 0x10, 0x00 }, 5 }, 0 },
//        { { { 0xe0, 0x31, 0x6e, 0xe4, 0x10, 0x00 }, 5 }, 0 },

// Move to 70° (not working)
        { { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
        { { { 0xe0, 0x31, 0x6e, 0xe4, 0x60, 0x00 }, 5 }, 0 },
};

static inline
void msleep(uint32_t msec)
{
        struct timespec req = { msec / 1000, 1000000 * (msec % 1000) };
        while (nanosleep(&req, &req)) ;
}

static void diseqc_send_msg(int fd, fe_sec_voltage_t v, struct diseqc_cmd **cmd,
                     fe_sec_tone_mode_t t, fe_sec_mini_cmd_t b)
{
        ioctl(fd, FE_SET_TONE, SEC_TONE_OFF);
        ioctl(fd, FE_SET_VOLTAGE, v);

        msleep(1000);
        while (*cmd) {
                printf("msg: %02x %02x %02x %02x %02x %02x\n",
                       (*cmd)->cmd.msg[0], (*cmd)->cmd.msg[1],
                       (*cmd)->cmd.msg[2], (*cmd)->cmd.msg[3],
                       (*cmd)->cmd.msg[4], (*cmd)->cmd.msg[5]);

                ioctl(fd, FE_DISEQC_SEND_MASTER_CMD, &(*cmd)->cmd);
                msleep((*cmd)->wait);
                cmd++;
        }
}


int main(int argc, char **argv)
{
        struct diseqc_cmd *cmd[2] = { NULL, NULL };
        char *fedev = "/dev/dvb/adapter0/frontend0";
        int fd;

        if (getenv("FRONTEND"))
                fedev = getenv("FRONTEND");

        printf("diseqc test: using '%s'\n", fedev);

        if ((fd = open(fedev, O_RDWR)) < 0) {
                perror("open");
                return -1;
        }
        unsigned int j;

        for (j=0; j<sizeof(switch_cmds)/sizeof(struct diseqc_cmd); j++)
        {
             cmd[0] = &switch_cmds[j];
             diseqc_send_msg(fd,
                                SEC_VOLTAGE_18,
                                cmd,
                                SEC_TONE_OFF,
                                SEC_MINI_A);
             msleep (15000);
       }
       msleep(100000);
       close(fd);

       return 0;
}
 
... but no Idea why the disable Limits Command (0xe0, 0x31, 0x63,) is not working.

Well, I guess it maybe is not a matter of 'disable limits' not working (because you now CAN move the dish beyond those limits, with Move East/West commands, and with GotoPosNn commands, can't you?),
but a matter of a motor-IC that doesn't respond to GotoX (angular position) commands beyond 65 degrees from zero.

I've read it often, that USALS doesn't go beyond 60 or 65 degrees, and always thought this boundary was in the USALS algoritm in the receiver.
But the boundary might well be in the motor IC, as well (or maybe even only in the motor-IC?).

Another strange thing of USALS: the GotoX commands have two possible formats: USALS/ GotoX; Raw diseqc commands

Greetz,
A33

By the way: Welcome to the forum, xforze!

Edit: By the way 2:
Did you also try Goto 66 degrees, 67 degrees, 68, and 69? Same result?

Edit2:
For those angular positions use command E0 31 6E E4, and then 20 or 30 or 40 or 50 (as you already tried 10 and 60).
 
Last edited:
Hey A33,

Greetins from München)
It seems that you are right, its not possible to turn beyond 65°. I tried 66° as well with my C-Script and it was not working.
It doesnt matter if I move Step by Step or directly to a Position behind the Limit, it will not work.
I attached the Positioner now to my Sat Receiver (VU-Solo) to test it there and its also not possible to move beyond 65°.
There is a "Limits" Menu where I can disable the limits even with this its not possible.

So it seems I have to mount two Positioner on each other an move each Positioner 35°:p

Thank you for your support, I will think now how I will continue.

Cheers, Thomas
 
What Titanium proposed didn't work?
Goto65 degrees, and then move beyond that, with the MoveEast/MoveWest command?
There you could save the new position (StoreNn), then.

I have read that that is the way to go, beyond the USALS 60/65 degree boundary.
But it might be that the STAB doesn't allow that, and that you'd need a motor like the SG2100 to do that?
I have never tested this myself, though. So no garantees whatsoever.

Greetz,
A33




Edit/added half an hour later:
The issue with a STAB and 65 degrees was also present in this thread: OTHER - HH90 out of range
Here it seems the TS used a SG2100 in the end, but didn't report back the results?
Only simple alternative I can think of: use a byrider LNB, at 5 degrees distance, as Brct203 suggested. Other solutions will give problems to get the angles right, to follow the arc east/west, I think, so I don't really recommend them (unless you think it though thoroughly~ better than I did in the linked thread, I don't know if my reasoning was very correct, I would have to read it very thoroughly again...) .
 
Last edited:
Hello !
"The disable limits function is for removing user set software limits." Ok, this would explain why disabling the 65° Limit will not work )
"Goto65 degrees, and then move beyond that, with the MoveEast/MoveWest command?" <- This will not work, there is no way to go beyond 65°

But thanks for your support!
 
So STAB, though they 'developed' USALS, have built in unnecessary limit(ation)s to their motors, it seems.....

Are you now gonna do this?
So it seems I have to mount two Positioner on each other an move each Positioner 35°:p

I'll be very interested in your work, there. I think it can be done, but you'll have two times backlash from the motors, so I would be interested in seeing the precision of that setup.

When you have just a 100cm or 110cm dish, I'd try a SG2100 or so.
Also when you just want to see satellites east or west of due south, a solution to follow just that part of the arc would be possible I think.

If I ever have/take the time to investigate on my defective STAB HH100, I'll check at what angles the reed switches get into action. If that really would be 70 degrees, or if it is in fact 65 degrees, and might be causing the 65degrees limits.

Greetz,
A33
(just about 850 km motorway away from München... :) )
 
I'll be very interested in your work, there. I think it can be done, but you'll have two times backlash from the motors, so I would be interested in seeing the precision of that setup.
I have come to accept that the last usable Satellite for me will be MonacoSat at 52.0°E., I wanted to tune to ABS2 75°E because of the channel "RU TV". but it seems its not possible.

Another question I have: How can I calculate the Rotor Position (gotox) for my Location (Atitude and longitude coordinates: 48.17904, 11.2547) ?


My STB is moving the Rotor to the following Postitions for the Satellites Türksat, Astra, Amos, Telestar)

E42° = 35° at Rotor
E19,2° = 9,5° at Rotor
W4° = -16° at Rotor
W15° = -30° at Rotor

As I want to rotate the Positioner wit my C-Script, I have to calculate the Positions for the different Satellites.

Thomas
 
Another question I have: How can I calculate the Rotor Position (gotox) for my Location (Atitude and longitude coordinates: 48.17904, 11.2547) ?

I have made a spreadsheet calculator that can calculate exactly that, but alas the "string-calculation" for the hexadecimal values has gone defect; I think because of compatibility-issues between openoffice/libreoffice and excel format.

I'd have to repair that first; but then I can calculate for you. Maybe this evening, I have time.
For what satellites do you want the angular/hex values // GotoX commands?
Do you want them for your actual latitude, or for your (sliiiightly different and sliiiightly better) so-called 'modified' latitude (assuming you've finetuned your motor setup)?


Though I have developed my calculator myself, I believe I've seen the formula to calculate the GotoX angle also on a developers forum somewhere. I don't think many people use their own calculation... :) :) :)
Come to think of it, I believe satellite-calculations.com, lookangles, also gives some motor angle results. I believe them to be trustworthy (but I haven't checked).
And I remember there's some other exe program, that gives several motor angles, but I've never used it.

Does this help?

Greetz,
A33
 
I just made a screen shot for your angles, for a few satellite positions.
( I noticed that I already chose to calculate the angles based only on the modified latitude, in my spreadsheet. )
NB. Though the DEC.N.HEX function does only truncate the original value, I made this calculator do a proper rounding for the HEX result of 1/16 degree.

column B; satellite longitude
column G: motor rotation angle (hour angle)
column I-J: raw diseqc command (you may have to add a couple of zeros, in your script)

Do you need data on more satellite positions?

Greetz,
A33

xforze  A33   Raw diseqc USALS angles   Number 1     Schermafdruk_2021-03-25_22-23-54.png
 
Hi!

Wow, great Work!! Also the diseqc Commands are printed out :clapping

I will try with -15° and 52° and come back to you if Its working and I need more Positions.
But it would be great to do the Calculation via a Script, I found the Script below and will have a look during the weekend if I can use it for the Calculation I need.
project-magpie/enigma2-openpli

Maybe you already have an Opinion if it will be useful )

Cheers, Thomas
 
Though I have developed my calculator myself, I believe I've seen the formula to calculate the GotoX angle also on a developers forum somewhere.

xforze :
I believe this was the topic that I referred to (hadn't time to read it all back again, and check):
Es ist sogar auf Deutsch! Kein Problem für dich? (It even is in german language! No problem for you?)

On my computer I also found this link: Angle setting on HH motor
Never checked that code, though.


And I also didn't check out your link, yet.
I quickly saw they use the flattening factor for the earth, that looks thorough!
(Many calculators use earth radius at the equator, 6378; I use the mean earth radius, 6371, which is better; but to account for the flattening at various latitude angles, is best!)

It's been a while since I was working on these earth/angle calculations....
(Now working on equations to calculate offset angle and focal length on a multifeed dish.)

Greetz for now,
A33.
 
  • Like
Reactions: Titanium
I found the Script below and will have a look during the weekend if I can use it for the Calculation I need.
project-magpie/enigma2-openpli

Maybe you already have an Opinion if it will be useful )

I just had a quick look. Looks like they first calculate elevation and azimuth of the sat, and out of these values they calculate the hour angle.
The formula in the german article that I linked does it directly out of site-lat, site-long, and sat-long (about the same formula as I found, IIRC; and the outcome is exactly the same). However, no earth flattening factor here; but you could use the mean earth radius, as I did. (Could mean a couple of hundredths degrees off!)

hour angle = arctan { [sin(sitelon-satlon)] / [ (cos(sitelon-satlon)) - ( r(earth) / r(ClarkeBelt) ) * cos(sitelat) ] }

Negative angle outcome = east; positive angle outcome = west (as in my spreadsheet).
For sitelat I use the modified site-latitude, as I indicated earlier.
And of course, check that you use radians and degrees correctly. I suppose that you know how to do that.

Greetz,
A33
 
Hi!

Thanks for your support! It seems that this C Function is working fine for me, its based on the Javascript Function from this site: Satellite Finder - Satellite Az-El Calculator to help point your dish

Code:
float rota(float satlong, float eslat, float eslong) {

    // Adjust eslat and eslong
    float minlat = ((eslat - (int) eslat) * 100) / 60.0;
    eslat = (int) eslat + minlat;

    float minlong = ((eslong - (int) eslong) * 100) / 60.0;
    eslong = (int) eslong + minlong;

    float radius=6378;
    float horb = 35786;
    float rcentrum = radius+horb;
    float alfa = eslat*(PI/180);
    float rm = radius*cos(alfa);
    float omega=satlong*(PI/180);
    float mu=eslong*(PI/180);
    float beta=omega-mu;
    float os=rcentrum;
    float oc=rm*cos(beta);
    float ac=rm*sin(beta);
    float cs=rcentrum-oc;
    float distx=atan(ac/cs);
    float landa=beta+distx;

    if (abs(landa*180/PI) >90) return -999;
    return (landa*180)/PI;
}

Cheers, Thomas
 
  • Like
Reactions: a33

Users Who Are Viewing This Thread (Total: 0, Members: 0, Guests: 0)

Who Read This Thread (Total Members: 2)