#nRF24LE1 AVRasp downloader
Consist of AVRasp firmware and command line utility. Command line required libusb (or libusb-win32 for windows). I have checked it for OS X only but it should work for Windows and Linux, will be happy for build for these platforms.
Command line:
- nrf24le1prog test - test nrf24le1 module by enabling and disabling write flag.
- nrf24le1prog write code <filename> - reads firmware from file and write to memory, before writing flash pages will be erased, only required pages will be processed so if firmware is 985 bytes length only 2 pages will be erased and programmed.
- nrf24le1prog read code <filename> - reads code meory (16kb) to file
- nrf24le1prog validate code <filename> - compare firmware in device and file, only first bytes will be compared if file length is less then 16kb
- nrf24le1prog erase code - erases all code pages, it's not erase all which can break device, it doesn't clear infopage and nvl memory
#How to build
- AVRasp - open console, go to avrasp folder, type make clean hex, requires avr-gcc in path. nrf24le1prog_asp.hex should be downloaded to AVRasp hardware.
- Command line utility - open console, go to prog folder, type make clean prog, requires libusb installed and added to path.
#Connect to nRF24LE1
#Thanks to
MaxMS for his http://homes-smart.ru and ideas for programming nRF24le1 using AVRasp.
Thomas Fischl for AVRasp, http://www.fischl.de/usbasp.
#Программатор для nRF24LE1 на основе AVRasp
Состоит из прошивки для AVRasp и утилиты командной строки. Последняя требует установленного libusb (libusb-win32 в случае Windows). Проверена для OS X, но должна работать для Windows и Linux, буду признателен, если кто-нибудь соберет и проверит для этих операционных систем.
Командная строка:
- nrf24le1prog test - проверяет nrf24le1 переключая разрешение на запись в регистре статуса, смотрим, чтобы была надпись SUCCESSED, в случае FAILED проверяем соединение или берем другой модуль.
- nrf24le1prog write code <filename> - записывает прошивку из файла, предварительно очищая страницы, будут очищены и записаны только необходимые страницы, т.е. если размер прошивки 980 байт, только 2 первые страницы будут очищены и записаны.
- nrf24le1prog read code <filename> - записывает содержимое памяти программы (16кб) в файл.
- nrf24le1prog validate code <filename> - сравнивает прошивку с содержимым файла, если рамер файла меньше 16кб - остаток игнорирется.
- nrf24le1prog erase code - очищает память программы (16кб), не затрагивая inforpage и nvl память, безопасна для устройства.
#Как собрать
- AVRasp - в консоли открыть папку avrasp, выполнить make clean hex, требует установленного avr-gcc, добавленного в PATH. После этого прошить nrf24le1prog_asp.hex с помощью avrdude.
- Утилита командной строки - в консоли открыть папку prog folder, выполнить make clean prog, требует libusb в переменной PATH.
#Подключить nRF24LE1
#Благодарности
MaxMS и его сайту http://homes-smart.ru
Thomas Fischl за AVRasp, http://www.fischl.de/usbasp.