before merging master
[inav.git] / src / utils / combine_tool
blob155738856755715e6b67ea769540be3ad7de68ab
1 #!/usr/bin/env ruby
3 ##
4 ## This file is part of INAV.
5 ##
6 ## INAV is free software. You can redistribute this software
7 ## and/or modify this software under the terms of the
8 ## GNU General Public License as published by the Free Software
9 ## Foundation, either version 3 of the License, or (at your option)
10 ## any later version.
12 ## INAV is distributed in the hope that they will be
13 ## useful, but WITHOUT ANY WARRANTY; without even the implied
14 ## warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15 ## See the GNU General Public License for more details.
17 ## You should have received a copy of the GNU General Public License
18 ## along with this software.
20 ## If not, see <http://www.gnu.org/licenses/>.
23 require_relative 'intelhex'
25 ih = IntelHex.new
26 ih.add_section 0x08000000, File.open(ARGV[0], 'rb')
27 ih.add_section 0x08008000, File.open(ARGV[1], 'rb')
28 ih.start_address = 0x08000000
29 ih.write File.open(ARGV[2], 'w')