Arm Community
Site
Search
User
Site
Search
User
Groups
Arm Research
DesignStart
Education Hub
Graphics and Gaming
High Performance Computing
Innovation
Multimedia
Open Source Software and Platforms
Physical
Processors
Security
System
Software Tools
TrustZone for Armv8-M
中文社区
Blog
Announcements
Artificial Intelligence
Automotive
Healthcare
HPC
Infrastructure
Innovation
Internet of Things
Machine Learning
Mobile
Smart Homes
Wearables
Forums
All developer forums
IP Product forums
Tool & Software forums
Pelion IoT Platform
Support
Open a support case
Documentation
Downloads
Training
Arm Approved program
Arm Design Reviews
Community Help
More
Cancel
Developer Community
IP Products
Processors
Jump...
Cancel
Processors
Classic processors forum
SAM7X calling function from interrupt
Blogs
Forums
Videos & Files
Help
Jump...
Cancel
New
State
Not Answered
Replies
5 replies
Subscribers
1 subscriber
Views
3208 views
Users
0 members are here
Software
Arm7tdmi
Interrupt
Related
SAM7X calling function from interrupt
Offline
fjb2069 fjb2069
over 7 years ago
Note: This was originally posted on 5th November 2008 at
http://forums.arm.com
I am trying to use a timer interrupt to "Set up" a function call. INstead of setting a flag in the interrupt and then polling that flag I would like the interrupt to call a function as soon as teh interrupt is done, but not during the interrupt.
I tried setting a software (swi) interrupt to fire during the timer interupt, but the problem was that it called the software int immediatley during the timer IRQ and not after. I thought the swi was a lower priotrity int then the timer IRQ (set to priority 7), But I guess not...am I wrong????
Is ther a way to do this?
Possibley use a lower priority IRQ to call a function by "Setting" that IRQ during a higher priority IRQ ?
Parents
0
Offline
Jacob Bramley
over 7 years ago
Note: This was originally posted on 6th November 2008 at
http://forums.arm.com
In this case, you simply want a list of function pointers. When you want to register a DFC, you add a function pointer to the list. When you run one, you remove it from the list.
Things to consider:
The list can be a simple array, but you'll need extra variables to indicate free slots and the like. If I were you, I'd use either a linked list or an array-based circular buffer. Google will have plenty of information on both.
If you aren't familiar with function pointers, try Google. There's tons of information on the web.
Your DFCs will probably need some data, so you may need another list of data to provide to the functions. This is entirely dependent on your application, however.
Good luck :-)
Cancel
Up
0
Down
Reply
Accept answer
Cancel
Reply
0
Offline
Jacob Bramley
over 7 years ago
Note: This was originally posted on 6th November 2008 at
http://forums.arm.com
In this case, you simply want a list of function pointers. When you want to register a DFC, you add a function pointer to the list. When you run one, you remove it from the list.
Things to consider:
The list can be a simple array, but you'll need extra variables to indicate free slots and the like. If I were you, I'd use either a linked list or an array-based circular buffer. Google will have plenty of information on both.
If you aren't familiar with function pointers, try Google. There's tons of information on the web.
Your DFCs will probably need some data, so you may need another list of data to provide to the functions. This is entirely dependent on your application, however.
Good luck :-)
Cancel
Up
0
Down
Reply
Accept answer
Cancel
Children
No data
More questions in this forum
By title
By date
By reply count
By view count
By most asked
By votes
By quality
Descending
Ascending
All recent questions
Unread questions
Questions you've participated in
Questions you've asked
Unanswered questions
Answered questions
Questions with suggested answers
Questions with no replies
Answered
Program Counter, Stack Pointer and Link Register Status During an Interrupt Service in ARM based Processors
+1
3475
views
2
replies
Latest
over 1 year ago
by
Aman007kc
Answered
ARM Assembly how to print numbers instead of their ascii representation of that number
+1
Armv6
Arm Assembly Language (ASM)
5910
views
2
replies
Latest
over 1 year ago
by
Kanan Jarrus
Not Answered
Why there is no translation tables concatenation for stage 1 of VA translation?
0
1499
views
0
replies
Started
over 1 year ago
by
Uzi Shvadron
Answered
Arm Cortex-A8 program flow prediction
+1
Armv7-A
Cache
Out-of-order Execution
Cortex-A
1789
views
1
reply
Latest
over 1 year ago
by
Andy Neil
Suggested Answer
Shifted binary generated by arm-none-eabi-objcopy
0
GCC
Cortex-A
Cortex-M
Baremetal
4959
views
8
replies
Latest
over 1 year ago
by
en2senpai
<
>
View all questions in Classic processors forum