Contribute
Register

Yet Another NUC iMac G4

Status
Not open for further replies.
Joined
Nov 25, 2013
Messages
12
Mac
  1. 0
Classic Mac
  1. 0
Mobile Phone
  1. 0
Hello Everyone,

After a long long time following the mods here at tonymacx86, in december I had the chance to get an iMac G4 17” for a bargain price – about 30 USD. The seller said, that not so long ago it worked fine but they moved and it no longer boots. So bought as a “not working” machine. The cosmetic condition looked okay, with some mark of water damage (limescale?) at the bottom plate. Anyway I bought it… I can use parts of it later if the screen is not working... so here goes... Yet Another NUC iMac G4!

Most of this mod is in the “planning” stage, some parts I already have. Will take a few months I think :ugeek: I would like to thank everyone here at tonymacx86 with the great mods and ideas as it moved me to get an iMac, try to mod and share my part :clap:

The hardware side is a NUC 3217 mobo (first revision without the USB header but I will solder one following this guide: http://www.whitebream.nl/nuc_usb) with 8Gb RAM, SK Hynix 256Gb SSD, PicoPSU (wide input) to run everything else. On the power supply side I plan to use a Toshiba Toughbook PSU (16V 60W), we have these at work and they look a lot smaller than the original one. I would like to have a DVD-RW and I also liked the idea of picaxe to control various things so:

  • WTV020-SD “mp3” player for start-up chime with the original internal speaker
  • DS18B20 temperature sensor + pwm fan control
  • Sleep led
  • Touch controlled brightness setting of screen
All this with a single picaxe 14M2. This sounds bold – but with some compromise here and there it may be possible. I already have everything assembled on a breadboard on my desk. The bottleneck is the temperature sensor (takes 0.75 sec for the picaxe to decode) so the fan is only updated every 10 seconds when not sleeping, and set off after 30 secs at sleep. Here’s my current pinout:

pinout.png

For the WTV020-SD I already converted an mp3 to ad4. See attachment…
The software is not final – not even close – but as soon as I have something worth checking I’ll post it. I'm pretty bad with electronics so...

About the iMac:
As I mentioned earlier it got wet and for a long time. Probably it stood in water for days or weeks. There are marks of limescale everywhere below the DVD. Also some rusting started at the bottom edge of the DVD drive. The fan and HDD looks fine though. Gave some quiet humming noise when turned on.

So I scrapped the internals except the DVD frame, put a Samsung SH-224 DVD drive into it in hope I can run it from USB – which I cannot confirm for now as still waiting for the USB-SATA adapter (sold as OSX compatible). This DVD drive’s front is replaceable/removable. Drilled 4 holes on the top side of the frame (95x90mm) and put the NUC on top of it with 4x 15mm M3 standoffs. I had to cut some part of the frame out to be able to access the HDMI ports.

100_2886.JPG100_2887.JPG

Waiting for internals, but holes drilled for touch sensors:
100_2890.jpg100_2894.JPG

At the same time I started to sketch a new PCB. I do not want to re-use the original motherboard parts but design my own. A friend of mine can make PCBs with laser etching. Already ordered the sockets, will de-solder the 6-pin special audio connector and re-use on my PCB.

100_2880ix.jpg

There are some items I'm still undecided: on one side of the PCB there is a miniVGA, 3x USB, 2x firewire and 1x RJ11 connector. I will use the 3x USB but the others I have no idea how to use. The oder side is clean and easy: 1x RJ45, 3x audio jack and a power button. How could i use those sockets? :think:

So I'm about here with the iMac since mid december.
Sorry about the picture quality but I’m very bad with cameras… and electronics... :rolleyes:
And also sorry about jumping around with topics but soooo much happened since I bought the iMac.

feczo

View attachment chime.zip
 
Hi feczo

Welcome to the community and good luck with this project.

All this with a single picaxe 14M2

I'm afraid, that this will not work. Why? The picaxe is a very slow microcontroller, which will not be able to process all the required tasks in parallel. Its Basic programming language is another limiting factor. I've used multiple Picaxe 08M2 in my HemiMac project, but would recommend to use an Arduino Pro Micro, like Kiwi and I did in our iMac G5 projects.
See here: http://www.tonymacx86.com/imac-mods/130197-mactester57s-imac-g5-17-a1058-model-6.html#post967135
and here: http://www.tonymacx86.com/imac-mods/107859-kiwis-next-project-imac-g5.html

MacTester
 
Well... by now I know how far a picaxe can get... :cool:
I love it coz it's small and simple to use.

My first thought was to do everything in parallel but that did not work at all. The temp reading takes extremely long and hangs every other stuff for that time. Then I started to think about what items I need to do and when. Then I turned out no parallel running is necessary. Here's my "solution":

if start-up condition:
- initialise everything
- chime
- load inverter settings from eeprom

if normal operation:
- every 10 sec check the temp and set the fan pwn according to that (takes the longest: 0.75 sec freeze for the system)
- check touch buttons and set the inververter (save changes to eeprom, calibrate as original)

if sleep state:
- pulsate the led
- if time>30 stop the fan

All these conditions are checked over and over again. So far it runs fast and smooth.
I had to tweak the pulsate routine the most, because the one I found here on the forum used for/next. That needs a complete cycle to terminate. But I come up with the following code:

Code:
' sleep led pulsate
if led_brightness <= 20 then
    led_pulsedir = 1
    pause 1000
end if
if led_brightness > 20 and led_brightness <= 40 then
    led_pulse = 1
    pause 25
end if
if led_brightness > 40 and led_brightness <= 60 then
    led_pulse = 2
    pause 6
end if
if led_brightness > 60 and led_brightness <= 80 then
    led_pulse = 2
end if
if led_brightness > 80 and led_brightness <= 400 then
    led_pulse = 8
end if
if led_brightness > 400 then
    led_pulsedir = 0
end if
if led_pulsedir = 0 then
    led_brightness = led_brightness - led_pulse
else
    led_brightness = led_brightness + led_pulse
end if
pwmduty led_sleep, led_brightness

Roughly does the same as original, but can terminate at any moment (the longest pause is at the dark state for half sec - as I run at 8MHz)

I also fear that arduino may be way too difficult for me to handle :oops:
 
I also fear that arduino may be way too difficult for me to handle :oops:
Hi There

I would think they are similar in complexity. A couple of differences.

  • I think the community around the Ardunino is stonger, so from a support perspective you are better positioned on Arduino.
  • The C/C++ may seem more overwhelming compared to BASIC, but part of the design principle of Arduino, is to try and hide the nasty bits away e.g. Pointers, so when you look at the code it is very similar.
  • With C/C++ you can moduler-ise your code, in BASIC every thing is very much global scope, so easier to structure, and less bugs overall. When you get into controlling multiple different functions BASIC can become harder to manage.
One last thing is you may find it difficult to control brightness from the Menu application, unless you can connect a USB/Serial adapter to a Picaxe, not sure if this is possible.

Kiwi

PS I saw your other post (about common solution), just very busy on my own project at this time.
 
Hi feczo,

glad to see a new iMac saved from the trash !!! Good luck and enjoy yourself well in your mods. like you I almost make my own circuit for rear panel output (the original motherboard creating too many unintended contact) but I want to re-use the mini VGA Output...


Hi There

One last thing is you may find it difficult to control brightness from the Menu application, unless you can connect a USB/Serial adapter to a Picaxe, not sure if this is possible.

Kiwi



I thought currently in a way like this to be able to control the brightness directly from the keyboard like the original iMac (and at the same time generated the nessessaire signal LED Eve). I thought using a PWM signal générérator USB module as the arduino but I do not know if interraction is possible directly from Mac OS X.

http://www.yoctopuce.com/FR/products/modules-de-commande-usb/yocto-pwm-tx
this type of module appears to be directly accessible via virtual hub but the investment is a little big, not knowing if it will work really .... so I wil make first the sound and video party .... there are many of work !!! :lol:
 
I spent the last few days to make the circuit for the picaxe 14m2. I hope I made no major mistakes, but I can only make the trial run on the next weekend. By that time I'll get the PCB and will solder the parts.
contcircuit.png
The PCB will be one sided and rather small: 2"x1.5" (5cm x 3.8cm)
There are SMD parts but my friend said it's no problem to solder and makes the size smaller.
contpcb.png
 
Last edited:
And to have some additional progress, today two things arrived to my mailbox:

- The smaller power supply. While a Delta ADP-65J is small (108x45x30mm), this one is even smaller (88x40x28mm) and fits nicely above the DVD door shield. Rated for 60W, made by Panasonic (I remembered Toshiba somehow). It's model no. is CF-AA6372A.
100_2896.JPG
- And the USB-SATA converter, which is advertised as driverless for OSX, and well... it works oob...
100_2897.JPG
 
I spent the last few days to make the circuit for the picaxe 14m2. I hope I made no major mistakes, but I can only make the trial run on the next weekend. By that time I'll get the PCB and will solder the parts.
This looks really great, look forward to see how it goes for you. Soldering SMD components doesn't sound like fun but yes, I am sure it will make the board allow smaller.

I know you are designing for a different purpose, but one thing to ensure a failsafe design, so that if the software fails then it doesn't leave the machine inoperable. Specifically on the ATX power control, and inverter output. I don't your ATX crucial but if the inverter turns off, this is not good.

See this post for complete circuit (look at the top left)
http://www.tonymacx86.com/imac-mods/107859-kiwis-next-project-imac-g5-26.html#post974424

And this for a bit more on ATX control.
http://www.tonymacx86.com/imac-mods/107859-kiwis-next-project-imac-g5-26.html#post973986

Cant wait too see how it goes.

Kiwi
 
Kiwi, you are right. Thanks for pointing that out.
I also realized some mistakes. I connected the picaxe and the WTV020-SD module to 3.3V, but that source is not always on. Goes down whenever the pico is off (e.g. sleep). So must change to 5Vsb.
 
Okay, looks alike I have a dead LCD. If it wasn't initially dead, I killed it in the process... :rolleyes:
And that's because the neck cable pinout is different from the guides I found via google :oops: or both of us - me and my girlfriend - are colorblind... :lol:

Here's my neck cable pinout:

Black cable
Pink sleeve is RX2
Blue sleeve is RX1
Green sleeve is RX0
Red sleeve is RXC

Grey cable
White is clock EDID
Black is data EDID
Pink is VEDID
Orange, purple and yellow is Vcc
Green, blue and grey is GND

Disassembled both sides of the cable to check the pinout.
Backlight comes on, but no picture. Any ideas to try? :think:
 
Status
Not open for further replies.
Back
Top