HDMI power and alternative remote inputs ( was Re: G7 X porting thread) - page 5 - General Discussion and Assistance - CHDK Forum

HDMI power and alternative remote inputs ( was Re: G7 X porting thread)

  • 79 Replies
  • 37027 Views
*

Offline Ant

  • *****
  • 509
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #40 on: 11 / January / 2019, 05:04:06 »
Advertisements
Are there any other alternatives, for example via the USB port?

 :)
http://lmgtfy.com/?q=arduino+usb+ptp

*

Offline c_joerg

  • *****
  • 1251
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #41 on: 11 / January / 2019, 05:18:14 »
http://lmgtfy.com/?q=arduino+usb+ptp

Interesting…,
But I have thought more that the Arduino is a simple slave device and only takes over the control of the engine or light ...
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline reyalp

  • ******
  • 14118
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #42 on: 11 / January / 2019, 23:26:23 »
I would like to control an external device (Motor Slider, Plant Lamp) in a time-lapse script via Arduino. Since that seems to me to be an elegant solution with the HDMI 5V output. If I understood correctly then the 5V voltage can also switch in recording mode.
Yes
Quote
Does it work even if the camera is in half-pressed shutter?
On sx710 at least it does

Quote
Could you also generate pulses (3 * 50ms with 50ms break)?
I don't think anyone hast tested the reaction time. Voltage seemed take noticeable time to drop after calling DisableHDMIPower with just multimeter, but faster with when the +5 was also connected to the hotplug detect pin.

If you want to experiment with this, you can find EnableHDMIPower and DisableHDMIPower in the funcs_by_*.csv for your camera, and call them with call_func_ptr(0xwhatever)

Note that HDMI power defaults to ON in playback mode, so whatever is reading the output should be prepared for that.

Quote
Are there any other alternatives, for example via the USB port?
We don't have a way to use the USB output without a full PTP connection.
Don't forget what the H stands for.

*

Offline c_joerg

  • *****
  • 1251
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #43 on: 12 / January / 2019, 02:41:03 »
If you want to experiment with this, you can find EnableHDMIPower and DisableHDMIPower in the funcs_by_*.csv for your camera, and call them with call_func_ptr(0xwhatever)


Thank you for the explanation. As soon as my cable is there I will experiment with it.
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd


*

Offline c_joerg

  • *****
  • 1251
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #44 on: 04 / February / 2019, 12:50:13 »
I tried the following script on my g1x 100e:


Code: [Select]
--[[
@title HDMI Test
@chdk_version 1.4
#delay=1000   "Delay"
#runs=10      "Runs"
--]]


print('HDMI Test')
z=0

repeat
 
    z=z+1
    print("Nr  :",z)
--EnableHDMIPower() 
call_func_ptr(0xff055850)
    sleep(delay)
--DisableHDMIPower()
call_func_ptr(0xff055858)
    sleep(delay)
 
until z==runs



Unfortunately, the output does not change ...
I only have one cut-through cable. I'm assuming that the red and black wire are the power supply. At these wires I measure in recording and playback mode 4,5V.
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline reyalp

  • ******
  • 14118
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #45 on: 04 / February / 2019, 16:55:13 »
Unfortunately, the output does not change ...
I only have one cut-through cable. I'm assuming that the red and black wire are the power supply. At these wires I measure in recording and playback mode 4,5V.
FWIW, I found an HDMI to DVI female adapter to be very convenient for testing: https://chdk.setepontos.com/index.php?topic=13451.msg137523#msg137523 (pinout on wikipedia https://en.wikipedia.org/wiki/Digital_Visual_Interface)

The voltage being 4.5 rather than 5 seems a little surprising.
Don't forget what the H stands for.

*

Offline c_joerg

  • *****
  • 1251
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #46 on: 05 / February / 2019, 12:46:41 »
on my S100 the HDMI 5V was always on, so there is no need to turn it on, maybe there is even no such function.
Like my G1x and S110. Would be interesting to know if you can turn it off on these cameras.

What is HdmiHpd5VOutput doing?

I tried also ChangePowerState with no effect. But code looks OK?
 
