maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Nokia N900 (https://talk.maemo.org/forumdisplay.php?f=44)
-   -   fun and no fun with n900 mmc controller gpios (https://talk.maemo.org/showthread.php?t=95602)

pythoneye2 2015-06-07 01:09

fun and no fun with n900 mmc controller gpios
 
1 Attachment(s)
Hi im playing with the gpios of the micro mmc card port at the moment.

I can toogle most of them by now, but im limited to 3V at the moment
and my initialisation sequence is very hacky.

And maybe im doing bad things on my way to systestmode and
especially trying to set 1.8V(which sadly doesnt work at the moment).

My current init sequence is:
1. take off backcover
2. run my init code, systestinit, once (returns with a bus error)
3. run my init code again (without bus error)
4. put on backcover
5. take off backcover

now i have VCC High (3.2V [400mA not sure about this]) and my
init sets the left closest gpio pin to camera High too. :)

And i can finally toggle them via systestreg via mmchs_systest to my liking.

i guess 2 is a timming issue cause bus error occurs after power on.

My guess 4 and 5 are needed to let omap_hsmmc adjust powersettings for me.
(abusing the magnetic switch.)

systestoff doesnt work either and i have to reboot to leave systestmode and disable vcc.

The spruf98.pdf mentioned in https://wiki.maemo.org/N900_Hardware_Hacking
can be found at http://www-s.ti.com/sc/techlit/SPRUF98 was/is a great help
and contains nearly all strange words in this text and maybe even the answers to my questions:

Someone knows the right init sequence for 1.8V? 3V?
Has someone used the gpio for something different than to connect a micro sdcard microcontroller?
Someone did spi?

my c and hardware skills are very limited, anyway code is attached. Bugfixes welcome.

run at YOUR OWN RISK, i dont know what im doing! It shouldnt but it may damage your device and you!

nieldk 2015-06-07 05:39

Re: fun and no fun with n900 mmc controller gpios
 
awesome project.
thats the kind of hacking i like :)

pythoneye2 2015-06-23 21:41

Re: fun and no fun with n900 mmc controller gpios
 
I looked a bit more into it, how to control those pins.
The wiki mentioned an easy way to configure them as gpios.
I guess they are talking about switching the mode to 4 in the
Core Control Module Pad Configuration Register Fields.
But as far i read and see they are locked by firewall and set in the signed and encrypted(?) part of the x-loader:
"X-Loader: 1) Sets up the pin muxing." (see http://wiki.maemo.org/Firmware_hacking).
So maybe it is easy, but i cant see it yet..
systestmode seems to give you out pins only (havent looked in it more deeply yet)


All times are GMT. The time now is 21:46.

vBulletin® Version 3.8.8