RH Mk2. Finished, video and some more pics added

Want to show off your own project? Want to keep a build log of it? Post it here!
The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

RH Mk2. Finished, video and some more pics added

Post by The F00 » Tue Jan 22, 2019 4:11 pm

I am at the planning stage of thisone and taking my time to breadboard it all out and 3d model as mush as posible.
Design goals are:

Main:
Battery monitoring
auto shutdown on low battery
LED battery indicator
Stereo sound
Tactile switch shutdown
Slim width
Programing/debug socket for the micro-controller
Custom main board PCB (home etched)

Secondary:
Headphone socket
Software based volume buttons
Sholder buttons
Backlight control


I am going to be using a m08 picaxe micro-controller to handle all the power monitoring and shutdown commands. My main reasons for using it are that its available in smt, need almost no additional components to run and I is programmable in BASIC, that I am slightly familiar with. It also has an ultra low power "hibernation" function shouldn't kill the lipo when not in use. I may add a batter disconnect switch to be safe.

I am planning that the picaxe will be providing the pi its 5v power supply. I am yet to test this so unsure if that's going to work.

So far I've done some modeling of the parts in fusion 360 and its looking to be nice and slim. Possible a little top heave but I am not keen on having the pi behind the lcd due to the heat. Speakers might be better off under the screen but I'd have too run the buttons lower which could be uncomfortable.

ImageImage

Parts so far

Gearbest screen (chosen for speed rather than quality)
Cheapo lipo charger with 5v output
pi zero 1.3 (to keep cost down and maybe power consumption?)
some nice tactile switches
2000mah lipo
Stereo amp (considering building my own on board)

Interested to see what you guys think so far. Nit sure if the picaxe is old hat these days and hasnt been used on one of these projects before. Seems like it should fit the bill but would like to know if you guys have a better option?
Image

Heres a quick image of the final thing. I'll update with a proper detailed post when I have time

Image

Image

Image

Last edited by The F00 on Sun Mar 03, 2019 4:10 pm, edited 10 times in total.

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. My third scratchbuild this month!

Post by The F00 » Thu Jan 24, 2019 3:18 pm

Having very mixed results with the toner transfer method of PCB etching so I've acquired a laser cutter :-)

This will be great for doing acrylic screen coverings and some nice wooden framing for the screen area instead of using the stick on plastic stuff on my last one

Image

So proud

Also got all of the parts needed for this project, plus a bench power supply for calibrating the auto shutdown and battery monitoring

User avatar
Helder
Trailblazer
Trailblazer
Posts: 2985
Joined: Thu May 05, 2016 8:33 am
Location: Rogers, AR
Has thanked: 1459 times
Been thanked: 3114 times

Re: RH Mk2. Laser cutter acquired!

Post by Helder » Thu Jan 24, 2019 4:28 pm

Awesome! I just ordered a Fiber Laser and should be having it arrive Monday. Plenty of cool things you can with the lasers for the projects here even offer acrylic cutouts that people need for the GameBoy Null by Ampersand here on the forums. Good luck on the project.
Chat with me and other members On Discord

Don't contact me about obtaining my board files (as you will not get them). If my Boards or PCB Kits are sold out, they will be restocked as soon as I can get them and there is demand for them. You can join the mailing list on my Website to be notified when they are available.


Helder's Game Tech Website

We will not support any cloned work so don't come to us with technical issues to resolve, go talk to the cloner for help.

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. Laser cutter acquired!

Post by The F00 » Thu Jan 24, 2019 4:46 pm

Cheers man. I must admit that case design was one of the things that pushed me over the edge on getting the laser. It's so nice.
Looking forward to firing it up over the weekend.

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. Laser cutter acquired!

Post by The F00 » Sat Jan 26, 2019 4:17 pm

Todays progress.

This set up is my poc for the picaxe to act as a lipo monitor. Its outputting the raw number to a debug window on my table at the moment. I've taken some notes using a bench power supply and can read the voltage fairly accurately.

Left to do with the this part is. Have the picaxe use the values to give basic feedback. I am planing to use a dual colour led for the battery indicator so I'll breadboard that. After that I need to try to see if I can get the picaxe to use the gpio shutdown function. Seems like it should work. Not sure yet how much power will be drawn once the pie is shutdown. I check the screen and it drops to 0.0033 amps when no input signal is detected. Not done the maths yet but that seems safe(ish). I am hoping to go without a physical power-switch but I am not sure how realistic that is yet.

