Go to file
Kever Yang c49bf47e08 fix array boundry error
g++ -DHAVE_CONFIG_H -I. -I./cfg  -Wall -Werror -Wextra -Wreturn-type
-fno-strict-aliasing -D_FILE_OFFSET_BITS=64 -D_LARGE_FILE
-I/usr/include/libusb-1.0    -O2 -g -pipe -Wall -Werror=format-security
-Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions
-fstack-protector-strong -grecord-gcc-switches
-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
-specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
-fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -c
-o main.o main.cpp
main.cpp: In function 'bool unpackBoot(char*)':
main.cpp:1734:11: error: array subscript 20 is outside array bounds of
'char [20]' [-Werror=array-bounds]1734 |  str[len] = 0;|  ~~~~~~~~~^~~
main.cpp:1772:7: note: while referencing 'name'1772 |  char name[MAX_NAME_LEN];|       ^~~~
cc1plus: all warnings being treated as errors
make[1]: *** [Makefile:475: main.o] Error 1

Reported-by: Peter Robinson <pbrobinson@gmail.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
2019-06-28 12:51:18 +08:00
cfg update the build system to use autotools 2017-03-24 11:00:36 -04:00
.gitignore update the build system to use autotools 2017-03-24 11:00:36 -04:00
99-rk-rockusb.rules rk3128: add rk3128 support 2018-03-18 04:32:46 +08:00
boot_merger.h boot_merger: modify default config file for boot merger 2017-04-18 10:08:50 +08:00
CMakeLists.txt Adapt to CMake. 2018-04-30 22:37:31 +08:00
config.h.in Adapt to CMake. 2018-04-30 22:37:31 +08:00
config.ini main: fix print 'failed to stat config.ini'error 2017-04-25 09:20:40 +08:00
configure.ac Fix iconv detection for FreeBSD 2018-09-06 21:57:26 -07:00
crc.cpp main: update to version 1.2 2017-04-11 18:21:54 +08:00
DefineHeader.h 1.add "wlx" command support flash image by name 2017-08-07 14:39:06 +08:00
Endian.h rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
gpt.h main: update to version 1.2 2017-04-11 18:21:54 +08:00
license.txt rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
main.cpp fix array boundry error 2019-06-28 12:51:18 +08:00
Makefile.am use rm instead of $(RM) for clean targets 2017-10-10 17:05:15 +02:00
parameter_gpt.txt 1.correct grow partition size error 2017-08-04 16:34:22 +08:00
Property.hpp rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
Readme.txt Readme.txt: update the compile error help 2017-08-30 15:55:46 +08:00
RKBoot.cpp rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
RKBoot.h rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
RKComm.cpp rkdeveloptool: v1.3 2018-03-28 09:22:40 +08:00
RKComm.h rkdeveloptool: v1.3 2018-03-28 09:22:40 +08:00
RKDevice.cpp rkdeveloptool: v1.3 2018-03-28 09:22:40 +08:00
RKDevice.h rkdeveloptool: v1.3 2018-03-28 09:22:40 +08:00
RKImage.cpp rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
RKImage.h rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00
RKLog.cpp main: fix print 'failed to stat config.ini'error 2017-04-25 09:20:40 +08:00
RKLog.h RKLog: disable record log by default 2017-04-18 10:13:25 +08:00
RKScan.cpp rk3128: add rk3128 support 2018-03-18 04:32:46 +08:00
RKScan.h rkDevelopTool: initial commit 2017-03-07 16:12:52 +08:00

rkdeveloptool gives you a simple way to read/write rockusb device.let's start.

compile and install
1 install libusb and libudev
	sudo apt-get install libudev-dev libusb-1.0-0-dev dh-autoreconf
2 go into root of rkdeveloptool
3 autoreconf -i
4 ./configure
5 make

rkdeveloptool usage,input "rkdeveloptool -h" to see

example:
1.download kernel.img
sudo ./rkdeveloptool db RKXXLoader.bin    //download usbplug to device
sudo ./rkdeveloptool wl 0x8000 kernel.img //0x8000 is base of kernel partition,unit is sector.
sudo ./rkdeveloptool rd                   //reset device

compile error help
if you encounter the error like below:
./configure: line 4269: syntax error near unexpected token `LIBUSB1,libusb-1.0'
./configure: line 4269: `PKG_CHECK_MODULES(LIBUSB1,libusb-1.0)'

You should install pkg-config libusb-1.0:
	sudo apt-get install pkg-config libusb-1.0