Rockbox Development > Starting Development and Compiling
Run Rockbox stub to debug original firmware
(1/1)
taksato:
Hi!
I recently got the im413 dock plus remote for Sansa. I quite like the concept, so I bought two. I would have access to labs at work for scope analysis. However, I am no longer an engineer and would need to make a special badge access request to do that.
Instead, I would like to try to get the dock working by more difficult analysis methods. To that end, I wish to run a stub of code while the original sansa FW is running. My stub of code would be analyzing the GPIO and such while throttling the info to disk. While the stub is doing that in the background, I would be messing around with the remote with the sansa in original FW sitting in the dock.
I tried pulling up the debug screen with the Sansa seated in the dock with rockbox running and messing with the remote. I did not notice a consistent effect when mashing the buttons on the remote.
Then I would post analyze the dumped log file to see where things lead. Short question is: Has anyone run stubbed code for emitting logging while original sansa FW is running?
Thanks!
Keywords to help other searchers get matches: original FW, RB stub, dump GPIO
saratoga:
--- Quote from: taksato on January 25, 2010, 09:13:48 PM ---I tried pulling up the debug screen with the Sansa seated in the dock with rockbox running and messing with the remote. I did not notice a consistent effect when mashing the buttons on the remote.
--- End quote ---
Its probably done over the RS232 port on the Sansas, and AFAIK that is only enabled on the ipods (for ipod accessories).
--- Quote from: taksato on January 25, 2010, 09:13:48 PM ---Then I would post analyze the dumped log file to see where things lead. Short question is: Has anyone run stubbed code for emitting logging while original sansa FW is running?
--- End quote ---
We've done some JTAG stuff on the AMS sansas, and for the PP ones Sandisk gave us a JTAGed dev device, but we never did much with it. Which Sansa are you talking about?
taksato:
Thanks for the further info! I am talking about Sansa c200 or e200 v1. Would be extremely lovely to use with remote on the im413. Serial is also my hunch after reading some other threads on the dock or docking stations in these forums.
saratoga:
First I would try enabling the serial port driver for the Ipods (which use the same chip) and seeing if you can talk to the remote using it.
taksato:
Thanks for the idea. Now working on it.
I did
#define IPOD_ACCESSORY_PROTOCOL
#define HAVE_SERIAL
in sansae200.h
Got rid of some ipod remote specific stuff with some #define flag guards.
Put Debug screen into two lines due to small screen.
Tried both of these:
outl(0x70000018, inl(0x70000018) & ~0xc00);
and
(*(volatile unsigned long *)(0x7000008C)) &= ~0x0C;
GPO32_ENABLE &= ~0x0C;
First one is always eight zeros. Second is always an 0xFF and then seven zeros.
Not sure what I will try next, but maybe I have to do some sequential reading in the procedures to see if there are any other areas where they have ipod version specific stuff in #if blocks that needs to be executed.
Navigation
[0] Message Index
Go to full version