Code: [Select]
   if (bi.platform=="g1x") and (bi.platsub=="100e") then
      --0xff0557d8,ChangePowerState_FW
      call_func_ptr(0xff0557d8,1)  
      --EnableHDMIPower() 
      --call_func_ptr(0xff055850)
      sleep(delay)
      --0xff0557d8,ChangePowerState_FW
      call_func_ptr(0xff0557d8,0)  
      --DisableHDMIPower()
      --call_func_ptr(0xff055858)
      sleep(delay)
    elseif (bi.platform=="s110") and (bi.platsub=="103a") then
      --0xf807a3d8,ChangePowerState_FW
      call_func_ptr(0xf807a3d8,1)  
      --EnableHDMIPower() 
      --call_func_ptr(0xf807a450)
      sleep(delay)
      --0xf807a3d8,ChangePowerState_FW
      call_func_ptr(0xf807a3d8,0)  
      --DisableHDMIPower()
      --call_func_ptr(0xf807a458)
      sleep(delay)
end

The voltage being 4.5 rather than 5 seems a little surprising.
Yes, but my S110 delivers 5.0V

M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline reyalp

  • ******
  • 14118
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #47 on: 06 / February / 2019, 00:42:34 »
What is HdmiHpd5VOutput doing?
Nothing on g1x, it's just a RET instruction.
Quote
I tried also ChangePowerState with no effect. But code looks OK?
EnableHDMIPower and DisableHDMIPower just call ChangePowerState with 1 or 0 respectively. The addresses you list are correct for g1x 100e.

On SX160IS (the only pre-digic 6 camera I have with HDMI), Enable and Disable work as expected in both playback and rec, 4.95V when on. By default HDMI power stays on in rec.
Don't forget what the H stands for.


*

Offline c_joerg

  • *****
  • 1251
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #48 on: 06 / February / 2019, 13:40:47 »
On SX160IS (the only pre-digic 6 camera I have with HDMI), Enable and Disable work as expected in both playback and rec, 4.95V when on.
Interesting…
My sx230 has also 5V in both playback and rec. If a camera has 5V on the HDMI port during playback and recording, why should Canon then install a switch off?

What can the 5V voltage drive? At 1K ohms the voltage breaks down to 2V.

It is interesting in the G1x: If I put the hotplug detect with a 1K ohm to the 4.5V, then the voltage goes to 5V.

I don’t not know if what that means:
My cameras have 8 bytes (?) Between the addresses of EnableHDMIPower and DiableHDMIPower. With your SX160IS 24 bytes.

To be quite sure, I will order once the proposed HDMI adapter…

Minimal HDMI remote for testing ;)
1 micro or mini HDMI to standard HDMI adapter
1 HDMI standard to DVI female adapter
1 paper clip
If I watch to the picture, I looks like you measure between pin 14 and 16 (+5V and Hot plug detect)
« Last Edit: 06 / February / 2019, 13:48:48 by c_joerg »
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline reyalp

  • ******
  • 14118
Re: HDMI power and alternative remote inputs ( was Re: G7 X porting thread)
« Reply #49 on: 06 / February / 2019, 16:18:37 »
It is interesting in the G1x: If I put the hotplug detect with a 1K ohm to the 4.5V, then the voltage goes to 5V.
Did you try calling Enable/Disable with the resistor present?

Quote
I don’t not know if what that means:

My cameras have 8 bytes (?) Between the addresses of EnableHDMIPower and DiableHDMIPower. With your SX160IS 24 bytes.
Good observation.

g1x looks like this
Code: [Select]
; EnableHDMIPower 0xff055850
    mov     r0, #1
    b       loc_ff0557d8 ; ChangePowerState_FW
sx160
Code: [Select]
; EnableHDMIPower 0xff86498c
    push    {r4, lr}
    mov     r0, #1
    bl      sub_ff937f48 ; HdmiHpd5VOutput_FW
    pop     {r4, lr}
    mov     r0, #1
    b       loc_ff864914 ; ChangePowerState_FW
Unlike g1x, HdmiHpd5VOutput is a real function on sx160. So, we know the canon firmware is different.

Quote
To be quite sure, I will order once the proposed HDMI adapter…

Minimal HDMI remote for testing ;)
1 micro or mini HDMI to standard HDMI adapter
1 HDMI standard to DVI female adapter
1 paper clip
If I watch to the picture, I looks like you measure between pin 14 and 16 (+5V and Hot plug detect)
Yes, that's what I measured last time because I had the pins there for a switch.

I get 5V (not 4.95 as on the HPD) measuring from pin 14 to ground (shell of the plug).
Don't forget what the H stands for.

 

SimplePortal 2.3.6 © 2008-2014, SimplePortal