Hi Mamim
1. In
Port_Interrupts.h you can find a define called
IRQ_TEST
. If you enable this (and
SUPPORT_EPORT is enabled) you can see a reference for setting up and using EPORT interrupt.
interrupt_setup.int_port_sense = IRQ_BOTH_EDGES; // interrupt on this edgecan be set to interrupt on rising, falling or both edges.
Run this is the VS simulator so that you can test the interrupts and your own handling.
See the guide
http://www.utasker.com/docs/uTasker/uTaskerADC.pdf for using the ADC.
In the file
ADC_Timers.h there are ADC and timer examples which you can use to sample the input periodically. Timers are described in
http://www.utasker.com/docs/uTasker/uTaskerHWTimers.PDF2. Once you have the sample values this is a standard software exercise.
3. The reference project includes a command line interface on a UART. Change
DEMO_UART to another UART number if required.
The UART documentation is in
http://www.utasker.com/docs/uTasker/uTaskerUART.PDF The initialisation can be found in
application.c (
fnSetNewSerialMode()) and the command line interface and its menus are in
debug.c.
You can extend the menus with your own commands or use a second UART with your own protocol.
With
ETH_INTERFACE and
USE_UDP
you will have UDP available. See
DEMO_UDP in application.c for a USD echo demonstration which you can adapt to send your own messages.
4. The reference project can be configured by defines in
config.h and
app_hw_m522xx.h so any parts that you don't require can be disabled.
I recommend making a copy of the directory
\Applications\uTaskerV1.4 and renaming it to your own project name- they work in that instead. Then you can also delete any code that you don't require without losing the reference project content which will probably be needed again at some point.
Remember that you can completely simulate the operation in Visual Studio so make use of this to simplify and speed development and learning. It is much more efficient and powerful that HW target debugging and gives you the opportunity to develop better and faster than others who limit themselves to only HW debugging. Use the tutorial
http://www.utasker.com/docs/M5223X/uTaskerV1-4_M522XX.PDF to start.
Regards
Mark