- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have been considering using Redboot as my bootloader. But, our custom board has to download it's code over an LVDS link. How hard is it to add new comms options to Redboot? This is the only connection to the host so I have no option except the LVDS. I could try to make it look like a serial port without the handshaking, but I would really like to just create a new comms option. Thanks.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you want to run all the console I/O over this channel, then you will need to provide a comms driver.
The functions required by Redboot for a comms driver aren't particularly complicated. If you take a look at: altera_avalon_jtag_uart_diag.c that should serve as a reasonable example. These can (and should) be polled functions, i.e. you shouldn't be using interrupts to drive the device. Initialising the channel is achieved by calling the macros CYGACC_COMM_IF_WRITE_SET etc. as done for the JTAG UART.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you don't want to use this channel for console I/O, but just want to add an extra download command to redboot that you can add to the boot script, then you can do that using something like:
# include "redboot.h" RedBoot_cmd("lvds_load", "load over LVDS", "[-w <timeout>]", do_lvds_load ); void do_lvds_load(int argc, char *argv[]) { // load the code } This will cause the function do_lvds_load() to run whenever the command lvds_load is issued. If you look in packages\redboot\v2_0\src (in particular at main.c), you'll see examples of this.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, this is exactly what I'm looking for.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page