Microship Status – Issue 87
The month since our last update has been a frenzy of control system design, casting about for lab space, publishing projects, Web site refinement, ongoing nautical research, and even a tiny bit of play. I think we’ve visited the boat, sitting bored in a storage yard just off campus, about twice… but Tuesday morning is our long-awaited meeting with Gino Morrelli, whereupon we will begin a serious investigation into rigging issues. Since that is likely to spawn at least a Status Report worth of new information, I thought I’d better get the accumulated news out of my IN-basket and into yours!
by Steven K. Roberts
Nomadic Research Labs
June 3, 1995
The New Microship Hub
I’ve recently had the distinct pleasure of dragging myself away from the keyboard and doing some actual engineering work. For months, I’ve been agonizing over Hub packaging — trying to visualize interface and hackability requirements, available kluge space, I/O board complement, whether or not to integrate the Sexbar with it, and… most difficult of all… whether to take the tempting shortcut of stealing the Bicycle Control Processor substrate out of BEHEMOTH. It is, after all, exactly what I need, and it’s not doing much in the bike these days…
And so, late one night, a-quiver with excitement and a vague sense of betrayal, I delicately extracted the heart of BEHEMOTH — the precise snicking of severed wire ties and tinking of a 7/32 ball driver against 6061 recalling all-nighters of yesteryear, dreams of the Road swirling in my head. Now it’s the Water that fuels these passions, so I pushed past the emotions… filling the denuded, accusing space with the kluge board from the comm bay in the trailer.
Now on a roll, I mounted the New Micros Hub board on the bottom of the lower level and ran a 34-pin bus to 6 peripheral boards on the top (list shows board and base addresss):
- Real-time clock board (NMIS-9003) $C000
- ACIA 1-channel serial board (NMIS-5000) $C010
- 64-bit output board (NMIS-3004) $C020
- 64-bit input board (NMIS-3003) $C030
- 3-channel 16-bit counter board (NMIS-9002) $C040
- RS-232 to RS-422/485 converter $C050
The input and output boards each carry a pair of ribbon cables to the hinged Robinson-Nugent prototyping board (“nexus”) on the top level of the assembly, making I/O interfacing simple. I’m now making a list of all the contact blocks we need to order from Phoenix Contact, providing convenient headers for cabling of power control, sensor inputs, serial data (I’m moving the serial crossbar circuitry to the nexus board), and so on.
The major Hub packaging project, however, was the “Power Steering” board. Named for the two functions supported, this little card lives along the edge of the peripheral board area and carries a switching power supply for the entire Hub (Power Trends regulator) and the circuitry that allows re-routing of the console and network ports.
This involved a bit of trickery. At first glance, it would seem that we could meet all of our redirection needs with the Sexbar, but there’s an evil situation that could occur from bad initialization: locking the user out of the system. The solution involved a pair of way-cool miniature Aromat DPDT latching relays, with support logic that power-on-resets them to the default state, while providing three decodes of Port D bits to do any of the following:
- redirect the Hub console from the Mac to crossbar channel 0
- redirect the network from Hub’s ACIA to crossbar channel 30
- return both of the above to the normal state
Note that this does not explicitly provide a way for the Hub’s ACIA to be present on the crossbar (a critically important function) — the trick is to connect them in parallel and then redirect the network to eliminate a conflict before setting up the external comm event via Sexbar-29.
In other words, anything in and around the Hub can now talk to anything on or off the ship. One of the killer apps here is remote login via packet from a manpack (or telnet session, for that matter), with direct access to the Hub’s console or the network available after satisfying a user validation task. A pair of flip-flops tracks the relays and displays redirect events on the LED matrix.
The final Hub touches included a backup battery to keep RAM alive, power cabling, a utility power socket for the logic probe, relocated status LEDs, local and network RESET buttons, and the LED status matrix system originally built for BEHEMOTH by Dan Kottke. Everything came up with the requisite 2-3 nights of debugging, and the Hub is now alive and merrily multitasking away…
Hub/network Security Tasks
Since the Hub is the core of the Microship system, I decided it was time to get serious about applications beyond the familiar BSNET utility (which just renders the Hub transparent in order to allow easy Node development). There are now three tasks in addition to the FORTH interpreter running on the Hub:
- HEALTH, which blinks the green LED and allows quick visual confirmation of Hub function — this links to a watchdog circuit that will sound an alarm upon system crash.
- BUTTON, which is a trivial temporary test that echoes a pushbutton on the LED matrix panel to one of the LED’s in the matrix.
- CLOCK, which updates the time on the 2-line LCD every second, shows the currently addressed node as <A> or whatever, and performs a security scan.
The latter is the fun part — now that we have all this I/O, it’s possible to actually DO something with the system besides endlessly building tools. At the moment, an infrared security sensor is watching the space between two lab benches, and anyone breaking the beam causes a ===Security Alert=== message to appear on the LCD… as well as a 45 SET_ANGLE message to be transmitted over the network to the video turret node. It’s a bit uncanny… you walk to a spot in the lab and a camera swings around to gaze at you… then looks away again as soon as you leave. The video is routed to the Mac via the ComputerEyes/RT SCSI frame grabber, so a record of your visit can be saved as a PICT or recorded on the little Sony VCR. The ship security system will be a vastly expanded version of this, enough to intimidate any casual thief (I’m now interfacing a <<details deleted for publication>> that should stop anyone in their tracks!).
Ah, technology.
By the way, sending that command to the turret — and polling nodes for variables — is a critical function in the system, involving lots of string transmission and ring-buffer parsing. Clark Guest wrote a new defining word yesterday that greatly simplifies the handling of string literals:
: STRING" ( -- addr count )
Create 22 Word C@ 1+ Allot Does> Dup C@ Swap 1+ Swap ;
This allows a named string to be created simply:
String" Gaze 45 Set_angle "
Once this is compiled, executing GAZE in another definition yields the starting address and count of the string in the dictionary, making it easy to transmit it over the network with S-TYPE, display on the LCD with DSP-TYPE, or whatever. Coupled with a little parser we wrote for extracting data from the ring buffer, we now have all the tools we need to allow Hub security/watch tasks to chat with the nodes.
DAT Reverse Engineering
As I mentioned in the last report, I’ve packaged the Audio and Video crossbar systems (Auxbar and Vixbar) on a single panel, with some added kluge area for power control. We’re now building some more audio tools into this package.
The first is happening with the aid of a couple of this quarter’s ECE students — Oliver Ling and David Chin. We have reverse-engineered the remote controller for Sony’s lovely little D-7 DAT recorder, and now have FORTH code that allows us to invoke any function available on the machine by simulating the transmission of a SIRCS serial control string. It turns out that keeping the remote control’s PC board adds some useful feedback in the form of the drive lines to three LEDs (Play, Record, and Pause) — making it possible for our code to detect search mode, end of tape, etc. We’re now interfacing it with node <A>, which is also getting a MING sound-capture board at the same time.
The DAT interface was an entertaining problem — we watched the data on the oscilloscope and wrote down the bit patterns, observing a 7-bit command followed by a 6-bit unit address (always the same). Timing was fairly critical, so the guys spent quite a bit of time testing delay loops and writing the word that rotates a specified constant and squirts it out a port bit. We now need to go through a similar process on the GV-S50 8mm VCR, which uses a LANC protocol that we’re hoping is about the same.
The point of all this, of course, is that the DAT and VCR can be stashed in a sealed enclosure except during tape changes, allowing easy capture or playback of any audio or video material accessible via the crossbars. Whether it’s a security function that scans the boat with a sweeping IR camera or a quick sound capture of whales heard on the hydrophone channels, this should be an extremely useful and entertaining system.
Faun’s Wireless Webcam
I’m not the only one in the family who’s been hacking lately — Faun is diving ever-deeper into the wonderful world of hair-pulling caffeine-driven all-nighters marked by occasional whoops and much muttering. She completed the wireless video turret project, and has been able to move live audio (Maven), video (CU-SeeMe), still images (GIFs to Netscape), and turret control (CGI) between a pair of Macs connected via Digital Ocean Groupers (wireless AppleTalk). She used Netscape on the client Mac to present a compass rose…well heck, I’ll let her tell you…
Essentially, there is a hyperlink on one of the pages that runs a cgi script. Like all links, it’s referenced by a tag:
<a href=”http://home/cgi-bin/script_name.cgi”>button.GIF</a>
When the client clicks on the hyperlink, “button.GIF”, MacHTTPd calls the script_name.cgi. The script activates when the link is hit and tells PhotoCapture and clip2gif to do their thing. PhotoCapture is an application that takes images, from a frame-grabber or other VDIG, and saves them as a PICT.
Since HTTP standards don’t recognize the PICT format (or quite possibly, I haven’t figured out how) we have to do a GIF conversion. Clip2gif is the best application I’ve found that’s scriptable.
After the conversion is done, MacHTTPd is sent a string to return another page to the client. The new page displays the latest image of the lab. If the image is black, we’re either not here, or doing something that we don’t want you to see!
Moving the turret from Netscape
Again, there is a hyperlink calling an Apple Script. This time, there are eight different degrees to move the turret: 45, 90, 135, 180, etc… When the link is pushed, MacHTTPd activates the Apple Event. The AppleScript tells the application MicroScript to send serial data through the Microship HUB to the video turret. The turret moves to the specified angle, and the client is returned another URL. (Thanks to Roy Lovejoy of Adept Solutions for the custom app, MicroScript!)
Back to the learning curves! Now I’m learning about audio files…
I tellya, this sure isn’t the same Faun I met 10.5 months ago behind a desk at a nearby apartment complex…
Closing Notes
Finally, the quarter is nearing a close and change is in the air. We’re restless — all the more so with the recurring tease of two trimarans and two kayaks in our fleet as well as friends like Lonnie Gamble who actually get us out on the water now and then (most recently, to attend an evening Indigo Girls concert, anchored just offstage). I don’t know whether we’ll be staying in San Diego or moving on — the critical issue now is lab space that can accommodate the ship, hopefully in a stimulating community of nautical-, computer-, composite-, machining-, and everything-literate people. We’re investigating on many fronts, and will of course keep you posted.
In the meantime, Faun has completed the publication of NRL-404, the monograph focused on the whole Fulmar epoch. We now have four monographs in stock, of the 50 or so planned — the 400 series consists largely of these reports all edited together, augmented by other stories, and fleshed out with photos and drawings. We’re about to do a mass mailing to satisfy subscribers of the old Journal of High-tech Nomadness who haven’t seen an issue in over a year. Drop Faun a line if you want more info.
Also, there are probably some people on this mailing list who are not on the nomadness list — please let me know if you want to receive the more general, big-picture updates that are published every few months. #27 was posted a few days ago…
Cheers from the lab!
You must be logged in to post a comment.