Visonic Powermax and Powermaster Component

Hi @svanstrom, on what kind of hardware do you run HA and which kind a of installation(hassio, docker, venv) ?
If the answer is a Raspberry Pi(version?, on sdcard or on ssd hard drive?) you could be facing a too low free memory issue and your server might spent most of time to swap memory from Ram to disk.
Swapping is an enormous ressource drainer.
It would arrive for sure on a Rpi 3 with some hassio containers, especially with influxdb and grafana or portainer.
I had that issue few weeks ago and because of a single one over more hassio module my rpi was completely unrespondable, sometime more than 5min just to login in it with over SSH !..
i’ve switch from an rpi3 to a « cheap » celeron, 6go ram and 128go ssd by profiting a nice black friday offer, no more out of memory issue since then(4g Ram would have been far enought i think but…).
You could check it by log in in ssh and using the « top » or « htop » program on the command line.
It will show you your memory usage(used, free, available ram) and so on for swap memory usage.
I don’t like to do product ads but that kind of pc are just awesome for HA:

Also i rembember to have read on theses forums that some users were complaining about over memory consuption(memory leaks) since HA 0.10x(don’t rember if 0.101,102 or 103)
Try to search for that topic, always good to got more infos and that kind of issue.

@pocket +1 for history on sqlite local storage, i think sqlite have to be load in memory and is periodicaly flushed to disk for data persistance. In my opinion out of the box recorder defaults config is a non sense, especially on sdcard rpi configuration because it will record every states changes of every integration, moreover that database use to get corrupted quite often while growing up, just an AC current issue and most of time you’ll be good to delete your history sqlite database…
In the « recorder » integration i had excluded all sensors data collection just to include ones that have a real mean and are usefull for my usage. My history isn’t a big mess anymore and start to be more usefull than before.

Yes, it’s easy to outgrow a Pi if you’re not mindful of what’s going on behind the scenes. @svanstrom, an easy way to find out is to stop HA and rename the home-assitant_v2.db file using SSH. I think a new file will be automatically created when HA is restarted. If the system immediately gets more responsive, that would be the cause. I only have about 20 include entries under recorder:, but even after a few weeks, the file is fairly large.

Regarding @olijouve’s comments on hardware, I took a similar path to the mini PC, but host Ubuntu and HA on an Odroid H2. Although bigger than the one you’ve linked, I had a choice for the amount of RAM and the storage to use. In the end, I elected to populate it with 16 GB RAM (overkill in hindsight) and a 240 GB SSD. The SSD is a type that is resistant to data loss due to power failures. It’s been pretty solid since August when I first got it up and running, and the database survived a power interruption during a storm a few months ago. Additionally, with it or any other x86 processor, I can load Visual Studio Code as a Hass.io add-on. VSC is a joy to use vs. some of the alternative ways of maintaining the configuration files, particularly when things go wrong.

Hi Dave,

I cannot see any new version in HACS, will it be released or should I update manually?

Also, is it possible to add this shock sensor:
https://www.visonic.com/Products/PowerG-Wireless-Property-Protection/sd-304-pg2
Currently I have this:

sensor type: UNKNOWN 53

Other sensors shows correct type.
If yes, do you need some log or anything that I can provide?

Thanks and best regards.

I can answer this one. If you’ve already installed 0.3.3.4 using HACS, manually replace those files with the new ones. Dave hasn’t yet formally released an update.

https://community.home-assistant.io/t/visonic-powermax-and-powermaster-component/55949/750

If it’s a new integration using HACS, install the listed one first so it’s ‘registered’ locally. After a manual update, it’ll still report the version HACS installed, but at least it’ll recognize when a newer version is formally released.

https://hacs.xyz/docs/basic/existing_elements

I’ve just released 0.3.4 to Github and hopefully made it formal so you get it from HACS.

As usual, any problems then let me know here :slight_smile:

2 Likes

Hey Dave,

Thanks for your work on this component, I’m new to HA and migrating away from Vera (well, openLuup actually) and the Visonic plugin from over there.

HA is running under Docker on my Synology NAS.

My panel is a Powermax+ connected with the “official” RS232 kit which in turn is interfaced to a Startech NETRS232 - all of this has worked fine for many years.

Having a few issues with consistently getting into Standard Plus / Powerlink mode, I’m pretty familiar with how the Vera plugin worked and as you’ve mentioned a few times in this forum and on your GetHub repo there’s definitely some timing / sequence issues.

Things are functional for me under Standard mode anyway with your component, but would prefer the slightly more robust Powerlink mode if possible.

With that in mind is there anyway to stop / start your component in HA independently of restarting the whole HA instance?

I’'m not familiar enough with how HA works, but it would seem that initializing the component as part of an HA restart adds to the timing problems, especially if you have a large HA install featuring Z-Wave and the like - a lot of system startup load. That’s also compounded somewhat on a Docker install where the entire container is stopped / started.

If it’s possible to start / stop the component from a “button” (or something) then I’m sure it would go a long way to help with timing issues and would also mean that it’s much simpler to get the “sequence” right - stop the component, restart the panel, start the component. Rather than having to bring down the whole HA instance.

Hope that’s a possibility?

Hello,
Motivated by this thread, I just ordered a Powermaster 30, with a USR-TCP232-E2 ordered here:


However it is not very clear to me (based on the explanations given in Github), how to connect the USR-TCP232-E2 to the Powermaster 30 ?
Do I need to order something else ?
Is there some picture somewhere ?
Thanks for the great work, I am really eager to test all this.

You could have some good use of some Dupont cables.
You connect to the “IP” port on the powermaster 30 as the pinout in the instructions.

Tx to Rx and Rx to Tx.

Here are some pictures I found from when I was doing it:
Rotate the first clockwise.

