<div dir="ltr">
        
        


<p style="margin-bottom:0in;line-height:100%">Hello, everyone.
This is my first post to the list. 
</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">I’m a long time
swiss army knife of a software and hardware engineer who has started
to pick up Erlang, because I believe it and languages like it to be
the future of software development.</p>
<p style="margin-bottom:0in;line-height:100%">With that said, I am
working on a personal project of mine that I have wanted to complete,
a 21<sup>st</sup> century version of a BBS system, and I believe
Erlang and OTP are a good language and toolkit to write it in.</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">Code is being
dropped here: <a href="http://github.com/tschak909/nakbbs">http://github.com/tschak909/nakbbs</a></p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">I am experimenting
with both Ranch and just using gen_tcp with my own socket pools, but
I do have some design questions.</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">The telnet ports
need to present a definite series of states, broken up into seperate
pieces:</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">I have definite
common events that can be stretched across multiple use cases:</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">* Display</p>
<p style="margin-bottom:0in;line-height:100%">* Wait for line of
input</p>
<p style="margin-bottom:0in;line-height:100%">* Wait for character
input</p>
<p style="margin-bottom:0in;line-height:100%">* branch to another
menu</p>
<p style="margin-bottom:0in;line-height:100%">* hang up</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;border-top:none;border-bottom:1px solid rgb(0,0,0);border-left:none;border-right:none;padding:0in 0in 0.03in;line-height:100%">
But there will also be definite sections of the system, which could
be thought of as states:</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">* Authentication</p>
<p style="margin-bottom:0in;line-height:100%">* Message Browser</p>
<p style="margin-bottom:0in;line-height:100%">* Message Editor</p>
<p style="margin-bottom:0in;line-height:100%">* Various Games</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">etc.</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">and I’m trying to
think of an appropriate architectural pattern that will avoid me
basically having to cram every conceivable state as a sort of
hierarchy of tuples into a single gen_statem module. How can I
approach this in a nice abstract and extensible manner, that I could
for example push into a Behaviour and subsequently utilize for
different terminal types? It would be nice to split up the different
parts of the system into applications that would essentially be
called from well defined APIs…</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">I’m just trying to
figure this all out, and would love a semblence of direction so I can
do the proper research and deeply understand what I need to learn.</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p>
<p style="margin-bottom:0in;line-height:100%">-Thom</p>
<p style="margin-bottom:0in;line-height:100%"><br>

</p></div>