]> git.draconx.ca Git - homepage.git/blob - content/weblog/ultra60-nvram.md
cdecl99-1.3 bash-5 hotfix
[homepage.git] / content / weblog / ultra60-nvram.md
1 ---
2 title: M48T59Y-70PC1 NVRAM Battery Replacement
3 copyright: 2022 Nick Bowler
4 license: cc-by-sa-4.0
5 published: 2022-07-09T12:12:21-0400
6 ---
7
8 *[NVRAM]: Non-Volatile Random Access Memory
9 *[SRAM]: Static Random-Access Memory
10 *[NOS]: New Old Stock
11 *[DIP]: Dual In-line Package
12 *[SOIC]: Small-Outline Integrated Circuit
13 *[MAC]: Media Access Control
14
15 Thanks to [Mark Henderson's Sun NVRAM FAQ][nvram-faq] for providing invaluable
16 insight regarding this repair.
17 {:article-info="article-info"}
18
19 [nvram-faq]: http://web.archive.org/web/20150919135835/http://www.squirrel.com/sun-nvram-hostid.faq.html
20
21 The Sun Ultra 60 workstation uses an ST M48T59Y-70PC1 battery-backed SRAM with
22 real-time clock.  When the embedded lithium primary cell inevitably dies, the
23 chip is essentially useless.  The most noticeable negative effect of a dead
24 chip is that the workstation always powers up in a default configuration with
25 diag-switch?  true, running several minutes of self tests every time, with
26 bogus MAC and host ID values.
27
28 <%= floating_img(@items["/images/m48t59y.jpg"], caption: <<EOF
29 You don't even know you are already dead.
30 EOF
31 ) %>
32
33 This device was branded obsolescent by the manufacturer in April of 2008 and
34 has presumably been out of production since around that time.  Similar chips
35 like the M48T58Y are still made but they are expensive (around $40) and slight
36 differences may result in compatibility problems.  It appears that NOS parts
37 can be found fairly cheap online but these must be almost 15 years old by now
38 and who knows what state the embedded batteries are in.  No thanks.
39
40 One option could be to find the SOIC version of the M48T59Y for which NOS also
41 seems to be available, although somewhat less readily than the DIP modules, and
42 then construct an adapter board to fit into the DIP socket on the motherboard.
43 The SOIC package does not include the battery and crystal; instead, it has
44 contacts on the top to attach a separate "SNAPHAT" package which are still
45 made.  This would be complicated and somewhat expensive.
46
47 Fortunately, a straightforward (if time-consuming) repair is possible.  This
48 is a literal hackjob: we can dig through the potting to expose the battery
49 terminals, disconnect the internal battery, and connect a normal battery clip.
50 This enables the use of readily-available CR2032 lithium primary cells that can
51 be replaced as needed, just like a normal PC.  Since we already have the chip
52 we need, it is not necessary to source any obscure or expensive components.
53
54 <%=
55 floating_img(@items["/images/m48t59y-terminals.jpg"], left: 1, caption: '')
56 %>
57
58 <%=
59 floating_img(@items["/images/m48t59y-solder.jpg"], left: 1, caption: '')
60 %>
61
62 The battery contacts are located on the end opposite pin 1, between pins
63 14 and 15.  Looking underneath the chip there is a small well at either end
64 filled with potting compound.  The battery connections are inside one of
65 these.  Using a knife, cut back the plastic outer shell on the battery side,
66 then begin scraping away potting compound until the terminals are exposed.
67 You can use a suitable DIP socket to help protect the pins from accidental
68 damage.
69
70 Once the terminals are exposed, the internal battery must be disconnected.
71 The thick protruding tabs near the bottom of the module are what we want
72 to solder to.  The vertical strips going up and into the module are the
73 internal battery terminals.  These can be desoldered from the tabs and
74 lifted out of the way, or simply cut off.
75
76 With the time-consuming parts completed it is a straightforward matter to
77 connect a normal battery clip to the exposed terminals.  As the Ultra 60 has
78 no clearance issues I simply glued it to the top of the chip.  Since this
79 would obscure the barcode sticker which is useful to restore the original MAC
80 address and host ID, I moved this sticker to the side of the chip.
81
82 Finally all that remains is to put everything back together and power up
83 the system.  The system will run the full self-diagnostic tests again and
84 if all goes well, the "NVRAM Battery Detect Test" should no longer display
85 any errors.  At the ok prompt, the memory can now be initialized.  Where
86 "AA BB CC" are the six hexadecimal digits from the orange barcode sticker:
87
88 <kbd class='ok'>set-defaults</kbd><br/>
89 <kbd class='ok'>setenv diag-switch? false</kbd><br/>
90 <kbd class='ok'>8 0 20 AA BB CC AABBCC mkpl<br/><em>&lt;Ctrl-D&gt;&lt;Ctrl-R&gt;</em></kbd><br/>
91 <kbd class='ok'>.idprom</kbd><br/>
92 <kbd class='ok'>reset</kbd>
93
94 <%= gallery_img(@items["/images/m48t59y-fixed.jpg"], caption: <<EOF
95 Just like a bought one!
96 EOF
97 ) %>
98 <%= gallery_img(@items["/images/m48t59y-installed.jpg"], caption: <<EOF
99 There's no place like home in the Ultra 60.
100 EOF
101 ) %>