Image

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. Shutdown and battery monitor code working

Post by The F00 » Sun Jan 27, 2019 10:30 am

I've now got the picaxe code roughly written.
So far it will indicate a low battery by lighting an led, flash at critical battery and shut down the pi after that.
There will still be some amp draw when the pi is powered down, but hopefully not enough to damage the battery. I've written the code so that ther led will flash after the shutdown to alleart that the power switch need to be turned off or it needs charging.

Code still need top be tidied up and the shutdown state need some power reduction added to it (I think there's hibernate or something like that).

One bug that need resolving is that currently if the pi was shutdown and not switched off via the power switch, when the battery reaches critical it will power on! I think this can be fix in the gpio set up. Its on my to-do list.

Any help on my code would be greatly appreciated. I am a total novice and basically learned this over the weekend.

Code: Select all

main:	readadc 2,b1		; read value into b1
	high B.4
	low B.1
	if b1 < 105 then Shutdown
	if b1 < 111 then Critical	; jump to flsh if b1 less than 111>
	if b1 < 119 then LowBat
	goto main		; else loop back to start

Critical:	high B.1		; switch on output B.1
	pause 1000		; wait 1 second
	low B.1			; switch off output B.1
	pause 1000		; wait 1 second
	goto main
LowBat:
	high B.1
	goto main
Shutdown:
	low B.4
	pause 1000
	high B.4
	goto Sleeptime
Sleeptime:
	high B.1
	Pause 300
	low B.1
	pause 300
	high B.4
	readadc 2,b1
	if b1 > 119 then main
	goto Sleeptime
This will need calibrating once its soldered to the board. But the picaxe is easy to write too via a serial link. I might add a debug socket to my pcb as it can use a 3.5mm audio jack. Not sure if that could be shared with headphones. Also could be programed directly though the pi, but that feels like it'll be a hassle to set up.

To get the gpio shutdown to work I've had to give the pin a touch over 4v. Not ideal but I've read that this can work fine and I've not had any issues so far. Reason for this is when I used got the voltage of the picaxe pin down to 3.3 setting it low would only pull the pin down to around 1.2v. Not enough to trigger the shutdown. Around 4.1 seemed to be as low as i could get it

I'll updae with a circuit diagram at some point.

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. Shutdown and battery monitor code working

Post by The F00 » Wed Jan 30, 2019 1:37 pm

Thanks to tinkerboy I have added screen dimming to this today. I was hoping to run it from the picaxe so I could have auto dimming when the battery is low but I am out of pins at the point. Next time I'll go for one of the lager pic's.

Still havent sort the issue of auto booting at low battery. The dtoverlay_poweroff command should do it but it ends in a Kernel panic. Not found a fix. Another option would be to termanate the program after the shutdown comand, but that would require cycling the power to get it to start back up. Possibly not a bad option. Better than killing the lipo

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. Shutdown and battery monitor code working

Post by The F00 » Sun Feb 03, 2019 9:40 am

This weekend I've been mostly learning Eagle cad. Definitely a steep learning curve. So far I have all the control buttons on there, the battery monitor, shutdown and the two colour monitor led. I think I am just going to add a shutdown button then put the rest on a smaller pcb on the rear of the console. That'll have screen brightness and the audio filter on it. Then that should be all the internals done. Then on to the fun part of designing the case :-)

Image

Image

Also, fixed all the bugs with the microcontroller code, so it now works correctly with no random boots.

The F00
Posts: 27
Joined: Sat Dec 22, 2018 1:13 pm
Has thanked: 6 times
Been thanked: 11 times

Re: RH Mk2. PCB laser etching in progress

Post by The F00 » Sun Feb 17, 2019 3:12 pm

Been working on etching the two PCB's for this project.

So far I'm happy with the progress.

Image

This is the board for the rear. It has the pwm audio filter, brightness controls and the lipo disconnect switch.

Image

This is the main board. This one has two bad traces. It's been a steep learning curve but I think I've cracked it now. Will have to wait till next weekend to try another.

Image

Orochi Kusanagi
Posts: 15
Joined: Tue Aug 29, 2017 3:28 pm
Has thanked: 3 times
Been thanked: 9 times

Re: RH Mk2. PCB laser etching in progress

Post by Orochi Kusanagi » Sun Feb 17, 2019 3:31 pm

I can't wait to see the final build. Your first version was really neat!

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest