You don't need a new Netduino SDK for 4.2 RC2, but we do have a new firmware build. Testing now...
Chris
Hi,
Has the new netduino firmware finally been released?
  | ||||||||||||||
The Netduino forums have been replaced by new forums at community.wildernesslabs.co.
This site has been preserved for archival purposes only
and the ability to make new accounts or posts has been turned off.
Bobi's ContentThere have been 10 items by Bobi (Search limited from 27-September 23) #18579 .NET Micro Framework 4.2 RC2 releasedPosted by Bobi on 29 September 2011 - 09:30 AM in General Discussion
Hi, Has the new netduino firmware finally been released? #19405 KeilPosted by Bobi on 19 October 2011 - 11:41 AM in Netduino 2 (and Netduino 1)
Hi Chris, Can you please provide some more information about how can I use Atmel SAM-BA to deploy my Keil-compiled code? I have downloaded and istalled the latest SAM-BA version - 2.10 I've read the tutorial and some other internet resources but I even failed the SAM-BA start up screen where you have to select a usb device and the model of your target device. It fails to connect. I'm not sure if I enter the usb device correctly - \usb\Netduino. It complains that it has failed to open a connection. My development computer is running 64bit Windows 7 and in the Devices Manager I saw that the usb device where my netduino is connected has the name "Netduino". On the atmel site I saw that their SAM-BA supports 64bit Win7 so that shouldn't be a problem. Another question - isn't it possible to build my Keil-compiled code in a way that I can deploy it on the Netduino using the MFDeploy tool? Thanks very much in advance! #19518 KeilPosted by Bobi on 21 October 2011 - 11:10 AM in Netduino 2 (and Netduino 1)
Hi Chris,
thanks a lot for your reply! I worked it out and it is awesome. I also tried the IAR environment and for the last couple of days I'm exploring one of the freeRTOS TCP/IP demos for AT91SAM7X. It creates a web server wich I maneged to get running on my netduino Now I'm trying to figure out how it works. It uses the uIP TCP/IP stack and the dosumentation is not very clear...
I'll be glad if you or someone else could share some experience about the uIP stack. I want to hadle HTTP POST requests in the server application. It seems to work fine with the GET requests... I don't see what's the difference. When I send a POST request in Fiddler I can see that the server returns http status code 504.
Thanks very much in advance!
#20362 FreeRTOSPosted by Bobi on 08 November 2011 - 08:17 AM in Netduino Plus 2 (and Netduino Plus 1)
This sounds awesome! Could you make available some code samples or anything else... about how is it possible to handle button interrupts. For the last many days I've been trying to create a simple freeRTOS program where I have one blinking LED and when you press the onboard button I want to handle the interrupt and set the LED off. What I've tried so far was to get the SAM7x512 Getting Started example from Atmel and their demo worked perfectly fine. Then I tried to do the same thing in one of the freeRTOS demos but it seems that the port is not the same and I don't know how to configure my interrupt correctly. #20410 FreeRTOS handling hardware interruptsPosted by Bobi on 09 November 2011 - 02:32 PM in Netduino Plus 2 (and Netduino Plus 1)
Hello,
I want to run a FreeRTOS program on my Netduino plus board. I'm working on the ARM7 uIP demo for IAR (uIP_Demo_IAR_ARM7) that's provided with the FreeRTOS source code. I know that this may be an easy question but I have lost too much time trying to do it on my own. I want to be able to handle PIO button interrupts. The netduino has an onaboard button (PA29) and I want to initialise and handle the interrupts so that when you press the button the onboard LED (PB23) will turn ON. I want to achieve this using the provided FreeRTOS at91sam7x256 port. I already have it working with the demos which come from the Atmel site but they use a very different port which fails to work together with the FreeRTOS. I want to use the FreeRTOS port because the main goal of the application will be far different from turning LEDs on and off. Here is my code: First in board.h I have defined that LED1 is (1 << 23) and SW1 is (1 << 29). I have the following interrupt handler, which will turn the onboard LED ON: void Handler(void) { if( AT91F_PIO_GetInput( AT91C_BASE_PIOA ) & LED1 ) { AT91F_PIO_ClearOutput( AT91C_BASE_PIOA, LED1 ); } else { AT91F_PIO_SetOutput( AT91C_BASE_PIOA, LED1 ); } } And in the prvSetupHardware function I have added the following: AT91F_PIO_CfgInput( AT91C_BASE_PIOA, SW1 ); AT91F_PIO_CfgPullup( AT91C_BASE_PIOA, SW1 ); AT91F_PIO_CfgInputFilter( AT91C_BASE_PIOA, SW1 ); AT91F_AIC_ConfigureIt(AT91C_BASE_PIOA, AT91C_ID_PIOA, 0x07, 0x0, Handler); AT91F_AIC_EnableIt(AT91C_BASE_PIOA, AT91C_ID_PIOA); And here I am confused about am I initializing the interrupt properly? As long as the button belongs to PA29 I know that I have to use the AT91C_BASE_PIOA when I make the call to AT91F_AIC_ConfigureIt. And here I am not sure about the irq_id parameter. Should it be 29 (as I am using PA29) or should it be AT91C_ID_PIOA? And if its AT91C_ID_PIOA where should I specify that I want to handle intterupts coming from PA29? Thanks #20415 FreeRTOS handling hardware interruptsPosted by Bobi on 09 November 2011 - 03:33 PM in Netduino Plus 2 (and Netduino Plus 1)
Hi, Ok great and do you think that the interrupt initialization is OK then, because when I press the button nothing happens? Is there any way to debug your code when it's running on the netduino if you don't have a jtag? #20418 FreeRTOS handling hardware interruptsPosted by Bobi on 09 November 2011 - 04:59 PM in Netduino Plus 2 (and Netduino Plus 1) Hi, Thanks for the fast reply! It looks perfectly fine to me now but it still doesn't work. What am I misssing? #define PIO_INTERRUPT_LEVEL 0x7 #define AT91C_AIC_SRCTYPE_EXT_NEGATIVE_EDGE ((unsigned int) 0x1 << 5) void Handler(void) { AT91F_PIO_ClearOutput( AT91C_BASE_PIOB, LED1 ); // turn LED OFF } static void prvSetupHardware( void ) { AT91F_PIO_CfgOutput( AT91C_BASE_PIOB, LED1 ); AT91F_PIO_SetOutput( AT91C_BASE_PIOB, LED1 ); // turn LED ON AT91F_PMC_EnablePeriphClock( AT91C_BASE_PMC, 1 << AT91C_ID_PIOA ); AT91F_PMC_EnablePeriphClock( AT91C_BASE_PMC, 1 << AT91C_ID_PIOB ) ; AT91F_PIO_InterruptEnable(AT91C_BASE_PIOA, 1 << AT91C_ID_PIOA); AT91F_PIO_CfgInput( AT91C_BASE_PIOA, SW1 ); AT91F_PIO_CfgPullup( AT91C_BASE_PIOA, SW1 ); AT91F_PIO_CfgInputFilter( AT91C_BASE_PIOA, SW1 ); AT91F_AIC_ConfigureIt(AT91C_BASE_PIOA, AT91C_ID_PIOA, PIO_INTERRUPT_LEVEL, AT91C_AIC_SRCTYPE_EXT_NEGATIVE_EDGE, Handler); AT91F_AIC_EnableIt(AT91C_BASE_PIOA, AT91C_ID_PIOA); } I'm not aboslutely sure about the PIO_INTERRUPT_LEVEL value. In the documentation they say that its between 0(lowest) and 7(highest). Otherwise this is what you mean, right? #20424 FreeRTOS handling hardware interruptsPosted by Bobi on 09 November 2011 - 06:54 PM in Netduino Plus 2 (and Netduino Plus 1)
OK, I did this and now when I deploy the bin file on the Netduino and connect it in my Computer I see an instant flash and the LED stays ON and when you press the button nothing happens. There must be something else... ? How is the right way to read the PIO_ISR register? Should I simply say: if(PIO_ISR == 29){ // ... } #20451 FreeRTOS handling hardware interruptsPosted by Bobi on 10 November 2011 - 02:27 PM in Netduino Plus 2 (and Netduino Plus 1)
Hi, thanks for your replies! I already have a working demo of the same functionality which was included in the Getting Started Tutorial I got from Atmel. It works perfectly fine and the code looks like executing exactly the same steps except that they are using a different port. FreeRTOS have implemented their own port and one solution I can think of is to get FreeRTOS running with the Atmel port for sam7x512. #20603 FreeRTOS handling hardware interruptsPosted by Bobi on 14 November 2011 - 10:16 AM in Netduino Plus 2 (and Netduino Plus 1)
Hi, I found the problem!!! It works great now.
There are a few things which need to be done:
In my case - I needed a context switch, so I had to create a DriverISR.s79 assembler file where I execute portSAVE_CONTEXT call the ISR routine portRESTORE_CONTEXT And this is all FreeRTOS specific (this is also described in the demo from the link above). Best Regards, Bobi
| ||||||||||||||
|
||||||||||||||
This webpage is licensed under a Creative Commons Attribution-ShareAlike License. | ||||||||||||||