ZymKey not working on latest Buster (8Apr20)

I’ve just moved a ZymKey still in developer mode from one Pi to another (both running Buster). It did go into slow blinking mode on the old Pi about 6 weeks ago. The new Pi has the latest Buster fully updated, i2c enabled. On installing the software no errors are reported and it gets through to ‘Rebooting now…’.

This is on a Pi3B+ with official 5.1V 2.5A psu. Keyboard, mouse and hdmi monitor connected.

However the ZymKey remains in its rapidly blinking mode?

I’ve tried this on 3 fresh installs with the same result. Some info below - anything else that I can check?

date

Wed  8 Apr 15:21:49 BST 2020

sudo apt update

Hit:1 http://archive.raspberrypi.org/debian buster InRelease
Hit:2 http://raspbian.raspberrypi.org/raspbian buster InRelease                    
Hit:3 https://zk-sw-repo.s3.amazonaws.com/apt-repo-buster buster InRelease         
Reading package lists... Done
Building dependency tree       
Reading state information... Done
All packages are up to date.

sudo apt full-upgrade

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

lsb_release -a

No LSB modules are available.
Distributor ID:	Raspbian
Description:	Raspbian GNU/Linux 10 (buster)
Release:	10
Codename:	buster

uname -a

Linux raspberrypi 4.19.97-v7+ #1294 SMP Thu Jan 30 13:15:58 GMT 2020 armv7l GNU/Linux

cat /var/log/syslog | grep Booting Linux|zkifc|Zymkey

Apr  8 08:30:21 raspberrypi kernel: [    0.000000] Booting Linux on physical CPU 0x0
Apr  8 08:36:37 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr  8 08:36:37 raspberrypi systemd[1]: Started Zymkey Interface Connector.
Apr  8 08:36:37 raspberrypi zkifc[2641]: /usr/bin/zkifc: error while loading shared libraries: libzk.so: cannot open shared object file: No such file or directory
Apr  8 08:36:37 raspberrypi systemd[1]: zkifc.service: Main process exited, code=exited, status=127/n/a
Apr  8 08:36:37 raspberrypi systemd[1]: zkifc.service: Failed with result 'exit-code'.
Apr  8 08:36:47 raspberrypi systemd[1]: zkifc.service: Service RestartSec=10s expired, scheduling restart.
Apr  8 08:36:47 raspberrypi systemd[1]: zkifc.service: Scheduled restart job, restart counter is at 1.
Apr  8 08:36:47 raspberrypi systemd[1]: Stopped Zymkey Interface Connector.
Apr  8 08:36:47 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr  8 08:36:48 raspberrypi systemd[1]: Started Zymkey Interface Connector.
Apr  8 08:38:10 raspberrypi systemd[1]: Stopping Zymkey Interface Connector...
Apr  8 08:38:28 raspberrypi zkifc[2830]: Zymkey Interface Connector, version 00.08.01 Mar 31 2019 21:34:00
Apr  8 08:38:29 raspberrypi systemd[1]: zkifc.service: Succeeded.
Apr  8 08:38:29 raspberrypi systemd[1]: Stopped Zymkey Interface Connector.
Apr  8 08:38:29 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr  8 08:38:30 raspberrypi systemd[1]: Started Zymkey Interface Connector.
Apr  8 08:38:40 raspberrypi systemd[1]: Stopping Zymkey Interface Connector...
Apr  8 08:39:19 raspberrypi zkifc[2905]: Zymkey Interface Connector, version 00.08.01 Mar 31 2019 21:34:00
Apr  8 08:39:20 raspberrypi systemd[1]: zkifc.service: Succeeded.
Apr  8 08:39:20 raspberrypi systemd[1]: Stopped Zymkey Interface Connector.
Apr  8 08:39:25 raspberrypi kernel: [    0.000000] Booting Linux on physical CPU 0x0
Apr  8 08:39:32 raspberrypi systemd[1]: Starting Restore System Clock from Zymkey...
Apr  8 08:44:33 raspberrypi systemd[1]: Started Restore System Clock from Zymkey.
Apr  8 08:44:33 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr  8 08:44:33 raspberrypi systemd[1]: Started Zymkey Interface Connector.

