From a working system, you can also learn more about the functioning of ed, by reading the documentation
In /usr/share/doc/usd are files from the UNIX User's Supplementary Documentation (USD), including entries for ed, ex, vi, sed, and awk (sadly the usd for troff and macro packages are not installed, but you can get them online). Makefiles are present for building them in postscript / text format, most can also be manually processed with nroff and fed into ed or a pager.
take a look at 09.edtut, and 10.edadv after that, you should be able to use ed effectively -- it is actually a very good tool, especially if a network connection is light, and a more modern line editor is not available. (e.g. vim followed by gQ command, or sam).