I was looking not so long time ago how to solve this problem:
I received a very nice solution from cegaton, but I am struggling to implement a script version of it. I would like vary angle of the two planes and bevel level.
I would really appreciate if you could help me with scripting of cegatons solution. Thanks.