• SEXPOTS timeout with onboard UART; works under strace, and with othe

    From Charles Blackburn@1:103/705 to Matthew Asham on Tue Oct 11 16:12:00 2022
    Re: SEXPOTS timeout with onboard UART; works under strace, and with othe
    By: Matthew Asham to Charles Blackburn on Mon Oct 10 2022 12:40:11

    it should give you a *nix login where you should be able to log into the box just like ssh etc.
    once mgetty is installed you can just use "mgetty -x7 <device line> -s 115200"
    eg mgetty -x7 ttyS0 -s 115200
    see what happens. be interesting... the -x7 is debug and that will appear in /var/log/mgetty/<logfile>

    I've tested this just now using mgetty and the modem initializes without incident and happily answers.

    yay, finally getting 5 minutes to sit down at the computer while in the hotel room.

    i'll answer your email in a few :D

    regards
    ---

    Charles Blackburn
    The F.B.O BBS 21:1/221 618:250/36
    bbs.thefbo.us IPV4/V6
    DOVE-Net FSX-Net MicroNET USENET




    ... Under capitalism man exploits man; under socialism the reverse is true.
    ---
    þ Synchronet þ The FBO BBS - bbs.thefbo.us - A place for aviation fun....
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Charles Blackburn@1:103/705 to Matthew Asham on Tue Oct 11 16:15:30 2022
    Re: SEXPOTS timeout with onboard UART; works under strace, and with othe
    By: Matthew Asham to Matthew Asham on Mon Oct 10 2022 16:03:05

    Okay - I found something else.

    in modem_send() https://gitlab.synchro.net/main/sbbs/-/blob/master/src/sexpots/sexpots.c#L619, if I comment out the call to comPurgeInput(com_handle) - the modem initializes successfully
    and this is repeatable.
    This happens right after the modem command is sent but before reading. tcflush(handle, TCIFLUSH) purges the input buffer, but why would strace slow the process down (or maybe i/o in the
    kernel?) enough so that this purge wouldn't have an affect?

    it could actually be the other way around..... it inits the modem and flushes the input which in turn flushes away the result code so therefore sexpots doesnt see the "OK" (or ERROR)

    having strace in the way could slow it down just enough.

    i might take a look at sexpots when i get back, normally though you flush the buffers right before you send something out, at least that's what i used to do

    I also tried putting my modem into no echo mode (ATE0) - no affect when comPurgeInput was still present in code.
    not sure that would work if that's what SP is expecting

    I also saw the mgetty is doing an fcntl FD_NOFL - but adding the same call to sexpots made no difference.

    iirc NNO-FL is no flush so it doesnt flush the buffer right after a send. nut that's from memory

    regards
    ---

    Charles Blackburn
    The F.B.O BBS 21:1/221 618:250/36
    bbs.thefbo.us IPV4/V6
    DOVE-Net FSX-Net MicroNET USENET




    ... We have phasers; I vote we blast 'em!
    ---
    þ Synchronet þ The FBO BBS - bbs.thefbo.us - A place for aviation fun....
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Digital Man@1:103/705 to Matthew Asham on Thu Oct 13 14:07:50 2022
    Re: SEXPOTS timeout with onboard UART; works under strace, and with othe
    By: Matthew Asham to Digital Man on Mon Oct 10 2022 08:09 pm

    I hope I didn't miss anything else :)

    I didn't see any results from experiments with increasing the SLEEP() duration (e.g. to 500, 1000, etc.).
    --
    digital man (rob)

    This Is Spinal Tap quote #42:
    What day the Lord created Spinal Tap and couldn't he have rested on that day? Norco, CA WX: 76.0øF, 66.0% humidity, 2 mph SE wind, 0.00 inches rain/24hrs
    --- SBBSecho 3.15-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Matthew Asham@1:153/149 to Digital Man on Sun Oct 23 11:26:50 2022
    I didn't see any results from experiments with increasing the SLEEP() duration (e.g. to 500, 1000, etc.).

    This didn't really help the problem and I'll have to come back to this down the road. Side lined with other projects atm but will share further testing as I can.

    Cheers
    --- SBBSecho 3.15-Linux
    * Origin: Reverse Polarity ~ Vancouver, Canada (1:153/149)