pi@raspberrypi:~ $

It looks like maybe the sudo apt full-upgrade has somehow removed the critical component libzk.so. I’ll have to investigate further on our side.

In the meantime, try the following: sudo apt install --reinstall libzk

Ran your command, rebooted - no apparent change.

Re-installed software again - no apparent change.

Do I need to start from a fresh Buster again?

Apr  8 19:47:43 raspberrypi kernel: [    0.000000] Booting Linux on physical CPU 0x0
Apr  8 19:47:50 raspberrypi systemd[1]: Starting Restore System Clock from Zymkey...
Apr  8 19:52:50 raspberrypi systemd[1]: Started Restore System Clock from Zymkey.
Apr  8 19:52:50 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr  8 19:52:51 raspberrypi systemd[1]: Started Zymkey Interface Connector.
Apr  8 19:53:01 raspberrypi systemd[1]: Stopping Zymkey Interface Connector...
Apr  8 19:53:41 raspberrypi zkifc[1478]: Zymkey Interface Connector, version 00.08.01 Mar 31 2019 21:34:00
Apr  8 19:53:42 raspberrypi systemd[1]: zkifc.service: Succeeded.
Apr  8 19:53:42 raspberrypi systemd[1]: Stopped Zymkey Interface Connector.
Apr  8 19:53:47 raspberrypi kernel: [    0.000000] Booting Linux on physical CPU 0x0
Apr  8 19:53:54 raspberrypi systemd[1]: Starting Restore System Clock from Zymkey...

Actually, something does seem to have changed. The message

/usr/bin/zkifc: error while loading shared libraries: libzk.so: cannot open shared object file: No such file or directory

does not show up now.

Are there any differences between the pi that was working vs the pi that doesn’t in hardware or software?

Previous Pi was a Pi2B with a slightly earlier version of Buster.

Any update on this issue? Anything I can check? Have you got a ZymKey working on the very latest Buster?

It sounds like you have tried to migrate an existing SD card and Zymkey from an RPi 2 to an RPi 3B+. I’ve completed such a test and it worked with no problem.

Here’s the scenario I worked out:

  1. Configure an RPi 2 with a Zymkey.
  2. Install Buster desktop (Feb 13, 2020) on RPi 2 with a Zymkey. On first boot, this version of Buster upgrades itself to the latest version.
  3. Enable i2c with raspi-config.
  4. Install Zymbit software. System reboots itself.
  5. After reboot, check that Zymkey flashes once per 3 seconds.
  6. Migrate SD card and Zymkey from original RPi 2 to an RPi 3B+ and power on.
  7. After boot, Zymkey flashes once per 3 seconds.

Let me know if I got it wrong.

No, I didn’t migrate a card. It’s a fresh install on a new sd card in new Pi3B+.

The initial upgrade never works for me as the network time hasn’t synced yet so fails.

Once it’s started up I do.

sudo apt update
sudo apt full-upgrade

I’ve tried that use case over here as well. No problems found.

If I put the zymkey back on the original Pi2 with the original sd card, the zymkey goes into the correct slow blinking mode.

Is there some log to show that a zymkey has successfully keyed with a new Pi?

This sounds like your RPi 3B+ might have a problem with the i2c pins (pins 3 & 5) or GPIO4 (pin 7). Have you tried this on another RPi 3B+?

To answer your other question, if there is an error experienced at the Zymkey, it should flash an error code. This looks like the following sequence:

  1. Very fast blinking for about 1 second (around 8 - 10 flashes per second)
  2. No blinking for about 1 second
  3. Slow blinks (around 2 per second). The number of times this blinks represents the error code.

This sequence repeats 3 times and then should return to the “waiting for host connection” flashing pattern (about 4 times per second).

If all you see is the “waiting for host connection” flash pattern, there might be something wrong with the i2c pins. If you see an error code sequence of 8 flashes, there is probably something wrong with GPIO4.

