Pynacl crypto_core_hsalsa20

Hey there,
I need the crypto_core_hsalsa20 function to greate an secret key for my NUKI Smartlock 2.0

Both sides calculate DH Key k using function dh1
a. Key
8. Both sides derive a long term shared secret key s from k using function kdf1
a. Shared key

4.2 The key derivation function kdf1
static const unsigned char _0[16];
static const unsigned char sigma[16] = “expand 32-byte k”;
Used to derive a long term secret key out of the shared key calculated by dh1

I alredy calculated the DH Key k with the nacl.publik.Box (=dh1) function.

Can someone tell me how to use the kdf1 function with pynacl?

I have the same question about Swift.

Can you please post your code for calculating DH1 as per example from spec? I cannot achieve same bytes. My working code for KDF in java using library: com.neilalexander.jnacl

        byte[] outv = new byte[32];
        byte[] inv =  new byte[32];
        byte[] k =    NaCl.getBinary("0DE40B998E0E330376F2D2FC4892A6931E25055FD09F054F99E93FECD9BA611E");
        byte[] c =    "expand 32-byte k".getBytes();
        hsalsa20.crypto_core(outv, inv, k, c);
        System.out.println("--------" );
        System.out.println(NaCl.asHex(outv).toUpperCase() );