LinkPi encoder family

Actually I quit using the NBC app as it was just too unreliable. I just watch those channels with YTTV now. They actually look better than the NBC app since YTTV has 1080p enhanced resolution (which basically means higher bitrate)

NBC app was completely unreliable during the Olympics, but since then it's been fine using the 9.9.1 version that doesn't have the dim screen issue at video start.

1 Like

Has anybody messed around with the LinkPi Encoder API yet? I'm working on a script to auto-crop some of the Xfinity premium channels. I'm done with the part to identify the crop required to make those channels fullscreen width-wise, while still maintaining the broadcast aspect ratio.

Now I need to send the commands to the LinkPi to do the cropping on the fly, but I can't get logged in via the API. Pretty much nothing but "Authentication failed" responses.

API documentation is here:

I've tried Postman using the described procedure in the doc, plus a couple of curl commands -- which is what I actually want to use:

curl --digest -u "username:password" http://linkpi-encoder/link/system/get_sys_state

and

curl --digest http://linkpi-encoder/link/system/get_sys_state?username=admin%passwd=password

No joy. :frowning:

It all seems so obvious now, but it took a while to figure this out :slight_smile::

curl --digest -L -H 'User-Agent: Mozilla' -u "${LINKPI_USERNAME}:${LINKPI_PASSWORD}" -i "http://${LINKPI_IP}/link/user/lph_login?username=${LINKPI_USERNAME}&passwd=${LINKPI_MD5_PASSWORD}"

Your password needs to be md5 hashed for the URL, but that password needs to be used behind the -u without hashing.

The JSON response includes 3 hash values: L-HASH, P-HASH and H-HASH. Each of those needs to be included in subsequent curl commands, each behind its own -H. No other authentication is required in those subsequent commands -- until the auth expires and you need to login again.

Subsequent commands, once auth'd, would look like this:

curl -H "L-HASH: $L_HASH" -H "P-HASH: $P_HASH" -H "H-HASH: $H_HASH" "http://${LINKPI_IP}/link/some_api_endpoint"

What are the functional applications of API access of the linkpi?

For me, it's just as I stated above:

Hard as it is to believe, they have a half a dozen premium movie channels they broadcast with large black borders around all 4 sides. Channels doesn't have the ability to zoom, and doing it via the TV zoom is a hassle at best. So, that's my motivation.

The cool thing about the way I'm going to use it, is that the cropping can be done on the fly without having to restart anything. Plus using the encoder to do it, saves on the resources required to use ffmpeg for the task -- not to mention it's a relatively small addon to an existing encode.

What others might come up with, I don't know, but I thought I'd spare anyone the hassle of figuring out how to authenticate with the API. I may add an Action or two to OliveTin-for-Channels, now that I have this LinkPi API access -- and the Docker socket available.

20241031 is out

Brand new OLED screen button interaction
Fixed the issue where the menu button is not displayed when accessing the backend via mobile phone
On the live push page, the problem that after clicking the save button when pushing has been fixed, there is a probability that the push preview cannot be viewed.
h5 player page, added the function of creating full-screen playback shortcuts for specified channels
Optimize decoding network streams containing B frames
System underlying optimization

Updated to latest with no issues so far... BTW - the ENC5V2 is no longer available on Amazon, but I see that you can purchase it from Aliexpress or direct from the manufacturer.

Is anyone aware of a 4K60 capable HDMI encoder with multiple inputs that works with ADBTuner?

1 Like

4K60 capture is going to be tough. It would require higher bandwidth than HDMi 1.4 and a work around for newer HDCP. Almost all these encoders work by “stepping around” older HDCP.

I don't even bother with 4K with this. I just use streamlinks to redirect me to the apps with the 4K feeds. There's only a finite amount of 4k channels much less 24/7 ones to be worth bothering anyways

1 Like

A note - my LinkPi found an even newer 1031 firmware, with version 3.5.2, instead of 3.5.0

Brand new OLED screen button interaction
Fixed the issue where the menu button is not displayed when accessing the backend via mobile phone
On the live push page, the problem that after clicking the save button when pushing has been fixed, there is a probability that the push preview cannot be viewed.
h5 player page, added the function of creating full-screen playback shortcuts for specified channels
Optimize decoding network streams containing B frames
System underlying optimization

1 Like

Updated my EncV2 and now it’s memory usage is at 99% and get an error trying to load the video stream.

Anyone know of a fix for this?

I assume you mean the ENC5V2? What version firmware did you install?
You have probably already tried these but this is what I have done when I had issues in the past.

Start with a 5 minute HARD power unplugged/power off restart. I would also restart the router. Verify that it has not changed any of the settings internally on the linkpi

If that doesn't work I have also done some of the following at times for issues...
Reinstall older version of firmware...sometimes back a couple versions then reinstall new version if it is working again.
Hold the reset button for 30 seconds to reset everything and put information back in.

2 Likes

Sorry actually it’s the same ENC1V3.

Seems like after an update, when using the mp3 audio encoder it will fill the memory, previously this would not happen.

Setting to AAC and rebooting fixes the issue.

Was using mp3 as it was working better with my HomePods I felt like, but will just stick with AAC.

Thanks for the tips though, if I run into issues in the future will try what you recommended.

2 Likes

I tried to change my ENC5V2 audio encoding to +6 dB because the LinkPi channels are slightly quieter than the TVE and HDHR ones but doing this seems to make the streams inaccessible - has anyone been able to change the audio settings on the Encode tab under overall config?

EDIT: after further review, apparently, after changing something on this page and doing a "save to local" or "save to group", then after a nightly reboot, sometimes the LinkPi ends up in a state where the streams are unavailable - sometimes changing a setting and doing a "save to local" and "save to group" can fix the problem as well - has anyone experienced this? Any solution?

App version:

3.5.1 build 20241031_2405

SDK version:

3.5.1 build 20241031_29857

Sys version:

3.5.2 build 20241031

Anyone found any settings to change to get the picture to be a little more crisp and less soft?

App version

3.5.1 build 20241031_2405

SDK version

3.5.1 build 20241031_29857

Sys version

3.5.2 build 20241031

20241231 is out

The laboratory has added a system log function, which supports viewing/downloading system operation logs
The interface output page has added Line Output control
The encoding setting page has added AAC-HE encoding for audio encoding
The file recording page has added loop recording, segment recording, power-on recording and other functions
Fixed the problem that audio mp3 encoding does not work
Optimized the scaling and performance issues of watermark special effects
Modified some page text descriptions

I just updated one of my linkpi from 1.0.0 to the latest version, however now the led screen infront is upside down. Anyone else face something similar? and how do you fix it?

how did you update? i seem to remember this being a byproduct of back-door installing the firmware.