This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x configuration information

Other Parts Discussed in Thread: AM3352

so i am a complete newbie with ARM. my background is in C6000 DSPs.

my company is attempting to try to switch to an ARM processor as a cost savings attempt.  i am being tasked with adjusting a project to work with the ARM processor. so i am not using an EVM board, i was told to jump straight to a custom board. we have not built the board yet so i have no hardware to play with

the processor picked is the AM3352

EDIT: we are planning to do this using the TI-RTOS, NOT LINUX or ANDROID

So my problem comes with understanding how to get started and where to find the information i need to start. i have looked over the datasheet, the technical reference manual, the SDK (to an extent) and wiki's and more. sorry if i sound bitter but it seems like i have been shot down at every attempt to understand how to start this project

here are the problems i have run into thus far:

i thought i would start with the GEL file and Clocking.  i picked the beagle bone black gel file as a start since they use the 3358 which is pretty close to the 3352. i find how to set the PLLs in the technical reference manual but there is no description on the procedure on how to properly set the gates. i have found the clock tree tool but man-o-man is that thing confusing.  in addition there is not a good way to extract the multitude (there are so many clock registers...) of register values out of it so i can set the clock gates properly, in addition i don't know if i am setting the register values in the right order. so i am feeling lost.  LATER when i find the SDK i find example projects where they set the various clocks to initialize the board but that is a code example and it doesn't explain the rules, the why's, and why nots.  i can follow the code but i won't fully understand why i am OR if i am doing it right for my specific board. i consider this to practically be a dead end even though i might get something working

so i moved on to the DDR3 setup. again, in the technical reference manual there is no explanation AT ALL (that i could find) about how to specifically set up the DDR3 interface.  i started using the beagle bone black gel file so i had hoped they had got it right but i also like to verify essential example code since so many gel files we have gotten from TI have been wrong in the past. i had thought i found it in a wiki when i went searching for the timing calculator spreadsheet but, alas, it said to follow the code in a particular SDK and it provided a link. when i clicked the link it was a dead link (404 error). when i went out to search for the specific item refernced in the link i get a bin file that i can not use on windows. so i guess i have to hope that the gel file got it right. another dead end

so next i figured i would see if i could get anything done with the pinmux.  most of the work has been done for me by our hardware guy so i just had to load his saved configuration file.  i see in the utility that there are 4 output files, including a c file and an h file. i think that's great they already provide you code to initialize your pinmux with. nope. the c file is a collection of array definitions. i wonder "what do i do with these files? i'll check the help" which leads me to a wiki for the utility. i think the wiki will explain everything. nope.  no mention of what these files are or how to use them. in addition the files don't provide any actual values you can put into specific registers so i am stuck doing this by hand anyway.

so i thought, at least i can make a project and start to piecemeal this thing together over time as i uncover data (that couldn't be better hidden if it was intentional). so i try to make a platform file. lo and behold the 3352 is not even an option in the processor drop down. luckily this question has already been answered in this forum which makes this my only non-dead-end (however without this question being asked here i would not have truly known what to do, i would have had to guess which not a great way to start engineering something).

so i need a major hand holding here or to be pointed in some direction where i can make my way through this.

so my questions end up being at the moment:

1) Where can i find the information that will explain how to properly set the clock gates/mux's?

2) How do i use the clock tree tool to find the right values for the registers that control the gates and mux's? i can look at the registers individually but there are A LOT of registers so is there some way that it gives you a list of registers that changed and what they need to be changed to?

3) How do i use the pinmux tool output to actually set my pinmux properly?

4) Where is the documentation for how to set up the DDR3 interface OR where is the code that provides the best example?

5) besides changing the config, timing1,2, and 3, and leveling values what else needs to be changed in the DDR3 init procedure?

