Can't find RELAYx_Pin =81

I am using the latest Mission planner 1.3.82 and trying to setup two camera switching on SpeedyBee F405 wing Mini.
Speedybee documentation like Matek list following setup:

But in the latest MP there are no options 81 or 82 for Pin setup

Does anyone know corresponding Relayx_Pin setup on SpeedyBee?

You can just type in the GPIO number you need without selecting it from the list - that list is not complete.
BUT…

For the Speedybee F405 Wing GPIO pin 81 will be the VTX Power control, probably not directly avaliable to you but it turns on and off the 9v supply to a VTX

VTX power control
GPIO 81 controls the VTX BEC output to pins marked "9V". Setting this GPIO high removes voltage supply to pins.

If you look in the hardware definition it lists the PWM output pins and their GPIO pin:

# PWM out pins. Note that channel order follows the ArduPilot motor
# order conventions
PB7  TIM4_CH2  TIM4 PWM(1) GPIO(50) BIDIR
PB6  TIM4_CH1  TIM4 PWM(2) GPIO(51)
PB0  TIM3_CH3  TIM3 PWM(3) GPIO(52)
PB1  TIM3_CH4  TIM3 PWM(4) GPIO(53) BIDIR
PC8  TIM8_CH3  TIM8 PWM(5) GPIO(54)
PC9  TIM8_CH4  TIM8 PWM(6) GPIO(55)
PB14 TIM8_CH2N TIM8 PWM(7) GPIO(56)

PA15 TIM2_CH1  TIM2 PWM(8) GPIO(57)
PB10 TIM2_CH3  TIM2 PWM(9) GPIO(58)
PB11 TIM2_CH4  TIM2 PWM(10) GPIO(59)

PB15 TIM1_CH3N TIM1 PWM(11) GPIO(60)
PA8  TIM1_CH1  TIM1 PWM(12) GPIO(61)# LED

If you have the Speedybee F405 Mini the main PWM pins have the same GPIO numbers, but there is no VTX power control or GPIO 81.
You’ll be able to find it’s hwdef from the link above, it’s nearby.

I am trying to setup two cameras and want to switch between the two on the speedybee f405-wing-mini (not to be confused by f405_mini).
Do you know how to setup a relay switch to switch between two cameras?

There’s no standard/documented method as far as I know. You’d need an RC channel to choose the camera, and a GPIO/relay pin to operate an actual relay or similar. You might be able to just switch the video signal, and power both cameras at once.
If you need to save a fraction of power you can use a douple pole double throw relay and switch over the power as well as the video signal.

In the manual.

Here are my setup and parameters:

  • SpeedyBeeF405-Wing-Mini running 4.5.5
  • Two cameras are wired sharing same voltage out put from the FC, but have two Vin for two cameras
  • On the radio, I have CH5 set to trigger camera switching.
  • RELAY1_FUNCTION = 1
  • RELAY1_PIN = 54 (81 CAUSES INVALID MESSAGE)
  • RC5_OPTION =28
  • SERVO5_FUNCTION = -1

With this setup and parameters no switching takes place.

Dave, I posted this snapshot at the beginning, something else is missing from the document. Parameter 81 gives invalid warning in the message box.

Only mention of pin 81 in the HWDEF file is for VTX power Control as Shawn mentioned. So, I don’t know.
Get A Matek H743-Wing …

Does your FC has AUX outputs or only main outputs. You can try
RELAY1_PIN = 105

I doubt that Speedybee knows what aux outputs are. None of those cheap FC’s have an IOMCU.

Yes, this is what i thought but Pin 54 is a AUX output and 105 a MAIN output if I follow the the description in the wiki
https://ardupilot.org/plane/docs/parameters.html#relay1-pin-relay-pin
So I would give it a chance to test it.

Worth a shot but I think it’s hardware dependent and when he uses the pin number Speedybee states in their manual for camera switching he says it produces an error. Nothing in the Ardupilot board specific docs about it. In fact the hwdef says pin 81 is for vtx power not camera switching. Pin 55 is chan 6 and 105 is undefined.

That feature is not yet implemented. A simple relay could alternate power between two VTX modules, but there is nothing in the AP codebase to take full advantage of that feature on pin 81 so far as I know, and attempting to use it will likely produce errors.

Speedebee’s own manual is wrong but who is surprised about that. The forum filler.

Actually I take back part of what I said. Pin 81 is set up as a simple GPIO and should be able to provide power to the VTX output when switched high. But I don’t know how that could be used to switch between dual transmitters by itself.

1 Like

Yea, that’s what I see.