Page 1 of 1

Push rotary and COM/NAV help [SOLVED]

Posted: Tue Aug 21, 2018 4:33 pm
by matya007
Hello,

i need some help gentlemens. Another topic i read, how to set pushable single encoder for comm and nav panels. I use CTS 288v encoder
I changed the script and of course change device, output etc. The push funktion is working perfect if i push the button change before and after the decimal the adjustable numbers but the numbers changing randomly not continuously. I try normal encoder that is working good. On the encoder has 2 ground pole ( i soldered it for one) and has 3 more pole, one for the push button and two for a rotary these cable connect to the master card.

Can you help me?
Here is my script i was changed, i found another topic this site.

Thank you, Peter.


Re: COM/NAV with single encoder[SOLVED]
Postby nolatron » Mon May 14, 2018 1:35 am

Doh! I meant to post that here so it's archived here as well.

Here’s the changes I made for COM1 and NAV1 radio panels to work with a single rotary encoder. You’ll need to adjust the Device and Input numbers for your hardware, and possibly the rotation value, adding a negative (-) or not, depending on your hardware setup.

Find this block of code for the COM1 panel:

Var 0502, name ROT_COM1_SW, Link IOCARD_ENCODER, Device 31, Input 57, Aceleration 1, Type 2
{
L0 = &ROT_COM1_SW * 1 // change turning direction
&ST_COM1High = ROTATE 18 ,36 ,L0
CALL &Com1ToNGX
}

Var 0503, name ROT_COM1_SF, Link IOCARD_ENCODER, Device 8, Input 4, Aceleration 1, Type 2
{
L0 = &ROT_COM1_SF * 25 // instead of acceleration that doesn't wor
&ST_COM1Low = ROTATE 0 ,999 ,L0
CALL &Com1ToNGX
}

and replace with the following

Var 8600, name COM_SWITCH, Link IOCARD_SW, Device 31, Input 62 Type P // in the shaft

Var 8601, name ROT_COM1_SW, Link IOCARD_ENCODER, Device 31, Input 57, Aceleration 1, Type 2
{
L0 = v8601 // * -1 make sure turning right increments
IF v8600 = 0
{
L0 = &ROT_COM1_SW * 1 // change turning direction
&ST_COM1High = ROTATE 18 ,36 ,L0
CALL &Com1ToNGX
}
ELSE
{
L0 = &ROT_COM1_SW * 25 // instead of acceleration that doesn't wor
&ST_COM1Low = ROTATE 0 ,999 ,L0
CALL &Com1ToNGX
}
}

======

Find this block of code for the NAV1 panel:

Var 0524, name ROT_NAV1_SW, Link IOCARD_ENCODER, Device 31, Input 55, Aceleration 1, Type 2
{
L0 = &ROT_NAV1_SW * -1 // change turning direction
&ST_NAV1High = ROTATE 8 ,17 ,L0
CALL &Nav1ToNGX
}

Var 0525, name ROT_NAV1_SF, Link IOCARD_ENCODER, Device 9, Input 4, Aceleration 1, Type 2
{
L0 = &ROT_NAV1_SF * -5 // instead of acceleration that doesn't wor
&ST_NAV1Low = ROTATE 0 ,99 ,L0
CALL &Nav1ToNGX
}

and replace with the following

Var 8602, name NAV_SWITCH, Link IOCARD_SW, Device 31, Input 61 Type P // in the shaft

Var 8603, name ROT_NAV1_SW, Link IOCARD_ENCODER, Device 31, Input 55, Aceleration 1, Type 2
{
L0 = v8603 // * -1 make sure turning right increments
IF v8602 = 0
{
L0 = &ROT_NAV1_SW * -1 // change turning direction
&ST_NAV1High = ROTATE 8 ,17 ,L0
CALL &Nav1ToNGX
}
ELSE
{
L0 = &ROT_NAV1_SW * -5 // instead of acceleration that doesn't wor
&ST_NAV1Low = ROTATE 0 ,99 ,L0
CALL &Nav1ToNGX
}
}

Here's a video showing it in action:
https://www.youtube.com/watch?v=jpovN2mLImQ

Re: Push rotary and COM/NAV help

Posted: Mon Oct 01, 2018 3:48 am
by nolatron
What type of hardware are you using? A custom built radio or plug-n-play module?

Are the numbers shows on the display (for example Com 1 Stand-by) totally different than what the sim shows for it? or is just certain digits that are off?

First thing comes to mind are incorrectly values assigned for the individual display outputs. Or possibly a wiring issue between 7-segment displays and the display card.

Re: Push rotary and COM/NAV help

Posted: Wed Oct 03, 2018 6:03 am
by matya007
Hi,