thank you for any help you can give me.

  • Hi,

    The Linux SDK will detect the AM335x device and setup all necessary clocks automatically. You don't need to bother with clocks at this stage. Here is a wiki that summarizes board bringup steps: processors.wiki.ti.com/.../AM335x_board_bringup_tips This is the Pinmux tool wiki page: processors.wiki.ti.com/.../TI_PinMux_Tool Usage is described here: processors.wiki.ti.com/.../TI_PinMux_Tool_v4 Note that the generated files cannot be used directly, you will need to integrate the data yourself in the U-boot board file and kernel device tree. These are the DDR confuiguration guidelines: processors.wiki.ti.com/.../AM335x_EMIF_Configuration_tips
    processors.wiki.ti.com/.../AM335x_DDR_PHY_register_configuration_for_DDR3_using_Software_Leveling
    And this is a step-by-step tutorial based on Beaglebone Black: processors.wiki.ti.com/.../Sitara_Linux_Training:_Tuning_the_DDR3_Timings_on_BeagleBoneBlack
  • i seem to have left out a very important bit of information, my apologies:

    we are trying to do this with TI-RTOS, not linux

    i have seen all those links and they do not help much.  

  • Well, that makes a difference. I have notified the RTOS team. They will respond directly here.
  • cobsonchael,

    Having gone through this process myself few years back, I can understand what you are going through so let me try to help you to my best ability.

    All of the Sitara devices have traditionally support Linux SDK. The TI RTOS offering for AM335x  family of devices was limited to customers who required real time performance in industrial applications using a software package called IDK. But you are in luck since we have recently changed our approach to SDK and now offer TI RTOS and drivers for AM335x for all users through a package call Processor SDK RTOS which you can find here:

    This package comes with TI RTOS and all required dependencies and a set of peripheral drivers. It is meant to be used with the code composer studio environment. You can find the documentation for this software package here:

    This should be your starting point for development. The package contains a PDK component which short for platform development kit that provides register definitions, LLD drivers, examples and a board library. The board library includes most of the initialization functions Mux, DDR, clocking etc. You can use that as reference instead of using the clocking tool.

    In order to simplify Mux configurations, we provide a utility called pinmux tool that can easily be used to configure your device

    [ This is not as confusing as the clock tool :) ]

    To check how to set pinmux for your platform, I recommend you take a couple of resources:

    Section 9.5 of the training presentation here:

    For DDR configuration, we provide a DDR configuration spreadsheet

    I hope my responses provide you a starting point. Please feel free to revert back if you are still looking for specifics regarding my responses.

    Regards,

    Rahul

  • So here is the thing. i found the RTOS SDK and i have been looking over the examples. i found the pinmux tool and the DDR wikis for the part.

    the SDK has drivers which would likely work, but my boss does not like SDK drivers. they tend to use up too many extra cycles to do simple things because they are often written with multiple processors in mind. in addition we also like to verify that the function we are calling is behaving the right way so we like to interrogate the code. it's hard to interrogate the code when there is no documentation for how to actually perform the action. so while the SDK might be what i need to get this thing off the ground i WILL need the documentation and source code very soon. we found too many mistakes, too many memory leaks, too much code that does not apply to us when we looked over drivers for the 6748 DSP that we do not trust much that comes along with most SDKs.

    the pin mux tool is great for figuring out which pins can have what functions all at the same time, but there is nothing that i can find with it that actually gives register values so i can truly USE the information it is showing. i know the SDK has a file that shows how to turn on modules for the pinmux but there are instances where we don't want to turn on WHOLE modules, some of the pins are optional and we might not want all of them. i'm sure this has already been thought of but i cannot find any DOCUMENTATION in the code that explains how this works in the SDK. to be honest it seems like it would be just as much work to figure out the registers and hand program them than to figure out and use the SDK example of the pinmux, but this would be MUCH easier if the pinmux tool actually just gave straight REGISTER VALUES as one of it's output files instead of a bunch of symbolic/cryptic files that are either useless unless you use linux or take quite a bit of time to translate

    and, again, i found the wiki for the DDR stuff but, again, there is no documentation on how to actually set it up so i cannot verify that the GEL file which i have chosen as an example if even doing it right. i just have to hope that the writer of the GEL file got it right and i am sure that it must be but i will be very angry if i load a program and run it and it crashes at a random time because there is some app note hidden in some file about using the 3352 instead of the 3358 in the DDR configuration that i missed.


    so the vibe i am getting is that the only answer for this part is the SDK and examples and there is no documentation for what i am looking for. is that correct?