Of extension ports and kernel mods


sixtyfifthbit

Member
Joined
Aug 24, 2007
Messages
168
I'm at the point in my AtariSIO project where I need to have better access to the serial port, code-wise. Now, I understand that enabling/modifying access to the UART/GPIO pins involves modifying either or both U-Boot and the kernel. What all is involved with doing this? For good reason I'm very nervous about modifying U-Boot as screwing that up means I gotta drop to JTAG (if I'm lucky) and even compiling the kernel is tricky, much less modifying it. I'm hoping those familiar with the OpenPandora code (and those familiar with kernel hacking in general) can give me pointers on how best to proceed. Obviously, being able to compile the existing U-Boot and kernel code is the first thing I should verify. Can you point me to the right source files for the serial port? Can you outline any caveats to modifying and installing a custom U-Boot/kernel? And finally, anything that other people can use, I'd like to give to the community so others can further enjoy the Pandora. It would be my first time actively contributing to an open-source project. What's the protocol for that?
 
Last edited by a moderator:
I'm at the point in my AtariSIO project where I need to have better access to the serial port, code-wise.
So you decided to use UART2 or UART3? UART3 is already visible from Linux, so you don't need to modify kernel or u-boot to use that, just write a program that operates with /dev/ttyS0 (you'll need to remove kernel messages from it first, but that's easy). You could use UART3 for rx/tx and one of the GPIOs for control, but I don't know how you plan to synchronize all this.

For good reason I'm very nervous about modifying U-Boot as screwing that up means I gotta drop to JTAG (if I'm lucky)
Pandora has peripheral boot mode which is handled by ROM code, so it's more or less unbrickable, you'd just need specially partitioned SD card to recover.

Can you point me to the right source files for the serial port? Can you outline any caveats to modifying and installing a custom U-Boot/kernel? And finally, anything that other people can use, I'd like to give to the community so others can further enjoy the Pandora. It would be my first time actively contributing to an open-source project. What's the protocol for that?
There is some info on kernel compiling on the wiki, but maybe you can avoid it? You can control UART2_* pins as GPIOs and UART3 as serial from a normal user program.


As for contributing, there is a wiki page here:


http://pandorawiki.org/Firmware_governance
 
Last edited by a moderator:
I'm at the point in my AtariSIO project where I need to have better access to the serial port, code-wise.
So you decided to use UART2 or UART3? UART3 is already visible from Linux, so you don't need to modify kernel or u-boot to use that, just write a program that operates with /dev/ttyS0 (you'll need to remove kernel messages from it first, but that's easy). You could use UART3 for rx/tx and one of the GPIOs for control, but I don't know how you plan to synchronize all this.

I think using the UART3/GPIO combo will end up being easier for this - and disabling kernel messages is outlined in the wiki, right?


Thanks for all your help.
 
Last edited by a moderator:
Back
Top