Custom built. The segments is correct, if in the game change my panel change too. The segments tested in sioc. Position, and wire is correct. The problem is maybe the rotary . I try it cts288v. 4 output (2 from rotary 1 from button ) go to the mastercard and the rotary and the push button gnd going to same gnd to mastercard. It is correct? The changing working. If i push the button change before and after the dot point the numbers, problem is if i turn the rotary the numbers not continously if i turn fast the rotaty sometimes the numbers going wrong direction.In sioc console working perfect, in the script of corse change the numbers. Thanks for your help. Peter.

Re: Push rotary and COM/NAV help (solved)

Posted: Tue Nov 27, 2018 5:05 pm
by matya007
matya007 wrote:Hello,

i need some help gentlemens. Another topic i read, how to set pushable single encoder for comm and nav panels. I use CTS 288v encoder
I changed the script and of course change device, output etc. The push funktion is working perfect if i push the button change before and after the decimal the adjustable numbers but the numbers changing randomly not continuously. I try normal encoder that is working good. On the encoder has 2 ground pole ( i soldered it for one) and has 3 more pole, one for the push button and two for a rotary these cable connect to the master card.

Can you help me?
Here is my script i was changed, i found another topic this site.

Thank you, Peter.


Re: COM/NAV with single encoder[SOLVED]
Postby nolatron » Mon May 14, 2018 1:35 am

Doh! I meant to post that here so it's archived here as well.

Here’s the changes I made for COM1 and NAV1 radio panels to work with a single rotary encoder. You’ll need to adjust the Device and Input numbers for your hardware, and possibly the rotation value, adding a negative (-) or not, depending on your hardware setup.

Find this block of code for the COM1 panel:

Var 0502, name ROT_COM1_SW, Link IOCARD_ENCODER, Device 31, Input 57, Aceleration 1, Type 2
{
L0 = &ROT_COM1_SW * 1 // change turning direction
&ST_COM1High = ROTATE 18 ,36 ,L0
CALL &Com1ToNGX
}

Var 0503, name ROT_COM1_SF, Link IOCARD_ENCODER, Device 8, Input 4, Aceleration 1, Type 2
{
L0 = &ROT_COM1_SF * 25 // instead of acceleration that doesn't wor
&ST_COM1Low = ROTATE 0 ,999 ,L0
CALL &Com1ToNGX
}

and replace with the following

Var 8600, name COM_SWITCH, Link IOCARD_SW, Device 31, Input 62 Type P // in the shaft

Var 8601, name ROT_COM1_SW, Link IOCARD_ENCODER, Device 31, Input 57, Aceleration 1, Type 2
{
L0 = v8601 // * -1 make sure turning right increments
IF v8600 = 0
{
L0 = &ROT_COM1_SW * 1 // change turning direction
&ST_COM1High = ROTATE 18 ,36 ,L0
CALL &Com1ToNGX
}
ELSE
{
L0 = &ROT_COM1_SW * 25 // instead of acceleration that doesn't wor
&ST_COM1Low = ROTATE 0 ,999 ,L0
CALL &Com1ToNGX
}
}

======

Find this block of code for the NAV1 panel:

Var 0524, name ROT_NAV1_SW, Link IOCARD_ENCODER, Device 31, Input 55, Aceleration 1, Type 2
{
L0 = &ROT_NAV1_SW * -1 // change turning direction
&ST_NAV1High = ROTATE 8 ,17 ,L0
CALL &Nav1ToNGX
}

Var 0525, name ROT_NAV1_SF, Link IOCARD_ENCODER, Device 9, Input 4, Aceleration 1, Type 2
{
L0 = &ROT_NAV1_SF * -5 // instead of acceleration that doesn't wor
&ST_NAV1Low = ROTATE 0 ,99 ,L0
CALL &Nav1ToNGX
}

and replace with the following

Var 8602, name NAV_SWITCH, Link IOCARD_SW, Device 31, Input 61 Type P // in the shaft

Var 8603, name ROT_NAV1_SW, Link IOCARD_ENCODER, Device 31, Input 55, Aceleration 1, Type 2
{
L0 = v8603 // * -1 make sure turning right increments
IF v8602 = 0
{
L0 = &ROT_NAV1_SW * -1 // change turning direction
&ST_NAV1High = ROTATE 8 ,17 ,L0
CALL &Nav1ToNGX
}
ELSE
{
L0 = &ROT_NAV1_SW * -5 // instead of acceleration that doesn't wor
&ST_NAV1Low = ROTATE 0 ,99 ,L0
CALL &Nav1ToNGX
}
}

Here's a video showing it in action:
https://www.youtube.com/watch?v=jpovN2mLImQ