Date:2009-08-21 11:00:33 (10 years 9 months ago)
Author:Wolfgang Spraul
Commit:40602c22354a988b7edc688e0672ab0ce479bf12
Message:added 0x for hex

Files: xbboot/host-app/host_main.c (2 diffs)
xbboot/scripts/boot-echo.sh (1 diff)

Change Details

xbboot/host-app/host_main.c
203203                fprintf(stderr, "Error - number of %s parameters %i\n", argv[1], argc);
204204                goto xout_xburst_interface;
205205            }
206            u32_param = strtoul(argv[2], 0 /* endptr */, 16 /* base */);
206            if (argv[2][0] == '0' && argv[2][1] == 'x')
207                u32_param = strtoul(&argv[2][2], 0 /* endptr */, 16 /* base */);
208            else
209                u32_param = strtoul(argv[2], 0 /* endptr */, 10 /* base */);
207210
208211            usb_status = usb_control_msg(xburst_h,
209212                /* requesttype */ USB_ENDPOINT_IN | USB_TYPE_VENDOR | USB_RECIP_DEVICE,
...... 
244247                fprintf(stderr, "Error - number of %s parameters %i\n", argv[1], argc);
245248                goto xout_xburst_interface;
246249            }
247            read_len = strtol(argv[2], 0 /* endptr */, 16 /* base */);
250            if (argv[2][0] == '0' && argv[2][1] == 'x')
251                read_len = strtol(&argv[2][2], 0 /* endptr */, 16 /* base */);
252            else
253                read_len = strtol(argv[2], 0 /* endptr */, 10 /* base */);
248254            read_buf = (char*) malloc(read_len);
249255            if (!read_buf) {
250256                fprintf(stderr, "Error - cannot allocate %i bytes read buffer.\n", read_len);
xbboot/scripts/boot-echo.sh
11#!/bin/bash
2../host-app/xbboot set_addr 80002000
2../host-app/xbboot set_addr 0x80002000
33../host-app/xbboot bulk_write ../target-stage1/stage1.bin
4../host-app/xbboot start1 80002000
5../host-app/xbboot set_addr 81c00000
4../host-app/xbboot start1 0x80002000
5../host-app/xbboot set_addr 0x81c00000
66../host-app/xbboot bulk_write ../target-echokernel/echo-kernel.bin
77../host-app/xbboot flush_cache
8../host-app/xbboot start2 81c00000
8../host-app/xbboot start2 0x81c00000

Archive Download the corresponding diff file



interactive