XM530 4MP Wifi Camera, H.265->H.264 possible? Maybe flash FW?

dikidera

n3wb
Joined
Jun 25, 2018
Messages
8
Reaction score
0
Location
Europe
So I got a generic Wifi camera with FW V5.00.R02.000807A8.10010.342917.0000010 which indicates a XM530v200(Board has markings, IPC-RM1-BLK530v200 and M23A-MINI-ETH-ABQ v1.01). What happened was I spent >$100 and found out you cannot use H.264 which my 8 channel XVR uses. Yes I use the Analog + IP cameras. So my new 4MP cameras are supported by the XVR, but only supports H.264 and not H.265.

The camera settings only has H.265....bummer cause I bought two. What happens is that I have a black image on my XVR.

I started digging in the fw of the camera(from an online dump) and found that the Sofia binary has references to H.264. The config files called Encode.json and another one have inside them settings for H.265 only. My idea was to FLASH a modified Encode.json with an additional options for H.264...and hope for the best.

Problem #1 - I have read that UART is disabled on these cameras.
Problem #2 - U-boot is password protected.
Problem #3 - I am not sure that even if there was no password protection if the H.264 setting would work.

I guess I am looking for advice. I also think it's a bit egregious that...these cameras force us to use H.265.
 
Last edited:

dsc7050

n3wb
Joined
Dec 2, 2020
Messages
9
Reaction score
3
Location
USA
try login the camera web interface, go to encode setting change from (H.265 to H.265X). that will work on H.264 XVR/NVR.
 

paul@austins.tv

Getting comfortable
Joined
Dec 4, 2015
Messages
313
Reaction score
293
I really cannot believe that the camera only has H265.
I would highly recommend the basics and taking the camera back to factory defaults. H264 as a minimum encode, should be available! Unless you have some fake weird camera and it's 4 MP upscale only works on H265 with awful bitrate levels.
You also sure the web access to the camera is not allowing full control for the camera interface?
Factory defaults, via correct browser is my advice.
 

dikidera

n3wb
Joined
Jun 25, 2018
Messages
8
Reaction score
0
Location
Europe
I can assure you the camera is stock. I've also done some crude analysis of the firmware and found that only H265 exists in the config files, logically if an H.264 option existed in the config file it should work, the software for encoding the camera sensor image to H264 or H265 is in there, they just choose not to use it and have locked down the bootloader which makes flashing custom things not possible unless you desolder and reprogram the flash chip directly, which requires a specific skillset to reball the chip.

As for upscaling yeah I guess it's possible as I was not too impressed with the quality of the image for the advertised 4MPX.

Here are the contents of Encode.json

{
"Mem":
{
"4M": [-1,34]
},
"CaptureSizes":
{
"4M": [2560, 1440, 1440],
"D1": [800, 448, 448]
},
"ExVb":
{
"2" : [640, 360, 3]
},
"Vi":
{
"SensorFPS_PAL": 20,
"SensorFPS_NTSC": 20,
"CapWHXY": [1920, 1080, 0, 0],
"ViX":
[
{
"Channel": 0,
"CapSize": "4M",
"VbBlk": 2
},
{
"Channel": 1,
"CapSize": "D1",
"VbBlk": 3
}
]
},
"Venc":
{
"VencMem" : "MINI",
"VencType": ["H265"],
"VencX":
[
{
"Channel": 0,
"MaxSize": "4M",
"CapSizeSrc": ["4M"]
},
{
"Channel": 1,
"MaxSize": "D1",
"CapSizeSrc": ["D1", "CIF"],
"BuffSize": 300
}
],
"Jpeg":
{
"Channel": 3,
"MaxSize": "D1",
"CapSizeSrc": ["D1", "CIF"]
}
},
"Audio":
{
"AudioPlayEnable": true
},
"Smart":
{
},
"ViV2":
{
},
"Isp":
{
}
}
And AVEnc.custom

{
"Encode" : [
{
"MainFormat" : [
{
"AudioEnable": true,
"Video" : {
"BitRateControl" : "VBR",
"BitRate" : 1638,
"Compression": "H.265",
"Resolution" : "4M",
"Quality": 3,
"FPS" : 12,
"GOP" : 2
}
},
{
"Video" : {
"BitRateControl" : "VBR",
"BitRate" : 1638,
"Compression": "H.265",
"Resolution" : "4M",
"Quality": 3,
"FPS" : 12,
"GOP" : 2
}
},
{
"Video" : {
"BitRateControl" : "VBR",
"BitRate" : 1638,
"Compression": "H.265",
"Resolution" : "4M",
"Quality": 3,
"FPS" : 12,
"GOP" : 2
}
}
],
"ExtraFormat" : [
{
"AudioEnable": true,
"VideoEnable" : true,
"Video" : {
"BitRateControl" : "VBR",
"BitRate" : 1280,
"Compression": "H.265",
"Resolution" : "D1",
"Quality": 3,
"FPS" : 12,
"GOP" : 2
}
}
],
"EncodeStaticParam": [
{
"Level": 41,
"Profile": 2
}
],
"SnapFormat": [
{
"Video": {
"BitRate": 512,
"BitRateControl": "VBR",
"Compression": "H.265",
"FPS": -3600,
"GOP": 2,
"Quality": 4,
"Resolution": "D1"
},
"VideoEnable": true
},
{
"Video": {
"BitRate": 512,
"BitRateControl": "VBR",
"Compression": "H.265",
"FPS": 1,
"GOP": 2,
"Quality": 4,
"Resolution": "D1"
},
"VideoEnable": false
},
{
"Video": {
"BitRate": 512,
"BitRateControl": "VBR",
"Compression": "H.265",
"FPS": 1,
"GOP": 2,
"Quality": 4,
"Resolution": "D1"
},
"VideoEnable": false
}
]
}
]
}
My XVR4108C-S2 only supports H264/H264+ and I believe all the encoding/decoding is done in hardware, so it's not possible to add anything but software decoding/encoding which will cause the device to lag. The next best solution was to hack the FW of the cam to enable H264, however the Chinese have made it very difficult to access these devices. Locked bootloader and locked UART.
 
Last edited:
Top