Thank you Dave, you are the best.
Really awesome support for this component!

Just updated and everything seems to be working fine.
And now my Shock sensors shows the correct sensor type :partying_face:

We won’t hold that against you :rofl: :rofl: … I did exactly the same a few years ago.

Can you please set logging to debug for my Component only (not for everything) and restart HA. Upload your log file to pastebin and I’ll take a look through to see if I can spot anything.
Does it go to powerlink sometimes or never? I would need to see a log file for when it doesn’t achieve powerlink please.

This is something that I’ve considered in the past and it’s on my todo list. Maybe over the Christmas holidays I’ll have a go :slight_smile: It is not possible to start/stop the component itself but it maybe possible to remake the connection to the panel.

Thanks and welcome
D

It went to Standard Plus a couple of times and Powerlink once so far. Unfortunately on subsequent restarts of HA (for unrelated reasons) it then failed to get back to anything other than Standard.

One thing I’ve noticed that’s different to the Vera Plugin is that whenever I entered the installer menu and back out again, I’d always see the “Downloading…” message briefly on the display. But with this component I’ve not seen that at all, although it’s a bit difficult to judge following a restart of HA as I’m then away from the panel physically.

I’ve been running with debug for the last 24 hours or so since the last restart of HA. I also restarted the panel this morning (enter installer menu and back out), I’ve zipped that whole log and uploaded it to Dropbox - File Deleted - Simplify your life

I think that log should be enough, but I can do a fresh smaller log if you’d prefer, I’m just trying to get a bit of consistent uptime on HA at the moment so may leave that to the weekend.

@rodak Thanks a lot !
Also I have read somewhere that it is better to go with the Powermax instead of the Powermaster because the Powermaster only give sensor status update when it is armed ?
Is it true ?
Or can we always get the sensor status even when it is not armed ?

Thanks

Well, the wireless PIRs only send status when armed to preserve battery. But magnet/schock/smoke sensors always send status update when triggered.
So I can use my door/window sensors for automations but unfortunately not the motion detectors.
I don’t know about powermax so I’ll let somebody else comment on that.

That’s strange, the exact opposite is described here:

I have a PowerMax Pro and I get sensor triggers all the time, regardless of the panel being armed or not. I have a mix of PIRs, wireless magnetic sensors and a wired door magnetic sensor.

1 Like

I have the MC-302E PG2 with the “E” after 302 and this one reports all status changes, maybe those are different in some way?
Also I have some shock/magnet sensors: SD-304 PG2. Those report as well.
Here you can see both tripped recently and I was at home with the system unarmed.
Z01 is the MC-302E PG2 and Z05 is the SD-304 PG2.


It is unfortunately not that clear in other forums as well if the Powermaster PIR can bet set up to send the status in the disarmed state.
I haven’t found anybode reporting that it is working for the PIR.
I will perhaps then rather buy a Powermax instead of a Powermaster ?

Hi, thanks for the log file, I’m up to line 15000 looking through it and it’s providing me with information on how well standard mode operates so I’ve tweaked a few settings in the code :slight_smile:

I know that you’re interested in Powerlink mode so here’s a bit of an explanation of what’s happening. It doesn’t work fairly quickly so that’s useful:

Your Log file lines
16:The first thing I do it to Exit …
24: … and then Stop any previous operations including EEPROM downloads
26: Initialise the connection
28: Receive an acknowledge from your panel for my Stop command
29: Receive an acknowledge from your panel for my Init command
31: Wait 8 seconds to make sure that the panel is happy (and is not splurging data at me)
33: Send the “Download Command” to get the EEPROM.

So, normally after the download command is sent, the panel should reply with a “3C” message giving me the panel type and model information. Yours doesn’t, it just ignores my command, it doesn’t even respond with an acknowledge to say that it’s got it :frowning:

Over the past few weeks I’ve been working with someone who has an older Powermax panel and his panel responded correctly with the “3C” message like this below. So older and newer panels do it, yours doesn’t :frowning:

Without this 3C message I’m stuck for what to do next, especially when your panel doesn’t acknowledge my downalod command. The Visonic Programmer Software, the first thing it does is send a download command and gets the 3C back.

Are you able to run my python script from a Windows PC (or Apple Mac) command line? You would need to install Python3 on the PC, a few libraries and then use test.py (all of this is explained in more detail on my Github page). Comment out the component in your HA config though as you can’t have both connecting to the panel at the same time.

Hello,

According to powermax+ installer guide, there is a case that could lead panel to not respond to download command, Page 17:


4.5.27 Mast. DL Code (fig. 4.5, location 27)
Here you determine the master installer 4-digit password for downloading/uploading  
data into/from the PowerMax+ memory. (See note in fig. 4.5). 
Attention! If "0000" is used, it will not enable connection of the PowerMax+    
to the PC for upload/download purpose.

I know it would be strange if it was previously working under Vera… but just to be sure @martynwendon could you check that your DL code is not set to 0000 in INSTALLER MODE → 5. DEFINE COMM → 27: MAST. DL CODE ?

Ah yes, I had forgotton that the Powermax+ has a manually set download code.
The bad news is that:

  1. In the download command on line 33 of the log file, I can see that it is set to “5650” and not “0000”.
  2. If the panel doesn’l like the download code it should reject with an “08”, “Access Denied” message and it doesn’t. It’s possible that the Powermax+ doesn’t do this.

Having said all that, it would be good for you to manually set the code in the panel to “5650” to make sure and try it again. Would it be sections 4.5.27 and 4.5.28 that would need to be set? Section “4.5.31 Upload Option” is also an interesting setting although we’re uploading when it’s disarmed so it should be OK.
Edit: Probably not 4.5.28 as it’s for downloading only and we don’t do that, we only upload.