Comments (6)
Hi Grzegorz,
thank you for your feedback. I have do admit that I'm not really using S12X any more, but I should still have a board somewhere. And I have used FreeRTOS with S12X only in a small project which was not banked (I believe), so it very well could be something I have missed. From your description it sounds that the Processor Expert code dealing with the tick interrupt should be different, and not sure what I have to change.
Could you provide the pice of source code you have changed so I can follow up on this? Maybe best with clear indication what you have changed where?
Thanks,
Erich
from mcuoneclipse.
Hi Erich,
I attach 2 modified and 2 original files, both generated by PE. Here's what happens in my understanding:
- TickCntr1_Interrupt occurs and program goes to ISR handler, PPAGE register stays intact
- ISR handler calls TickCntr1_OnInterrupt() with CALL instruction and PPAGE register may change if there are multiple flash pages used and this function is on different one than function when interrupt happened.
- portSAVE_CONTEXT macro is called and possibly incorrect PPAGE register is pushed on stack
- at the end of function portRESTORE_CONTEXT macro is called and possibly incorrect PPAGE value is pulled from stack and copied to register which results in jumping to random place in code
Solution would be to move portSAVE_CONTEXT macro to primary ISR handler - before function call(attached files), or move everything to ISR handler (and then remove code that fixes stack with LEAS instructions).
BR
Grzegorz Sobczyk
from mcuoneclipse.
Hi Grzegorz,
thanks for the extra details. I wanted to investigate this last weekend, but did not find the time. I hope because you have found a solution it is not that urgent?
Thanks,
Erich
from mcuoneclipse.
from mcuoneclipse.
You can disable the overwrite if you disable code generation for a component, see https://mcuoneclipse.com/2012/03/23/disable-my-code-generation/
from mcuoneclipse.
closing issue: for now disabling code generation should do it.
from mcuoneclipse.
Related Issues (20)
- FreeRTOS component fails to reload HOT 14
- SD_Card Component Doesn't allow selection of CS pin in SPIMaster_LDD HOT 1
- CodeWarrior 10.6 for MC9S08 C compiler don't have stdbool.h and stdint.h HOT 2
- InitUSB error with MKL26 with KSDK1.3 HOT 6
- CriticalSection bug HOT 10
- FreeRTOS compile issue HOT 13
- nRF24 project with KDS HOT 3
- Bad cast in gprof for arm HOT 3
- Weird Problem when snapshotting components HOT 2
- "Unknown macro" error when generating FreeRTOS component files HOT 1
- No re-enable interrupts HOT 2
- Don't name libraries this way! HOT 1
- Wifi driver for joystick HOT 1
- could you help me i meet a error when i use this script HOT 2
- SDRAM DCD Settings for the Arch Mix board HOT 1
- building tinyK22_RaspberryPi_UPS on linux: naming error HOT 1
- Cannot see anything in Image Info Tab of MCUXpressoIDE v11.2.1_4149? HOT 1
- minINI: writing to the sd card HOT 1
- McuSWO.c - SWO_PrintChar - The character is always sent to Stimulus port 0. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mcuoneclipse.