I have tried the zymkey on 2 brand new Pi3B+. I only ever see fast blinking, no flashing error codes.

Is it significant that there is about 5 minus between ‘Starting Restore System Clock’ and ‘Started Restore System Clock’?

Apr 22 11:45:01 raspberrypi kernel: [    0.000000] Booting Linux on physical CPU 0x0
Apr 22 11:45:08 raspberrypi systemd[1]: Starting Restore System Clock from Zymkey...
Apr 22 11:50:08 raspberrypi systemd[1]: Started Restore System Clock from Zymkey.
Apr 22 11:50:08 raspberrypi systemd[1]: Starting Zymkey Interface Connector...
Apr 22 11:50:08 raspberrypi systemd[1]: Started Zymkey Interface Connector.

Any updates on this issue? It seems several people are having issues with latest Buster?

1 Like

My guess is that the Zymkey software cannot cover the new hardware rpi4 and Buster 10. Thanks for clarity on this point from the manufacturer. I would like to know if I have to use another product or if there is a solution for this in the near future. Thanks to the great developers. For me some functions are still missing in version 4…

  • Bigger Bat
  • optional 3v Pin out
  • LowVoltage Diag
  • Battery Replacement time for closing case
  • two led: power consumption, sys function
  • List item

@mara thanks for your feedback.

All of the functions you highlight are in our next release of product (Hardware and software). This is not public information at this time, but if you care to send us an email - support@zymbit.com, then perhaps we can open a private dialogue to discuss your needs.

Thanks

1 Like

Hi Mara,

We have tested the RPi4 with the latest Buster and it works. I sent this to you via email but I’ll repost the questions here so the rest of the community can see. Hopefully we can determine what’s different between the working and non-working configurations.

  • It is IMPORTANT you have a good power supply. The RPi4 requires at least 3 Amps, and with a HAT and video displays, even more power would be better. Can you confirm the output of your power supply?

  • Is this a new setup for you, or is it something that previously worked and stopped working after something changed? Do you just have one Zymkey and one RPi4, or do you have the ability to switch hardware to see if there may be some bad hardware?

  • Have the GPIO pins ever been used for anything else? In particular, the 1-Wire interface should be disabled. You can do that through raspi-config -> Interfacing Options -> 1-Wire -> Disable. If you aren’t sure, send me a copy of your /boot/config.txt and I can take a look.

  • I don’t think it should matter, but are you using Raspian Desktop, Raspian Lite, or Raspian Full? The image date we tested with is 2020-02-13, plus apt-get update, apt-get upgrade.

1 Like

Thanks it works with a clean image!
The PSU are more then 3A i know rpi4 needs ampere :slight_smile:

The RTC Clock not works. Status out:
Local time: Sat 2020-05-16 06:01:17 BST
Universal time: Sat 2020-05-16 05:01:17 UTC
RTC time: n/a
Time zone: Europe/London (BST, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no

The Time sync by reboot without nic runs. Date is correctly :smiley:

That is great news that it is working. It sounds like the RTC is setting your date correctly, which is also good news. The RTC won’t show up in the timedatectl display, or hwclock. Here’s a little background copied from another post:

Given that Raspbian and friends are a moving target, we elected to not develop any kernel modules for the RTC and, therefore, the stock Linux components (e.g. hwclock) won’t work with Zymkey’s RTC.

Instead, our approach was to keep everything in user space and in systemd. During boot, we currently have a systemd script that checks zymkey for a more recent time than the last one that RPi captured and stored on disk during the last proper shutdown.

This means that, if everything is properly configured and running, the system time (GMT) should be initially set to zymkey’s time before NTP has had a chance to run.

1 Like

Hi Bob,

thats run!

Good joooob! When lunched version 6?

Finally found the problem I was having - the 1-wire interface was enabled. Didn’t see this in your documentation.

If I move the ZymKey pin from GPIO4 to another pin, can I re-enable the 1-wire interface?

Is your ‘Troubleshooting FAQ’ supposed to be accessible?

I get ’ Access Denied while trying to load /t/id_for/trouble-shooting-zymkey-4i’