![]() |
Re: Announce: USB Mode (easy switch to USB host mode)
To establish usb host mode and correct speed detection is boost needed.
So host mode with charging first activate host mode with boost and then switch to charging mode. |
Re: Announce: USB Mode (easy switch to USB host mode)
1 Attachment(s)
Quote:
i have drawn a diagram of how i think it would be connected,but i haven't tried it yet as i'm not sure what will happen with the n900 port giving out 5V while it is connected at the same time to a power source. |
Re: Announce: USB Mode (easy switch to USB host mode)
...which means You just use USB Y-cable (google for it) :) It's possible to buy such thing, but I would recommend DIY it.
|
Re: Announce: USB Mode (easy switch to USB host mode)
Quote:
just as Pail said Quote:
anyway my concerns are with long term use, i don't think it would blow up the 2A fuse on the V+ of the n900 USB port, so have anyone tried it yet? i'd like to know who actually got or built a Y cable and is using this for a while with no issues. also what happens when the power lines while in boost mode get shorted, say a bad USB flash drive with a broken shorted out connector was connected to the device, what will happen? in a normal USB host like with a laptop if the USB power got shorted the USB controller cuts the power and in some computers the system will get a notification of the short |
Re: Announce: USB Mode (easy switch to USB host mode)
Nah, it is used with H-E-N for ages, exactly the same way, and work flawlessly. Never ever experienced any heat increase/problem when connecting 5V charger to Y-cable, where N900 already provides 5V. And my 5V PS isn't lab-accurate one, for sure :)
/Estel |
Re: Announce: USB Mode (easy switch to USB host mode)
Pali, every time I edit PatternBoost to my liking, upon next start of usbmode, it forces mceledpattern to comment *out* PatternBoost, and add it again, with default settings set by You. It's very irritating, had to delete whole led-editing part of code from usbmode.sh (and check for it, 2 lines later).
Also, there is already PatternVboost, doing same thing, introduced by H-E-N since improved booston script by joerg (=since last update in -devel). This one was needed to be introduced manually, but many hostmode users have it already. wouldn't it be good idea to check for PatternVboost (like now, script checks for PatternBoost), and if it is here, leave it alone and use - otherwise, adding PatternVboost, that will work with both USB Mode and H-E-N? Thanks a lot in any case, /Estel // Edit Pali, as for "pure" hostmode working, it's great - "automatically" enumerated my USB Hard-Drive on first try. although, when tracing dmesg output, at the same time when device is enumerated, I see "Forced hostmode error: High-speed device connected, but no high-speed mode selected". My HD works in both full-speed and high-speed mode (most pendrives too, I think). Of course, during hostmode start, it wasn't enumerated on low-speed, and got enumerated (+blinked) only on full-speed test. Then, hostmode immediately decided "job done", and haven't started enumeration again (no more blinks on HD). Have it changed to high-speed during-runtime, without another enumeration, or is it working in full-speed only? How can I check that, what should I search for in dmesg? How USB Mode handles devices that can work in *both* full-speed and high-speed (but, obviously, high-speed is preferable)? Sorry for long description, but I think it's necessary to properly understand why I'm asking, and what I'm asking about :) // edit 2 And another question - when it's already in hostmode and ke-recv mounted external USB disk, upon switching to peripheral, does umount automatically, or one should do it by hand, before activating periph. mode? If it doesn't (umount automatically), maybe it would be good idea? |
Re: Announce: USB Mode (easy switch to USB host mode)
Quote:
Quote:
Quote:
Quote:
Quote:
So I had idea to add umount button into file manager. But file manager is closed :-( Next I got idea for SD card: when kernel receive that gpio switch event it first sync & umount card and then it power down. But I do not have idea if we can call umount from kernel. And for usb disks in host mode maybe it will be really good to call umount. But problem can be how to determinate disks names (in /dev) which some from usb device (which will report lsusb)... |
Re: Announce: USB Mode (easy switch to USB host mode)
Quote:
|
Re: Announce: USB Mode (easy switch to USB host mode)
Thanks a lot for Your answers, Pali. I'll check if HD is properly enabled as high-speed, using sysfs entry You've mentioned.
As for bug with mce.ini edition, it's strange, as I can't reproduce it now. Before, every attempt resulted in mceledpattern commenting out pattern (with comment, before, containing date when it was commented out), and immediately adding new one. I tried to reproduce it now, to help with debugging, and I'm able to insert my own pattern, without triggering buggy behavior, or modifying usbmode.sh. WTF? Quote:
Look for something like: Code:
sda: sda1 Also, isn't there a way to track what ke-recv mounted at given event (immediately, after usbmode finish with establishing USB connection as hostmode), and then, just umount it? It require some smart scripting, as user may have few different USB devices connected (via HUB). It would be bad to umount all, forcibly, when one of them disconnects. ENORMOUS thanks for providing properly-integrated and automatic hostmode, after so many years! It's great, that such essential thing have active maintainer, now. /Estel // Edit Just small idea for future - despite automatic mode working reliably, it would be great to add some "advanced" button (or so), that would allow for choosing speed and moment of enabling boost manually. It would really make H-E-N obsolete, in favor of USB Mode (would also eliminate small glitch with duplicated PatternVBoost - USB Mode PatternBoost would become only one needed). Why it may be better? For example, with my USB keyboard, I've observed strange behavior. Sometimes - like 20% - despite enumerating well (and being actually detected by extkbd, it is "too slow" for USB Mode, and USB mode try another speed, unnecessary. So, I must wait for it to check that higher speed (full-speed), then until it go back again to low-speed, and hope, that this time keyboard will enumerate quickly enough. It's not a big deal, as it happens no more than during 1 out of 5 connecting attempt, but possibility of doing things manually would help, without need for keeping H-E-N as emergency solution. |
Re: Announce: USB Mode (easy switch to USB host mode)
Pali, I've checked sysfs entry, and HD is properly enumerated as high spped device :) Great job! I've also tested wireless mouse (which is full-speed one), and USB keyboard mentioned earlier (which is low-speed, but works in high-speed also), and for both of them, sysfs entry report low/full - I suspect, that it's OK, and it's exported for both low and full speed? BTW, of course, keyboard is properly used as low-speed (judging by moment, when it's enumerated), so no unnecessary power wastes here (via higher speed mode), and everything works like a charm.
I have, hoever, discovered a glitch. I have USB high-speed hub, that works perfectly with H-E-N and manual enumeration, but fails on USB Mode. Judging by diodes, it *is* properly enumerated, but, just like keyboard I've mentioned earlier, it's "too slow" for USB Mode, and the latter already start changing speed, ignoring that device got properly enumerated in last moment. But, unlike with keyboard, when it happened only during 20% of attempts, for HUB it fails 100% times. Could timeout *before changing speed* be extended, a little? /Estel |
All times are GMT. The time now is 16:44. |
vBulletin® Version 3.8.8