-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
40 lines (31 loc) · 1.79 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
lpicp: The embedded Linux PIC programmer
Copyright (c) 2011 Eran Duchan <[email protected]>
http://www.pavius.net/2011/06/lpicp-the-embedded-linux-pic-programmer
---------------------------------------------------------------------
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License, version 2, as
published by the Free Software Foundation.
---------------------------------------------------------------------
:: About
lpicp allows reading/writing/erasing the program, configuration and eeprom memory of
PIC devices from an embedded Linux environment. It allows you to turn any board running
embedded Linux with 4 spare GPIOs into a PIC programmer.
lpicp currently only supports a small set of PIC devices (PIC18F2xx/4xx and PIC18F2xxx/4xxx)
but is extendable in such a way that keeps all device-specific code in device-specific modules
(e.g lpicp_dev_18f_2xx_4xx.c). As more devices are supported, the shared code will undoubtedly
change but will still atempt to eliminate the zillion "if (device == DEV_ID) {} else {}" that
plague so many PIC programmers.
lpicp requires a custom ICSP kernel driver compiled into the kernel and instantiated with:
> mknod /dev/icsp0 c 245 0
:: More info and kernel driver
http://www.pavius.net/2011/06/lpicp-the-embedded-linux-pic-programmer
:: Compiling
The build environment supports both running on x86 (for testing purposes, without the ICSP
driver) and ppc, but more support can be added as needed by writing a cmake script.
To compile debug load for ppc:
- cd to build/ppc/debug
- cmake ../.. -DCMAKE_TOOLCHAIN_FILE=../tc-eldk-ppc-8xx.cmake -DCMAKE_BUILD_TYPE=Debug
- make
:: For future versions
- Program at offset/selective program
- Dump from device to HEX file (currently only prints the data to stdout)