Adjust pin slot design on moving curves

Hello, I need help to model the flow wall desk by Robert van Embricqs. the desk has flush vertical slats that twist and unfold into a tabletop. Each of the slats has two joints. At the bottom where it connects to the top of the desk is a revolving joint. In the middle of each slat where it meets the rod is a pin slot. The motion of the desk slides on the rigid rod that runs through the slats.

I need help modelling the pin slot. I believe the pin slots form an arc facing up when the desk is closed, and it faces down when the desk is open.

I think I’m close to modelling this however, when the desk is open and the arc faces down, the base of the arc isn’t a straight line. I need help modelling the position of these pin slots, please.

I’m attaching my script below, to make it simpler I internalized some dimensions and geometries, but I kept all components relevant to what I’m trying to do.

If you can help me out, it would be much appreciated. Thank you!

help (69.3 KB)